| 07-12-2003, 11:02 PM | #1 | |
Hi there. I am having a problem with the game i am making. What i am attempting to accomplish by this trigger is that when a player enters a region (selecting either cop or robber) it places them as the ally to everyone else in that playergroup. The problem is, when a person selects the unit, it doesn't always set them as allies to the other people! It works sometimes and sometimes it doesn't. This get's to be a real problem in the game i am creating. My trigger is below, if anyone knows of a better and more effective way to do this i'll be forever greatful and would even be willing to give credit to in my map =P Quote:
|
| 07-13-2003, 12:27 AM | #2 |
Maybe this is why A personenters robber then a person enters before the unit is spawned causing this problem so the trigger has to be disabled so no one can do it until that person is done |
| 07-13-2003, 02:46 AM | #3 |
ack well unfortunately i still have the same problem =\ i added a turn off trigger at the beginning and a turn on at the end, however it still ahs the same problem as before |
| 07-13-2003, 08:49 AM | #4 |
Guest | Your trigger seemes to be really messed up. I've added comment next to the trigger functions: Events Unit - A unit enters Choice Robber <gen> Conditions AllowedRobbers Greater than 0 -(what does Allowedrobbers stand for?)- Actions Set AllowedRobbers = (AllowedRobbers - 1) Player Group - Add (Owner of (Triggering unit)) to Robber Player Group - Pick every player in Robber and do (Actions) Loop - Actions Set PlayerVariable = (Picked player) -(I'm assuming playervariable is not a playergroup but just a playervariable)- -(cause you can't assign multiple players to a playervariable I'm assuming 'robber' now only consist of 'owner of triggering unit')- HINT: If u assign multiple players to a playervariable the computer randomly picks one of the players u assigned. Player Group - Pick every player in Robber -(which is the owner is triggering unit)- and do (Player - Make PlayerVariable -(which also is the owner is triggering unit)- treat (Picked player) -(himself!)- as an Ally with shared vision) Player Group - Pick every player in Robber -(which is the owner is triggering unit)- and do (Player - Make (Picked player) -(which is the owner is triggering unit)- treat PlayerVariable -(which is the owner is triggering unit) -as an Ally with shared vision) Unit - Remove (Triggering unit) from the game Unit - Create 1 Robber for (Owner of (Triggering unit)) at (Random point in Robber Spawn <gen> ) facing Default building facing degrees If (AllowedRobbers Equal to 0) then do (Game - Display to (All players) for 3.00 seconds the text: All the Robbers hav...) else do (Do nothing) Trigger - Run Leaderboard <gen> (ignoring conditions |
| 07-14-2003, 01:04 AM | #5 |
I see what my problem is in your post, however i have absolutely no idea how i would go about fixing this problem. I hate begging for help when i have not made any contribution myself, but this one thing has had me stumped for over 3 days =\ |
| 07-14-2003, 05:16 AM | #6 |
Guest | You might want to try this: Robber Spawn Events Unit - A unit enters Choice Robber <gen> Conditions AllowedRobbers Greater than 0 Actions Set AllowedRobbers = (AllowedRobbers - 1) Player Group - Pick every player in Robber and do (Player - Make (Owner of (Triggering Unit)) treat (Picked player) as an Ally with shared vision) Player Group - Pick every player in Robber and do (Player - Make (Picked player) treat (Owner of (Triggering Unit)) as an Ally with shared vision) Player Group - Add (Owner of (Triggering unit)) to Robber Unit - Remove (Triggering unit) from the game Unit - Create 1 Robber for (Owner of (Triggering unit)) at (Random point in Robber Spawn <gen> ) facing Default building facing degrees If (AllowedRobbers Equal to 0) then do (Game - Display to (All players) for 3.00 seconds the text: All the Robbers hav...) else do (Do nothing) |
| 07-14-2003, 08:03 AM | #7 |
Guest | If you could send me your map I could try and fix your problem. Cause the trigger you posted doesn't really show me what you want to accomplish. Triggers are my field so I think fixing it won't be a problem. |
