Basicly for my script I usually modify mohdm1, when I just add exec global/cardgame to it my dudes will play cards, but when I add the elevator part to the script suddenly the dudes think a lady has entered the room and they all want to stand.
Even when I add basic lines like global/exploder and global/bomber its enough to throw my cardgame.
So here it is maybe something will jump out and hit you. :]
Thanks
// SOUTHERN FRANCE
// ARCHITECTURE: SENN
// SCRIPTING: POWZER
main:
// set scoreboard messages
setcvar "g_obj_alliedtext1" "hanger_se"
setcvar "g_obj_alliedtext2" ""
setcvar "g_obj_alliedtext3" ""
setcvar "g_obj_axistext1" ""
setcvar "g_obj_axistext2" ""
setcvar "g_obj_axistext3" ""
setcvar "g_scoreboardpic" "hanger_se"
// call additional stuff for playing this map round
based is needed
if(level.roundbased)
thread roundbasedthread
exec global/cardgame.scr
level waitTill prespawn
thread elevator_preparation //Set the threads...
//*** Precache Dm Stuff
exec global/DMprecache.scr
level.script = maps/dm/hanger_se.scr
exec global/ambient.scr hanger_se
exec global/bomber.scr
exec global/exploder.scr
exec global/door_locked.scr
level waittill spawn
end
//------------------------------------------------------------
-----------------
elevator_preparation:
$elevator moveto $waypoint_down // Moves elevator to
waypoint_down.
$elevator_button bind $elevator // Attaches the
elevator_button into the elevator, this making it move same
time as the elevator.
$elevator time 4 // sets the elevator move time, 4 seconds in
this case, could also use the command "speed".
local.elepos = 0 // Defines the position of the elevator. "0 -
lift down" "1 - lift up" Default - lift down
goto elevator_standby // standing by and waiting player to
activate the trigger
//----------------------------------------------------------->
// Elevator is idle, and waiting user to activate the trigger
//----------------------------------------------------------->
elevator_standby:
$elevator_button waittill trigger
if (local.elepos == 0) // If lift state is down, its better
get up.
{
println "elevator down - moving up" //prints this text to
console if the developer mode is set.
goto lift_move_up // jumps straight to the "lift_move_up" part
in the script
}
else
if (local.elepos == 1) // Or maybe lift state is up, and you
need to get down?
{
println "elevator up - moving down" //prints this text to
console if the developer mode is set.
goto lift_move_down // jumps straight to the "lift_move_down"
part in the script
}
//----------------------------------------------------------->
lift_move_up:
$elevator moveto $waypoint_up //moves the lift to
info_waypoint with targetname waypoint_up
$elevator playsound elevator_run //plays the
"sound/mechanics/Mec_ElevatorRun_01.wav" defined in the
ubersound.scr line 1052
$elevator waitmove //wait till the elevator has completed the
move before doing anything else
local.elepos = 1 // it seems the elevator is up now, so we set
the local.elepos to 1
goto elevator_standby // Jumps back to the standby part of the
script waiting user to activate the trigger
//----------------------------------------------------------->
lift_move_down:
$elevator moveto $waypoint_down //moves the lift to
info_waypoint with targetname waypoint_down
$elevator playsound elevator_run //plays the
"sound/mechanics/Mec_ElevatorRun_01.wav" defined in the
ubersound.scr line 1052
$elevator waitmove //wait till the elevator has completed the
move before doing anything else
local.elepos = 0 // it seems the elevator is down now, so we
set the local.elepos to 1
goto elevator_standby // Jumps back to the standby part of the
script waiting user to activate the trigger
roundbasedthread:
// Can specify different scoreboard messages for round
based games here.
level waitTill prespawn
level waittill spawn
// set the parameters for this round based match
level.dmrespawning = 0 // 1 or 0
level.dmroundlimit = 5 // round time limit in minutes
level.clockside = kills // set to axis, allies, kills,
or draw
level waittill roundstart
end
little help with my script ... thanks
Moderator: Moderators
-
small_sumo
-
Guest