Skip to content

Commit 690402e

Browse files
committed
fix particles not being limited for long lines
1 parent a4bbb7e commit 690402e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

api.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ local function make_line(pos1, pos2, color, name, time, density)
9797
return minetest.add_particlespawner({
9898
playername = name,
9999
time = time,
100-
amount = math.ceil(distance * density * 3.0),
100+
amount = math.ceil(math.min(distance, 10.0) * density * 3.0),
101101
minpos = pos1,
102102
maxpos = pos1,
103103
minvel = vel,

0 commit comments

Comments
 (0)