Post: Cod4 CarePackages That Are Solid + Code
02-24-2011, 04:38 PM #1
nay1995
The Master
(adsbygoogle = window.adsbygoogle || []).push({}); This is from a Se7ensins member DJQUICKSILVER

So i just brought it to the NGU community

All credit goes to DJQUICKSILVER

I know a lot of people want to know how to make bunkers and skybases like the ones in MW2 so i thought I would give a shot at coding solid models.
Unfortunately Call of Duty 4 doesn't support the ability to turn models solid so I have had to create a new function that allows you to create a barrier.

level.solid = spawn( "trigger_radius", ( 0, 0, 0 ), 0, 65, 30 ); //spawns the barrier
level.solid.origin = (0,0,0); //sets the location
level.solid.angles = (0, 90, 0); //sets the angles
level.solid setContents( 1 ); //sets the contents of the barrier

Example: stairway to heaven from MW2

self thread stairz(70); //add to onPlayerSpawned
self thread stair(70); //add to onPlayerSpawned

stairz(size)
{
stairz = [];
stairPos = self.origin+(100, 0, 0);
for(i=0;i<=size;i++)
{
newPos = (stairPos + ((58 * i / 2 ), 0, (17 * i / 2)));
stairz = spawn("script_model", newPos);
stairz.angles = (0, 90, 0);
wait .1;
stairz setModel( "com_plasticcase_green_big" );
}
}

stair(size)
{
stairz = [];
stairPos = self.origin+(100, 0, 0);
for(i=0;i<=size;i++)
{
newPos = (stairPos + ((58 * i / 2 ), 0, (17 * i / 2)));
level.packo = spawn( "trigger_radius", ( 0, 0, 0 ), 0, 65, 30 );
level.packo.origin = newpos;
level.packo.angles = (0, 90, 0);
level.packo setContents( 1 );
}
}
(adsbygoogle = window.adsbygoogle || []).push({});
03-01-2011, 11:19 AM #11
GaLaXy98-q8
Maggbot timeout!
OMG Thats Great Codes Thankes

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo