ninjaalamode
New Member
- Reaction score
- 0
I need help getting these four triggers to work. They're for a hero based custom game I'm making. The first gives you your hero picking unit (but it doesn't select it), the second creates the hero at the starting region (but again, the hero is not selected). The third and fourth triggers are two spells that go together, the third damages the enemy, and creates a unit at the targeted enemy (but the trigger doesn't seem to turn off after it is used, and doesn't seem to turn on the fourth trigger), and then the forth is on the created unit, it calls back the created unit... but the fourth does not work, or rather, because of the third not working it is never on, and thus cannot work.
Also, I need some help with the abilities themselves, (I used channeling as the base) the hero ability shows up green when selecting it after a level-up, and when using it it does not add the stunned (pause) buff (2 seconds).
Code:
Spawn Hero Picker Red
Events
Map initialization
Conditions
(Player 1 (Red) controller) Equal to User
Actions
Unit - Create 1 Hero Picker for Player 1 (Red) at (Center of Hero Picker <gen>) facing Default building facing degrees
Unit Group - Add (Last created unit) to (Units currently selected by Player 1 (Red))
Camera - Pan camera for Player 1 (Red) to (Center of Hero Picker <gen>) over 0.00 seconds
Code:
Guido Mista
Events
Unit - A unit enters Pick Guido Mista <gen>
Conditions
((Owner of (Entering unit)) controller) Equal to User
Actions
Unit - Remove (Entering unit) from the game
Unit - Create 1 Guido Mista for (Owner of (Entering unit)) at (Center of Hero Start <gen>) facing Default building facing degrees
Set GuidoMista = (Last created unit)
Camera - Pan camera for (Owner of GuidoMista) to (Position of GuidoMista) over 0.00 seconds
Unit Group - Add (Last created unit) to (Units currently selected by (Owner of GuidoMista))
Unit - Create 1 Sex Pistols 1 for Player 12 (Brown) at (Center of Sex Pistols loaded <gen>) facing Default building facing degrees
Set SexPistols[1] = (Last created unit)
Unit - Create 1 Sex Pistols 2 for Player 12 (Brown) at (Center of Sex Pistols loaded <gen>) facing Default building facing degrees
Set SexPistols[2] = (Last created unit)
Unit - Create 1 Sex Pistols 3 for Player 12 (Brown) at (Center of Sex Pistols loaded <gen>) facing Default building facing degrees
Set SexPistols[3] = (Last created unit)
Unit - Create 1 Sex Pistols 5 for Player 12 (Brown) at (Center of Sex Pistols loaded <gen>) facing Default building facing degrees
Set SexPistols[5] = (Last created unit)
Unit - Create 1 Sex Pistols 6 for Player 12 (Brown) at (Center of Sex Pistols loaded <gen>) facing Default building facing degrees
Set SexPistols[6] = (Last created unit)
Unit - Create 1 Sex Pistols 7 for Player 12 (Brown) at (Center of Sex Pistols loaded <gen>) facing Default building facing degrees
Set SexPistols[7] = (Last created unit)
Code:
Stand Shoot Sex Pistols
Events
Unit - A unit Begins casting an ability
Conditions
(Ability being cast) Equal to Stand Shoot- Sex Pistols
Actions
Unit Group - Pick every unit in (Units in Sex Pistols loaded <gen>) and do (Actions)
Loop - Actions
Set LoadedSexPistol = (Random unit from (Last created unit group))
Unit - Cause (Casting unit) to damage (Target unit of ability being cast), dealing (Random real number between 1.00 and 10.00) damage of attack type Spells and damage type Normal
Unit - Move LoadedSexPistol instantly to (Position of (Target unit of ability being cast))
Unit - Change ownership of LoadedSexPistol to Player 1 (Red) and Change color
Unit Group - Add LoadedSexPistol to (Units currently selected by (Owner of GuidoMista))
Unit - Remove Stand Shoot- Sex Pistols from GuidoMista
Trigger - Turn on Stand Shoot Return Sex Pistols <gen>
Trigger - Turn off Stand Shoot Sex Pistols <gen>
Code:
Stand Shoot Return Sex Pistols
Events
Unit - A unit Begins casting an ability
Conditions
(Ability being cast) Equal to Return- Sex Pistols
Actions
Unit - Move LoadedSexPistol instantly to (Center of Sex Pistols loaded <gen>)
Unit - Change ownership of LoadedSexPistol to Player 12 (Brown) and Change color
Unit Group - Add GuidoMista to (Units currently selected by (Owner of GuidoMista))
Unit - Add Stand Shoot- Sex Pistols to GuidoMista
Trigger - Turn on Stand Shoot Sex Pistols <gen>
Trigger - Turn off Stand Shoot Return Sex Pistols <gen>
Also, I need some help with the abilities themselves, (I used channeling as the base) the hero ability shows up green when selecting it after a level-up, and when using it it does not add the stunned (pause) buff (2 seconds).