update delete action
This commit is contained in:
parent
35935c0fdc
commit
c679cf919e
@ -253,8 +253,9 @@ function onPlayerConnect()
|
||||
Wait.time(function() playermatApi.redrawSlotSymbols("All") end, 0.2)
|
||||
end
|
||||
|
||||
-- disable delete action (only applies to promoted players) and discard objects instead
|
||||
function onPlayerAction(player, action, targets)
|
||||
if action == Player.Action.Delete and not player.admin then
|
||||
if action == Player.Action.Delete and player.admin ~= true then
|
||||
for _, target in ipairs(targets) do
|
||||
local matColor = playermatApi.getMatColorByPosition(target.getPosition())
|
||||
local trash = guidReferenceApi.getObjectByOwnerAndType(matColor, "Trash")
|
||||
|
Loading…
Reference in New Issue
Block a user