• Listen to a special audio message from Bill Roper to the Hive Workshop community (Bill is a former Vice President of Blizzard Entertainment, Producer, Designer, Musician, Voice Actor) 🔗Click here to hear his message!
  • Read Evilhog's interview with Gregory Alper, the original composer of the music for WarCraft: Orcs & Humans 🔗Click here to read the full interview.

problem with observers on my map

Status
Not open for further replies.
Level 15
Joined
Jul 9, 2008
Messages
1,552
ok so when some 1 picks to be an observer be for the game starts, then the game goes on(starts playing) they are no longer observers.....

they have full controll of there pre placed units they can only view there teams they can talk like normal and so on

also the fixxed player settings are checked if this has any thing to do with it

so what can i do to fix this problem

+rep for helpers
 
Level 5
Joined
Apr 8, 2006
Messages
130
You could try removing all of the placed units for that player.. so if the observer is player 7 get rid of all of player 7's units in WE

I don't think there is anything in the GUI that can detect whether a player is an observer or not but i'll take a look.. But normally in custom games, if there are observers they are seperate slots and have no units already in the game..
 
Level 15
Joined
Jul 9, 2008
Messages
1,552
Pre Placed units? Are they neutral or player owned, like player 1, 2 ect?

there player owned

You could try removing all of the placed units for that player.. so if the observer is player 7 get rid of all of player 7's units in WE

I don't think there is anything in the GUI that can detect whether a player is an observer or not but i'll take a look.. But normally in custom games, if there are observers they are seperate slots and have no units already in the game..

if i did do that the observer still cant see both sides like normal and chat as if there a normal player
 
Level 5
Joined
Apr 8, 2006
Messages
130
Well, try this.

  • Events
    • Make this whatever event you want to allow the player to become observer
  • Conditions
  • Actions
    • Visibility - Create an initally enabled visibility modifier for (triggering player) emitting Visibility across (Playable map area)
That will allow the player to see the full map after they have chosen to become an observer in-game because if they do it in the lobby you can't detect whether a player is an observer or not unless theres a JASS script that can, but i'm not sure... That'll let the player type to people and see the whole map area, I think :p
 
Level 6
Joined
May 7, 2009
Messages
228
I don't think it's possible to detect observers in the lobby. You'll have to make them pseudo observers through triggers as Hadhafang said.
 
Level 15
Joined
Jul 9, 2008
Messages
1,552
so like a player types -observer then have a trigger that makes all his/her units removed and turns of there unit spawns and then also istead of making them just veiw the hole map make all players treat them as allies so that he can see what there doing like in when u normaly observer

what would be the best way to turn off there unit spawns because all the players can get alot of spawing units


it works by after they reasearch a unit it turns on a trigger for e.g
  • Riflemen red
    • Events
      • Time - Every 30.00 seconds of game time
    • Conditions
      • (Player 1 (Red) slot status) Equal to Is playing
    • Actions
      • Set spawn_point[1] = (Center of Player 1 <gen>)
      • Unit - Create 1 Rifleman for Player 1 (Red) at spawn_point[1] facing Default building facing degrees
      • Custom script: call RemoveLocation (udg_spawn_point[1])
 
Well, i guess you could do it like
  • Trigger
  • Events
    • Time - Elapsed time is 0.00 seconds
  • Conditions
  • Actions
    • Set Force[1] = (All players matching ((((Matching Player)'s slot) Equal to Is Playing) and (((Matching Player) controller) Equal to User))
  • Trigger2
  • Events
    • Time - Every 30.00 seconds of game-time
  • Conditions
  • Actions
    • For each (Integer A) from 1 to 12, do (Actions)
      • Loop - Actions
        • Set Point1 = (Player(IntegerA)'s Start Location)
        • If (All conditions are true) then do (Actions) else do (Actions)
          • If - Conditions
            • ((Player(IntegerA)) is in Force[1]) Equal to True
          • Then - Actions
            • Unit - Create 1 Rifleman for (Picked Player) at Point1 facing default building degrees
          • Else - Actions
        • Custom script: call RemoveLocation (udg_Point1)
  • Trigger3
  • Events
    • Player - Player 1 (Red) types a message containing -observer as en exact match
    • Player - Player 2 (Blue) types a message containing -observer as en exact match
    • Player - Player 3 (Teal) types a message containing -observer as en exact match
    • Player - Player 4 (Purple) types a message containing -observer as en exact match
    • Player - Player 5 (Yellow) types a message containing -observer as en exact match
    • ....
  • Conditions
  • Actions
    • Player - Remove (Triggering Player) from Force[1]
    • Set Temp_Group = (Units owned by (Triggering Player))
    • Unit Group - Pick up every unit in (Temp_Group) and do (Actions)
      • Loop - Actions
        • Unit - Kill (Picked unit)
    • Player - Add (Triggering Player) to Force[2]
Force[1] is "Player Group" variable with Array. It is there to depict the default force of all user players.
Force[2] is there to depict the Observers' Group.
 
Level 15
Joined
Jul 9, 2008
Messages
1,552
i wana add a dialog for like are u sure kind of thing but im not sure how to do it

  • become observer
    • Events
      • Player - Player 1 (Red) types a chat message containing -observer as An exact match
      • Player - Player 2 (Blue) types a chat message containing -observer as An exact match
      • Player - Player 3 (Teal) types a chat message containing -observer as An exact match
      • Player - Player 4 (Purple) types a chat message containing -observer as An exact match
      • Player - Player 5 (Yellow) types a chat message containing -observer as An exact match
      • Player - Player 6 (Orange) types a chat message containing -observer as An exact match
      • Player - Player 7 (Green) types a chat message containing -observer as An exact match
      • Player - Player 8 (Pink) types a chat message containing -observer as An exact match
      • Player - Player 9 (Gray) types a chat message containing -observer as An exact match
      • Player - Player 10 (Light Blue) types a chat message containing -observer as An exact match
    • Conditions
    • Actions
      • Dialog - Clear Vote_Dialog
      • Dialog - Change the title of Vote_Dialog to Are you sure
      • Dialog - Create a dialog button for Vote_Dialog labelled Yes
      • Set Vote_buttons[3] = (Last created dialog Button)
      • Dialog - Create a dialog button for Vote_Dialog labelled Yes
      • Set Vote_buttons[4] = (Last created dialog Button)
      • Dialog - Show Vote_Dialog for (Triggering player)
and then ill have

  • confermed Observer
    • Events
      • Dialog - A dialog button is clicked for Vote_Dialog
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Vote_buttons[3]
        • Then - Actions
        • Else - Actions

i dunno because i cant use triggering player and i dont wana use a variable because if 2 people do it,it will overight each other
 
Level 6
Joined
Mar 20, 2008
Messages
208
constant native IsPlayerObserver takes player whichPlayer returns boolean

You're gonna have to jass it or add in a custom script inside the GUI trigger.
 
Level 15
Joined
Jul 9, 2008
Messages
1,552
i wana add a dialog for like are u sure kind of thing but im not sure how to do it

  • become observer
    • Events
      • Player - Player 1 (Red) types a chat message containing -observer as An exact match
      • Player - Player 2 (Blue) types a chat message containing -observer as An exact match
      • Player - Player 3 (Teal) types a chat message containing -observer as An exact match
      • Player - Player 4 (Purple) types a chat message containing -observer as An exact match
      • Player - Player 5 (Yellow) types a chat message containing -observer as An exact match
      • Player - Player 6 (Orange) types a chat message containing -observer as An exact match
      • Player - Player 7 (Green) types a chat message containing -observer as An exact match
      • Player - Player 8 (Pink) types a chat message containing -observer as An exact match
      • Player - Player 9 (Gray) types a chat message containing -observer as An exact match
      • Player - Player 10 (Light Blue) types a chat message containing -observer as An exact match
    • Conditions
    • Actions
      • Dialog - Clear Vote_Dialog
      • Dialog - Change the title of Vote_Dialog to Are you sure
      • Dialog - Create a dialog button for Vote_Dialog labelled Yes
      • Set Vote_buttons[3] = (Last created dialog Button)
      • Dialog - Create a dialog button for Vote_Dialog labelled Yes
      • Set Vote_buttons[4] = (Last created dialog Button)
      • Dialog - Show Vote_Dialog for (Triggering player)
and then ill have

  • confermed Observer
    • Events
      • Dialog - A dialog button is clicked for Vote_Dialog
    • Conditions
    • Actions
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • (Clicked dialog button) Equal to Vote_buttons[3]
        • Then - Actions
        • Else - Actions

i dunno because i cant use triggering player and i dont wana use a variable because if 2 people do it,it will overight each other

you talking abou this?
 
Status
Not open for further replies.
Top