in order to get accustomed to the editor i started messing around with the campaign maps and I created a new difficulty level.
It worked fine and i was able to use it with most other triggers just as a pre-built difficulty.
But i have problems with attack wave triggers, as the trigger I'd like to use and that is used in the campaign is:
and edited the triggers to:
AIAttackWaveAddUnits4(0, 2, 6, 7, 8, "Marine")
AIAttackWaveSend(pLAYER_02_DOMINION, (DifficultyValueInt(400, 400, 210, 180, 160)), true),
but it doesn't work ingame as no attack waves are arriving.
I guess the problem is the first custom action definition, as the "insane count" integer is not referenced anywhere else, but i don't know how to get it to work.
Oh, ok, i'll add the actions.
First the action how it appears in the second campaign-map and then the action i changed it into:
The original: DominionAttackWaves
Conditions
* Comparison((TriggerIsEnabled((TriggerGetCurrent()))), ==, true)
Actions
* TriggerEnable((TriggerGetCurrent()), false)
* SetAttackWaveParameters()
* AIAttackWaveAddUnits4(0, 2, 4, 5, 6, "Marine")
* AIAttackWaveSend(pLAYER_02_DOMINION, (DifficultyValueInt(400, 400, 225, 180, 160)), true)
The trigger adds a different amount of units to the next attack wave for each difficulty level. But the original action using the action definition "AIAttackWaveAddUnits4" only has the option to set this amount for the pre-built difficulty-levels, not for mine.
So, I tried to add a new field to the bracket, so the action will use my custom difficulty-level I made in the data editor.
But I don't know how to do this properly.
What you can see in the screenshots is my first attempt - the action definition, adding a new integer and the function adding a new integer and a new return option. But that doesn't function the way I hoped it would.
Thanks for your reply
You missed my point. "Action Definition" is not magic. It won't work by simply changing the parameters. You need to add lines of actions to it to make it useful.
Do you know where i can find the lines of actions of the pre-build action definition I tried to base it on?
As I have no clue how to do these lines. That's why I started with the campaign map, so I can learn by copy and pasting a lot.
I mean, in the function shown in the second screenshot, there is the return option right there in the function definition and so I could add it accordingly.
Can you help me writing these lines of action or is there any tutorial on action definitions so I can understand it?
You need to add something such as "Add unit to attack wave", etc to the Action part. However, if this is only for learn purpose, I suggest you better don't go too deep as it is neither easy nor very useful practically.
here's the low down on action definations. Basically from what i am seeing, your action defination should be just a regular trigger. Reason is because action definations are usually used for actions that are repetitivly used in your trigger data, therefore you dont need to keep copy pasting 10+ lines of the same action and just have it in one simple built-in trigger.
From what I am seeing from your screenshots, if your trying to set difficulty for the attack waves, I suggest something along these lines. Have a trigger with if then else actions for easy, hard, insane, etc.... Now for each of these would modify a variable integer that would dictate how many units are made each wave.
Now you make an action defination where the parameters will be your variable integer. And the action will create the amount of integer variable wave units for each region/point. Have another trigger which activates this action defination with lets say, a periodic timer, that also modifies the variable integer so that more units spawn as each wave increases.
This is a simple 2 trigger 1 action defination way of making attack waves.
Hi,
in order to get accustomed to the editor i started messing around with the campaign maps and I created a new difficulty level. It worked fine and i was able to use it with most other triggers just as a pre-built difficulty.
But i have problems with attack wave triggers, as the trigger I'd like to use and that is used in the campaign is:
AIAttackWaveAddUnits4(0, 2, 6, 7, "Marine") AIAttackWaveSend(pLAYER_02_DOMINION, (DifficultyValueInt(400, 400, 210, 180)), true),
which both only have 4 values for the pre-built difficulty levels.
So, i tried to create one new action definition and one new function based one the ones used by the campaign:
http://img339.imageshack.us/i/aiwave.jpg/ http://img257.imageshack.us/i/difficultyint.jpg/
and edited the triggers to: AIAttackWaveAddUnits4(0, 2, 6, 7, 8, "Marine") AIAttackWaveSend(pLAYER_02_DOMINION, (DifficultyValueInt(400, 400, 210, 180, 160)), true), but it doesn't work ingame as no attack waves are arriving.
I guess the problem is the first custom action definition, as the "insane count" integer is not referenced anywhere else, but i don't know how to get it to work.
Thanks for your help.
I see no action in your first screenshot.
DominionAttackWaves
Events
Local Variables
Conditions
* Comparison((TriggerIsEnabled((TriggerGetCurrent()))), ==, true)
Actions
* TriggerEnable((TriggerGetCurrent()), false) * SetAttackWaveParameters() * AIAttackWaveAddUnits4(0, 2, 4, 5, "Marine") * AIAttackWaveSend(pLAYER_02_DOMINION, (DifficultyValueInt(400, 400, 225, 180)), true) The edited one:
DominionAttackWaves
Events
Local Variables
Conditions
* Comparison((TriggerIsEnabled((TriggerGetCurrent()))), ==, true)
Actions
* TriggerEnable((TriggerGetCurrent()), false) * SetAttackWaveParameters() * AIAttackWaveAddUnits4(0, 2, 4, 5, 6, "Marine") * AIAttackWaveSend(pLAYER_02_DOMINION, (DifficultyValueInt(400, 400, 225, 180, 160)), true) The trigger adds a different amount of units to the next attack wave for each difficulty level. But the original action using the action definition "AIAttackWaveAddUnits4" only has the option to set this amount for the pre-built difficulty-levels, not for mine. So, I tried to add a new field to the bracket, so the action will use my custom difficulty-level I made in the data editor. But I don't know how to do this properly. What you can see in the screenshots is my first attempt - the action definition, adding a new integer and the function adding a new integer and a new return option. But that doesn't function the way I hoped it would. Thanks for your reply
No no no.....
You missed my point. "Action Definition" is not magic. It won't work by simply changing the parameters. You need to add lines of actions to it to make it useful.
I hoped it was :P
Do you know where i can find the lines of actions of the pre-build action definition I tried to base it on? As I have no clue how to do these lines. That's why I started with the campaign map, so I can learn by copy and pasting a lot. I mean, in the function shown in the second screenshot, there is the return option right there in the function definition and so I could add it accordingly.
Can you help me writing these lines of action or is there any tutorial on action definitions so I can understand it?
Thanks a lot :).
You need to add something such as "Add unit to attack wave", etc to the Action part. However, if this is only for learn purpose, I suggest you better don't go too deep as it is neither easy nor very useful practically.
here's the low down on action definations. Basically from what i am seeing, your action defination should be just a regular trigger. Reason is because action definations are usually used for actions that are repetitivly used in your trigger data, therefore you dont need to keep copy pasting 10+ lines of the same action and just have it in one simple built-in trigger.
From what I am seeing from your screenshots, if your trying to set difficulty for the attack waves, I suggest something along these lines. Have a trigger with if then else actions for easy, hard, insane, etc.... Now for each of these would modify a variable integer that would dictate how many units are made each wave.
Now you make an action defination where the parameters will be your variable integer. And the action will create the amount of integer variable wave units for each region/point. Have another trigger which activates this action defination with lets say, a periodic timer, that also modifies the variable integer so that more units spawn as each wave increases.
This is a simple 2 trigger 1 action defination way of making attack waves.