kevin11 Posted June 13, 2010 Posted June 13, 2010 (edited) well i tried making a no dmg for cars and it worked but this is my problem when i start the resource and spawn a car it works but when i spawn a new car it get damaged it only works if i keep restarting the resource everytime im going into a new car here is my code vehicles = getElementsByType ( "vehicle" ) for vehicleKey, vehicleValue in ipairs(vehicles) do setVehicleDamageProof( vehicleValue, true) end addEventHandler ( "onVehicleEnter", setVehicleDamageProof ) Edited June 13, 2010 by Guest
The_Ex Posted June 13, 2010 Posted June 13, 2010 Your code sets damageProof once (when you start the resource). So you have to use setVehicleDamageProof every time you spawn a new vehicle. MTASA.LV - Latvian MTA Community
kevin11 Posted June 13, 2010 Author Posted June 13, 2010 Your code sets damageProof once (when you start the resource). So you have to use setVehicleDamageProof every time you spawn a new vehicle. ?this doesnt work either
dzek (varez) Posted June 13, 2010 Posted June 13, 2010 DO NOT EDIT POST AFTER SOMEBODY REPLY! addEventHandler("onVehicleEnter", getRootElement(), function() setVehicleDamageProof(source,true) end) Multi theft auto tools - replace cars and peds, move your map or compile your Lua files online! programista php rzeszów Need free webhosting for your small site? PM me. Need help with portforwarding? PM me. Do not PM me asking for help with scripting. Having problems with port forwarding? Send me pm, I can do whole thing for you using TeamViewer (already helped about 20 people, no worries)!
dzek (varez) Posted June 13, 2010 Posted June 13, 2010 i just hit the keyboard with my head.. somebody, please tell him WHY.. I can't, i just can't stand it.. Multi theft auto tools - replace cars and peds, move your map or compile your Lua files online! programista php rzeszów Need free webhosting for your small site? PM me. Need help with portforwarding? PM me. Do not PM me asking for help with scripting. Having problems with port forwarding? Send me pm, I can do whole thing for you using TeamViewer (already helped about 20 people, no worries)!
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