awacke1 commited on
Commit
5cddd96
·
verified ·
1 Parent(s): 04880a6

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -0
app.py CHANGED
@@ -157,6 +157,10 @@ all_initial_objects = []
157
  for plot in plots_metadata:
158
  all_initial_objects.extend(load_plot_objects(plot['filename'], plot['x_offset'], plot['z_offset']))
159
 
 
 
 
 
160
  # --- Sidebar ---
161
  with st.sidebar:
162
  st.title("🏗️ World Controls")
 
157
  for plot in plots_metadata:
158
  all_initial_objects.extend(load_plot_objects(plot['filename'], plot['x_offset'], plot['z_offset']))
159
 
160
+ # --- Update GameState with initial objects if empty ---
161
+ if not game_state.get_state():
162
+ game_state.update_state(all_initial_objects)
163
+
164
  # --- Sidebar ---
165
  with st.sidebar:
166
  st.title("🏗️ World Controls")