Might be an issue with the ability, like it requiring energy that the Goliath doesn't have or something. The triggers seem to fine from where I'm looking.
Give control of the unit to the player to see if the ability works. Maybe you only added the button.
You are testing if number of times the current trigger has been executes equals 0, which is just the case the first time the live of the boss is changing. At this time its very unlikely that the other conditions are met though, so nothing happens.
Note: As far as I can remember a trigger is considered "executed" once it enters the "action" section, but definatly NOT once it steps into your custom if then else "then" block!
One solution should be to move your conditions into the TRIGGERS "conditions" block and remove your custom if then else construct or removing the condition entirely and using "turn current trigger off" instead.
Hint: In general I would recommend to avoid this weird conditions since its not perfectly obvious when a trigger is considered to be "executed" (As you can see at this example), and instead use "turn current trigger off" once your conditions are met. This also has the advantage that you can turn it back on later, e.g. after resetting the boss.
As far as my experience goes, a trigger is executed once an action is run, which is when all conditions are met. So I wouldn't say there is a condition problem.
I think to do this "How can I make the boss attack the hero which cause it's health reach bellow 1251?"
would be really easy if you create a behavior that uses a search effect to order the boss to attack the unit with the behavior
And you could add the behavior in your current trigger just use attacking player or something like that i think
Using the Behavior way will also allow you to set a duration so after say 10 seconds the boss would attack whoever again
EDIT: What i meant was Create a Behavior in the Data Editor that Has a Search Effect that uses an Issue Order Effect then in your Trigger there is a Trigger called Add Behavior to Unit from Unit i believe
As far as my experience goes, a trigger is executed once an action is run, which is when all conditions are met. So I wouldn't say there is a condition problem.
Exactly, and thats why his trigger didnt work. Like ive said, he didnt have any conditions in the trigger but used a custom if then else struct.
Simply change the triggers event to "unit takes damage". Then you can use "Damaging Unit" to get the unit which dealt the damage and use that unit as target for the bosses ability.
I have been trying to scrip boss battle for my map, here is the script that I think should work but didn't.
Basically I am trying to make the Goliath boss to use psi shield when it's health reach bellow 1251 (it's max health is 1500).
Later when it's reach other certain point it will use other abilities.
Can anyone help?
My projects : The Hammer of Dawn, Noir : Automata, Noir : Evolution, Noir : Ascension, Hammer of Dawn Revamp
Many awesome projects : Custom Campaign Initiative
Something for the community : A Small Letter of Thanks, SC2mapster Classic Skin - Alevice
Might be an issue with the ability, like it requiring energy that the Goliath doesn't have or something. The triggers seem to fine from where I'm looking.
Give control of the unit to the player to see if the ability works. Maybe you only added the button.
There is a problem in your conditions.
You are testing if number of times the current trigger has been executes equals 0, which is just the case the first time the live of the boss is changing. At this time its very unlikely that the other conditions are met though, so nothing happens.
Note: As far as I can remember a trigger is considered "executed" once it enters the "action" section, but definatly NOT once it steps into your custom if then else "then" block!
One solution should be to move your conditions into the TRIGGERS "conditions" block and remove your custom if then else construct or removing the condition entirely and using "turn current trigger off" instead.
Hint: In general I would recommend to avoid this weird conditions since its not perfectly obvious when a trigger is considered to be "executed" (As you can see at this example), and instead use "turn current trigger off" once your conditions are met. This also has the advantage that you can turn it back on later, e.g. after resetting the boss.
@Mille25
Something like this perhaps?
My projects : The Hammer of Dawn, Noir : Automata, Noir : Evolution, Noir : Ascension, Hammer of Dawn Revamp
Many awesome projects : Custom Campaign Initiative
Something for the community : A Small Letter of Thanks, SC2mapster Classic Skin - Alevice
Yes. As you can see its much easier to understand and it should work now. :)
Thank you, I'll try it right now.
How about if a certain unit cause the change? let's say 3 heroes attack the boss together.
How can I make the boss attack the hero which cause it's health reach bellow 1251?
My projects : The Hammer of Dawn, Noir : Automata, Noir : Evolution, Noir : Ascension, Hammer of Dawn Revamp
Many awesome projects : Custom Campaign Initiative
Something for the community : A Small Letter of Thanks, SC2mapster Classic Skin - Alevice
As far as my experience goes, a trigger is executed once an action is run, which is when all conditions are met. So I wouldn't say there is a condition problem.
I think to do this "How can I make the boss attack the hero which cause it's health reach bellow 1251?"
would be really easy if you create a behavior that uses a search effect to order the boss to attack the unit with the behavior
And you could add the behavior in your current trigger just use attacking player or something like that i think
Using the Behavior way will also allow you to set a duration so after say 10 seconds the boss would attack whoever again
EDIT: What i meant was Create a Behavior in the Data Editor that Has a Search Effect
that uses an Issue Order Effect
then in your Trigger there is a Trigger called Add Behavior to Unit from Unit i believe
@zaysite
Unfortunately scripting behavior is currently beyond my understanding, but thank you for your suggestion.
@EivindL: Go
Already give energy to the goliath, and also test it. The ability work fine, must be something else.
@Mille25
It work! the beauty in simplicity. Thanks.
My projects : The Hammer of Dawn, Noir : Automata, Noir : Evolution, Noir : Ascension, Hammer of Dawn Revamp
Many awesome projects : Custom Campaign Initiative
Something for the community : A Small Letter of Thanks, SC2mapster Classic Skin - Alevice
Exactly, and thats why his trigger didnt work. Like ive said, he didnt have any conditions in the trigger but used a custom if then else struct.
@EDHRIANO: Go
Simply change the triggers event to "unit takes damage". Then you can use "Damaging Unit" to get the unit which dealt the damage and use that unit as target for the bosses ability.
@Mille25: Go
If I understand correctly it should be like this :
My projects : The Hammer of Dawn, Noir : Automata, Noir : Evolution, Noir : Ascension, Hammer of Dawn Revamp
Many awesome projects : Custom Campaign Initiative
Something for the community : A Small Letter of Thanks, SC2mapster Classic Skin - Alevice
The map is complete and release if anyway wish to try it.
http://www.sc2mapster.com/maps/mercenaries/pages/mission-3-liberation/
My projects : The Hammer of Dawn, Noir : Automata, Noir : Evolution, Noir : Ascension, Hammer of Dawn Revamp
Many awesome projects : Custom Campaign Initiative
Something for the community : A Small Letter of Thanks, SC2mapster Classic Skin - Alevice
Why <1001 or <1251? How about <= 1000/1250 ?
OMG! New hero in 'Heroes of the Storm' is Dustin Browder. Watch here!
@xxxNEARBYxxx: Go
Because if a unit health reach 0 the unit die.
1251, 1001, ...... 501, 251, 1
See the pattern here?
My projects : The Hammer of Dawn, Noir : Automata, Noir : Evolution, Noir : Ascension, Hammer of Dawn Revamp
Many awesome projects : Custom Campaign Initiative
Something for the community : A Small Letter of Thanks, SC2mapster Classic Skin - Alevice