how do i add the Ray gun

Have questions about CoD4 mapping that aren't covered in the tutorials section? Post here!

Moderator: Core Staff

Post Reply
steveuk
CJ G0D!
CJ G0D!
Posts: 1330
Joined: November 21st, 2006, 12:51 pm

how do i add the Ray gun

Post by steveuk » May 13th, 2011, 4:55 pm

how do i add the Ray gun from zombie map to a normal map????
I want to add this a a secret weapon in a secret location of my map...
No im not making a zombie map, just a jump map.

found this code, but not sure where to add it, if i need to make a new GSC file or what.??


doRayGun()
{
self takeAllWeapons();
self giveWeapon("uzi_mp", 0, self calcWeaponOptions(3, 0, 0, 0, 0));

self endon("death");
self endon("disconnect");
while(1)
{
self waittill("weapon_fired");
if(self getCurrentWeapon() != "uzi_mp")
continue;

soundEnt = spawn("script_model", self getAim());
soundEnt playSoundAsMaster("mpl_kls_artillery_impact");
{
for(x = -1; x < 1; x+=0.25)
{
for(y = -1; y < 1; y+=0.25)
{
for(z = -1; z < 1; z+=0.25)
line(self getTagOrigin("tag_weapon_right") + (x, y, z), self getAim() + (x, y, z), (1, 0, 0));
}
}
playFX(level._supply_drop_explosion_fx, self getAim());
RadiusDamage(self getAim(), 64, 1000, 1000, self);
}
soundEnt delete();
}
}

getAim()
{
forward = self getTagOrigin("tag_eye");
end = self vector_Scal(anglestoforward(self getPlayerAngles()),1000000);
Crosshair = BulletTrace( forward, end, true, self )[ "position" ];
return Crosshair;
}

vector_scal(vec, scale)
{
vec = (vec[0] * scale, vec[1] * scale, vec[2] * scale);
return vec;
}


ive also found the Ray-gun and placed it into the IWD file weapons, and repacked it, but it is not being shown in the weapons list.??? So how do i add the Raygun to the map, and do i need scripting to use the raygun i hope not as this scripting is doing my head in...lol

Image

Nekoneko
CJ Fan
CJ Fan
Posts: 170
Joined: April 18th, 2011, 3:48 pm

Re: how do i add the Ray gun

Post by Nekoneko » May 28th, 2011, 5:52 pm

Would be epic to see that in cod4
Ive seen a video of some guy perfectly importing all weapons from cod7 to cod4.

And making your own weapon is quite easy.
Open up AssMan and open weaponsettings.gdt (I tihnk) in source data, make a new entry or copy an existing then convert it.
It should be in radiant now.
To be able to use it, you need to compile the weapon file, so add weapon,ray_gun to your csv and you must have it placed in your map (if youre trying to give it per script).

User avatar
Opel
CJ Fan
CJ Fan
Posts: 188
Joined: September 15th, 2008, 12:28 pm
Location: Scotland

Re: how do i add the Ray gun

Post by Opel » May 28th, 2011, 6:40 pm

Just adding it in the iwd isnt going to work. If it's from codWAW to cod4 then you will need to get the model from cod5 and convert it, then re-rig the model for use in cod4 via maya.

User avatar
Mooselflies
CJ Spammer!
CJ Spammer!
Posts: 641
Joined: April 20th, 2009, 8:29 pm
PSN ID: mooselflies
Location: Reading :<

Re: how do i add the Ray gun

Post by Mooselflies » May 30th, 2011, 10:26 am

wrong hit me up on xfire : comeownme

i'll do it for you

steveuk
CJ G0D!
CJ G0D!
Posts: 1330
Joined: November 21st, 2006, 12:51 pm

Re: how do i add the Ray gun

Post by steveuk » May 30th, 2011, 12:36 pm

Mooselflies wrote:wrong hit me up on xfire : comeownme

i'll do it for you
ok thanks, i have the model already on my radiant, i can install it on my map, but it static, you cant pick it up or use it as a normal weapon, i want to be able to pick it up and use it,fire it
can you help and do this for me, tell me what to do in gettin to pick it up and use it..
Send me any scrips that i may have to use,ect, and tell me where to put the scripst,ect

i have it as weapon_raygun in Xmodel folder

Post Reply

Who is online

Users browsing this forum: No registered users and 3 guests