Narutimmy Posted October 6, 2013 Posted October 6, 2013 Hola como puedo detectar que un auto entro a un area?
Narutimmy Posted October 6, 2013 Author Posted October 6, 2013 Si es un colshape cononColShapeHit lo ise asi: function hill_Enter ( thePlayer ) local theVehicle = getPedOccupiedVehicle ( thePlayer ) setVehicleDamageProof( theVehicle, true) end addEventHandler ( "onColShapeHit", hillArea, hill_Enter ) function hill_Exit ( thePlayer ) local theVehicle = getPedOccupiedVehicle ( thePlayer ) setVehicleDamageProof( theVehicle, false) end addEventHandler ( "onColShapeLeave", hillArea, hill_Exit ) si funciona pero si el auto entra sin un piloto.... no funciona
Sensacion Posted October 7, 2013 Posted October 7, 2013 Prueba con algo como: function hill_Enter ( hitElement ) if getElementType ( hitElement ) == "vehicle" then setVehicleDamageProof( hitElement, true) end end addEventHandler ( "onColShapeHit", hillArea, hill_Enter )
Recommended Posts