Jooster
New Member
- Reaction score
- 7
alright so my friend posted this a couple days ago im just unable to find his post. but anyways. i went through and and added 2 new player groups. 1 for each team. coulda set them as arrays yes. blah ...anyways so yea, Team1 and Team2_count are integers being set as +1 for each player in the group like so
********************* EDIT****************
so i just did some brain storming and i beleive if i add this instead of the code line above in it's place that should fix the problem??
then when they leave
the problem were running into is that its not deviding the set 120g up between the value of Team1/Team2_count which is the number of how many people are in that player group.
Code:
Player Group - Pick every player in team_1 and do (Actions)
Loop - Actions
Set Team1_count = (Team1_count + 1)
********************* EDIT****************
so i just did some brain storming and i beleive if i add this instead of the code line above in it's place that should fix the problem??
Code:
For each (Integer A) from 1 to (Number of players in team_1), do (Actions)
Loop - Actions
Set Team1_count = (Team1_count + 1)
then when they leave
Code:
Players Leave team 1
Events
Player - Player 1 (Red) leaves the game
Player - Player 2 (Blue) leaves the game
Player - Player 3 (Teal) leaves the game
Player - Player 4 (Purple) leaves the game
Player - Player 5 (Yellow) leaves the game
Player - Player 6 (Orange) leaves the game
Conditions
Actions
Set unit_group = (Units in (Playable map area) owned by (Triggering player))
Set Team1_count = (Team1_count - 1)
Unit Group - Pick every unit in unit_group and do (Actions)
Loop - Actions
Unit - Remove (Picked unit) from the game
Custom script: call DestroyGroup (udg_unit_group)
Code:
income and tax Copy
Events
Time - Every 20.00 seconds of game time
Conditions
Actions
Player Group - Pick every player in team_1 and do (Actions)
Loop - Actions
Player - Add (120 / Team1_count) to (Picked player) Current gold
Player - Add income_var[(Player number of (Picked player))] to (Picked player) Current gold
Player Group - Pick every player in team_2 and do (Actions)
Loop - Actions
Player - Add (120 / Team2_count) to (Picked player) Current gold
Player - Add income_var[(Player number of (Picked player))] to (Picked player) Current gold
Player Group - Pick every player in team_1 and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked player) Food used) Greater than or equal to 101
((Picked player) Food used) Less than 150
Then - Actions
Player - Add (-24 / Team1_count) to (Picked player) Current gold
Else - Actions
Player Group - Pick every player in team_2 and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked player) Food used) Greater than or equal to 101
((Picked player) Food used) Less than 150
Then - Actions
Player - Add Team2_count to (Picked player) Current gold
Else - Actions
Player Group - Pick every player in team_1 and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked player) Food used) Greater than or equal to 151
Then - Actions
Player - Add (-48 / Team1_count) to (Picked player) Current gold
Else - Actions
Player Group - Pick every player in team_2 and do (Actions)
Loop - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
((Picked player) Food used) Greater than or equal to 151
Then - Actions
Player - Add (-48 / Team2_count) to (Picked player) Current gold
Else - Actions
the problem were running into is that its not deviding the set 120g up between the value of Team1/Team2_count which is the number of how many people are in that player group.