Item Carry System

KingJohn

New Member
Reaction score
0
Hey guys, I would really appreciate if you could help me with my special problem.
Assuming, a creep drops an item, which is a sword.
A blademaster can pick it up, and the item attributes are granted, for example +6 agility.
A healer shall also be able to pick it up, but won't benefit from the agility bonus, but is still able to bring it to a shop and sell it.
This could be done with dummy items, which I want to avoid.
I don't have my heroes organized in classes like in WoW, so I would write triggers for each hero:
Hero 1 - Item A and Item B benefits you, Item C doesn't
Hero 2 - Item A and Item C benefits you, Item B doesn't
and so on.
Had something like "disable the ability of an item" in my mind, don't know if it's possible.

My two alternatives that I can trigger myself would be:
1. A hero is only able to pick up the right items for it, wrong ones will be dropped instantly (which will result in hundreds of items laying around until someones pick it up)
2. Wrong ones can be picked up, too, but will be sold instantly (which isn't very realistic and things like "oh, an purple epic item, let's pick it up, whoops it's gone, hey, why are you mad, Axe Master? - oh it was the item you were waiting for dropping for two months, I see!" could happen"

Hope there is a simple solution that I overlooked.
Thanks in advance!
 

Zorobay

Member
Reaction score
1
I guess it would be possible to use tomes instead. The item dropped can be a tome, and the effects will be gained, and when the hero picks it up, use a trigger that gives the hero the real item (that has no effects on it). But a problem still persists. I don't really know how you would make the tomes act different depending on your hero... I will have to wait until after work to help you further
 

KingJohn

New Member
Reaction score
0
Well, thank you once already, the tome idea is a good food for thoughts. What I didn't get is, a tome's bonus is permanent. How do you remove the effect, when the Hero drops or switches his weapon? Of course you can trigger it for every item, but then you could also use dummy items, the effort amounts to the same thing.
I would be looking for a simple "disable item's attributes" function, if that's possible.

A third idea that has come to my mind last night:
Heroes may only pick up the items destined for them. If an item lays on the ground untouched for two minutes for example, it will be sold, and the gold amount is splitted up to the group.
Disadvantage: Players aren't motivated to pick up stuff to sell it at the shop anymore, since it will be done anyways..
So much options, so much agony!

Would be great, if you think further about it after your work.
Thanks!
 

KaerfNomekop

Swim, fishies. Swim through the veil of steel.
Reaction score
612
What Zorobay means by tomes are dummy items with tome abilities. Tomes can be picked up at any time (even with a full inventory) and their ability is used once you pick them up.

You could detect the ability being used, and compare it with the unit's type to see if the unit can pick up the real item. If it can, create the real item and place it into the unit's inventory; if not, create a dummy item that does nothing instead.
 

KingJohn

New Member
Reaction score
0
What Zorobay means by tomes are dummy items with tome abilities. Tomes can be picked up at any time (even with a full inventory) and their ability is used once you pick them up.

Okay, I think I get that, but what's the advantage of being able to pick an item up with a full inventory? Why don't I just use a trigger, that detects the item picked up and either do nothing, if it's the appropriate hero or replace it with a dummy one without abilities, but with the same icon and price, if it's an inappropriate hero?

You could detect the ability being used, and compare it with the unit's type to see if the unit can pick up the real item. If it can, create the real item and place it into the unit's inventory; if not, create a dummy item that does nothing instead.

That would work of course, but it's just the other way round I described up there.
I guess it's not possible to simply deactivate the abilites of an item.
Thank you nonetheless!
 

maxou

You can change this now in User CP.
Reaction score
15
If you have a sword that gives +6 agility, create another sword, that give nothing, with same icon but in tooltip, add something in red like : |cffff0000You can't use this item!|r, by this way, it looks like you have the sword +6 agility, but you can't use it, you don't have its bonus, then you use a trigger to check if the item can be holded by your unit, if he can't, remove the sword +6 agility, and create a fake sword +6 agility for your heroe (be sure to have the same price on both swords)
Then, if he drops the fake swords, remove it and create a real sword, and here you are ! :)
You don't even need to detect an ability, just the 'acquire an item' 'loses an item' event are required :p
If you want more I can do an exemple system for you :)
 

KaerfNomekop

Swim, fishies. Swim through the veil of steel.
Reaction score
612
Why don't I just use a trigger, that detects the item picked up and either do nothing, if it's the appropriate hero or replace it with a dummy one without abilities, but with the same icon and price, if it's an inappropriate hero?
Because then you can complete recipes with a full inventory.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top