Hikayeler

Reklam vermek için turkmmo@gmail.com
Kaynak ikonu

Fivem Geri Sayım Scripti 2020-03-13

indirmek için izniniz yok

Kullanılması gerekli:
TriggerEvent('lorraxs_progress', time-in-milsec, function(isBusy)
 if not isBusy then
   your-code
 end
end)

Gerekli kod:
TriggerEvent('lorraxs_progress', time-in-milsec, function(isBusy)
 if not isBusy then
   your-code
 end
end)
Example with esx_extraitems (oxygen_mask):

RegisterNetEvent('esx_extraitems:oxygen_mask')
AddEventHandler('esx_extraitems:oxygen_mask', function()
    TriggerEvent('lorraxs_progress', 200000, function(isBusy)
    if not isBusy then
        local playerPed  = GetPlayerPed(-1)
        local coords     = GetEntityCoords(playerPed)
        local boneIndex  = GetPedBoneIndex(playerPed, 12844)
        local boneIndex2 = GetPedBoneIndex(playerPed, 24818)
        
        ESX.Game.SpawnObject('p_s_scuba_mask_s', {
            x = coords.x,
            y = coords.y,
            z = coords.z - 3
        }, function(object)
            ESX.Game.SpawnObject('p_s_scuba_tank_s', {
                x = coords.x,
                y = coords.y,
                z = coords.z - 3
            }, function(object2)
                AttachEntityToEntity(object2, playerPed, boneIndex2, -0.30, -0.22, 0.0, 0.0, 90.0, 180.0, true, true, false, true, 1, true)
                AttachEntityToEntity(object, playerPed, boneIndex, 0.0, 0.0, 0.0, 0.0, 90.0, 180.0, true, true, false, true, 1, true)
                SetPedDiesInWater(playerPed, false)               
                Citizen.Wait(200000)  --Because we trigger hud with 200000ms
                SetPedDiesInWater(playerPed, true)
                DeleteObject(object)
                DeleteObject(object2)
                ClearPedSecondaryTask(playerPed)
                end)
            end)
        end
    end)
end)


Ekli dosyayı görüntüle 4373
Yazar
ShadowBluRay
Kaynak İndirilme
2
Görüntüleme
435
İlk yayınlama
Son Güncelleme
Değerlendirme
0.00 yıldız(lar) 0 rating
Geri
Üst