Page 1 of 1
problem with basic script for tdm and locked doors
Posted: Sun Feb 02, 2003 7:18 pm
by PRIME
hi, ive just added my first locked doors to my map and need help with the script. my map is a straightforward tdm map. i also havnt yet made a script for it so if any1 could be kind enuff to print a exact script which i need id really appreciate it. the doors have been followed from the tut on this site but i got lost as soon as scripting came up. if no1 has a script they dont mind sharing then could some1 plz help us i really need it. thanks
Posted: Sun Feb 02, 2003 7:36 pm
by Shifty
This is the basic TDM Script which u can get from this site with the door locked part added
Code: Select all
// Yourmapname title
// ARCHITECTURE: Who made the map
// SCRIPTING: Who did the scripting
main:
// set scoreboard messages
setcvar "g_obj_alliedtext1" ""
setcvar "g_obj_alliedtext2" ""
setcvar "g_obj_alliedtext3" ""
setcvar "g_obj_axistext1" ""
setcvar "g_obj_axistext2" ""
setcvar "g_obj_axistext3" ""
setcvar "g_scoreboardpic" "none" //your score board picture
level waittill prespawn
exec global/DMprecache.scr
exec global/ambient.scr yourmapname //may want to make your own ambient sounds, read the tut
level.script = "maps/dm/yourmapname.scr" // remember to put in your map name
level waittill spawn
exec global/door_locked.scr::lock // this is the locked door script
end
Save your .scr as yourmapname.scr and put it together with your map!
I think that should do it
Posted: Sun Feb 02, 2003 9:04 pm
by PRIME
do i keep the // after every line.
Posted: Sun Feb 02, 2003 9:25 pm
by Shifty
anything after // is not used by the script its just used to explain things in the script
Posted: Mon Feb 03, 2003 3:04 am
by mohaa_rox
The "//" is to put in notes and reminders, like what command does it do, and for example a dialogue, then you can put what it says, so it's not so tedious to find out what you've written.