Help stopping certain people spawning in rounds
#1
any sort of dvar or something i can prevent certain players spawning in sd for a round or so?

#2
Not sure about how you could stop them spawning, but the very frame that they spawn, you could send them to spectator/different team/kill them.

Code:
init() { level thread spawndvar(); } spawndvar() { if(getdvarint("scr_nospawn") == "") { setdvar("scr_nospawn", 0); } } onPlayerSpawned() { self waittill("spawned_player"); if(getdvarint("scr_nospawn") == 1) self suicide(); // (or change team/put to spectate/whatever) }

You'd have to edit it a little bit to make it work with certain players, just set the dvar to the players entity number, and when it checks the dvar check it against their entity number.

#3
ya i thought about doing it this way, was just hoping there was some dvar to stop people spawning in sd..


guess it will do for now, thanks anyways.

#4
(07-27-2011, 15:39)koil Wrote: any sort of dvar or something i can prevent certain players spawning in sd for a round or so?

this spawn a player:
Code:
self thread [[level.spawnPlayer]]();

find this code on _globallogic_spawn.gsc and modify like this:
Code:
if(self.canspawn == 1) { self thread [[level.spawnPlayer]](); } else { level waittill("notify"); //or self waittill self thread [[level.spawnPlayer]](); }

#5
(07-28-2011, 00:47)Puffiamo Wrote:
(07-27-2011, 15:39)koil Wrote: any sort of dvar or something i can prevent certain players spawning in sd for a round or so?

this spawn a player:
Code:
self thread [[level.spawnPlayer]]();

find this code on _globallogic_spawn.gsc and modify like this:
Code:
if(self.canspawn == 1) { self thread [[level.spawnPlayer]](); } else { self waittill("notify"); self thread [[level.spawnPlayer]](); }

Change self.canspawn to self.pers["canspawn"] , because otherwise it will be lost after 1 round.

#6
if(self.pers["mod_ts"] != 1) {
self thread [[level.spawnPlayer]]();
}
else {
self thread respawn_asSpectator( self.origin + (0, 0, 60), self.angles );
spawnedAsSpectator = true;
}


worked well, thanks man.. I already had my own variable set from another thread, this worked great.



Possibly Related Threads…
Thread Author Replies Views Last Post
  Help Spawning carepackage helicopter -- DidUknowiPwn 4 5,721 11-08-2013, 08:18
Last Post: DidUknowiPwn
  Spawning Solid Models akillj 5 6,143 09-08-2013, 00:07
Last Post: akillj
  Chicken spawning possible? akillj 8 7,045 09-07-2013, 06:22
Last Post: ScHmIdTy56789
  Help Server not in list, but people join 99IRock 8 9,032 07-17-2013, 21:26
Last Post: clacki
  I need to sorry all of you people Bloodfocus 23 16,352 04-05-2013, 18:15
Last Post: SuperNovaAO
  I want to thank some people [2] Mods edition Arteq 7 8,498 04-05-2013, 18:10
Last Post: SuperNovaAO
Question Help Kick people with space in name koro35 13 11,500 01-06-2013, 14:14
Last Post: master131
Heart Thanking some people 99IRock 6 5,523 12-27-2012, 14:40
Last Post: kokole
  I want to thank some people 99IRock 5 4,919 12-26-2012, 18:33
Last Post: surtek
  [Request] ForgeMOD - Spawning Crates (MW3) Destroyer1834 8 8,065 11-23-2012, 14:56
Last Post: 99IRock

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2026 Melroy van den Berg.