Icône de clé de contrôle FIVEM
if(GetDistanceBetweenCoords(coords.x, coords.y, coords.z, trunkpos.x, trunkpos.y, trunkpos.z, true) < 2.5) and not tube then
sleep = 0
DrawText3Ds(trunkpos.x, trunkpos.y, trunkpos.z - 0.5, "To pull out the hose, press [E]")
if(IsControlJustReleased(0, Keys['E']) and not IsPedInAnyVehicle(ped, false)) then
FreezeEntityPosition(ped, true)
startAnim(ped, 'mini@repair', 'fixing_a_ped')
Citizen.Wait(1000)
ClearPedTasks(ped)
FreezeEntityPosition(ped, false)
tube = true
for i=1, 3 do
Citizen.Wait(5)
RopeLoadTextures()
end
rope = AddRope(trunkpos.x, trunkpos.y, trunkpos.z, 0.0, 0.0, 0.0, 10.0, 3, 1.0, 1.0, 0, 0, 0, 0, 0, 0, 0)
AttachEntitiesToRope(rope, Trailer, ped, trunkpos.x, trunkpos.y, trunkpos.z-1.0, coords.x, coords.y, coords.z, 1.0)
StartRopeWinding(rope)
ActivatePhysics(rope)
RopeForceLength(rope, 4.0)
end
rv_7tp