From a523066c42eaa0b82a05e03fdf49b7c73c26235a Mon Sep 17 00:00:00 2001
From: DarkGod <darkgod@net-core.org>
Date: Thu, 4 Aug 2016 09:50:39 +0200
Subject: [PATCH] Fixed Hymns of Moonlight not working with Ranged
 Amplification Device (from Embers of Rage) Fixed Swap Tinker option to not
 reset to enabled when the game restarts

---
 game/modules/tome/data/talents/celestial/hymns.lua | 2 +-
 game/modules/tome/dialogs/GameOptions.lua          | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/game/modules/tome/data/talents/celestial/hymns.lua b/game/modules/tome/data/talents/celestial/hymns.lua
index 28de24d7c1..a9bd8e19bf 100644
--- a/game/modules/tome/data/talents/celestial/hymns.lua
+++ b/game/modules/tome/data/talents/celestial/hymns.lua
@@ -172,7 +172,7 @@ newTalent{
 		if self:getNegative() < t.getNegativeDrain(self, t) then return end
 
 		local tgts = {}
-		local grids = core.fov.circle_grids(self.x, self.y, 5, true)
+		local grids = core.fov.circle_grids(self.x, self.y, self:getTalentRange(t), true)
 		for x, yy in pairs(grids) do for y, _ in pairs(grids[x]) do
 			local a = game.level.map(x, y, Map.ACTOR)
 			if a and self:reactionToward(a) < 0 then
diff --git a/game/modules/tome/dialogs/GameOptions.lua b/game/modules/tome/dialogs/GameOptions.lua
index 453bc9aeb3..835fed26fb 100644
--- a/game/modules/tome/dialogs/GameOptions.lua
+++ b/game/modules/tome/dialogs/GameOptions.lua
@@ -538,7 +538,7 @@ function _M:generateListGameplay()
 		return tostring(config.settings.tome.tinker_auto_switch and "enabled" or "disabled")
 	end, fct=function(item)
 		config.settings.tome.tinker_auto_switch = not config.settings.tome.tinker_auto_switch
-		game:saveSettings("tome.tinker_auto_switch", ("tome.tinker_auto_switch = %s\n"):format(tostring(config.settings.tome.rest_before_explore)))
+		game:saveSettings("tome.tinker_auto_switch", ("tome.tinker_auto_switch = %s\n"):format(tostring(config.settings.tome.tinker_auto_switch)))
 		self.c_list:drawItem(item)
 	end,}
 
-- 
GitLab