diff --git a/main.lua b/main.lua index 10fc005..004fefd 100644 --- a/main.lua +++ b/main.lua @@ -666,11 +666,13 @@ local function doit(dummy) if cfg.decrement_reward and reward_delta == 0 then reward_delta = reward_delta - 1 end - if not ingame_paused and controllable and game.get_state() ~= 'win_walking' then + if not ingame_paused and game.get_state() ~= 'win_walking' then -- note that we exclude points gained walking into the castle. -- this way, we avoid adding the timer-based fireworks to our reward, -- which are basically unwanted noise due to the way they trigger. - reward = reward + reward_delta + if flagpole_bonus > 0 or controllable then + reward = reward + reward_delta + end end --gui.text(72, 12, ("%+4i"):format(reward_delta), '#FFFFFF', '#0000003F') diff --git a/smb.lua b/smb.lua index 0cf85f4..178f330 100644 --- a/smb.lua +++ b/smb.lua @@ -212,7 +212,9 @@ local function handle_enemies() -- this is a mess... gotta find out its rotation and then project. -- TODO: handle long fire bars too local rot = R(0xA0 + i) --* 0x100 + R(0x58 + i) - gui.text(x-13, y-3+9, ("%04X"):format(rot), '#FFFFFF', '#0000003F') + if overlay then + gui.text(x-13, y-3+9, ("%04X"):format(rot), '#FFFFFF', '#0000003F') + end local x_off, y_off = rotation_offsets[rot*2+1], rotation_offsets[rot*2+2] x, y = x + x_off, y + y_off end