From 9550a6000b613b29c2f2a1577b5ef72f3465f83b Mon Sep 17 00:00:00 2001 From: FaceDeer Date: Sat, 7 Jan 2023 15:11:14 -0700 Subject: [PATCH] actually use the state pointer --- init.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/init.lua b/init.lua index 197dc22..6fd2efb 100644 --- a/init.lua +++ b/init.lua @@ -574,14 +574,14 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) local refresh = false local state = formspec_state[player_name] if fields.type_select then - formspec_state[player_name].selected_type = fields.type_select + state.selected_type = fields.type_select refresh = true end if fields.waypoint_table then local table_event = minetest.explode_table_event(fields.waypoint_table) if table_event.type == "CHG" then - formspec_state[player_name].row_index = table_event.row + state.row_index = table_event.row refresh = true end end