Is this a bug? If so, then it's a potential infinite loop O.o

master
Starbeamrainbowlabs 2020-05-02 00:07:36 +01:00
parent 7df26a2cc7
commit e2b321cdad
No known key found for this signature in database
GPG Key ID: 1BE5172E637709C2
1 changed files with 4 additions and 4 deletions

View File

@ -7,11 +7,11 @@ function worldedit_hud_helper.raycast(player)
player_pos.y = player_pos.y + 1.5 -- Calculate from the eye position
for i = 1,100 do
i = i/10
local j = i/10
cur_pos.x = (look_dir.x*i) + player_pos.x
cur_pos.y = (look_dir.y*i) + player_pos.y
cur_pos.z = (look_dir.z*i) + player_pos.z
cur_pos.x = (look_dir.x*j) + player_pos.x
cur_pos.y = (look_dir.y*j) + player_pos.y
cur_pos.z = (look_dir.z*j) + player_pos.z
local node_name
node_name = minetest.get_node(cur_pos).name