mirror of
https://github.com/sys4-fr/server-nalc.git
synced 2025-02-09 08:10:25 +01:00
[throwing] Fix value not retrieved before being used
This commit is contained in:
parent
b53d407979
commit
3c9b2de8ef
@ -49,7 +49,7 @@ THROWING_ARROW_ENTITY.on_step = function(self, dtime)
|
|||||||
local objs = minetest.get_objects_inside_radius({x=pos.x,y=pos.y,z=pos.z}, 1)
|
local objs = minetest.get_objects_inside_radius({x=pos.x,y=pos.y,z=pos.z}, 1)
|
||||||
for k, obj in pairs(objs) do
|
for k, obj in pairs(objs) do
|
||||||
if throwing_is_player(self.player, obj) or throwing_is_entity(obj) then
|
if throwing_is_player(self.player, obj) or throwing_is_entity(obj) then
|
||||||
if throwing_touch(pos, objpos) then
|
if throwing_touch(pos, obj:getpos()) then
|
||||||
local puncher = self.object
|
local puncher = self.object
|
||||||
if self.player and minetest.get_player_by_name(self.player) then
|
if self.player and minetest.get_player_by_name(self.player) then
|
||||||
puncher = minetest.get_player_by_name(self.player)
|
puncher = minetest.get_player_by_name(self.player)
|
||||||
|
Loading…
Reference in New Issue
Block a user