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

moar

git-svn-id: http://svn.net-core.org/repos/t-engine4@3429 51575b47-30f0-44d4-a5cc-537603b46e54
parent 817f5cfd
No related branches found
No related tags found
No related merge requests found
......@@ -37,27 +37,6 @@ function _M:init(t, no_default)
Entity.init(self, t, no_default)
end
--- Adds a particles emitter following the actor
function _M:addParticles(ps)
self.__particles[ps] = true
if self.x and self.y and game.level and game.level.map then
ps.x = self.x
ps.y = self.y
game.level.map:addParticleEmitter(ps)
end
return ps
end
--- Removes a particles emitter following the actor
function _M:removeParticles(ps)
self.__particles[ps] = nil
if self.x and self.y and game.level and game.level.map then
ps.x = nil
ps.y = nil
game.level.map:removeParticleEmitter(ps)
end
end
--- Moves a projectile on the map
-- *WARNING*: changing x and y properties manually is *WRONG* and will blow up in your face. Use this method. Always.
-- @param map the map to move onto
......@@ -110,6 +89,8 @@ function _M:move(x, y, force)
self:useEnergy()
map:checkAllEntities(x, y, "on_projectile_move", self, force)
return true
end
......
......@@ -38,6 +38,10 @@ newEntity{
pass_projectile = true,
air_level = -40,
is_void = true,
--- Called when we are targeted by a projectile
on_projectile_move = function(self, x, y, p)
p:useEnergy(game.energy_to_act * 5) -- Projectiles move much slower in the void
end,
}
newEntity{
......
game/modules/tome/data/gfx/shockbolt/npc/humanoid_dwarf_dwarven_summoner.png

11.9 KiB

game/modules/tome/data/gfx/shockbolt/npc/humanoid_human_ziguranth_wyrmic.png

8.5 KiB

game/modules/tome/data/gfx/shockbolt/npc/humanoid_thalore_ziguranth_summoner.png

9.02 KiB

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