Files
wnsrc/gamemodes/darkrp/plugins/waterloot/items/sh_watervalve.lua
lifestorm df294d03aa Upload
2024-08-04 23:54:45 +03:00

44 lines
1.0 KiB
Lua
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

--[[
| This file was obtained through the combined efforts
| of Madbluntz & Plymouth Antiquarian Society.
|
| Credits: lifestorm, Gregory Wayne Rossel JR.,
| Maloy, DrPepper10 @ RIP, Atle!
|
| Visit for more: https://plymouth.thetwilightzone.ru/
--]]
local PLUGIN = PLUGIN
ITEM.name = "Su Vanası"
ITEM.model = "models/props/de_nuke/hr_nuke/metal_pipe_001/metal_pipe_001_gauge_valve_low.mdl"
ITEM.width = 1
ITEM.height = 1
ITEM.description = "Suyun akmasına yardımcı olacak bir su vanası."
ITEM.category = "Tools"
ITEM.functions.Place = {
name = "Su Deposuna Yerleştir",
tip = "equipTip",
icon = "icon16/link_add.png",
OnRun = function(itemTable)
if (SERVER) then
local client = itemTable.player
PLUGIN:PlaceValve(client, itemTable)
return false
end
end,
OnCanRun = function(itemTable)
if IsValid(itemTable.entity) then return false end
end
}
function ITEM:OnTransferred(curInv, inventory)
if (SERVER) then
if self.waterCache and IsValid(self.waterCache) then
self.waterCache.HasPotPlaced = nil
end
end
end