Fixed bug with Death Script.
+ Stopped errors from occuring.
This commit is contained in:
@@ -158,7 +158,7 @@ AddEventHandler("DeathScript:Revive", function( adrev, admin, all)
|
||||
if adrev then
|
||||
exports['EGRP-Notifications']:Success("System", "You have been revived by an admin!", "top", 5000, true)
|
||||
--ShowNotification("~g~You have been revived by an admin!")
|
||||
TriggerServerEvent('DeathScript:AdminReturn', admin)
|
||||
--TriggerServerEvent('DeathScript:AdminReturn', admin)
|
||||
end
|
||||
else
|
||||
exports['EGRP-Notifications']:CaptionIcon("System", "You can revive in "..ReviveTime.." seconds!", "top", 3000, "dark", "", true, "mdi-medical-bag")
|
||||
@@ -166,8 +166,7 @@ AddEventHandler("DeathScript:Revive", function( adrev, admin, all)
|
||||
end
|
||||
else
|
||||
if adrev then
|
||||
TriggerServerEvent('DeathScript:AdminReturn', admin)
|
||||
else
|
||||
--TriggerServerEvent('DeathScript:AdminReturn', admin)
|
||||
exports['EGRP-Notifications']:Negative("System", "You can't revive yourself when you're alive!", "top", 3000, true)
|
||||
--ShowNotification("~g~You're alive!")
|
||||
end
|
||||
@@ -192,7 +191,7 @@ AddEventHandler("DeathScript:Respawn", function( adres, admin, all)
|
||||
if adres then
|
||||
exports['EGRP-Notifications']:Success("System", "You have been respawned by an admin!", "top", 5000, true)
|
||||
--ShowNotification("~g~You have been respawned by an admin!")
|
||||
TriggerServerEvent('DeathScript:AdminReturn', admin)
|
||||
--TriggerServerEvent('DeathScript:AdminReturn', admin)
|
||||
end
|
||||
else
|
||||
exports['EGRP-Notifications']:CaptionIcon("System", "You can respawn in "..RespawnTime.." seconds!", "top", 3000, "dark", "", true, "mdi-medical-bag")
|
||||
@@ -200,7 +199,7 @@ AddEventHandler("DeathScript:Respawn", function( adres, admin, all)
|
||||
end
|
||||
else
|
||||
if adres then
|
||||
TriggerServerEvent('DeathScript:AdminReturn', admin)
|
||||
--TriggerServerEvent('DeathScript:AdminReturn', admin)
|
||||
else
|
||||
exports['EGRP-Notifications']:Negative("System", "You can't respawn when you're alive!", "top", 3000, true)
|
||||
--ShowNotification("~g~You're alive!")
|
||||
|
||||
@@ -81,6 +81,6 @@ RegisterCommand('deathtoggle', function(source, args, rawCommand)
|
||||
end, true)
|
||||
|
||||
|
||||
AddEventHandler('DeathScript:AdminReturn', function(msg, id)
|
||||
TriggerClientEvent("DeathScript:ShowNotification", msg)
|
||||
end)
|
||||
--AddEventHandler('DeathScript:AdminReturn', function(msg, id)
|
||||
--TriggerClientEvent("DeathScript:ShowNotification", msg)
|
||||
--end)
|
||||
Reference in New Issue
Block a user