Skip to content
Snippets Groups Projects
Commit efeb05cf authored by dg's avatar dg
Browse files

Maelstrom will not destroy the stairs from killing the assassin lord

git-svn-id: http://svn.net-core.org/repos/t-engine4@6636 51575b47-30f0-44d4-a5cc-537603b46e54
parent 04bb62a8
No related branches found
No related tags found
No related merge requests found
......@@ -1952,7 +1952,7 @@ function _M:setAllowedBuild(what, notify)
end
function _M:playSoundNear(who, name)
if who and not who:attr("_forbid_sounds") and self.level and self.level.map.seens(who.x, who.y) then
if who and (not who.attr or not who:attr("_forbid_sounds")) and self.level and self.level.map.seens(who.x, who.y) then
local pos = {x=0,y=0,z=0}
if self.player and self.player.x then pos.x, pos.y = who.x - self.player.x, who.y - self.player.y end
self:playSound(name, pos)
......
......@@ -223,7 +223,7 @@ newTalent{
e.particles = game.level.map:particleEmitter(x, y, e.radius, "generic_vortex", {radius=e.radius, rm=255, rM=255, gm=180, gM=255, bm=180, bM=255, am=35, aM=90})
game.level:addEntity(e)
game.level.map(x, y, Map.TERRAIN, e)
game.nicer_tiles:updateAround(game.level, x, y)
--game.nicer_tiles:updateAround(game.level, x, y)
game.level.map:updateMap(x, y)
game:playSoundNear(self, "talents/lightning_loud")
return true
......
......@@ -69,7 +69,13 @@ newEntity{ define_as = "ASSASSIN_LORD",
can_talk = "assassin-lord",
on_die = function(self, who)
game.level.map(self.x, self.y, game.level.map.TERRAIN, game.zone.grid_list.UP_WILDERNESS)
local oe = game.level.map(self.x, self.y, game.level.map.TERRAIN)
local g = game.zone.grid_list.UP_WILDERNESS
if oe and oe:attr("temporary") and oe.old_feat then
oe.old_feat = g
else
game.level.map(self.x, self.y, game.level.map.TERRAIN, g)
end
game.logSeen(who, "As the assassin dies the magical veil protecting the stairs out vanishes.")
for uid, e in pairs(game.level.entities) do
if e.is_merchant and not e.dead then
......
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