Skip to content
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Donate
Collapse

Plutonium

  1. Home
  2. BO2 Modding Support & Discussion
  3. [Support] GSC: Spectators?

[Support] GSC: Spectators?

Scheduled Pinned Locked Moved BO2 Modding Support & Discussion
4 Posts 3 Posters 148 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • undefined Offline
    undefined Offline
    Farzad
    wrote on Apr 6, 2020, 5:05 PM last edited by Mr. Android Apr 7, 2020, 7:23 PM
    #1
    
    checkAllowSpectating()
    {
    wait ( 0.05 );
    
    update = false;
    if ( !level.aliveCount[ game["attackers"] ] )
    {
    level.spectateOverride[game["attackers"]].allowEnemySpectate = 1;
    update = true;
    }
    if ( !level.aliveCount[ game["defenders"] ] )
    {
    level.spectateOverride[game["defenders"]].allowEnemySpectate = 1;
    update = true;
    }
    if ( update )
    maps\mp\gametypes\_spectating::updateSpectateSettings();
    }
    
    

    -If I wanted to set spectators to an automatic team, axis or allies, would this be the right code to do it, I think It’s not?

    1 Reply Last reply
    0
    • undefined Offline
      undefined Offline
      GewoonIraj VIP
      wrote on Apr 6, 2020, 5:35 PM last edited by
      #2

      If you don't know if it's the right/wrong code for it: test it.

      1 Reply Last reply
      0
      • undefined Offline
        undefined Offline
        Sorex Contributor
        wrote on Apr 6, 2020, 5:51 PM last edited by
        #3

        Farzad what is your code? the code to go in spectator mode?
        Use this to go in spectator mode

        goInSpectator(){
            self maps\mp\gametypes\_spectating::setSpectatePermissions();
            self allowSpectateTeam( "freelook", true );
            self.sessionstate = "spectator";
        }
        
        undefined 1 Reply Last reply Apr 6, 2020, 6:09 PM
        0
        • undefined Offline
          undefined Offline
          Farzad
          replied to Sorex on Apr 6, 2020, 6:09 PM last edited by Farzad Apr 6, 2020, 9:10 PM
          #4

          Sorex With SnD, you can’t just spawn in if you connect late and the round has started.. I’m looking to auto set any spectators (people who connect late to the round and can’t spawn in) to allies or axis

          1 Reply Last reply
          0

          2/4

          Apr 6, 2020, 5:35 PM

          • Login

          • Don't have an account? Register

          • Login or register to search.
          1 / 1
          • First post
            2/4
            Last post
          0
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Donate