Missing Players
Jun 12 2008, 6:45 pm
By: 49281358723941702706  

Jun 12 2008, 6:45 pm 49281358723941702706 Post #1



I am working on Team Micro Work 4 and have run into a problem. In Team Micro Work 3 it was made so when the first round began it was like this.
Quote
PLAYERS
Player 8
CONDITIONS:
Player 8 accumulates exactly 1 gas
ACTIONS
Wait for 5000 milliseconds
Create 1 Marine for Player 1 at location X
Create 1 Marine for Player 2 at location X
Create 1 Marine for Player 3 at location X
Create 1 Marine for Player 4 at location X
Create 1 Marine for Player 5 at location X
Create 1 Marine for Player 6 at location X
Create 1 Archon for Player 7 at location X
If a player left the game, it created a unit for the player who left....however the unit would be controlled by a computer and not do anything.

In my sequal I wanted it to be randomly distributed to players who are in the game. For example if only 2 players join the game out of 6, I wanted it to give the 4 missing marines to the 2 players who are in the game. How would i make it either randomly distributed or evenly distributed among the players who are in the game. This should apply also if a player leaves the game.



None.

Jun 12 2008, 7:12 pm Filleinconnue Post #2



You'd have to make a Trigger for Each Player thaty Assimilates the Missing person.

Such as on my map, When player ? controlls nothing I set up a trigger that Set Switches that allowed it to over-go it.

Player 1 Controls 0 Units Anywhere
-------------------------------------------------
Set Switch 1
Wait 1 Mili
[Comment]

Switch 1 is Set
------------------------------------------------
Create [Whatever] for [Player] at [Where-ever]

Continue doing this until all players are Covered.



None.

Jun 12 2008, 7:14 pm Clokr_ Post #3



Preplace an unit for every player like a flag or something. The players who own a flag will be the players currently in game.
We'll create all the marines for P12 then equally give them to the current ingame players.

Code
Players:
- Player 8
Conditions:
- Whatever
Actions:
- Create 6 marine for P8 at loc
- Give all the marines owned by P8 at loc to P12
- Preserve trigger


Now we'll give the P12 marines equally to every player. To do so we'll use a deathcounter to keep track to what player we'll give the next unit. We'll only give units to the players that own flags.

Code
Players:
- Player 8
Conditions:
- P12 commands atleast 1 marine
- P8 has exactly 0 deaths of Unused Unit
- P1 commands atleast 1 flag
Actions
- Give 1 marine owned by P12 to P1
- Modify deaths for Unused Unit for P8: add 1
- Preserve trigger

... (the same for P2..P5)

Players:
- Player 8
Conditions:
- P12 commands atleast 1 marine
- P8 has exactly 5 deaths of Unused Unit
- P6 commands atleast 1 flag
Actions
- Give 1 marine owned by P12 to P6
- Modify deaths for Unused Unit for P8: set to 0
- Preserve trigger

Players:
- Player 8
Conditions:
- P12 commands atleast 1 marine
- P8 has exactly 0 deaths of Unused Unit
- P1 commands exactly 0 flag
Actions
- Modify deaths for Unused Unit for P8: add 1
- Preserve trigger

... (the same for P2..P5)

Players:
- Player 8
Conditions:
- P12 commands atleast 1 marine
- P8 has exactly 5 deaths of Unused Unit
- P6 commands exactly 0 flag
Actions
- Modify deaths for Unused Unit for P8: set to 0
- Preserve trigger


That should do the trick, and it'll also work if a player leaves :)

EDIT: Actually you'll need to remove all the flags for P12. Add this trigger on top of those ones:
Code
Players:
- Player 8
Conditions:
- Always
Actions:
- Remove all flags for P12
- Preserve trigger


Post has been edited 3 time(s), last time on Jun 12 2008, 9:23 pm by Clokr_.



?????

Jun 12 2008, 9:10 pm who Post #4



Can't you set it up like this?

For Player 8:
c: player 8 has gas
a: wait 5000
add 1 DC to all other players

For other players (individually):
c: suffered 1 of DC
a: create unit at location X, set DC to 0



None.

Jun 12 2008, 9:25 pm Clokr_ Post #5



I believe he wants 6 marines created regardless how many players are in game, then he wants them to be distributed equally for every player. The same with the marines owned by a player when they leave the game.
Modified my method a bit, I didn't realize that the original trigger only creates marines for 6 human players.



?????

Jun 13 2008, 9:25 pm NudeRaider Post #6

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

All of the above should work but it can be done much simpler:

Create the units for a computer player and make this trigger:
Force 1 *)
Conditions:
<any you see fit>
Actions:
Give 1 [men] from <comp player> to Current Player
Preserve trigger

*) Assuming the player Force is Force 1. If the Players are spread among multiple forces make 1 trigger for each Force.
Lower player numbers will have "first strike" when there are not enough units for all present players.

You might want to combine the above method with what Clokr_ suggested. Give the comp units to P12 and give from P12 instead. This has the advantage that you can control better which units are given and units from leavers are also given.




Jun 13 2008, 9:36 pm who Post #7



Oh, I didn't read the first post carefully enough. For equal distribution, NudeRaider has the simplest method



None.

Jun 13 2008, 9:41 pm Clokr_ Post #8



He really doesn't. If player 7 has 3 marines and leaves then player 6 has 3 marines and leaves my method ensures that the rest of players will recive marines almost equally. But with nuderaider's P1, P2 and P3 would recibe all the marines while P4 and P5 would recive none.



?????

Jun 14 2008, 8:00 am NudeRaider Post #9

We can't explain the universe, just describe it; and we don't know whether our theories are true, we just know they're not wrong. >Harald Lesch

Quote from Clokr_
He really doesn't. If player 7 has 3 marines and leaves then player 6 has 3 marines and leaves my method ensures that the rest of players will recive marines almost equally. But with nuderaider's P1, P2 and P3 would recibe all the marines while P4 and P5 would recive none.
My method works well in the beginning and if a leaver had many units.
Whereas you need to use Clokr_'s method if leavers leave only a few (1-5) units behind.




Options
  Back to forum
Please log in to reply to this topic or to report it.
Members in this topic: None.
[2026-10-11. : 6:02 am]
Donald -- Samase
[2026-10-09. : 2:53 am]
Mr.BurnLiquid -- Symmetry
Symmetry shouted: I'll check it out this weekend!
Thanks
[2026-10-09. : 2:47 am]
Symmetry -- I'll check it out this weekend!
[2026-10-09. : 2:40 am]
Mr.BurnLiquid -- Symmetry
Symmetry shouted: Another map maker? Damn we really ARE back
I invite you to try out the map I modified. I don't have the creativity to create maps from scratch, but I do have the know-how to modify existing ones; my project is to tweak community campaigns (specifically those with errors—to make them playable.
[2026-10-09. : 2:27 am]
Symmetry -- Another map maker? Damn we really ARE back
[2026-10-09. : 1:51 am]
Mr.BurnLiquid -- Ultraviolet
Ultraviolet shouted: Mr.BurnLiquid actually yeah though I wasn't really saying it to narc on you. It just caught me off guard because I don't usually see it (because it's against the rules) "The avatar may not be bigger than 150x150 pixels". Kinda silly that it relies on users to be well behaved rather than just limiting the dimensions on uploads :lol:
Now that I wanted to change my avatar, the error image is showing up, haha.
[2026-10-09. : 1:34 am]
Mr.BurnLiquid -- Ultraviolet
Ultraviolet shouted: Mr.BurnLiquid actually yeah though I wasn't really saying it to narc on you. It just caught me off guard because I don't usually see it (because it's against the rules) "The avatar may not be bigger than 150x150 pixels". Kinda silly that it relies on users to be well behaved rather than just limiting the dimensions on uploads :lol:
Mr.BurnLiquid
Mr.BurnLiquid shouted: Ultraviolet Thanks; I'm new to the site and a Spanish speaker. I must have missed the part where it was prohibited—I'll change it now.
I invite you to try out a mission I'm modifying from *StarCraft Reversed*; I'm trying to make it more playable and challenging.
[2026-10-09. : 1:33 am]
Mr.BurnLiquid -- Ultraviolet
Ultraviolet shouted: Mr.BurnLiquid actually yeah though I wasn't really saying it to narc on you. It just caught me off guard because I don't usually see it (because it's against the rules) "The avatar may not be bigger than 150x150 pixels". Kinda silly that it relies on users to be well behaved rather than just limiting the dimensions on uploads :lol:
Thanks; I'm new to the site and a Spanish speaker. I must have missed the part where it was prohibited—I'll change it now.
[2026-10-09. : 1:31 am]
Ultraviolet -- Mr.BurnLiquid
Mr.BurnLiquid shouted: Ultraviolet Is it forbidden to have a large avatar?
actually yeah though I wasn't really saying it to narc on you. It just caught me off guard because I don't usually see it (because it's against the rules) "The avatar may not be bigger than 150x150 pixels". Kinda silly that it relies on users to be well behaved rather than just limiting the dimensions on uploads :lol:
Please log in to shout.


Members Online: Wing Zero, Butch, NudeRaider