From 233e478e40d72a091f70f18dc6846066a4f52016 Mon Sep 17 00:00:00 2001 From: Alexander Pickering Date: Thu, 24 Aug 2017 20:32:34 -0400 Subject: Fix all linter warnings --- gamemode/shared/prayersystem/prayers/ninelives.lua | 100 ++++++++++----------- 1 file changed, 50 insertions(+), 50 deletions(-) (limited to 'gamemode/shared/prayersystem/prayers/ninelives.lua') diff --git a/gamemode/shared/prayersystem/prayers/ninelives.lua b/gamemode/shared/prayersystem/prayers/ninelives.lua index 44b3099..707e8b6 100644 --- a/gamemode/shared/prayersystem/prayers/ninelives.lua +++ b/gamemode/shared/prayersystem/prayers/ninelives.lua @@ -1,50 +1,50 @@ -do return end ---[[ - An example prayer -]] -local prayer = {} - ---Required, a name, all item names must be unique -prayer.Name = "Nine Lives" - ---Optional, a tooltip to display when hovered over -prayer.Tooltip = "A prayer to the rouge god to prevent fall dammage for the next 9 falls that you would have taken dammage, or for 5 minutes, whichever comes first." - ---Optional, when the player clicks this item, a menu will show up, if the menu item is clicked, the function is ran. This is all run client side, so if you want it to do something server side, you'll need to use the net library. Remember that items are in the shared domain, so you can define what it does in the same file! -local prayedplayers = {} -if SERVER then - util.AddNetworkString("art_prayer_ninelives") - net.Receive("art_prayer_ninelives",function(ln,ply) - if ply:HasPrayer("Nine Lives") then - prayedplayers[ply] = 9 - timer.Simple(60 * 5,function() - prayedplayers[ply] = nil - end) - end - end) -end - - -local lastprayer = CurTime() -prayer.Pray = function(self) - if SERVER then return end - if CurTime() > lastprayer + 0 then - net.Start("art_prayer_ninelives") - net.SendToServer() - lastprayer = CurTime() - end -end - -hook.Add( "EntityTakeDamage" , "artery_ninelives" , function(ent,info) - if info:GetDamageType() == DMG_FALL and prayedplayers[ent] ~= nil and prayedplayers[ent] > 0 then - info:SetDamage(0) - end -end) - ---Optional. Something run once when this item is drawn in a backpack -function prayer.DoOnPanel(dimagebutton) - dimagebutton:SetImage( "prayericons/ninelives.png") -end - - -ART.RegisterPrayer(prayer) +-- do return end +-- --[[ +-- An example prayer +-- ]] +-- local prayer = {} +-- +-- --Required, a name, all item names must be unique +-- prayer.Name = "Nine Lives" +-- +-- --Optional, a tooltip to display when hovered over +-- prayer.Tooltip = "A prayer to the rouge god to prevent fall dammage for the next 9 falls that you would have taken dammage, or for 5 minutes, whichever comes first." +-- +-- --Optional, when the player clicks this item, a menu will show up, if the menu item is clicked, the function is ran. This is all run client side, so if you want it to do something server side, you'll need to use the net library. Remember that items are in the shared domain, so you can define what it does in the same file! +-- local prayedplayers = {} +-- if SERVER then +-- util.AddNetworkString("art_prayer_ninelives") +-- net.Receive("art_prayer_ninelives",function(ln,ply) +-- if ply:HasPrayer("Nine Lives") then +-- prayedplayers[ply] = 9 +-- timer.Simple(60 * 5,function() +-- prayedplayers[ply] = nil +-- end) +-- end +-- end) +-- end +-- +-- +-- local lastprayer = CurTime() +-- prayer.Pray = function(self) +-- if SERVER then return end +-- if CurTime() > lastprayer + 0 then +-- net.Start("art_prayer_ninelives") +-- net.SendToServer() +-- lastprayer = CurTime() +-- end +-- end +-- +-- hook.Add( "EntityTakeDamage" , "artery_ninelives" , function(ent,info) +-- if info:GetDamageType() == DMG_FALL and prayedplayers[ent] ~= nil and prayedplayers[ent] > 0 then +-- info:SetDamage(0) +-- end +-- end) +-- +-- --Optional. Something run once when this item is drawn in a backpack +-- function prayer.DoOnPanel(dimagebutton) +-- dimagebutton:SetImage( "prayericons/ninelives.png") +-- end +-- +-- +-- ART.RegisterPrayer(prayer) -- cgit v1.2.3-70-g09d2