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

ActorProject can now use a "args" field to it's particle settings

git-svn-id: http://svn.net-core.org/repos/t-engine4@2558 51575b47-30f0-44d4-a5cc-537603b46e54
parent 84019fa9
No related branches found
No related tags found
No related merge requests found
......@@ -115,14 +115,14 @@ function _M:project(t, x, y, damtype, dam, particles)
if type(damtype) == "function" then if damtype(px, py, tg, self) then stop=true break end
else DamageType:get(damtype).projector(self, px, py, damtype, dam, tmp) end
if particles then
game.level.map:particleEmitter(px, py, 1, particles.type)
game.level.map:particleEmitter(px, py, 1, particles.type, particles.args)
end
end
else
if type(damtype) == "function" then if damtype(px, py, tg, self) then stop=true break end
else DamageType:get(damtype).projector(self, px, py, damtype, dam, tmp) end
if particles then
game.level.map:particleEmitter(px, py, 1, particles.type)
game.level.map:particleEmitter(px, py, 1, particles.type, particles.args)
end
end
end
......@@ -228,14 +228,14 @@ function _M:projectDoAct(typ, tg, damtype, dam, particles, px, py, tmp)
if type(damtype) == "function" then if damtype(px, py, tg, self) then return true end
else DamageType:get(damtype).projector(self, px, py, damtype, dam, tmp) end
if particles and type(particles) == "table" then
game.level.map:particleEmitter(px, py, 1, particles.type)
game.level.map:particleEmitter(px, py, 1, particles.type, particles.args)
end
end
else
if type(damtype) == "function" then if damtype(px, py, tg, self) then return true end
else DamageType:get(damtype).projector(self, px, py, damtype, dam, tmp) end
if particles and type(particles) == "table" then
game.level.map:particleEmitter(px, py, 1, particles.type)
game.level.map:particleEmitter(px, py, 1, particles.type, particles.args)
end
end
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