diff --git a/game/engines/default/engine/Projectile.lua b/game/engines/default/engine/Projectile.lua index b69d5b1e547feae77450c377813595aa11a4a538..ac9835a1e8075915035c804f5ef7aa10644cbe4b 100644 --- a/game/engines/default/engine/Projectile.lua +++ b/game/engines/default/engine/Projectile.lua @@ -203,7 +203,7 @@ function _M:act() end game.level:removeEntity(self) self.dead = true - self.src:projectDoStop(self.project.def.typ, self.project.def.tg, self.project.def.damtype, self.project.def.dam, self.project.def.particles, radius_x, radius_y, self.tmp_proj) + self.src:projectDoStop(self.project.def.typ, self.project.def.tg, self.project.def.damtype, self.project.def.dam, self.project.def.particles, self.x, self.y, self.tmp_proj, radius_x, radius_y) end elseif self.homing then self:moveDirection(self.homing.target.x, self.homing.target.y) diff --git a/game/engines/default/engine/Target.lua b/game/engines/default/engine/Target.lua index 9dbfbcc175132031a15d0532706d304512fdef53..9401a94fa239847b8bc67f45eedebbef53d23338 100644 --- a/game/engines/default/engine/Target.lua +++ b/game/engines/default/engine/Target.lua @@ -89,7 +89,7 @@ function _M:display(dispx, dispy) -- Correct the explosion source position if we exploded on terrain local radius_x, radius_y - if self.target_type.block_path then + if self.target_type.block_path and self.target_type.radius and self.target_type.radius > 0 then _, radius_x, radius_y = self.target_type:block_path(stopx, stopy) end if not radius_x then @@ -138,7 +138,7 @@ function _M:getType(t) if not typ.no_restrict then if typ.requires_knowledge and not game.level.map.remembers(lx, ly) and not game.level.map.seens(lx, ly) then return true end if not typ.pass_terrain and game.level.map:checkEntity(lx, ly, engine.Map.TERRAIN, "block_move") then return true - -- If we explode do to something other than terrain, then we should explode ON the tile, not before it + -- If we explode due to something other than terrain, then we should explode ON the tile, not before it elseif typ.stop_block and game.level.map:checkAllEntities(lx, ly, "block_move") then return true, lx, ly end if typ.range and typ.source_actor and typ.source_actor.x and math.sqrt((typ.source_actor.x-lx)^2 + (typ.source_actor.y-ly)^2) > typ.range then return true end end diff --git a/game/engines/default/engine/interface/ActorProject.lua b/game/engines/default/engine/interface/ActorProject.lua index 7e8730a6f2e4c0c99c48d10525df45ba257fbd13..cf24e237019a1714bafbaf23c0c858809d16be88 100644 --- a/game/engines/default/engine/interface/ActorProject.lua +++ b/game/engines/default/engine/interface/ActorProject.lua @@ -230,7 +230,7 @@ function _M:projectDoAct(typ, tg, damtype, dam, particles, px, py, tmp) end end -function _M:projectDoStop(typ, tg, damtype, dam, particles, lx, ly, tmp) +function _M:projectDoStop(typ, tg, damtype, dam, particles, lx, ly, tmp, rx, ry) local grids = {} local function addGrid(x, y) if not grids[x] then grids[x] = {} end @@ -238,20 +238,20 @@ function _M:projectDoStop(typ, tg, damtype, dam, particles, lx, ly, tmp) end if typ.ball and typ.ball > 0 then - core.fov.calc_circle(lx, ly, typ.ball, function(_, px, py) + core.fov.calc_circle(rx, ry, typ.ball, function(_, px, py) -- Deal damage: ball addGrid(px, py) if typ.block_radius and typ:block_radius(px, py) then return true end end, function()end, nil) - addGrid(lx, ly) + addGrid(rx, ry) elseif typ.cone and typ.cone > 0 then local initial_dir = lx and util.getDir(lx, ly, x, y) or 5 - core.fov.calc_beam(lx, ly, typ.cone, initial_dir, typ.cone_angle, function(_, px, py) + core.fov.calc_beam(rx, ry, typ.cone, initial_dir, typ.cone_angle, function(_, px, py) -- Deal damage: cone addGrid(px, py) if typ.block_radius and typ:block_radius(px, py) then return true end end, function()end, nil) - addGrid(lx, ly) + addGrid(rx, ry) else -- Deam damage: single addGrid(lx, ly) diff --git a/game/modules/tome/data/talents/spells/fire.lua b/game/modules/tome/data/talents/spells/fire.lua index 4d36aa1bff7252fb7fffdfc4b6d736d31eafb723..9515b8be696b7ee56639a3c61df124607b652651 100644 --- a/game/modules/tome/data/talents/spells/fire.lua +++ b/game/modules/tome/data/talents/spells/fire.lua @@ -101,7 +101,7 @@ newTalent{ local tg = {type="ball", range=self:getTalentRange(t), radius=1 + self:getTalentLevelRaw(t), friendlyfire=self:spellFriendlyFire(), talent=t, display={particle="bolt_fire", trail="firetrail"}} local x, y = self:getTarget(tg) if not x or not y then return nil end - self:projectile(tg, x, y, DamageType.FIREBURN, self:spellCrit(self:combatTalentSpellDamage(t, 28, 280)), function(self, tg, x, y, grids) + self:projectile(tg, x, y, DamageType.FIRE, self:spellCrit(self:combatTalentSpellDamage(t, 28, 280)), function(self, tg, x, y, grids) game.level.map:particleEmitter(x, y, tg.radius, "fireflash", {radius=tg.radius, grids=grids, tx=x, ty=y}) end) game:playSoundNear(self, "talents/fireflash")