Gia Testata.
Client Side :
Fai un file e chiamalo -> rimorchio.lua <- ed inserisci questo :
addEventHandler("onClientVehicleEnter", root,
function(thePlayer, seat)
local theVehicle = source
if seat == 0 and thePlayer == localPlayer and getElementModel(theVehicle) == 515 then
rimorchio = createVehicle ( 450, 0, 0, 0 )
attachTrailerToVehicle ( theVehicle, rimorchio)
end
end
)
addEventHandler("onClientVehicleExit", root,
function(thePlayer, seat)
local theVehicle = source
if seat == 0 and thePlayer == localPlayer and getElementModel(theVehicle) == 515 then
destroyElement (rimorchio)
end
end
)
Nel meta.xml aggiungi :
<script src="rimorchio.lua" type="client" />
Aggiungi questa stringa subito dopo
Esempio :
<meta>
<script src="rimorchio.lua" type="client" />