.. I use so many triggers just for 1 level:
Quote:
Level 1 Timer
Events
Time - Elapsed game time is 1.00 seconds
Conditions
Actions
Game - Display to (All players) for 5.00 seconds the text: 30 ...
Wait 10.00 seconds
Game - Display to (All players) for 5.00 seconds the text: 20
Wait 10.00 seconds
Game - Display to (All players) for 5.00 seconds the text: 10 ...
Wait 5.00 seconds
Game - Display to (All players) for 1.00 seconds the text: 5 ...
Wait 1.00 seconds
Game - Display to (All players) for 1.00 seconds the text: 4 ...
Wait 1.00 seconds
Game - Display to (All players) for 1.00 seconds the text: 3 ...
Wait 1.00 seconds
Game - Display to (All players) for 1.00 seconds the text: 2 ...
Wait 1.00 seconds
Game - Display to (All players) for 1.00 seconds the text: 1 ...
-------- Actions --------
Trigger - Add to Level 1 <gen> the event (Time - Elapsed game time is 1.00 seconds)
Quote:
Level 1
Events
Conditions
Actions
Sound - Play QuestNew <gen>
Game - Display to (All players) for 5.00 seconds the text: |cffffcc00Level 1|r
For each (Integer A) from 1 to 20, do (Actions)
Loop - Actions
Unit - Create 1 Level 1 for Player 12 (Brown) at (Random point in BattleField <gen>) facing Default building facing degrees
Unit - Order (Last created unit) to Attack (Random unit from (Units in BattleField <gen> owned by (Random player from (All enemies of Player 12 (Brown)))))
Trigger - Add to Next Level 2 <gen> the event (Time - Every 1.00 seconds of game time)
Quote:
Next Level 2
Events
Conditions
(Number of living Level 1 units owned by Player 12 (Brown)) Less than or equal to 0
Actions
Trigger - Add to Level 2 Timer <gen> the event (Time - Elapsed game time is 1.00 seconds)
Trigger - Turn off (This trigger)
This is just for one level.. And i think its.. SO annoying..
Anyone who can give me some Tips, for a better and easier Level System?|||There's no reason you can't use the same triggers for each level if you were a little more efficient with how you code them:
Code:
Countdown
Events
Time - Elapsed game time is 1.00 seconds
Conditions
Actions
Countdown Timer - Start LevelTimer as a One-shot timer that will expire in 30.00 seconds
Countdown Timer - Create a timer window for LevelTimer with title Next level
Countdown Timer - Show (Last created timer window)
-------- Display countdown @ last 5 seconds --------
Countdown Timer - Start Countdown25 as a One-shot timer that will expire in 24.00 seconds
Code:
Countdown 25
Events
Time - Countdown25 expires
Conditions
Actions
Countdown Timer - Start DisplayTimer as a Repeating timer that will expire in 1.00 seconds
Code:
Countdown Display
Events
Time - DisplayTimer expires
Conditions
(Remaining time for LevelTimer) Greater than 0.00
Actions
Game - Display to (All players) for 1.00 seconds the text: ((String((Integer((Remaining time for LevelTimer))))) + ...)
For example, above I have done all the same things your countdown system did, but the triggers are cleaner, more efficient, and completely reusable for counting down between every level.
If the general structure of your levels is the same every level (i.e. units of one type on the battlefield in random locations), just replace the things that change with variables. For example, the number of units spawned, the types of units, and their levels can all be set to variables and then just change the value of the variables between levels... or even better, make them into arrayed variables and have the variable array index be the level.|||Ahh.. Why dident i see the Countdown Timer? Simple...
Whats do this trigger does?
Quote:
Countdown Display
Events
Time - DisplayTimer expires
Conditions
(Remaining time for LevelTimer) Greater than 0.00
Actions
Game - Display to (All players) for 1.00 seconds the text: ((String((Integer((Remaining time for LevelTimer))))) + ...)
Can you for exsample do like this:
1. When all Heroes is chosen, Start the timer -Countdown 30. (I can make this one myself)
2. When the timer reach 0.. Can you make a variable that automatically Runs The Level triggers(Like level 1-50, one trigger for each levels, that contains create units) When level 1 is complete, then it runs the timer, and after timer the level 2?
3. Also a trigger/variable that shows the current Level, when a new level starts..
- So i need ALL Those trigger.. Just a Few Variables.. Interger Variable for Levels? .. And i have no idea for the Level String, string and interger?
- You can send me a map exsample?|||Quote:
Whats do this trigger does?
I was attempting to duplicate your text message countdown display. It's not really necessary, since there's a countdown timer window, but if you wanted those game-text messages for effect, that's a way to accomplish it.
Quote:
Can you make a variable that automatically Runs The Level triggers
Trigger is a type of variable, so sure. You could make a trigger variable, arrayed, with the array defined to point to each trigger, if you wanted. If the structure is similar each round (random unit placement), though, you don't even need to do that.
In maps where I've had a series of attacking rounds, I've just had 4 or 5 different configurations and used a trigger to select from the patterns randomly using something like:
Code:
Run Trigger - TriggerVariable[random number between 1 and 5]|||How can i make a Variable That Remember the Last Level (Level 1) Trigger, And Turns on The Next Level (Level 2),
Is that possible?
This is what i got so far.. But i need a way to: when ALL Units (Level 1 Units) is Dead, The Timer starts, and when the timer expires, level 2 starts.. And so on..
My Timer setup
Quote:
Timer Setup
Events
Conditions
Actions
Set Timer = (Last started timer)
Set Timer_window = (Last created timer window)
Countdown Timer - Create a timer window for Timer with title |cffffcc00Next Leve...
Countdown Timer - Show (Last created timer window)
Trigger Activates When a user User player Enters Region
Quote:
Find Players
Events
Time - Every 0.10 seconds of game time
Conditions
(Number of units in (Units in BattleField <gen> owned by (Random player from (All players controlled by a User player)))) Greater than or equal to 1
Actions
Trigger - Add to Healing Orbs <gen> the event (Time - Every 20.00 seconds of game time)
Trigger - Run Timer Start 30 <gen> (ignoring conditions)
Trigger - Turn off (This trigger)
30 Sec Timer
Quote:
Timer Start 30
Events
Conditions
Actions
Countdown Timer - Start (Last started timer) as a One-shot timer that will expire in 30.00 seconds
Level 1
Quote:
Level 1
Events
Time - Timer expires
Conditions
Actions
Game - Display to (All players) the text: ((|cffffcc00 + (Name of the current trigger)) + |r)
For each (Integer A) from 1 to 20, do (Actions)
Loop - Actions
Unit - Create 1 Level 1 for Player 12 (Brown) at (Random point in BattleField <gen>) facing Default building facing degrees
Unit - Order (Last created unit) to Attack (Random unit from (Units in BattleField <gen> owned by (Random player from (All enemies of Player 12 (Brown)))))
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Number of units in (Units in BattleField <gen> owned by Player 12 (Brown))) Greater than or equal to 20
Then - Actions
Countdown Timer - Start (Last started timer) as a One-shot timer that will expire in 30.00 seconds
Trigger - Turn off (This trigger)
Else - Actions
Do nothing
Level 2
Quote:
Level 2
Events
Time - Timer expires
Conditions
? Equal to <Empty String>
Actions
Game - Display to (All players) the text: ((|cffffcc00 + (Name of the current trigger)) + |r)
For each (Integer A) from 1 to 20, do (Actions)
Loop - Actions
Unit - Create 1 Level 1 for Player 12 (Brown) at (Random point in BattleField <gen>) facing Default building facing degrees
Unit - Order (Last created unit) to Attack (Random unit from (Units in BattleField <gen> owned by (Random player from (All enemies of Player 12 (Brown)))))
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Number of units in (Units in BattleField <gen> owned by Player 12 (Brown))) Greater than or equal to 20
Then - Actions
Countdown Timer - Start (Last started timer) as a One-shot timer that will expire in 30.00 seconds
Trigger - Turn off (This trigger)
Else - Actions
Do nothing
Well.. I KNOW that both of the trigger will start when the Timer runs down to 0.. But.. Any Conditons or Variable To make it work? Need a Solution...|||Quote:
when ALL Units (Level 1 Units) is Dead, The Timer starts, and when the timer expires, level 2 starts.. And so on..
I wouldn't use that option. I'd go with adding the units to a unit group - removing them from the unit group when they die, and checking to see if the unit group is empty as a condition... or if they are always owned by the same player, I'd just make sure the units use at least 1 food resource and then when the owning player's food resource used is 0, end the round... or just simply check any one of a dozen other ways to check for conditions they might meet when a unit dies...|||Ahh.. I understand..
Just for getting this into the right place..
Can you make a trigger exsample?
No comments:
Post a Comment