Skip to content
Snippets Groups Projects
Commit 4b3ef19d authored by DarkGod's avatar DarkGod
Browse files

Merge branch 'MoreMinimapGrids' into 'master'

More minimap grids

Makes doors and known traps detected at range remembered (and on the minimap)
parents 2265e0b3 fcfc469d
No related branches found
No related tags found
No related merge requests found
......@@ -120,7 +120,10 @@ end
-- You may overload this method to customize your minimap
function _M:setupMinimapInfo(mo, map)
if self.special_minimap then mo:minimap(self.special_minimap.r, self.special_minimap.g, self.special_minimap.b) return end
if self.change_level then mo:minimap(240, 0, 240) return end
if self.change_level then mo:minimap(240, 0, 240) return
elseif self.is_door then
if self.does_block_move then mo:minimap(140, 80, 25) else mo:minimap(80, 30, 20) end return
end
return engine.Grid.setupMinimapInfo(self, mo, map)
end
......
......@@ -506,7 +506,8 @@ function _M:playerFOV()
if self:attr("detect_actor") and game.level.map(x, y, game.level.map.ACTOR) then ok = true end
if self:attr("detect_object") and game.level.map(x, y, game.level.map.OBJECT) then ok = true end
if self:attr("detect_trap") and game.level.map(x, y, game.level.map.TRAP) then
game.level.map(x, y, game.level.map.TRAP):setKnown(self, true)
game.level.map(x, y, game.level.map.TRAP):setKnown(self, true, x, y)
game.level.map.remembers(x, y, true)
game.level.map:updateMap(x, y)
ok = true
end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment