Post: Drivable Cop Car !!!
10-25-2012, 03:05 AM #1
crazymodzz
Pokemon Trainer
(adsbygoogle = window.adsbygoogle || []).push({}); Hey guys so i was just looking around and saw this


And here is the code

BTW: I really dont know who created this so im sorry about the Credits on this.


    carSpawner()
{
self setOrigin((300,300,40.5)); //sets the coordinates for you to spawn
racecar = spawn( "script_model", (0,0,40.5) ); //sets the coordinates for the model to spawn
racecar.angles = (0,10,0); //sets the models angles
racecar.targetname = "destructible_vehicle"; //sets the type
racecar.destructible_type = "vehicle_policecar"; //sets the destructable type if it is destructable
racecar setModel( "vehicle_policecar_lapd_destructible" ); //sets the model
racecar common_scripts\_destructible::setup_destructibles( );
racecar.inUse = 0; //necessary var
for(;Winky Winky
{
if(distance(self.origin, racecar.origin) <100 && racecar.inUse == 0)
{
self iPrintlnBold("Press X to use"); //Text
}


if(distance(self.origin, racecar.origin) <100 && self usebuttonpressed() && racecar.inuse == 0)
{
self iPrintlnBold("You are now driving");
racecar.inUse = 1;
self playerlinkto(racecar); //links you to the model
self setPlayerAngles(racecar.angles+(0,0,0)); //sets your angles to the models
self takeAllWeapons(); //deletes weapons
wait 1.0;
}

if(racecar.inUse == 1 && self usebuttonpressed())
{
racecar.inUse = 0;
self unlink(racecar); //unlinks you from the model
self giveWeapon( "deserteaglegold_mp", 0, false ); //gives you gold deagle
wait 1.0;
}

if(racecar.inUse == 1 && self attackbuttonpressed())
{
if(racecar.angles != self.angles+(0,0,0) && racecar.inUse == 1)
{
racecar.angles = self.angles+(0,0,0); //checks to make sure the models angles are equal to yours
}
racecar moveto(racecar.origin+anglestoforward(self getplayerangles())*200, 0.05); //Necessary move function
wait 0.001;
}
wait 0.01;
}
}


Have fun and i put this out there because i dont see this In patchs and its still fun to use !!!!!!
(adsbygoogle = window.adsbygoogle || []).push({});

The following 2 users say thank you to crazymodzz for this useful post:

-Xperia-, *xActionMods*
10-25-2012, 05:04 PM #11
lolololololoolol
10-25-2012, 10:12 PM #12
crazymodzz
Pokemon Trainer
Originally posted by BlurzGoHard View Post
you put carSpawner() twice is there a reason or was that a accident? some people might not know just trying to help others


Thanks i'll fix that

Originally posted by another user
LightModz
I think your right about GodlyModz creating this because he did make that Garage Mod which was really cool and involed driveable stuff, but im not very sure about it so no credits right now :blank:
10-26-2012, 10:28 PM #13
crazymodzz
Pokemon Trainer
it was GodlyModz that made this i did research aha thts a first :boss:

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo