Colakohle Posted April 29, 2012 Share Posted April 29, 2012 I am searching for a resource, that can attach objects to vehicles.... like this: https://www.youtube.com/watch?v=KVZtOaaibq4 I think i have seen this resource a few years ago but i can't find it... Is it possible to make one that can do something like that? Sorry for my bad englisch.... Link to comment
Wei Posted April 29, 2012 Share Posted April 29, 2012 (edited) local ccx,ccy,ccz,ccrx,ccry,ccrz= 0,2.5,0.1,0,0,0 local cx,cy,cz,crx,cry,crz= 0,-1.5,-0.1,0,0,-90 local x,y,z,rx,ry,rz= -0.7,-0.0,0.8,0,0,-90 local ax,ay,az,arx,ary,arz= -0.4,-0.0,0.8,0,0,-90 local aax,aay,aaz,aarx,aary,aarz= -0.1,-0.0,0.8,0,0,-90 local aaax,aaay,aaaz,aaarx,aaary,aaarz= 0.2,-0.0,0.8,0,0,-90 local aaaax,aaaay,aaaaz,aaaarx,aaaary,aaaarz= 0.5,-0.0,0.8,0,0,-90 function upgradeTheCar(cmd) local veh = getPedOccupiedVehicle ( localPlayer ) cminigun = createObject( 1636, 2,2,2) minigun = createObject( 2985, 2,2,2) base = createObject( 360, 2,2,2) abase = createObject( 360, 2,2,2) aabase = createObject( 360, 2,2,2) aaabase = createObject( 360, 2,2,2) aaaabase = createObject( 360, 2,2,2) setElementCollisionsEnabled ( base, false ) attachElements ( cminigun, veh, ccx,ccy,ccz,ccrx,ccry,ccrz) attachElements ( minigun, veh, cx,cy,cz,crx,cry,crz) attachElements ( base, veh, x,y,z,rx,ry,rz) attachElements ( abase, veh, ax,ay,az,arx,ary,arz) attachElements ( aabase, veh, aax,aay,aaz,aarx,aary,aarz) attachElements ( aaabase, veh, aaax,aaay,aaaz,aaarx,aaary,aaarz) attachElements ( aaaabase, veh, aaaax,aaaay,aaaaz,aaaarx,aaaary,aaaarz) end addCommandHandler("upgradeMyCar", upgradeTheCar) this is the sample. if you type command /upgradeMyCar it will make some things like that. You can modyfy it free P.S when you type command go out of vehicle. Edited April 29, 2012 by Guest Link to comment
Colakohle Posted April 30, 2012 Author Share Posted April 30, 2012 Thanks! i hope it works perfect Edit: it don't work... i made an meta.xml and an script.lua and then i put it into an zip file. i put it on my server started the resource enter the command but it ain't work... D: Link to comment
Wei Posted April 30, 2012 Share Posted April 30, 2012 Thanks! i hope it works perfect Edit: it don't work... i made an meta.xml and an script.lua and then i put it into an zip file. i put it on my server started the resource enter the command but it ain't work... D: Did you make it client side? And when you enter command the go out of car! Link to comment
Colakohle Posted April 30, 2012 Author Share Posted April 30, 2012 Sorry i'm new.... how to make it client side D: Link to comment
Wei Posted April 30, 2012 Share Posted April 30, 2012 <meta> <script src="script.lua" type="client"/> </meta> Link to comment
Colakohle Posted April 30, 2012 Author Share Posted April 30, 2012 Ah now it work thanks! Can everyone on my server see this upgrade? Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now