mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2025-12-31 04:51:40 +09:00
Merge pull request #186 from bbassie/remove/kill-button
Remove/kill button
This commit is contained in:
@@ -84,19 +84,6 @@ local bring_player = new_button('utility/import',{'player-list.bring-player'})
|
|||||||
end
|
end
|
||||||
end)
|
end)
|
||||||
|
|
||||||
--- Kills the action player, if there are alive
|
|
||||||
-- @element kill_player
|
|
||||||
local kill_player = new_button('utility/too_far',{'player-list.kill-player'})
|
|
||||||
:on_click(function(player)
|
|
||||||
local selected_player_name = get_action_player_name(player)
|
|
||||||
local selected_player = game.players[selected_player_name]
|
|
||||||
if selected_player.character then
|
|
||||||
selected_player.character.die()
|
|
||||||
else
|
|
||||||
player.print({'expcom-kill.already-dead'},Colors.orange_red)
|
|
||||||
end
|
|
||||||
end)
|
|
||||||
|
|
||||||
--- Reports the action player, requires a reason to be given
|
--- Reports the action player, requires a reason to be given
|
||||||
-- @element report_player
|
-- @element report_player
|
||||||
local report_player = new_button('utility/spawn_flag',{'player-list.report-player'})
|
local report_player = new_button('utility/spawn_flag',{'player-list.report-player'})
|
||||||
@@ -203,16 +190,6 @@ return {
|
|||||||
goto_player,
|
goto_player,
|
||||||
bring_player
|
bring_player
|
||||||
},
|
},
|
||||||
['command/kill'] = {
|
|
||||||
auth=function(player,selected_player)
|
|
||||||
if player.name == selected_player.name then
|
|
||||||
return true
|
|
||||||
elseif Roles.player_allowed(player,'command/kill/always') then
|
|
||||||
return auth_lower_role(player,selected_player)
|
|
||||||
end
|
|
||||||
end, -- player must be lower role, or your self
|
|
||||||
kill_player
|
|
||||||
},
|
|
||||||
['command/report'] = {
|
['command/report'] = {
|
||||||
auth=function(player,selected_player)
|
auth=function(player,selected_player)
|
||||||
if not Roles.player_allowed(player,'command/give-warning') then
|
if not Roles.player_allowed(player,'command/give-warning') then
|
||||||
|
|||||||
@@ -6,7 +6,6 @@ reason-confirm=Confirm Reason
|
|||||||
reason-entry=Enter Reason
|
reason-entry=Enter Reason
|
||||||
goto-player=Goto player
|
goto-player=Goto player
|
||||||
bring-player=Bring player
|
bring-player=Bring player
|
||||||
kill-player=Kill player
|
|
||||||
report-player=Report player
|
report-player=Report player
|
||||||
warn-player=Warn player
|
warn-player=Warn player
|
||||||
jail-player=Jail player
|
jail-player=Jail player
|
||||||
|
|||||||
Reference in New Issue
Block a user