| Author |
Topic: SP Objectives & AI spawning. |
| antonio.horvatovic0 |
General Member Since: Jan 31, 2014 Posts: 225 Last: Jul 14, 2017 [view latest posts] |
|
|
|
Category: CoD2 SP Mapping Posted: Sunday, Oct. 19, 2014 12:11 pm |
 |
After getting home drunk and doing some tests I've figured it out...
make a trigger_once and name it obj2. The add the weapon panzherscrheck on the ground and make the trigger_once cover it. Than add this to your map.gsc
{
obj2 = getent("obj2","targetname");
objective_add(2,"active",&"NOYERS_NOYERS_PANZERSCHRECK",( -665, -22, 45));
objective_current(2);
while(!level.player hasweapon("panzerschreck"))
wait .1;
//obj2 waittill (!level.player hasweapon("panzerschreck"));
objective_state(2,"done");
obj2 delete();
}
edited on Oct. 19, 2014 05:12 am by antonio.horvatovic0 |
 |
|
|
| 65kawasaki |
General Member Since: Nov 15, 2013 Posts: 73 Last: Sep 19, 2017 [view latest posts] |
|
|
|
|
| antonio.horvatovic0 |
General Member Since: Jan 31, 2014 Posts: 225 Last: Jul 14, 2017 [view latest posts] |
|
|
|
|
| 65kawasaki |
General Member Since: Nov 15, 2013 Posts: 73 Last: Sep 19, 2017 [view latest posts] |
|
|
|
Category: CoD2 SP Mapping Posted: Sunday, Oct. 19, 2014 04:36 pm |
 |
|
 |
|
|
| 65kawasaki |
General Member Since: Nov 15, 2013 Posts: 73 Last: Sep 19, 2017 [view latest posts] |
|
|
|
|
| antonio.horvatovic0 |
General Member Since: Jan 31, 2014 Posts: 225 Last: Jul 14, 2017 [view latest posts] |
|
|
|
Category: CoD2 SP Mapping Posted: Thursday, Oct. 30, 2014 01:02 pm |
 |
Make a script_model and give it these values:
key:model
value:xmodel/german_artillery_flak88_nm
Now give it a targetname of flak_obj1
key:targetname
value:flak_obj1
Make another script_model with these values
key:model
value:xmodel/german_artillery_flak88_nm_destroy
give the model a targetname flak_destroy1.
key:targetname
value:flak_destroy1
Now take this destroyed model and place it where the other flak model is so they overlap.
Make another script_model and give it these values
key:model
value:xmodel/military_tntbomb
Give it a targetname.
key:targetname
value:flak_bomb1
Place that tnt model somewhere on the flak, but do not connect it.
Make another script_model and give it these values.
key:model
value:xmodel/military_tntbomb_obj
You will not see a model only a empty blue box kinda thing but don't worry it is there.
give it a targetname.
key:targetname
value:flak_bomb_glow1
Now just as you did with the flaks overlap this tnt over the other tnt.
Make a trigger_use and give it a targetname.
key:targetname
value:flak_trig1
You can give the trigger_use a message that appears when the player walks near the trigger to alert him or her what to do. To do this do the following:
key:hintstring
value:Press [USE] to plant the explosives
///////////////////////////////
THIS IS MY SCRIPT SO YOU NEED TO CHANGE THE OBJ STRINGS AND ORIIN POINTS :D
ADD THIS TO YOUR MAIN SCRIPT:
main()
{
maps\_flak88::main("xmodel/german_artillery_flak88_nm");
maps\_load::main();
precacheModel("xmodel/german_artillery_flak88_nm_destroy");
precacheModel("xmodel/military_tntbomb");
precacheModel("xmodel/military_tntbomb_obj");
precacheShader("hudStopwatch");
precacheShader("hudStopwatchNeedle");
precacheShader("inventory_tnt_small");
}
THEN CALL THE FLAK THREAD SOMEWHERE AFTER YOUR OBJECTIVE
Flak1()
{
objective_add(4, "active",&"BOCAGE_OBJ3",(1336, 2198, 24));///change these coordinates to where your script_model is
objective_current(4);
glow1 = getent("flak_bomb_glow1", "targetname");
flakbomb1 = getent("flak_bomb1", "targetname");
flakbomb1 hide();
flak1 = getent("flak_obj1", "targetname");
flak1.health = 10000000;
flak_d1 = getent("flak_destroy1", "targetname");
flak_d1 hide();
flaktrig1 = getent ("flak_trig1", "targetname");
flaktrig1 waittill("trigger",other);
wait .05;
level notify("bomb_planted");
glow1 delete();
flakbomb1 show();
flaktrig1 delete();
wait .05;
level notify("bomb_planted");
flakbomb1 playSound( "explo_plant_no_tick" );
flakbomb1 playLoopSound( "bomb_tick" );
level.bombstopwatch = maps\_utility::getstopwatch(60);//setClock( level.explosiveplanttime, 60, "hudStopwatch", 64, 64 ); // count down for 10 of 60 seconds, size is 64x64
wait ( level.explosiveplanttime );
flakbomb1 stopLoopSound( "bomb_tick" );
level.bombstopwatch destroy();
radiusdamage(flak1.origin, 216, 350, 50);
earthquake( 0.25, 1, flak1.origin, 1000 );
flak_d1 playsound ("flak88_explode");
playfx( level._effect["flak_burst"], flak1.origin );
playfx( level._effect["flak88_explode"], flak1.origin );
flak1 delete();
flakbomb1 delete();
flak_d1 show();
playfx( level._effect["damaged_vehicle_smoke"], flak1.origin );
playfx( level._effect["flak_dust_blowback"], flak1.origin );
flak1 notify("death");
wait 2;
objective_state(4, "done");
}
|
 |
|
|
| 65kawasaki |
General Member Since: Nov 15, 2013 Posts: 73 Last: Sep 19, 2017 [view latest posts] |
|
|
|
|
| sgt.hawkins |
General Member Since: Apr 12, 2013 Posts: 122 Last: Nov 28, 2016 [view latest posts] |
|
|
|
|
| antonio.horvatovic0 |
General Member Since: Jan 31, 2014 Posts: 225 Last: Jul 14, 2017 [view latest posts] |
|
|
|
Category: CoD2 SP Mapping Posted: Thursday, Oct. 30, 2014 07:28 pm |
 |
sgt.hawkins writes...Quote: The easiest way would make the player have to destroy them in order. then just write the objective "destroy flak guns. 3 remaining." then after you destroy the first one make the second objective "destroy flak guns. 2 remaining" ect...
I approve it :D |
 |
|
|
| 65kawasaki |
General Member Since: Nov 15, 2013 Posts: 73 Last: Sep 19, 2017 [view latest posts] |
|
|
|
Category: CoD2 SP Mapping Posted: Thursday, Oct. 30, 2014 07:37 pm |
 |
|
 |
|
|
|
|
mp_TempleCall of Duty: Mods: Multiplayer (624.12Kb)
|