just a quick suggestion, can't really see the script that well (my monitors facing the sun )
anyway if you add to your script,
//level waittill spawn //after this line
wait 5
iprintlnbold "is it working." // this'll show you onscreen whether it's running any of the script,
//if this doesn't appear after the 5 second wait after spawning then you know that there is something wrong with the script
//otherwise if this appears you know that the entities are named wrong or a similar problem
hope this helps, prob not cos it's all foreign 2 me :-/
If U are running the map in a pk3, and there is an equal *.scr file in the maps dir: MOHAA will run the file in the maps dir... thus ignoring the one in the *.pk3.
Only thing I can think of.
No, one more thing: write logfile 1 in the consol berfore starting the map ( this will write all consol text to a file named qconsole.log in the main folder )
$player item weapons/bar.tik
$player item weapons/springfield.tik
$player item weapons/colt45.tik
$player item weapons/m2frag_grenade.tik
$player ammo mg 1000
$player ammo rifle 1000
$player ammo pistol 1000
$player ammo grenade 1000
$player useweaponclass mg thread setup_1
thread setup_2
end //you have an end here? the only reason you will want this is for play testing and if you have a this thread before it, when testing your scripts 2 decide which parts aren't working it's easier to disable a thread rather than disabling imparticular lines, hopefully that makes sense
setup_1:
$tank hide
$tank_trigger hide //you don't need to hide a trigger
$bomb hide
$medic_trigger hide
$save1 hide
end
setup_2:
thread friendly_setup
thread ai_guys_atwork
thread objectives
thread mg
end
objectives:
waitthread global/objectives.scr::add_objectives 1 2 "Locate the rest of your squad." $one.origin
end
starting:
$3 runto $start
$3 turnto $player
$3 lookat $player
$3 waittill movedone
wait 0.2
$3 exec global/stand.scr
$3 say dfr_m5l1_add01 //come with me sir, the rest of the tank crew is holed up back here
$3 waittill saydone
$3 turnto NULL
$3 lookat NULL
$3 runto $runhere
thread objective1
end
objective1:
$obj1 waittill trigger
waitthread global/objectives.scr::add_objectives 1 3 "Locate the rest of your squad." $one.origin
wait 2
iprintlnbold_noloc "Your medic needs some health supplies before your squad can follow you."
iprintlnbold_noloc "Find him some health supplies."
waitthread global/objectives.scr::add_objectives 2 2 "Find some supplies for your medic." $obj1.origin
end
deathmessage1:
self waittill death
iprintlnbold "Sergeant Hammon has been killed in action."
end
deathmessage2:
self waittill death
iprintlnbold "T/2 Engineer Campbell has been killed in action."
end
deathmessage3:
self waittill death
iprintlnbold "T/4 Medic Glenn has been killed in action."
end
objective2:
$health remove
waitthread global/objectives.scr::add_objectives 2 3 "Find some supplies for your medic." $obj1.origin
wait 2
iprintlnbold_noloc "Now bring back the supplies to your medic."
$medic_trigger show
waitthread global/objectives.scr::add_objectives 3 2 "Bring back the supplies to your medic." $obj2.origin
thread obj3
end
obj3:
$medic_trigger waittill trigger
waitthread global/objectives.scr::add_objectives 3 3 "Bring back the supplies to your medic." $obj2.origin
thread friendlies
end
friendlies:
//making friendlies friendly
if (isAlive $3)
{
$3 thread global/friendly.scr::friendlythink
$3.friendtype = 5
$3.distance = 128
$3.destination = $player
}
if (isalive $1)
{
$1 thread global/friendly.scr::friendlythink
$1.friendtype = 1
$1.distance = 128
$1.destination = $player
}
if (isalive $2)
{
$2 thread global/friendly.scr::friendlythink
$2.friendtype = 1
$2.distance = 128
$2.destination = $player
} //you may find it easier to use self thread commands here if multiple targets are using the same script
thread obj4
end
obj4:
$save1 show
$tank_trigger show//not sure as to what the trigger is for but just hiding and showing it won't disable the trigger, you will need "$tank_trigger triggerable" or "$tank_trigger nottriggerable" respectively (note the "" surround the script, the whole sentence isn't script)
$tank show
waitthread global/objectives.scr::add_objectives 4 2 "Find the explosives." $obj4.origin
thread tank_start
end
objective4:
$explosives remove
waitthread global/items.scr::add_item "explosives"
waitthread global/objectives.scr::add_objectives 4 3 "Find the explosives." $obj4.origin
wait 2
waitthread global/objectives.scr::add_objectives 5 2 "Use the explosives to destroy the fence." $obj5.origin
$bomb show // would you not need "thread objective5" in here
end
objective5:
$bomb model "animate/explosive.tik"
$bomb playsound explosive
$player loopsound bombtick
$player stopwatch 10
wait 10
$player stoploopsound bombtick
$bomb playsound explode_tank
$bomb remove
exec global/exploder.scr::explode 1
radiusdamage $hurtobject 256 384
waitthread global/objectives.scr::add_objectives 5 3 "Use the explosives to destroy the fence." $obj5.origin
end
objective1:
$obj1 waittill trigger
waitthread global/objectives.scr::add_objectives 1 3 "Locate the rest of your squad." $one.origin
wait 2
iprintlnbold_noloc "Your medic needs some health supplies before your squad can follow you."
iprintlnbold_noloc "Find him some health supplies."
waitthread global/objectives.scr::add_objectives 2 2 "Find some supplies for your medic." $obj1.origin end
$obj1.origin is the compass isn't it if you use " $obj1 waittill tigger " won't it point at your current location ? and don't you need a thread objective2 at the end of this thread? And a start for objective 5 and or a trigger?
It seems to me to be something about the triggers are they trigger_multiples ? . I guess you know you can use a trigger_multiple with a key of setthread and a value of objective1 to trigger the thread instead of useing $obj1 waittill trigger .
$obj trigger is my first objective trigger, which is to find the soliders. It's origin is $one.origin
$obj1.origin is my second objective's origin. And "objective2" is a setthread used in this case.
Live to map, not map to live. -mohaa_rox, .map
moderator