Map is weird...

If you're looking for mapping help or you reckon you're a mapping guru, post your questions / solutions here

Moderator: Moderators

Post Reply
User avatar
mohaa_rox
Field Marshal
Posts: 2760
Joined: Mon Nov 11, 2002 7:05 am
Contact:

Map is weird...

Post by mohaa_rox »

My map is pretty weird. When starting, it does not add new objectives. But when I complete the objective, the objective appears, and puts a check. What is the problem? Is my script ok?

//The Rescue
//Architecture: Simon
//Scripting: Simon

main:

exec global/ai.scr
exec global/door_locked.scr::lock
exec global/exploder.scr
exec global/loadout.scr maps/test_therescue.scr

level waittill prespawn

exec global/ambient.scr 1l2

level waittill spawn

$player item weapons/colt45.tik
$player ammo pistol 1000
$player useweaponclass pistol
$player item weapons/m2frag_grenade.tik
$player ammo grenade 5
$player useweaponclass grenade
$player item weapons/m1_garand.tik
$player ammo rifle 1000
$player useweaponclass rifle
end

thread objectives

objectives:
waitthread global/objectives.scr::add_objectives 1 2 "Find and rescue the SAS agent." $obj1.origin
waitthread global/objectives.scr::current_objectives 1
end

objective1:
thread mission_complete
end

mission_complete:
waitthread global/objectives.scr::add_objectives 1 3 "Find and rescue the SAS agent." $obj1.origin
waitthread global/objectives.scr::current_objectives 0
exec global/missioncomplete.scr test_therescue
end
jv_map
Site Admin
Posts: 6521
Joined: Tue Sep 03, 2002 2:53 pm
Location: The Netherlands
Contact:

Post by jv_map »

I suppose the thread 'objective1:' is called from the BSP?

//The Rescue
//Architecture: Simon
//Scripting: Simon

main:
exec global/ai.scr
exec global/door_locked.scr::lock
exec global/exploder.scr

level waittill prespawn

exec global/ambient.scr m1l2

level waittill spawn

$player item weapons/colt45.tik
$player ammo pistol 1000
$player item weapons/m2frag_grenade.tik
$player ammo grenade 5
$player item weapons/m1_garand.tik
$player ammo rifle 1000
$player useweaponclass rifle
//end -> This would end the script!!

waitthread global/objectives.scr::add_objectives 1 2 "Find and rescue the SAS agent." $obj1.origin
waitthread global/objectives.scr::current_objectives 1
end

objective1:
thread mission_complete
end

mission_complete:
waitthread global/objectives.scr::add_objectives 1 3 "Find and rescue the SAS agent." $obj1.origin
waitthread global/objectives.scr::current_objectives 0
exec global/missioncomplete.scr test_therescue
end
Image
User avatar
mohaa_rox
Field Marshal
Posts: 2760
Joined: Mon Nov 11, 2002 7:05 am
Contact:

Post by mohaa_rox »

Ya, my trigger multiple is called a setthread objective1.
User avatar
mohaa_rox
Field Marshal
Posts: 2760
Joined: Mon Nov 11, 2002 7:05 am
Contact:

Post by mohaa_rox »

Ok, I had it fixed. Who wants to test out my beta test_therescue map? It's about rescuing Major Grillo in a Single Player campaign I'm working on.
Post Reply