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

fix

git-svn-id: http://svn.net-core.org/repos/t-engine4@4375 51575b47-30f0-44d4-a5cc-537603b46e54
parent b396236d
No related branches found
No related tags found
No related merge requests found
......@@ -69,8 +69,8 @@ function _M:project(t, x, y, damtype, dam, particles)
l = core.fov.line(srcx, srcy, x, y)
end
local block_corner = function(_, bx, by)
if self.target_type.block_path then
local b, h, hr = self.target_type:block_path(bx, by, true)
if typ.block_path then
local b, h, hr = typ:block_path(bx, by, true)
return b and h and not hr
else
return false
......@@ -211,8 +211,8 @@ function _M:canProject(t, x, y)
l = core.fov.line(self.x, self.y, x, y)
end
local block_corner = function(_, bx, by)
if self.target_type.block_path then
local b, h, hr = self.target_type:block_path(bx, by, true)
if typ.block_path then
local b, h, hr = typ:block_path(bx, by, true)
return b and h and not hr
else
return false
......@@ -297,8 +297,8 @@ end
-- @return stop is this the last (blocking) tile?
function _M:projectDoMove(typ, tgtx, tgty, x, y, srcx, srcy)
local block_corner = function(_, bx, by)
if self.target_type.block_path then
local b, h, hr = self.target_type:block_path(bx, by, true)
if typ.block_path then
local b, h, hr = typ:block_path(bx, by, true)
return b and h and not hr
else
return false
......
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