| 02-28-2006, 08:22 PM | #1 |
Im trying to make it so Players_1 can pick from - Free for all - Teams of 2players - Teams of 3players - Teams of 4players - Teams of 6players However when he selects the option from a dialogue the players are Randomly shuffeled and put into the appropiate team formats. I think Im on the right track, just need alittle help. I was thinking first, detect which player slots are active, then add them to a player group. If the total number of players active is NOT dividable by the teams then automatically make it FFA if not start dividing the players up into the appropiate teams. Create a Player group for each team and equally divide the players into the groups. Set the alliances/enemies. Is this the best way to do it? Ill give it a try see if it works. thank you |
| 02-28-2006, 10:56 PM | #2 |
Ok im stuck. Ive got all the active players in 1 variable group. I've created a seperate group for each team. All I need to do is randomly take ppl from the main group and divide them up amongst the team groups. Code:
Player Group - Add (Random player from PickTeamsGroup) to TeamsSize2No1 If I had 4 players in main group and I did the above trigger 4 times, would it not possiblity pick the same player twice? How can I randomly remove a player from the first group and still add him to a teamgroup? thank you |
| 03-01-2006, 02:57 AM | #3 |
Take the easy way out. My suggestion would be this: Create a boolean array. When you pick a player out filter it through the condition that their boolean is false(standard boolean setting after its created). Then once a player is picked set their boolean to true. This should effectively filter out previously picked players without the need for adding and removing them from some main group(aside from "Allplayers") |
| 03-01-2006, 10:07 PM | #5 |
Player Group - Pick every player in (All players matching (((Matching player) slot status) Equal to Is playing)) This is one of the most annoying triggers in existance. It is buggy. Try using player group - pick every place in (All players matching (((matching player) controller Equal to User)). |
| 03-02-2006, 09:16 AM | #6 |
I tried it that way it doesnt work either. End up with 3 allies, 1 enemy |
