particles to disappear when it hits the ground

This commit is contained in:
minjaesong
2023-10-12 01:56:07 +09:00
parent 6bf535e968
commit 3a3d789777
2 changed files with 2 additions and 2 deletions

View File

@@ -100,7 +100,7 @@ object PickaxeCore {
y * TILE_SIZED + 4 + (4 * (it / 3))
)
createRandomBlockParticle(tile, pos, 1.0 * (if (Math.random() < 0.5) -1 else 1)).let {
it.despawnUponCollision = false
it.despawnUponCollision = true
(Terrarum.ingame as TerrarumIngame).addParticle(it)
}
}

View File

@@ -106,7 +106,7 @@ object SledgehammerCore {
y * TILE_SIZED + 4 + (4 * (it / 3))
)
createRandomBlockParticle(wall, pos, 1.0 * (if (Math.random() < 0.5) -1 else 1)).let {
it.despawnUponCollision = false
it.despawnUponCollision = true
it.drawColour.set(App.tileMaker.wallOverlayColour)
(Terrarum.ingame as TerrarumIngame).addParticle(it)
}