mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2026-08-13 00:45:11 +09:00
Fix issue with MapPosition.energy
This commit is contained in:
@@ -326,7 +326,7 @@ local function vlayer_gui_list_refresh(player)
|
||||
|
||||
for i = 1, vlayer.get_interface_counts()[vlayer_control_type_list[target]], 1 do
|
||||
local entity = assert(interface[i])
|
||||
local entity_position = entity.position --[[@as MapPosition.struct]]
|
||||
local entity_position = entity.position
|
||||
table.insert(full_list, i .. " X " .. entity_position.x .. " Y " .. entity_position.y)
|
||||
end
|
||||
|
||||
|
||||
@@ -799,7 +799,7 @@ Event.on_nth_tick(math.floor(60 / config.update_smoothing), function()
|
||||
end
|
||||
|
||||
-- Check if the player is within range
|
||||
local warp_pos = warp.position --[[@as MapPosition.struct]]
|
||||
local warp_pos = warp.position
|
||||
if warp.surface == surface then
|
||||
local dx, dy = px - warp_pos.x, py - warp_pos.y
|
||||
local dist = (dx * dx) + (dy * dy)
|
||||
|
||||
Reference in New Issue
Block a user