- Joined
- Jul 28, 2019
- Messages
- 78
Hi,
1) What is the easiest way to do this? Currently I only have a dozen or so spells, so my way is manageable, but it would be a headache with more. I can handle basic JASS if that is worth it.
Spells (3 level max) are sold as a dummy unit that costs resource saved in int array "INT_ability_point_resource." There doesn't seem to be an "ability-type" command or way to reference the ability's rawcode. Pyrogasm suggested hashtables but I do not understand the ways of hashtables.
2) What does "Ability Code" mean? Hoping it would be a way to refer to the rawcode but it requires reference to a unit(??). (https://i.imgur.com/GHmcoaz.png)
1) What is the easiest way to do this? Currently I only have a dozen or so spells, so my way is manageable, but it would be a headache with more. I can handle basic JASS if that is worth it.
Spells (3 level max) are sold as a dummy unit that costs resource saved in int array "INT_ability_point_resource." There doesn't seem to be an "ability-type" command or way to reference the ability's rawcode. Pyrogasm suggested hashtables but I do not understand the ways of hashtables.
2) What does "Ability Code" mean? Hoping it would be a way to refer to the rawcode but it requires reference to a unit(??). (https://i.imgur.com/GHmcoaz.png)
-
Buys ability
-
Events
- Unit - A unit enters (Playable map area)
-
Conditions
-
Or - Any (Conditions) are true
-
Conditions
- (Unit-type of (Triggering unit)) Equal to Entangling Roots (Dummy ability unit)
- (Unit-type of (Triggering unit)) Equal to Silence (Dummy ability unit)
-
Conditions
-
Or - Any (Conditions) are true
-
Actions
- Set TempInt = (Player number of (Owner of (Triggering unit)))
- Set TempPlayer = (Owner of (Triggering unit))
- Set TempUnit = Player_Heroes[TempInt]
- Unit - Remove (Triggering unit) from the game
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- INT_ability_point_resource[TempInt] Equal to 0
-
Then - Actions
- Game - Display to (Player group((Player(TempInt)))) for 4.00 seconds the text: |cff00ff00Not enoug...
-
Else - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Unit-type of (Triggering unit)) Equal to Entangling Roots (Dummy ability unit)
-
Then - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Level of Entangling Roots (custom version) for Player_Heroes[TempInt]) Equal to 3
-
Then - Actions
- Game - Display to (Player group((Player(TempInt)))) for 4.00 seconds the text: |cff00ff00Ability a...
-
Else - Actions
- Set INT_ability_point_resource[TempInt] = (INT_ability_point_resource[TempInt] - 1)
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- (Level of Entangling Roots (custom version) for Player_Heroes[TempInt]) Greater than 0
-
Then - Actions
- Unit - Set level of Entangling Roots (custom version) for TempUnit to ((Level of Entangling Roots (custom version) for TempUnit) + 1)
- Game - Display to (Player group((Player(TempInt)))) for 4.00 seconds the text: |cff00ff00Ability p...
-
Else - Actions
- Unit - Add Entangling Roots (custom version) to Player_Heroes[TempInt]
- Hero - Modify unspent skill points of Player_Heroes[TempInt]: Add 1 points
- Hero - Learn skill for (Triggering unit): Entangling Roots (custom version)
- Game - Display to (Player group((Player(TempInt)))) for 4.00 seconds the text: |cff00ff00Ability p...
-
If - Conditions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
Events
Last edited: