ok MadJack and Ifurita…
i have been reading, and studying more and i can say that i understand parts of a script and can recongnise (kind of) what happens in the different routines and triggers and things… sort of at least.
so i decided to make a test map, for practicing in… using two tutorials, one by sock on these forums about the forward spawn, and one by marko on destructible objectives and ive tried to tie them together but it’s not quite working… would you point me in the right direction? i think its the wobj bit.
i have a simple map with the following entities in it:
red and blue spawns (permanent ‘back’ spawns, away from the flag)
red and blue spawns around the flag with targetnames oldcityspawns
a team_WOLF_checkpoint with the following keys/values:
targetname oldcityflag
scriptname oldcityflag
target oldcityspawns // points to the nearby spawns with the corresponding names yes?
spawnflags 1 // am i right in thinking this makes it default axis?
a team_WOLF_objective witht he following: (I DONT UNDERSTAND THIS ENTITY OR ITS PURPOSE)
targetname old_city_wobj
scriptname old_city_wobj
description Old City
spawnflags 1
a func_explosive
targetname dynawall // dont understand the importance of this key???
scriptname oldcitywall
noise brick
mass 200
a trigger_objective_info
spawnflags 1
objflags 4 //makes dynamite logo appear???
track the thing you must blow up // the hint?
and here is my script in whole, as you cans ee im still cut/pasting too much but at least im trying:
game_manager
{
spawn
{
accum 1 set 0 // State of objective number one
accum 5 set 0 // Corrent number of Pak 75mm guns destroyed
accum 6 set 0 // Current number of water pumps built
accum 7 set 0 // Value used in checking whether or not to announce "Axis have damaged both water pumps!"
globalaccum 5 set 0
globalaccum 6 set 0
// Game rules
wm_axis_respawntime 30
wm_allied_respawntime 20
wm_number_of_objectives 8
wm_set_round_timelimit 30
// Objectives
// 1: Primary1 : Destroy the North gun
// 2: Primary2 : Destroy the South gun
// 3: Primary3 : Breach Old City wall
// 4: Secondary1 : Capture forward spawn point
// 5: Secondary2 : Drain/flood cave system by repairing/damaging the Oasis pump
// 6: Secondary3 : Drain/flood cave system by repairing/damaging the Old City pump
// 7: Allied command post
// 8: Axis command post
// Current main objectives for each team (0=Axis, 1=Allies)
wm_set_main_objective 3 0
wm_set_main_objective 3 1
// Objective overview status indicators
//wm_objective_status <objective> <team (0=Axis, 1=Allies)> <status (0=neutral 1=complete 2=failed)>
wm_objective_status 1 1 0
wm_objective_status 1 0 0
wm_objective_status 2 1 0
wm_objective_status 2 0 0
wm_objective_status 3 1 0
wm_objective_status 3 0 0
wm_objective_status 4 1 0
wm_objective_status 4 0 0
wm_objective_status 5 1 0
wm_objective_status 5 0 0
wm_objective_status 6 1 0
wm_objective_status 6 0 0
wm_objective_status 7 1 0
wm_objective_status 7 0 0
wm_objective_status 8 1 0
wm_objective_status 8 0 0
// Stopwatch mode defending team (0=Axis, 1=Allies)
wm_set_defending_team 0
// If the round timer expires, the Axis have won, so set the current winning team
// Set the round winner: 0 == AXIS, 1 == ALLIED
wm_setwinner 0
// Set autospawn markers <team (0 = axis, 1 = allies)> <message key of marker>
// Spawns on siwa:
// Axis Garrison
// Allied Camp
// Old City
wait 150
setautospawn "Old City" 1
setautospawn "Old City" 0
wait 350
disablespeaker wp1_sound // water pump 1
disablespeaker wp2_sound // water pump 2
disablespeaker hose1_sound1 // water outlet 1
disablespeaker hose1_sound2 // water tunnel 1
disablespeaker hose2_sound1 // water outlet 2
disablespeaker hose2_sound2 // water tunnel 2
disablespeaker allies_compost_sound // allies command post
disablespeaker axis_compost_sound // axis command post
disablespeaker axis_compost_sound_lms // axis command post lms
wait 2000
// *----------------------------------- vo ------------------------------------------*
wm_addteamvoiceannounce 0 "oasis_axis_city_defend"
wm_addteamvoiceannounce 0 "oasis_axis_pumps_stop"
wm_addteamvoiceannounce 0 "axis_hq_compost_construct"
wm_addteamvoiceannounce 1 "oasis_allies_city_capture"
wm_addteamvoiceannounce 1 "oasis_allies_pumps_repair"
wm_addteamvoiceannounce 1 "allies_hq_compost_construct"
wm_teamvoiceannounce 0 "oasis_axis_city_defend"
wm_teamvoiceannounce 0 "oasis_axis_pumps_stop"
wm_teamvoiceannounce 0 "axis_hq_compost_construct"
wm_teamvoiceannounce 1 "oasis_allies_city_capture"
wm_teamvoiceannounce 1 "oasis_allies_pumps_repair"
wm_teamvoiceannounce 1 "allies_hq_compost_construct"
// *---------------------------------------------------------------------------------*
}
oldcityflag
{
spawn
{
accum 0 set 0 // Who has the flag: 0-Axis, 1-Allied
}
trigger axis_capture // Flag has been touched by an Axis player
{
accum 0 abort_if_equal 0 // do Axis own flag?
accum 0 set 0 // Axis own the pole
wm_announce "Axis reclaim the Old City!"
// *----------------------------------- vo ------------------------------------------*
wm_addteamvoiceannounce 0 "oasis_axis_city_defend"
wm_addteamvoiceannounce 1 "oasis_allies_city_capture"
wm_teamvoiceannounce 0 "oasis_axis_city_captured"
wm_teamvoiceannounce 1 "oasis_allies_city_lost"
wm_removeteamvoiceannounce 0 "oasis_axis_wall_defend"
wm_removeteamvoiceannounce 1 "oasis_allies_wall_destroy"
// *---------------------------------------------------------------------------------*
wm_objective_status 4 0 1
wm_objective_status 4 1 2
alertentity old_city_wobj
}
trigger allied_capture // Flag has been touched by an allied player
{
accum 0 abort_if_equal 1 // do Allies own flag?
accum 0 set 1 // Allied own the flag
wm_announce "Allies capture the Old City!"
// *----------------------------------- vo ------------------------------------------*
wm_addteamvoiceannounce 0 "oasis_axis_wall_defend"
wm_addteamvoiceannounce 1 "oasis_allies_wall_destroy"
wm_teamvoiceannounce 0 "oasis_axis_city_lost"
wm_teamvoiceannounce 0 "oasis_axis_wall_defend"
wm_teamvoiceannounce 1 "oasis_allies_city_captured"
wm_teamvoiceannounce 1 "oasis_allies_wall_destroy"
wm_removeteamvoiceannounce 0 "oasis_axis_city_defend"
wm_removeteamvoiceannounce 1 "oasis_allies_city_capture"
// *---------------------------------------------------------------------------------*
wm_objective_status 4 0 2
wm_objective_status 4 1 1
alertentity old_city_wobj
}
trigger check_obj
{
accum 0 abort_if_equal 1 // Do Allied own the flag?
wm_objective_status 4 0 2
wm_objective_status 4 1 1
}
trigger force_allied
{
accum 0 abort_if_equal 1 // Do Allied own the flag?
alertentity old_city_wobj
alertentity oldcityspawns
}
trigger kill
{
remove
}
}
oldcitywall //Broken section of Old City wall
{
spawn
{
wait 200
constructible_class 3
}
death
{
trigger oldcityflag force_allied // Switch forward spawn to Allied ONLY
trigger oldcityflag check_obj
trigger oldcityflag kill
wm_announce "Allies have breached the Old City wall"
// *----------------------------------- vo ------------------------------------------*
wm_addteamvoiceannounce 0 "oasis_axis_paks_defend"
wm_addteamvoiceannounce 1 "oasis_allies_paks_destroy"
wm_teamvoiceannounce 0 "oasis_axis_wall_destroyed"
wm_teamvoiceannounce 0 "oasis_axis_paks_defend"
wm_teamvoiceannounce 1 "oasis_allies_wall_destroyed"
wm_teamvoiceannounce 1 "oasis_allies_paks_destroy"
wm_removeteamvoiceannounce 0 "oasis_axis_wall_defend"
wm_removeteamvoiceannounce 0 "oasis_axis_city_defend"
wm_removeteamvoiceannounce 1 "oasis_allies_wall_destroy"
wm_removeteamvoiceannounce 1 "oasis_allies_city_capture"
// *---------------------------------------------------------------------------------*
wm_objective_status 3 0 2
wm_objective_status 3 1 1
wm_set_main_objective 1 0
wm_set_main_objective 1 1
}
}
}
what you wrote and I can’t really answer as I don’t know what is not working neither what that test map is supposed to be doing.
