Page 1 of 1

force spectate

Posted: Mon Mar 13, 2006 11:21 pm
by ViPER
How do you force dead players to spectate from map script?

3D

Posted: Tue Mar 14, 2006 2:59 am
by tltrude
Not sure you can, but you can force everyone into 3D mode.

setcvar cg_3rd_person 1

0 - turns it back off. You can also force them all to watch from a camera location.

Code: Select all

missle_explode:

	level.missle_destroyed = 1
	$watch_camera fov 70 2
	setcvar cg_3rd_person 1
	$watch_camera watch "$missle_burn" 0
	if (level.missle_gone == 0)
	{
		$watch_camera watch "$silo_origin" 0
	}
	$watch_camera cut
	cuecamera $watch_camera

	local.fire3 = spawn script_model 
	local.fire3 model models/emitters/missile_explosion.tik // was  fx/fx_flak88_explosion.tik 
 	local.fire3.origin = $missle.origin + (0 0 0)
 	local.fire3.scale = 3
	local.fire3 anim start

	if (level.missle_gone == 1)  // Skips these if missile is in silo.
	{
			//wait .4
		$mexplode2 anim start
		wait .4
		$mexplode1 anim start
	}

	$missle stoploopsound
	$mexplode1 playsound v4_explode_snd
	wait .2
	exec global/earthquake.scr 3 .5 0 0

	$missle_fire unbind $missle
	$missle_fire.scale = 5
	$missle_fire anim start

	$missle2 show
	$missle2 unbind $missle
	$missle remove
	$missle_fire bind $missle2
	$missle_burn moveto $missle2
	$missle_burn move

	$engine_1 anim stop
	$engine_2 anim stop
	$rocket_steam1 anim stop
	$rocket_steam2 anim stop
	$ventfire1 anim stop
	$ventfire2 anim stop
	$mexplode2 anim stop
	$engine_lite remove

	$missle_burn anim start

	$missle2 notsolid          // Falling missile
	$missle2 speed 150
	$missle2 time 6 // was 8
	$missle2 moveto $silo_origin

	if (level.missle_gone == 1)  // Skips these if missile is in silo.
	{
	$missle2 rotateY 30
	$missle2 rotateZup 95
	}

	$missle2 waitmove
	$silo_clip remove

	$missle_burn remove
	local.fire7 = spawn script_model 
	local.fire7 model models/emitters/missile_explosion.tik 
 	local.fire7.origin = $missle2.origin
 	local.fire7.scale = 3
	local.fire7 anim start

	$silodoor_left remove
	$silodoor_right remove
	exec global/exploder.scr::explode 1
	thread kill_gawkers
	$v4_startup_speaker playsound v4_explode_snd
	exec global/earthquake.scr 3 .5 0 0
	thread pusher
	$missle2 hide

	wait 10
	$missle_fire anim stop
	teamwin allies
	wait 3
	setcvar cg_3rd_person 0

end

Posted: Tue Mar 14, 2006 3:03 am
by PKM
hey tl, uh what does that above script do in layman's terms ? 'cause i dunno but with the word's missle in it, gotta say like it'd look damn cool.

Posted: Tue Mar 14, 2006 6:07 am
by ViPER
Thanks Tom,

looks like it forces everyone to view an event from a camera angle. What i'm trying to do, is as players die I want to force them to spectate down to the last.

spawn

Posted: Tue Mar 14, 2006 7:58 am
by tltrude
Hmmm, have you tried removing all the spawn spots after the last player joins the game? Come to think of it, isn't there a game type setting that makes everyone wait in spectate until the last guy on one team is killed?

That thread is from the map "Gotterdammerung". A brillent conversion of a StarWars Jedi Outcast map called "Kejim". It has been transformed into a Nazi ICBM base! This isn't your typical "V2 Facility" map because the Allied Players can shoot the missile down as it takes off. Axis Players must try to keep the silo doors closed, and prevent the allied players from stopping the countdown, or destroying their final hope for victory!

Posted: Tue Mar 14, 2006 9:22 am
by ViPER
not in FFA -

Posted: Tue Mar 14, 2006 2:11 pm
by Rookie One.pl
Viper, check out Mefy's freeze tag scripts.

Re: spawn

Posted: Tue Mar 14, 2006 4:58 pm
by PKM
tltrude wrote:
That thread is from the map "Gotterdammerung". A brillent conversion of a StarWars Jedi Outcast map called "Kejim". It has been transformed into a Nazi ICBM base! This isn't your typical "V2 Facility" map because the Allied Players can shoot the missile down as it takes off. Axis Players must try to keep the silo doors closed, and prevent the allied players from stopping the countdown, or destroying their final hope for victory!
thanks tl, i thought the code was some kind of ''sound effect/view effect'' initiated when a player is foreced into spectate.

Posted: Tue Mar 14, 2006 5:46 pm
by ViPER
Thanks Rookie, I will.