HomeUser Control Panel (unavailable in archive)ForumsTutorialsArt GalleryResourcesMaps

Why doesn't this trigger work? ((long))

10-10-2003, 06:06 PM#1
Zachary_Shadow
Xp Trigger1
Events
Time - Elapsed game time is 4.00 seconds
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 3 (Teal) controller) Equal to User
Then - Actions
Player Group - Add Player 3 (Teal) to ActiveHeaven
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 4 (Purple) controller) Equal to User
Then - Actions
Player Group - Add Player 4 (Purple) to ActiveHeaven
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 5 (Yellow) controller) Equal to User
Then - Actions
Player Group - Add Player 5 (Yellow) to ActiveHeaven
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 6 (Orange) controller) Equal to User
Then - Actions
Player Group - Add Player 6 (Orange) to ActiveHeaven
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 7 (Green) controller) Equal to User
Then - Actions
Player Group - Add Player 7 (Green) to ActiveHell
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 8 (Pink) controller) Equal to User
Then - Actions
Player Group - Add Player 8 (Pink) to ActiveHell
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 9 (Gray) controller) Equal to User
Then - Actions
Player Group - Add Player 9 (Gray) to ActiveHell
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 10 (Light Blue) controller) Equal to User
Then - Actions
Player Group - Add Player 10 (Light Blue) to ActiveHell
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 1 (Red) controller) Equal to User
Then - Actions
Player Group - Add Player 1 (Red) to ActiveHell
Else - Actions
Do nothing
Trigger - Run Xp Trigger2 <gen> (checking conditions)

This sets the Active Players to their respective player groups, ActiveHeaven & ActiveHell. ONLY players who are controlled by users should be added...

Then:

Xp Trigger2
Events
Conditions
Actions
Set ActiveHeaven1 = (Number of players in ActiveHeaven)
Set ActiveHell1 = (Number of players in ActiveHell)
Trigger - Run Xp Trigger3 <gen> (checking conditions)

A trigger to set the integers ActiveHeaven1 and ActiveHell1 to the number of players in each player group. Then:

Xp Trigger3
Events
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHeaven1 Equal to 0
Then - Actions
Player Group - Pick every player in ActiveHeaven and do (Actions)
Loop - Actions
Game - Display to (All players) for 20.00 seconds the text: |c000000ffHeaven|r ...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHeaven1 Equal to 1
Then - Actions
Player Group - Pick every player in ActiveHeaven and do (Actions)
Loop - Actions
Hero - Make (Picked player) Heroes gain 90.00% experience from future kills
Game - Display to (All players) for 20.00 seconds the text: |c000000ffHeaven|r ...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHeaven1 Equal to 2
Then - Actions
Player Group - Pick every player in ActiveHeaven and do (Actions)
Loop - Actions
Hero - Make (Picked player) Heroes gain 65.00% experience from future kills
Game - Display to (All players) for 20.00 seconds the text: |c000000ffHeaven|r ...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHeaven1 Equal to 3
Then - Actions
Player Group - Pick every player in ActiveHeaven and do (Actions)
Loop - Actions
Hero - Make (Picked player) Heroes gain 35.00% experience from future kills
Game - Display to (All players) for 20.00 seconds the text: |c000000ffHeaven|r ...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHeaven1 Equal to 4
Then - Actions
Player Group - Pick every player in ActiveHeaven and do (Actions)
Loop - Actions
Hero - Make (Picked player) Heroes gain 25.00% experience from future kills
Game - Display to (All players) for 20.00 seconds the text: |c000000ffHeaven|r ...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHell1 Equal to 0
Then - Actions
Player Group - Pick every player in ActiveHell and do (Actions)
Loop - Actions
Game - Display to (All players) for 20.00 seconds the text: |c00ff0000Hell|r co...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHell1 Equal to 1
Then - Actions
Player Group - Pick every player in ActiveHell and do (Actions)
Loop - Actions
Hero - Make (Picked player) Heroes gain 90.00% experience from future kills
Game - Display to (All players) for 20.00 seconds the text: |c00ff0000Hell|r co...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHell1 Equal to 2
Then - Actions
Player Group - Pick every player in ActiveHell and do (Actions)
Loop - Actions
Hero - Make (Picked player) Heroes gain 65.00% experience from future kills
Game - Display to (All players) for 20.00 seconds the text: |c00ff0000Hell|r co...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHell1 Equal to 3
Then - Actions
Player Group - Pick every player in ActiveHell and do (Actions)
Loop - Actions
Hero - Make (Picked player) Heroes gain 35.00% experience from future kills
Game - Display to (All players) for 20.00 seconds the text: |c00ff0000Hell|r co...
Else - Actions
Do nothing
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
ActiveHell1 Equal to 4
Then - Actions
Player Group - Pick every player in ActiveHell and do (Actions)
Loop - Actions
Hero - Make (Picked player) Heroes gain 25.00% experience from future kills
Game - Display to (All players) for 20.00 seconds the text: |c00ff0000Hell|r co...
Else - Actions
Do nothing

This trigger should then recognice what number the ActiveHeaven1 and ActiveHell1 has, and run the triggers acordingly....but..

It only runs the ActiveHeaven1 as if 4 players were in that group (even though 0 exists) AND it displays the text 4 times. ActiveHell1 doesn't even get to display any messages, even though 1 player is there (red)

This is when I test it, I haven't tried to make a lan and log on two players...

Anyone know how to fix these issues? Thanks in advance.
10-10-2003, 06:09 PM#2
Zachary_Shadow
w00ps, figured out why it was displaying the text 4 times :P I was looping it for each picked player...BUT still don't get why Heaven get's 4 players and Hell 0....
10-10-2003, 06:30 PM#3
Zachary_Shadow
oops, should have used:

If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Player 1 (Red) slot status) Equal to Is playing
Then - Actions
Player Group - Add Player 1 (Red) to ActiveHell
Else - Actions
Do nothing

For determing that players is there :P Now it works ;)