test test
This commit is contained in:
1 parent
ca2a9205b0
commit
fefd53857e
7 files changed
+109
-93
No files matched your search
+8
-10
@@ -1,11 +1,9 @@
|
||||
local QBCore = exports['qb-core']:GetCoreObject()
|
||||
|
||||
RegisterNetEvent('md-drugs:client:consumedrugs', function(time, effect, anim, progresstext, status, item)
|
||||
print(time, effect, anim, progresstext, status, item)
|
||||
if not progressbar(progresstext .. GetLabel(item).. "!", time, anim ) then return end
|
||||
TriggerServerEvent('md-drugs:server:removeconsum', item)
|
||||
for k, v in pairs (status) do
|
||||
print(k,v)
|
||||
if k == 'health' then
|
||||
local cur = GetEntityHealth(PlayerPedId())
|
||||
SetEntityHealth(PlayerPedId(), cur + v)
|
||||
@@ -21,7 +19,7 @@ RegisterNetEvent('md-drugs:client:consumedrugs', function(time, effect, anim, pr
|
||||
TriggerEvent('md-drugs:client:recievebuff', k, v)
|
||||
end
|
||||
end
|
||||
TriggerEvent('evidence:client:SetStatus', 'widepupils', 200) if effect == "alien" then AlienEffect() elseif effect == "ecstacy" then EcstasyEffect() elseif effect == "meth" then MethBagEffect() elseif effect == "coke" then CokeBaggyEffect() elseif effect == "trevor" then TrevorEffect() else end if status == nil then return end
|
||||
TriggerEvent('evidence:client:SetStatus', 'widepupils', 200) if effect == "alien" then AlienEffect() elseif effect == "ecstacy" then EcstasyEffect() elseif effect == "meth" then MethBagEffect() elseif effect == "coke" then CokeBaggyEffect() elseif effect == "trevor" then TrevorEffect() else end if status == nil then return end
|
||||
end)
|
||||
|
||||
RegisterNetEvent('md-drugs:client:recievebuff', function(type, amount)
|
||||
@@ -36,12 +34,12 @@ if type == 'speed' then
|
||||
end
|
||||
if type == 'strength' then
|
||||
local strength = 0
|
||||
SetCurrentPedWeapon(PlayerPedId(), 'weapon_unarmed', true)
|
||||
SetWeaponDamageModifier(GetHashKey("WEAPON_UNARMED"), 60.0)
|
||||
repeat
|
||||
strength = strength + 1
|
||||
Wait(1000)
|
||||
until strength == amount
|
||||
SetWeaponDamageModifier(GetHashKey("WEAPON_UNARMED"), 1.0)
|
||||
SetCurrentPedWeapon(PlayerPedId(), 'weapon_unarmed', true)
|
||||
SetWeaponDamageModifier(GetHashKey("WEAPON_UNARMED"), 50.0)
|
||||
repeat
|
||||
strength = strength + 1
|
||||
Wait(1000)
|
||||
until strength == amount
|
||||
SetWeaponDamageModifier(GetHashKey("WEAPON_UNARMED"), 1.0)
|
||||
end
|
||||
end)
|
||||
Reference in new issue
Block a user