• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Question about quests

Sam Drost

Intermediate OT User
Joined
May 29, 2017
Messages
88
Reaction score
118
So in real Tibia, things like the Fanfare quest give you an item once. Is there a way to do something similar, but it always gives you the item, or, if duplicating the item is a concern, only gives you the item if you don't have it in your inventory, and if it you have it in your depot, it gives you the item and then removes it from your depot? Obviously wouldn't do too well for equipment, but I'm more thinking about things like keys where losing the key somehow means you can never open that door again.
 
It would probably be smarter to just keep that key unique to the player (such as keeping the GUID of the player unique to the key as an action id) rather than keeping track of it at all times trying to avoid duplicates.
 
If we're talking strictly about "Key" type items, then you could do something similar to the Black Bert NPC, where if you've lost a certain key- you say that "Keys name" the NPC checks if you've done the quest & if so, allows you to buy a replacement key.
In instances like this though it's best just to make the chest give out the key once a day, these kinds of chests exist in real tibia for certain items that are required for a quest.

If you're talking strictly about "Unique items" like Fanfare, I see no reason why it's your fault that the player lost his item, that's the unique thing about Tibia, shit happens.
 
It would probably be smarter to just keep that key unique to the player (such as keeping the GUID of the player unique to the key as an action id) rather than keeping track of it at all times trying to avoid duplicates.

I'm not saying keep track of it at all times. What I'm saying is that I have a chest that gives the key. Before the chest gives the key, it simply checks the player's inventory and their depot. If the key exists in their inventory, it gives nothing. If the key exists in their depot, it removes it and adds it to their inventory. That way I keep track of it only when it matters.

I know absolutely nothing about how the server works, and so while I am playing around how I would do certain things in my head, I am asking questions to see if the ideas in my head are feasible.

If you're talking strictly about "Unique items" like Fanfare, I see no reason why it's your fault that the player lost his item, that's the unique thing about Tibia, shit happens.

Of course it is not my fault that the player lost their item. It is my fault to have that possibility and not design for it. If my design is "tough. you should have kept better track of it" that is still a design. Personally, I don't particularly care for that "feature" of Tibia, and if there is a way to design it differently, I am for that.
 
I'm not saying keep track of it at all times. What I'm saying is that I have a chest that gives the key. Before the chest gives the key, it simply checks the player's inventory and their depot. If the key exists in their inventory, it gives nothing. If the key exists in their depot, it removes it and adds it to their inventory. That way I keep track of it only when it matters.

I know absolutely nothing about how the server works, and so while I am playing around how I would do certain things in my head, I am asking questions to see if the ideas in my head are feasible.



Of course it is not my fault that the player lost their item. It is my fault to have that possibility and not design for it. If my design is "tough. you should have kept better track of it" that is still a design. Personally, I don't particularly care for that "feature" of Tibia, and if there is a way to design it differently, I am for that.
What about houses?
If you add houses to the equation, it can become pretty costly and could cause lag, but I don't see why you wouldn't include houses because you'd also be able to store said key inside your house (or even someone else's, which is another issue).
 
Of course it is not my fault that the player lost their item. It is my fault to have that possibility and not design for it. If my design is "tough. you should have kept better track of it" that is still a design. Personally, I don't particularly care for that "feature" of Tibia, and if there is a way to design it differently, I am for that.

That's true, but then the item no longer becomes unique- it loses it's sense of worth, what stops a player from just giving this item away? Only to pick it up again later, this makes it meaningless for others to do the quest as they can just obtain one from their friend- or is the system keeping track of the item & only generating a new one if they actually lose it due to a floor clean?
It seems like you're actually trying to fight a fundamental part of tibia, rather than a simple "feature" you disagree with.

Obviously the choice of how you handle it is your own of course, I think it's an odd feature of Tibia to disagree with though- You could go down the World of Warcraft route & have these items "Bind" to the character, similar to how the "Store Bag" works in real tibia, that way they can't drag it out of their Depo/Backpack but that doesn't really work with an item such as the Fanfare as it's purpose is a decorative item, which your system defeats the point of in a sense due to the house system, you can't possibly keep track of whether said person lost this item- if you can easily replace it you risk flooding the game with it & then it loses the reason why it's unique in the first place.

Edit: Actually having it bind to the character solves the issue entirely, you'd have it work exactly how decorative items from the store page work, you can only "Unpack it" inside a house, that way it isn't possible for the "player" to actually lose the item in the first place.
This also means on death they do not lose the item, as you don't drop bound items & it also means they'll always have it with them or in their Depo.

I see no reason why you couldn't do this with any item you didn't want people to "lose". Obviously it knocks out the value still as it would no longer become tradable but I get the idea that's what you're going for, because I don't think you can have the system you want but also allow it to be tradable in anyway.
 
Last edited:
Actually having it bind to the character solves the issue entirely, you'd have it work exactly how decorative items from the store page work, you can only "Unpack it" inside a house, that way it isn't possible for the "player" to actually lose the item in the first place.
This also means on death they do not lose the item, as you don't drop bound items & it also means they'll always have it with them or in their Depo.

I see no reason why you couldn't do this with any item you didn't want people to "lose". Obviously it knocks out the value still as it would no longer become tradable but I get the idea that's what you're going for, because I don't think you can have the system you want but also allow it to be tradable in anyway.

That is exactly what I want. Thanks. Is that feature supported for all versions? Or do I need to pick a specific version of the server to use that?

What about houses?
If you add houses to the equation, it can become pretty costly and could cause lag, but I don't see why you wouldn't include houses because you'd also be able to store said key inside your house (or even someone else's, which is another issue).

You are correct. I had not thought about houses, or other people's houses.
 
That is exactly what I want. Thanks. Is that feature supported for all versions? Or do I need to pick a specific version of the server to use that?

That'd be a question for someone else, can't help you with that one sorry.
I'm a RL tibia player, rarely play OTs nowadays except super custom ones.

My guess would be whatever server is designed for protocol 11.00 and up of Real Tibia, I don't think you can get one for client version 12.00 as it's an entirely new client but I've actually no fking idea.
 
That is exactly what I want. Thanks. Is that feature supported for all versions? Or do I need to pick a specific version of the server to use that?
There is no such feature, you have to code it yourself
 
Not knowing how the structure of everything is, I am going out on a limb here, but I would assume this would accomplish my goal:
  • Add a flag to an item
  • Check an item when it is being moved out of inventory. If it is flagged, check to see where it is being moved and cancel the move if the destination is not allowed
  • On death nullify the chances of that item being lost
Is that something that can be done in Lua or will I need to modify the source code and recompile?

I do have some programming background, but I've never looked at Lua. I think I could probably accomplish it in Lua, if that is possible.

For C++, though, I haven't touched it in decades and when I look at sources today, I cannot wrap my head around it anymore. Also, the last C++ compiler I had produced 32-bit binaries for MS-DOS.
 
Back
Top