Small improvements

All new ideas for the upcoming releases of ToME 4.x.x should be discussed here

Moderator: Moderator

Post Reply
Message
Author
ghostbuster
Uruivellas
Posts: 617
Joined: Mon Oct 09, 2006 7:47 pm

Small improvements

#1 Post by ghostbuster »

Just a couple of improvements for the final polishing

1/ when you have telephaty, a ranged talent not use as default target an out-of-LoS foe.

2/ autoexplore should visit locked doors last, as it does for vaults. This would make autoexploring the prides easier.

3/ have the 'l'ook action circulate over the different points of interest when restriked. I think it was the behavior in T2.

tiger_eye
Perspiring Physicist
Posts: 889
Joined: Thu Feb 17, 2011 5:20 am

Re: Small improvements

#2 Post by tiger_eye »

ghostbuster wrote:2/ autoexplore should visit locked doors last, as it does for vaults. This would make autoexploring the prides easier.
Good idea. Also attached.

Code: Select all

diff --git a/game/modules/tome/class/interface/PlayerExplore.lua b/game/modules/tome/class/interface/PlayerExplore.lua
index 836203b..df24bea 100644
--- a/game/modules/tome/class/interface/PlayerExplore.lua
+++ b/game/modules/tome/class/interface/PlayerExplore.lua
@@ -2187,7 +2187,7 @@ function _M:autoExplore()
 			for _, c in ipairs(unseen_doors) do
 				local x, y = toDouble(c)
 				local terrain = game.level.map(x, y, Map.TERRAIN)
-				if not terrain.door_player_check then
+				if not terrain.door_player_check and not terrain.door_player_stop then
 					target_type = "door"
 					choices[#choices + 1] = c
 					-- we may take an extra step to approach a door squarely from a cardinal direction, so let's account for this
@@ -2230,7 +2230,7 @@ function _M:autoExplore()
 			for _, c in ipairs(unseen_doors) do
 				local x, y = toDouble(c)
 				local terrain = game.level.map(x, y, Map.TERRAIN)
-				if terrain.door_player_check then
+				if terrain.door_player_check or terrain.door_player_stop then
 					target_type = "door"
 					choices[#choices + 1] = c
 					local dist = core.fov.distance(self.x, self.y, x, y, true) + 10*door_values[c]
Attachments
ae_locked_doors.txt
(1.13 KiB) Downloaded 108 times
darkgod wrote:OMFG tiger eye you are my hero!

Post Reply