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.
[07:46 am]
RIVE -- :wob:
[2024-4-22. : 6:48 pm]
Ultraviolet -- :wob:
[2024-4-21. : 1:32 pm]
Oh_Man -- I will
[2024-4-20. : 11:29 pm]
Zoan -- Oh_Man
Oh_Man shouted: yeah i'm tryin to go through all the greatest hits and get the runs up on youtube so my senile ass can appreciate them more readily
You should do my Delirus map too; it's a little cocky to say but I still think it's actually just a good game lol
[2024-4-20. : 8:20 pm]
Ultraviolet -- Goons were functioning like stalkers, I think a valk was made into a banshee, all sorts of cool shit
[2024-4-20. : 8:20 pm]
Ultraviolet -- Oh wait, no I saw something else. It was more melee style, and guys were doing warpgate shit and morphing lings into banelings (Infested terran graphics)
[2024-4-20. : 8:18 pm]
Ultraviolet -- Oh_Man
Oh_Man shouted: lol SC2 in SC1: https://youtu.be/pChWu_eRQZI
oh ya I saw that when Armo posted it on Discord, pretty crazy
[2024-4-20. : 8:09 pm]
Vrael -- thats less than half of what I thought I'd need, better figure out how to open SCMDraft on windows 11
[2024-4-20. : 8:09 pm]
Vrael -- woo baby talk about a time crunch
[2024-4-20. : 8:08 pm]
Vrael -- Oh_Man
Oh_Man shouted: yeah i'm tryin to go through all the greatest hits and get the runs up on youtube so my senile ass can appreciate them more readily
so that gives me approximately 27 more years to finish tenebrous before you get to it?
Please log in to shout.


Members Online: MetalGear, Roy, jjf28, lil-Inferno