Login x
User Name:
Password:
Social Links Facebook Twitter YouTube Steam RSS News Feeds

Members Online

»
0 Active | 101 Guests
Online:

LATEST FORUM THREADS

»
CoD: Battle Royale
CoD+UO Map + Mod Releases
Damaged .pk3's
CoD Mapping
heli to attack ai
CoD4 SP Mapping

Tutorials

»
CoD2 Mapping
ratings:
Awful Rating
Poor Rating
Average Rating
Good Rating
Excellent Rating
Door Kick Tutorial
Versions: You must be logged in to view history.
Door Kick Tutorial by Ace008

door3qp8_400

Alright lets get started

Step 1: Create a node_scripted and give it a targetname:

Value:targetname
Key:door_node

doortutym2_400

Step 2: Create an actor of your choosing and give him a targetname:

Value:targetname
Key:doorkicker


doortut1gb0_400

Step 3: Create your door, which the actor will kick, and turn it into a script_brushmodel. To do this while the door is selected right click in your grid and look for something called script. Inside that you will see script_brushmodel, which you will click. The door will turn blue on the grid to let you know it is now a script_brushmodel.

** NOTE: When you make the first door, add a origin brush that has the same targetname with it. Without this the door moves way to quick and looks unrealistic.

Now give the door a targetname:

Value:targetname
Key:door

Also while the door is selected press N and put a check in the box that says DynamicPath.

doortut2fs1_400

Step 4: Create another door the same size as the first with the same texture of course and turn it into a script_brushmodel. This door is where the first door will
swing to after the actor kicks it so place it where you want the door to end up.

doortut3gc2_400

Step 5: Now select the first door and then the second door and press W to connect them. You will see a blue line indicating they are connected.

doortut4zu0_400

Step 6: Draw out a brush and make it a trigger_once. To do this right click in your grid and under trigger there will be
something called once. Now give it a targetname:

Value:targetname
Key:door_trig

doortut5sh6_400

Step 7: This is the last part for mapping! Place the scripted node about 10 units away from the door so it looks like the actor is actually kicking it. If it is any farther away it looks kinda odd. Also make sure the node is facing towards the door . To do this on top there is a button that has a Z with an arrow to N(The 8th button on the row) click that and an arrow will appear from the node. Make sure that arrow is pointing towards the door so the actor kicks in the correct direction.

////////////////////

Okay now the feared part, the part everyone hates...Scripting WUHAAAAA.

Step 1: Create a GSC file called mymapname.gsc and copy this code into it:

#include maps\_utility;
#include maps\_anim;

main()
{


maps\_load::main();
mapsmymapname_anim::main();

level.player takeallweapons();
level.player giveWeapon ("enfield");
level.player switchToWeapon ("enfield");

thread kick_door();
}
kick_door()
{




door_node = getnode ("door_node", "targetname");

doortrig = getent("door_trig","targetname");

doortrig waittill("trigger",other);


level.doorkicker = getent("doorkicker","targetname");
level.doorkicker.animname = "doorkicker";
level.doorkicker.anim_node = door_node;
level.doorkicker notify ("stop friendly think");

level.doorkicker thread magic_bullet_shield();
level.doorkicker.ignoreme = true;

level maps\_anim::anim_reach_solo (level.doorkicker, "kickdoor", undefined, door_node);
level.doorkicker pushPlayer (false);
door_node thread maps\_anim::anim_single_solo (level.doorkicker, "kickdoor");

level.doorkicker waittillmatch ("single anim", "soundfx = kickdoor");

door = getent ("door", "targetname");
door playsound ("kickdoor");

door rotateyaw(90,.5,.2,.2);

door connectpaths();

level.doorkicker notify ("stop magic bullet shield");
level.doorkicker.ignoreme = false;

}


Step 2: Now make another gsc fille and call it mymapname_anim.gsc and copy this code into it:

#using_animtree("generic_human");
main()
{

//animations
level.scr_anim["doorkicker"]["kickdoor"] = (%kickdoor_guy2);
}

Thats it for scripting, aren't you happy!

//////////////////////

Okay Now for the Sound in your COD2 main folder create a folder called Soundaliases. Inside that create
a new text document and place this code into it:

name,sequence,file,vol_min,vol_max,vol_mod,pitch_min,pitch_max,
dist_min,dist_max,channel,type,probability,loop,masterslave,loadspec,
subtitle,compression,secondaryaliasname,volumefalloffcurve,startdelay,
speakermap,reverb,lfe percentage

#door,,,,,,,,,,,,,,,,,,,,,,,
kickdoor,1,doors/door_wd_kick.wav,0.92,0.92,foley,0.9,0.9,350,2000,auto,,,,,mymapname,,,

*note: that first line of code is all one line.

Save this as mymapname.csv and you are all done.


Now go compile and admire your work!

Latest Syndicated News

»
Codutility.com up and runn...
Nice, and there still using the logo and template for the screenshots, which...
Codutility.com up and runn...
dundy writes...Quote:Call of Duty modding and mapping is barly alive only a ...
Codutility.com up and runn...
Mystic writes...Quote:It seems to me the like the site is completely dead? ...
Codutility.com up and runn...
It seems to me the like the site is completely dead?

Partners & Friends

»