mirror of
https://git.minetest.land/MineClone2/MineClone2.git
synced 2025-01-01 14:17:29 +01:00
Dispensers work with fireworks
This commit is contained in:
parent
93a6ce6824
commit
9ef0738a2e
@ -6,7 +6,7 @@ local description = S("Firework Rocket")
|
||||
local function explode(self, pos)
|
||||
-- temp code
|
||||
vl_fireworks.generic_particle_explosion(pos)
|
||||
mcl_mobs.mob_class.boom(self, pos, 1)
|
||||
mcl_mobs.mob_class.safe_boom(self, pos, 1)
|
||||
end
|
||||
|
||||
local firework_entity = {
|
||||
@ -132,6 +132,12 @@ local function register_rocket(n, duration, force)
|
||||
velocity=vector.new(0,1,0)
|
||||
})
|
||||
end,
|
||||
_on_dispense = function(dropitem, pos, droppos, dropnode, dropdir)
|
||||
vl_projectile.create("vl_fireworks:rocket_" .. n, {
|
||||
pos=pos,
|
||||
velocity=vector.new(0,1,0)
|
||||
})
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user