15 posts Prolly consuming ur best friends soul.....Mmm tastes like chicken joined
#1
Bahamuts Gigas Flare
A charge up spell that channels for a certain amount of time then releases energy....pretty much the same as D0Tas keeper of the light's illuminate spell....i can get the main spells but i cant make the triggering for the chargin and the increasing of damage per sec....any1 can help??
trigger#1: Event - spell effect Caondition - spell = yourSpell Action: Set ChargeCounter = 0 Set ChargeEnd = false Custom Script: loop Custom Script: exitwhen udg_ChargeCounter > 5 or udg_ChargeEnd == true Custom Script: call TriggerSleepAction(1) Custom Script: set udg_ChargeCounter = udg_ChargeCounter + 1 Custom Script: endloop Create unit at pos of triggering unit Set last created unit's dummy ability level to ChargeCounter Order... . .
trigger#2 Event - unit stops channeling Condition - spell = yourSpell Action: Set ChargeEnd = true
So you need 2 vars, ChargeCounter is an integer, ChargeEnd is a boolean variable. The custom script part is in jass. In jass, you have to put an 'udg_' part before the variable's name. TriggerSleepAction is the same as Wait in GUI. Little explanation of custom script:
loop //--> starts the loop actions
exitwhen udg_ChargeCounter > 5 or udg_ChargeEnd == true //--> every time the loop starts again, these conditions will be checked
call TriggerSleepAction(1) //--> wait 1 second
set udg_ChargeCounter = udg_ChargeCounter + 1 //--> ...
endloop //--> closes the loop (don't forget this!!)
If you get this to work, you can tell about yourself that you've used jass!
Vars in jass has the same name as in GUI, exept, they have an 'udg_' part before them. For example, if you have a variable in GUI called MyVar, it is called udg_MyVar in jass. There is the action, Custom Script (somewhere between the firs few actions in the list). If you double click on it, you see an editable line. The script you need has 5 lines, so you must have a Custom Script action for each line! JASS:
loop
exitwhen udg_ChargeCounter > 5 or udg_ChargeEnd == true
call TriggerSleepAction(1)
set udg_ChargeCounter = udg_ChargeCounter + 1
endloop