• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

[Trigger] no tomes?

Status
Not open for further replies.
Well, you need to trigger it.

Events
A unit starts the effect of an ability
Conditions
Ability being cast Equal to (Your summoning ability)
Actions
Set Point1 = (Position of (Casting unit))
Unit - Create 1 Pack Mule for (Owner of (Triggering unit)) at Point1 facing defaulkt building degrees
Unit - Add X.00 seconds Generic expiration timer to (Last created unit)
Custom script: call RemoveLocation (udg_Point1)

Events
A unit acquires an item
Conditions
((Unit-type of (Hero Manipulating Item)) Equal to Pack Mule
(Item-type of (Item being Manipulated)) Equal to Tome of Experience)
Actions
Set Point2 = (Position of (Hero Manipulating Item))
Unit - Order (Hero Manipulating Item) to drop (Item being manipulated) at Point2
Custom script: call RemoveLocation (udg_Point2)




Edit: It doesn't work. Sorry.


Edit2:

Events
Unit - A unit Is issued an order targeting an object
Conditions
(Unit-type of (Ordered unit)) Equal to Pack Horse
(Item-type of (Target item of issued order)) Equal to Tome of Experience
Actions
Unit - Order (Ordered unit) to Stop

This?

Edit3: Neither this can work. I reeeeeeally don't know.
 
Level 8
Joined
Mar 12, 2008
Messages
437
I assume you gave the pack mule an inventory?
The inventory is the hero inventory (Which allows the unit to buy and use items). Copy the ability [creating a new one] and remove the flag that allows the unit to buy items [from the ability]
And be sure to give your unit the new inventory ability, instead of the other one.

"Can get items", that is?

But that removes the capability of purchasing items, doesn't it?
 
"Can get items", that is?

But that removes the capability of purchasing items, doesn't it?
Well it eliminates the buildings ability to select the unit as a hero. "Can get items" keeps units from giving that unit items, i believe. I think what might be causing the crash, is that the unit has items when it's expiration timer 'expires'. Which would make the items disappear into oblivion.
So maybe an expiring pack horse would be a bad idea.
Maybe you could have a pack horse vendor. and make units drop items once they enter a region or something.
 
Which is what i was suggesting at first. Making the hero inventory a unit inventory. That cannot USE items. I was misunderstood. Maybe because I didn't make myself clear.
And for the misconception, the hero inventory is a unit ability because it is not supposed to be levellable. Hero abilities are castable and levellable abilities (for the most part). Unit abilities are normally just general abilities given to the unit.
 
Level 20
Joined
Oct 21, 2006
Messages
3,230
Make FAKETOMES and REALTOMES.

When unit acquires FAKETOMEOFAGILITY then do nothing.
When hero acquires FAKETOMEOFAGILITY then remove FAKETOMEOFAGILITY from the game and create item REALTOMEOFAGILITY for hero-manipulating-item.

FAKETOMES are just items without any abilities, they just have same icon as normal tomes.
 
Level 3
Joined
Apr 8, 2009
Messages
63
Make a tome that do nothing and don't auto-use, if a unit pick it upn then do nothing, if a hero pick it up, then delete this fake tome and add XXX exp / str / int / agi to the hero
 
Level 7
Joined
Feb 1, 2008
Messages
296
The answer to your solution is very simple. If you want the mule to carry but not be able to use items, create another inventory(hero) ability and check off the box that says "Can use items". If you want the mule to use items but not get tomes, the answer is very easy as it is a simple trigger.
  • Tome
  • Events
    • Unit - A unit uses an item
  • Conditions
    • Borlean - (Hero Manipulating Item) is a hero equal to true
  • Actions
    • If (Item type of (Item Being Manipulated) equal to Tome of Strength then (Hero - Set strength of (Hero Manipulating Item) to (Strength of (Hero Manipulating Item) + <Wanted Value>)
As you can see, you can easily change the item type and the attribute type without mistakes. Sorry about the icons, I cant seem to remember the correct name of the triggers but its close.
 
Level 14
Joined
Nov 20, 2005
Messages
1,156
I assume you gave the pack mule an inventory?
The inventory is the hero inventory (Which allows the unit to buy and use items). Copy the ability [creating a new one] and remove the flag that allows the unit to buy items [from the ability]
And be sure to give your unit the new inventory ability, instead of the other one.

QFT.

So shut the heck up with your wrong information.
 
Status
Not open for further replies.
Top