Page 1 of 1

Can't Test Map

Posted: Thu Apr 22, 2004 11:12 pm
by MadMapper
Ive got my new (but small) objective test map... but I cant test the blow-up part cause the Allies win as soon as I join :(...

script

Posted: Fri Apr 23, 2004 12:29 am
by tltrude
Post the script in the scripting forum.

Posted: Fri Apr 23, 2004 12:36 am
by lizardkid
or, start a server and add some bots to it.

botify using jv_maps botify script thing. you dont need to botify it totally, jsut a couple nodes.

Posted: Fri Apr 23, 2004 8:00 pm
by MadMapper
Here's the script... basicly copy and pasted from the tutorial, with the needed changes

Code: Select all

// ARCHITECTURE: SlasherZ
// SCRIPTING: Bjarne Gr?nnevik / SlasherZ

main:


setcvar "g_obj_alliedtext1" "Destroy both walls" 
setcvar "g_obj_alliedtext2" "Defend the documents"
setcvar "g_obj_alliedtext3" ""
setcvar "g_obj_axistext1" "Defend both walls"
setcvar "g_obj_axistext2" "Steal the documents"
setcvar "g_obj_axistext3" ""
setcvar "g_scoreboardpic" "none"


level waittill prespawn


exec global/DMprecache.scr
level.script = maps/obj/garden.scr
exec global/ambient.scr garden
thread global/exploder.scr::main // Initialize the exploder subsystem


level waittill spawn


level.defusing_team = "axis" // Axis like the bombs unplanted
level.planting_team = "allies" // Allies will try to plant the bombs
level.targets_to_destroy = 1 // Number of targets in this map
level.bomb_damage = 200 // Default damage of the bomb
level.bomb_explosion_radius = 2048 // Default radius of bomb blast


// Set the parameters for round based match
level.dmrespawning = 0 // 1 or 0 (0=no respawn)
level.dmroundlimit = 5 // round time limit in minutes
level.clockside = axis // set to axis, allies, kills, or draw


// level waittill roundstart // Comment out this line using '//' before it to be able to set the bomb when alone on the map ( just for testing )


$panel_bomb thread global/obj_dm.scr::bomb_thinker // "panel_bomb" is the targetname set on the bomb in MOHRadiant
thread allies_win_bomb // Start the win check thread for allies
$panel_bomb thread axis_win_timer // Start the win check thread for axis
end // end of main

// Allied victory test


allies_win_bomb:
while(level.targets_destroyed < level.targets_to_destroy) // While undestroyed objectives left
waitframe // chill out
teamwin allies // No objectives left allies win
end // end allied victory test

// Axis victory test


axis_win_timer:
level waittill axiswin // At the end Axis win
end // end axis victory test

map

Posted: Fri Apr 23, 2004 8:49 pm
by tltrude
You must of made a mistake in the map because the script thinks the bomb has been blown up. You should probably do that tutorial again (the mapping part), or find a different one for objective maps.

Posted: Fri Apr 23, 2004 8:55 pm
by MadMapper
hmm... Ill try that