From 548a5be5dc727318ef74d1311c5b5175df0582e9 Mon Sep 17 00:00:00 2001 From: PHIDIAS Date: Thu, 6 Feb 2025 22:53:09 +0900 Subject: [PATCH 1/2] Fix on_click in task list (#374) --- exp_legacy/module/modules/gui/task-list.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/exp_legacy/module/modules/gui/task-list.lua b/exp_legacy/module/modules/gui/task-list.lua index eb20e2ae..983fb9e0 100644 --- a/exp_legacy/module/modules/gui/task-list.lua +++ b/exp_legacy/module/modules/gui/task-list.lua @@ -244,8 +244,7 @@ local task_view_edit_button = Gui.element("task_view_edit_button") tooltip = { "task-list.edit-tooltip" }, style = "shortcut_bar_button", }:style(Styles.footer_button):on_click( - function(def, event, element) - local player = Gui.get_player(event) + function(def, player, element) local selected = PlayerSelected:get(player) PlayerIsEditing:set(player, true) From f84b0adee71531b5cac1a02e52d32487810f8b43 Mon Sep 17 00:00:00 2001 From: PHIDIAS Date: Thu, 6 Feb 2025 22:55:27 +0900 Subject: [PATCH 2/2] Fix role check in /kill (#375) * Update kill.lua * Update kill.lua --------- Co-authored-by: Cooldude2606 <25043174+Cooldude2606@users.noreply.github.com> --- exp_scenario/module/commands/kill.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exp_scenario/module/commands/kill.lua b/exp_scenario/module/commands/kill.lua index ac4356d0..17d291fd 100644 --- a/exp_scenario/module/commands/kill.lua +++ b/exp_scenario/module/commands/kill.lua @@ -20,7 +20,7 @@ Commands.new("kill", { "exp-commands_kill.description" }) if other_player == nil then -- Can only be nil if the target is the player and they are already dead return Commands.status.error{ "exp-commands_kill.already-dead" } - elseif (other_player == player) or (highest_role(other_player).index < highest_role(player).index) then + elseif (other_player == player) or (highest_role(player).index < highest_role(other_player).index) then -- You can always kill yourself or can kill lower role players if script.active_mods["space-age"] then other_player.surface.create_entity{ name = "lightning", position = { other_player.position.x, other_player.position.y - 16 }, target = other_player.character }