tommerbob
Minecraft. :D
- Reaction score
- 110
1.
My goal: Heroes can carry only 1 of each item class/type. They can carry only 1 weapon, 1 armor, 1 helm, 1 ring....etc.
I've seen rpg maps where they've done this. I'm trying to achieve something like Ace's Item Restrictions, but I want a vJass system that is efficient and can handle lots of items without lots of code.
What's the best way to implement it? I looked through kingking's Advanced Item Indexing and Unit Inventory Data, but they look like they handle only individual items, not item classes, which is what I want.
My initial thought about the best way to do it: Make all weapons "artifacts", all armors "permanent", all rings "miscellaneous", etc. Then when the item is acquired, I check if the hero is already carrying an item of that same class. Is this the best way?
2.
I've seen maps that use backpack systems, such as Gaia's Retaliation. They use an extra hero as the "backpack". Are there any systems around for this type of thing? I assume its just creating a hero with no model, and using a high-frequency timer, periodically move the backback unit to the same position as the hero?
My goal: Heroes can carry only 1 of each item class/type. They can carry only 1 weapon, 1 armor, 1 helm, 1 ring....etc.
I've seen rpg maps where they've done this. I'm trying to achieve something like Ace's Item Restrictions, but I want a vJass system that is efficient and can handle lots of items without lots of code.
What's the best way to implement it? I looked through kingking's Advanced Item Indexing and Unit Inventory Data, but they look like they handle only individual items, not item classes, which is what I want.
My initial thought about the best way to do it: Make all weapons "artifacts", all armors "permanent", all rings "miscellaneous", etc. Then when the item is acquired, I check if the hero is already carrying an item of that same class. Is this the best way?
2.
I've seen maps that use backpack systems, such as Gaia's Retaliation. They use an extra hero as the "backpack". Are there any systems around for this type of thing? I assume its just creating a hero with no model, and using a high-frequency timer, periodically move the backback unit to the same position as the hero?