• 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] custom spell problem

Status
Not open for further replies.
Level 7
Joined
Mar 29, 2009
Messages
139
Hi, im gonna make a unit cast a custom spell at a unit and it doesn't work.
I tried everything!
The spell is Life Drain.
This is the trigger i use:
  • L1a
    • Events
      • Unit - A unit enters L1a <gen>
    • Conditions
    • Actions
      • Unit - Order Spell Caster 0002 <gen> to Neutral Dark Ranger - Life Drain Mazer 0001 <gen>
I tried the spell on a unit i controlled and used it on an enemy. it worked.
But when i use the trigger, nothing happens. Neutral Dark Ranger - Life Drain is the spell i used from the bottom. It should be right. I'm so confused!

Some help? +rep to first and correct answer :)
 
Level 11
Joined
Feb 14, 2009
Messages
884
Your current trigger causes your Spell Caster to cast Life Drain to Mazer when a unit enters L1a. If no unit enters your region, the trigger won't work. The following trigger will cause Spell Caster to drain the unit entering L1a. Not sure if that's what you need though...

  • Events
    • Unit - A unit enters L1a <gen>
  • Conditions
  • Actions
    • Unit - Order Spell Caster 0002 <gen> to Neutral Dark Ranger - Life Drain (Triggering unit)
 
Level 11
Joined
May 16, 2007
Messages
288
Possible things that are causing this problem:

- The unit doesn't have a life drain ability to cast.
- The unit cannot move and the target is too far away.
- The unit doesn't have enough mana to cast it.
- The unit isn't an enemy of the target unit (drain life is hardcoded and will only hit enemy units, no matter what).
 
Level 7
Joined
Mar 29, 2009
Messages
139
Possible things that are causing this problem:

- The unit doesn't have a life drain ability to cast.
- The unit cannot move and the target is too far away.
- The unit doesn't have enough mana to cast it.
- The unit isn't an enemy of the target unit (drain life is hardcoded and will only hit enemy units, no matter what).

I got a trigger that makes the unit learn the ability.
The unit is very close and i set range to 1000 and area of effect to 1000.
Manacost: 0
The targetted unit is the player's unit (Player 1(red)) and the unit that targets is the computer (Player 4(Purple)). I also checked that the computer is an enemy.
 
Level 9
Joined
May 27, 2006
Messages
498
Try giving the casting unit the life drain ability through the Object Editor, maybe the ability-learn trigger is failing somehow.
Also, check in-game if you can target the enemy with life drain. Place the caster unit on map, set the owner to red so that you can control it and give it the life drain. Then try to target an enemy with the spell and see if you get any error messages like "cant target unit" or sthing.
I've had lots of errors with this ability and this simple test really solved the problem.
 
Level 7
Joined
Mar 29, 2009
Messages
139
Try giving the casting unit the life drain ability through the Object Editor, maybe the ability-learn trigger is failing somehow.
Also, check in-game if you can target the enemy with life drain. Place the caster unit on map, set the owner to red so that you can control it and give it the life drain. Then try to target an enemy with the spell and see if you get any error messages like "cant target unit" or sthing.
I've had lots of errors with this ability and this simple test really solved the problem.

Nope!

The problem is pretty weird. I tested the trigger with my units. No text appears. And the ability is learned.
 
Level 11
Joined
Feb 14, 2009
Messages
884
Well, since it's not complete yet, why would anybody steal it? Besides, users in Hive don't tend to uhm... steal maps. I suggested that because nobody seems to be able to find a solution, so I thought that if one has your map, he/she can help you better.
 
Status
Not open for further replies.
Top