Oranblock commited on
Commit
cbed036
·
verified ·
1 Parent(s): f2c363b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +89 -89
app.py CHANGED
@@ -6,14 +6,14 @@ def load_config():
6
  with open('config.json', 'r') as f:
7
  return json.load(f)
8
 
9
- def checkbox_with_default(label, value):
10
- return st.checkbox(label, value=value)
11
 
12
- def text_input_with_default(label, value):
13
- return st.text_input(label, value)
14
 
15
- def selectbox_with_default(label, options, value):
16
- return st.selectbox(label, options, index=options.index(value))
17
 
18
  def get_user_input(config):
19
  st.title("Advanced Roblox Lua Script Generator")
@@ -21,151 +21,151 @@ def get_user_input(config):
21
  default_params = config["default_parameters"]
22
 
23
  # Game Object Properties
24
- color_enabled = checkbox_with_default("Enable Color", True)
25
- size_enabled = checkbox_with_default("Enable Size", True)
26
- position_enabled = checkbox_with_default("Enable Position", True)
27
- shape_enabled = checkbox_with_default("Enable Shape", True)
28
- material_enabled = checkbox_with_default("Enable Material", True)
29
- transparency_enabled = checkbox_with_default("Enable Transparency", True)
30
- reflectance_enabled = checkbox_with_default("Enable Reflectance", True)
31
- rotation_speed_enabled = checkbox_with_default("Enable Rotation Speed", True)
32
- bounce_height_enabled = checkbox_with_default("Enable Bounce Height", True)
33
- collision_enabled = checkbox_with_default("Enable Collision", True)
34
- surface_enabled = checkbox_with_default("Enable Surface Type", True)
35
- anchor_enabled = checkbox_with_default("Enable Anchor", True)
36
- collision_group_enabled = checkbox_with_default("Enable Collision Group", True)
37
- custom_physics_enabled = checkbox_with_default("Enable Custom Physics", True)
38
- part_cframe_enabled = checkbox_with_default("Enable Part CFrame", True)
39
 
40
  # Camera Properties
41
- camera_enabled = checkbox_with_default("Enable Camera Configuration", True)
42
- camera_interpolation_enabled = checkbox_with_default("Enable Camera Interpolation", default_params["camera_interpolation"])
43
 
44
  # Lighting Properties
45
- lighting_enabled = checkbox_with_default("Enable Lighting Configuration", True)
46
- fog_enabled = checkbox_with_default("Enable Environmental Fog", True)
47
- shadow_enabled = checkbox_with_default("Enable Shadow Properties", True)
48
 
49
  # Player Properties
50
- player_settings_enabled = checkbox_with_default("Enable Player Settings", True)
51
- respawn_time_enabled = checkbox_with_default("Enable Respawn Time", True)
52
 
53
  # Sound Properties
54
- sound_enabled = checkbox_with_default("Enable Sound", True)
55
- sound_effects_enabled = checkbox_with_default("Enable Sound Effects", True)
56
- environmental_sounds_enabled = checkbox_with_default("Enable Environmental Sounds", True)
57
 
58
  # UI Properties
59
- ui_enabled = checkbox_with_default("Enable UI Configuration", True)
60
 
61
  # Decals
62
- decals_enabled = checkbox_with_default("Enable Decals", True)
63
 
64
  # Particle Effects
65
- particles_enabled = checkbox_with_default("Enable Particle Effects", True)
66
 
67
  # Advanced Game Object Properties Inputs
68
  if color_enabled:
69
- color = text_input_with_default("Enter Color (RGB, e.g., 255,0,0)", default_params["color"])
70
  else:
71
  color = None
72
 
73
  if size_enabled:
74
- size = text_input_with_default("Enter Size (X,Y,Z, e.g., 4,1,2)", default_params["size"])
75
  else:
76
  size = None
77
 
78
  if position_enabled:
79
- position = text_input_with_default("Enter Position (X,Y,Z, e.g., 0,10,0)", default_params["position"])
80
  else:
81
  position = None
82
 
83
  if shape_enabled:
84
- shape = selectbox_with_default("Select Shape", config["shapes"], default_params["shape"])
85
  else:
86
  shape = None
87
 
88
  if material_enabled:
89
- material = selectbox_with_default("Select Material", config["materials"], default_params["material"])
90
  else:
91
  material = None
92
 
93
  if transparency_enabled:
94
- transparency = text_input_with_default("Enter Transparency (0-1, e.g., 0.5)", default_params["transparency"])
95
  else:
96
  transparency = None
97
 
98
  if reflectance_enabled:
99
- reflectance = text_input_with_default("Enter Reflectance (0-1, e.g., 0.5)", default_params["reflectance"])
100
  else:
101
  reflectance = None
102
 
103
  if rotation_speed_enabled:
104
- rotation_speed = text_input_with_default("Enter Rotation Speed (e.g., 10)", default_params["rotation_speed"])
105
  else:
106
  rotation_speed = None
107
 
108
  if bounce_height_enabled:
109
- bounce_height = text_input_with_default("Enter Bounce Height (e.g., 10)", default_params["bounce_height"])
110
  else:
111
  bounce_height = None
112
 
113
  if collision_enabled:
114
- collision = selectbox_with_default("Enable Collision", config["collisions"], default_params["collision"])
115
  else:
116
  collision = None
117
 
118
  if surface_enabled:
119
- surface = selectbox_with_default("Select Surface Type", config["surfaces"], default_params["surface"])
120
  else:
121
  surface = None
122
 
123
  if anchor_enabled:
124
- anchor = selectbox_with_default("Enable Anchor", ["true", "false"], default_params["anchor"])
125
  else:
126
  anchor = None
127
 
128
  if collision_group_enabled:
129
- collision_group = selectbox_with_default("Select Collision Group", config["collision_groups"], default_params["collision_group"])
130
  else:
131
  collision_group = None
132
 
133
  if custom_physics_enabled:
134
- angular_velocity = text_input_with_default("Enter Angular Velocity (X,Y,Z, e.g., 0,0,0)", default_params["angular_velocity"])
135
- linear_velocity = text_input_with_default("Enter Linear Velocity (X,Y,Z, e.g., 0,0,0)", default_params["linear_velocity"])
136
- density = text_input_with_default("Enter Density", default_params["density"])
137
  else:
138
  angular_velocity = None
139
  linear_velocity = None
140
  density = None
141
 
142
  if part_cframe_enabled:
143
- part_cframe = text_input_with_default("Enter Part CFrame (e.g., CFrame.new(0, 50, -100))", default_params["part_cframe"])
144
  else:
145
  part_cframe = None
146
 
147
  # Camera Properties Inputs
148
  if camera_enabled:
149
- camera_type = selectbox_with_default("Select Camera Type", config["camera_types"], default_params["camera_type"])
150
- camera_position = text_input_with_default("Enter Camera Position (X,Y,Z, e.g., 0,50,-100)", default_params["camera_position"])
151
- field_of_view = text_input_with_default("Enter Field of View", default_params["field_of_view"])
152
  else:
153
  camera_type = None
154
  camera_position = None
155
  field_of_view = None
156
 
157
  if camera_interpolation_enabled:
158
- camera_interpolation = checkbox_with_default("Enable Camera Interpolation", default_params["camera_interpolation"])
159
  else:
160
  camera_interpolation = None
161
 
162
  # Lighting Properties Inputs
163
  if lighting_enabled:
164
- ambient_light = text_input_with_default("Enter Ambient Light (RGB, e.g., 128,128,128)", default_params["ambient_light"])
165
- brightness = text_input_with_default("Enter Brightness", default_params["brightness"])
166
- time_of_day = selectbox_with_default("Select Time of Day", config["times_of_day"], default_params["time_of_day"])
167
- shadow_softness = text_input_with_default("Enter Shadow Softness (0-1, e.g., 0.5)", default_params["shadow_softness"])
168
- shadow_color = text_input_with_default("Enter Shadow Color (RGB, e.g., 0,0,0)", default_params["shadow_color"])
169
  else:
170
  ambient_light = None
171
  brightness = None
@@ -174,9 +174,9 @@ def get_user_input(config):
174
  shadow_color = None
175
 
176
  if fog_enabled:
177
- fog_start = text_input_with_default("Enter Fog Start Distance", default_params["fog_start"])
178
- fog_end = text_input_with_default("Enter Fog End Distance", default_params["fog_end"])
179
- fog_color = text_input_with_default("Enter Fog Color (RGB, e.g., 128,128,128)", default_params["fog_color"])
180
  else:
181
  fog_start = None
182
  fog_end = None
@@ -184,45 +184,45 @@ def get_user_input(config):
184
 
185
  # Player Properties Inputs
186
  if player_settings_enabled:
187
- walk_speed = text_input_with_default("Enter Walk Speed", default_params["walk_speed"])
188
- jump_power = text_input_with_default("Enter Jump Power", default_params["jump_power"])
189
- health = text_input_with_default("Enter Health", default_params["health"])
190
  else:
191
  walk_speed = None
192
  jump_power = None
193
  health = None
194
 
195
  if respawn_time_enabled:
196
- respawn_time = text_input_with_default("Enter Respawn Time", default_params["respawn_time"])
197
  else:
198
  respawn_time = None
199
 
200
  # Sound Properties Inputs
201
  if sound_enabled:
202
- background_music = text_input_with_default("Enter Background Music ID (e.g., rbxassetid://123456789)", default_params["background_music"])
203
- sound_volume = text_input_with_default("Enter Sound Volume (e.g., 1)", default_params["sound_volume"])
204
  else:
205
  background_music = None
206
  sound_volume = None
207
 
208
  if sound_effects_enabled:
209
- sound_effects = text_input_with_default("Enter Sound Effects ID (e.g., rbxassetid://987654321)", default_params["sound_effects"])
210
  else:
211
  sound_effects = None
212
 
213
  if environmental_sounds_enabled:
214
- environmental_sounds = text_input_with_default("Enter Environmental Sounds ID (e.g., rbxassetid://1122334455)", default_params["environmental_sounds"])
215
  else:
216
  environmental_sounds = None
217
 
218
  # UI Properties Inputs
219
  if ui_enabled:
220
- ui_text = text_input_with_default("Enter UI Text", default_params["ui_text"])
221
- ui_position = text_input_with_default("Enter UI Position (X,Y,Z, e.g., 0.5,-100,0.5,-25)", default_params["ui_position"])
222
- ui_size = text_input_with_default("Enter UI Size (X,Y,Z, e.g., 0,200,0,50)", default_params["ui_size"])
223
- ui_color = text_input_with_default("Enter UI Color (RGB, e.g., 255,255,255)", default_params["ui_color"])
224
- ui_font = selectbox_with_default("Select UI Font", config["fonts"], default_params["ui_font"])
225
- ui_text_size = text_input_with_default("Enter UI Text Size", default_params["ui_text_size"])
226
  else:
227
  ui_text = None
228
  ui_position = None
@@ -233,22 +233,22 @@ def get_user_input(config):
233
 
234
  # Decals Inputs
235
  if decals_enabled:
236
- texture_id = text_input_with_default("Enter Texture ID (e.g., rbxassetid://123456789)", default_params["texture_id"])
237
- decal_position = selectbox_with_default("Select Decal Position", config["decal_positions"], default_params["decal_position"])
238
  else:
239
  texture_id = None
240
  decal_position = None
241
 
242
  # Particle Effects Inputs
243
  if particles_enabled:
244
- particle_texture = text_input_with_default("Enter Particle Texture ID (e.g., rbxassetid://123456789)", default_params["particle_texture"])
245
- particle_lifetime = text_input_with_default("Enter Particle Lifetime (e.g., 1,2)", default_params["particle_lifetime"])
246
- particle_rate = text_input_with_default("Enter Particle Rate (e.g., 100)", default_params["particle_rate"])
247
- particle_speed = text_input_with_default("Enter Particle Speed (e.g., 10,20)", default_params["particle_speed"])
248
- particle_size = text_input_with_default("Enter Particle Size (e.g., 1,2)", default_params["particle_size"])
249
- particle_acceleration = text_input_with_default("Enter Particle Acceleration (X,Y,Z, e.g., 0,-10,0)", default_params["particle_acceleration"])
250
- particle_rot_speed = text_input_with_default("Enter Particle Rotation Speed (e.g., 100,200)", default_params["particle_rot_speed"])
251
- particle_color = text_input_with_default("Enter Particle Color (RGB, e.g., 255,255,255)", default_params["particle_color"])
252
  else:
253
  particle_texture = None
254
  particle_lifetime = None
@@ -259,10 +259,10 @@ def get_user_input(config):
259
  particle_rot_speed = None
260
  particle_color = None
261
 
262
- custom_prompt_enabled = checkbox_with_default("Enable Custom Prompt", False)
263
 
264
  if custom_prompt_enabled:
265
- custom_prompt = st.text_area("Enter Custom Prompt")
266
  else:
267
  custom_prompt = None
268
 
 
6
  with open('config.json', 'r') as f:
7
  return json.load(f)
8
 
9
+ def checkbox_with_default(label, value, key):
10
+ return st.checkbox(label, value=value, key=key)
11
 
12
+ def text_input_with_default(label, value, key):
13
+ return st.text_input(label, value=value, key=key)
14
 
15
+ def selectbox_with_default(label, options, value, key):
16
+ return st.selectbox(label, options, index=options.index(value), key=key)
17
 
18
  def get_user_input(config):
19
  st.title("Advanced Roblox Lua Script Generator")
 
21
  default_params = config["default_parameters"]
22
 
23
  # Game Object Properties
24
+ color_enabled = checkbox_with_default("Enable Color", True, "color_enabled")
25
+ size_enabled = checkbox_with_default("Enable Size", True, "size_enabled")
26
+ position_enabled = checkbox_with_default("Enable Position", True, "position_enabled")
27
+ shape_enabled = checkbox_with_default("Enable Shape", True, "shape_enabled")
28
+ material_enabled = checkbox_with_default("Enable Material", True, "material_enabled")
29
+ transparency_enabled = checkbox_with_default("Enable Transparency", True, "transparency_enabled")
30
+ reflectance_enabled = checkbox_with_default("Enable Reflectance", True, "reflectance_enabled")
31
+ rotation_speed_enabled = checkbox_with_default("Enable Rotation Speed", True, "rotation_speed_enabled")
32
+ bounce_height_enabled = checkbox_with_default("Enable Bounce Height", True, "bounce_height_enabled")
33
+ collision_enabled = checkbox_with_default("Enable Collision", True, "collision_enabled")
34
+ surface_enabled = checkbox_with_default("Enable Surface Type", True, "surface_enabled")
35
+ anchor_enabled = checkbox_with_default("Enable Anchor", True, "anchor_enabled")
36
+ collision_group_enabled = checkbox_with_default("Enable Collision Group", True, "collision_group_enabled")
37
+ custom_physics_enabled = checkbox_with_default("Enable Custom Physics", True, "custom_physics_enabled")
38
+ part_cframe_enabled = checkbox_with_default("Enable Part CFrame", True, "part_cframe_enabled")
39
 
40
  # Camera Properties
41
+ camera_enabled = checkbox_with_default("Enable Camera Configuration", True, "camera_enabled")
42
+ camera_interpolation_enabled = checkbox_with_default("Enable Camera Interpolation", default_params["camera_interpolation"], "camera_interpolation_enabled")
43
 
44
  # Lighting Properties
45
+ lighting_enabled = checkbox_with_default("Enable Lighting Configuration", True, "lighting_enabled")
46
+ fog_enabled = checkbox_with_default("Enable Environmental Fog", True, "fog_enabled")
47
+ shadow_enabled = checkbox_with_default("Enable Shadow Properties", True, "shadow_enabled")
48
 
49
  # Player Properties
50
+ player_settings_enabled = checkbox_with_default("Enable Player Settings", True, "player_settings_enabled")
51
+ respawn_time_enabled = checkbox_with_default("Enable Respawn Time", True, "respawn_time_enabled")
52
 
53
  # Sound Properties
54
+ sound_enabled = checkbox_with_default("Enable Sound", True, "sound_enabled")
55
+ sound_effects_enabled = checkbox_with_default("Enable Sound Effects", True, "sound_effects_enabled")
56
+ environmental_sounds_enabled = checkbox_with_default("Enable Environmental Sounds", True, "environmental_sounds_enabled")
57
 
58
  # UI Properties
59
+ ui_enabled = checkbox_with_default("Enable UI Configuration", True, "ui_enabled")
60
 
61
  # Decals
62
+ decals_enabled = checkbox_with_default("Enable Decals", True, "decals_enabled")
63
 
64
  # Particle Effects
65
+ particles_enabled = checkbox_with_default("Enable Particle Effects", True, "particles_enabled")
66
 
67
  # Advanced Game Object Properties Inputs
68
  if color_enabled:
69
+ color = text_input_with_default("Enter Color (RGB, e.g., 255,0,0)", default_params["color"], "color")
70
  else:
71
  color = None
72
 
73
  if size_enabled:
74
+ size = text_input_with_default("Enter Size (X,Y,Z, e.g., 4,1,2)", default_params["size"], "size")
75
  else:
76
  size = None
77
 
78
  if position_enabled:
79
+ position = text_input_with_default("Enter Position (X,Y,Z, e.g., 0,10,0)", default_params["position"], "position")
80
  else:
81
  position = None
82
 
83
  if shape_enabled:
84
+ shape = selectbox_with_default("Select Shape", config["shapes"], default_params["shape"], "shape")
85
  else:
86
  shape = None
87
 
88
  if material_enabled:
89
+ material = selectbox_with_default("Select Material", config["materials"], default_params["material"], "material")
90
  else:
91
  material = None
92
 
93
  if transparency_enabled:
94
+ transparency = text_input_with_default("Enter Transparency (0-1, e.g., 0.5)", default_params["transparency"], "transparency")
95
  else:
96
  transparency = None
97
 
98
  if reflectance_enabled:
99
+ reflectance = text_input_with_default("Enter Reflectance (0-1, e.g., 0.5)", default_params["reflectance"], "reflectance")
100
  else:
101
  reflectance = None
102
 
103
  if rotation_speed_enabled:
104
+ rotation_speed = text_input_with_default("Enter Rotation Speed (e.g., 10)", default_params["rotation_speed"], "rotation_speed")
105
  else:
106
  rotation_speed = None
107
 
108
  if bounce_height_enabled:
109
+ bounce_height = text_input_with_default("Enter Bounce Height (e.g., 10)", default_params["bounce_height"], "bounce_height")
110
  else:
111
  bounce_height = None
112
 
113
  if collision_enabled:
114
+ collision = selectbox_with_default("Enable Collision", config["collisions"], default_params["collision"], "collision")
115
  else:
116
  collision = None
117
 
118
  if surface_enabled:
119
+ surface = selectbox_with_default("Select Surface Type", config["surfaces"], default_params["surface"], "surface")
120
  else:
121
  surface = None
122
 
123
  if anchor_enabled:
124
+ anchor = selectbox_with_default("Enable Anchor", ["true", "false"], default_params["anchor"], "anchor")
125
  else:
126
  anchor = None
127
 
128
  if collision_group_enabled:
129
+ collision_group = selectbox_with_default("Select Collision Group", config["collision_groups"], default_params["collision_group"], "collision_group")
130
  else:
131
  collision_group = None
132
 
133
  if custom_physics_enabled:
134
+ angular_velocity = text_input_with_default("Enter Angular Velocity (X,Y,Z, e.g., 0,0,0)", default_params["angular_velocity"], "angular_velocity")
135
+ linear_velocity = text_input_with_default("Enter Linear Velocity (X,Y,Z, e.g., 0,0,0)", default_params["linear_velocity"], "linear_velocity")
136
+ density = text_input_with_default("Enter Density", default_params["density"], "density")
137
  else:
138
  angular_velocity = None
139
  linear_velocity = None
140
  density = None
141
 
142
  if part_cframe_enabled:
143
+ part_cframe = text_input_with_default("Enter Part CFrame (e.g., CFrame.new(0, 50, -100))", default_params["part_cframe"], "part_cframe")
144
  else:
145
  part_cframe = None
146
 
147
  # Camera Properties Inputs
148
  if camera_enabled:
149
+ camera_type = selectbox_with_default("Select Camera Type", config["camera_types"], default_params["camera_type"], "camera_type")
150
+ camera_position = text_input_with_default("Enter Camera Position (X,Y,Z, e.g., 0,50,-100)", default_params["camera_position"], "camera_position")
151
+ field_of_view = text_input_with_default("Enter Field of View", default_params["field_of_view"], "field_of_view")
152
  else:
153
  camera_type = None
154
  camera_position = None
155
  field_of_view = None
156
 
157
  if camera_interpolation_enabled:
158
+ camera_interpolation = checkbox_with_default("Enable Camera Interpolation", default_params["camera_interpolation"], "camera_interpolation")
159
  else:
160
  camera_interpolation = None
161
 
162
  # Lighting Properties Inputs
163
  if lighting_enabled:
164
+ ambient_light = text_input_with_default("Enter Ambient Light (RGB, e.g., 128,128,128)", default_params["ambient_light"], "ambient_light")
165
+ brightness = text_input_with_default("Enter Brightness", default_params["brightness"], "brightness")
166
+ time_of_day = selectbox_with_default("Select Time of Day", config["times_of_day"], default_params["time_of_day"], "time_of_day")
167
+ shadow_softness = text_input_with_default("Enter Shadow Softness (0-1, e.g., 0.5)", default_params["shadow_softness"], "shadow_softness")
168
+ shadow_color = text_input_with_default("Enter Shadow Color (RGB, e.g., 0,0,0)", default_params["shadow_color"], "shadow_color")
169
  else:
170
  ambient_light = None
171
  brightness = None
 
174
  shadow_color = None
175
 
176
  if fog_enabled:
177
+ fog_start = text_input_with_default("Enter Fog Start Distance", default_params["fog_start"], "fog_start")
178
+ fog_end = text_input_with_default("Enter Fog End Distance", default_params["fog_end"], "fog_end")
179
+ fog_color = text_input_with_default("Enter Fog Color (RGB, e.g., 128,128,128)", default_params["fog_color"], "fog_color")
180
  else:
181
  fog_start = None
182
  fog_end = None
 
184
 
185
  # Player Properties Inputs
186
  if player_settings_enabled:
187
+ walk_speed = text_input_with_default("Enter Walk Speed", default_params["walk_speed"], "walk_speed")
188
+ jump_power = text_input_with_default("Enter Jump Power", default_params["jump_power"], "jump_power")
189
+ health = text_input_with_default("Enter Health", default_params["health"], "health")
190
  else:
191
  walk_speed = None
192
  jump_power = None
193
  health = None
194
 
195
  if respawn_time_enabled:
196
+ respawn_time = text_input_with_default("Enter Respawn Time", default_params["respawn_time"], "respawn_time")
197
  else:
198
  respawn_time = None
199
 
200
  # Sound Properties Inputs
201
  if sound_enabled:
202
+ background_music = text_input_with_default("Enter Background Music ID (e.g., rbxassetid://123456789)", default_params["background_music"], "background_music")
203
+ sound_volume = text_input_with_default("Enter Sound Volume (e.g., 1)", default_params["sound_volume"], "sound_volume")
204
  else:
205
  background_music = None
206
  sound_volume = None
207
 
208
  if sound_effects_enabled:
209
+ sound_effects = text_input_with_default("Enter Sound Effects ID (e.g., rbxassetid://987654321)", default_params["sound_effects"], "sound_effects")
210
  else:
211
  sound_effects = None
212
 
213
  if environmental_sounds_enabled:
214
+ environmental_sounds = text_input_with_default("Enter Environmental Sounds ID (e.g., rbxassetid://1122334455)", default_params["environmental_sounds"], "environmental_sounds")
215
  else:
216
  environmental_sounds = None
217
 
218
  # UI Properties Inputs
219
  if ui_enabled:
220
+ ui_text = text_input_with_default("Enter UI Text", default_params["ui_text"], "ui_text")
221
+ ui_position = text_input_with_default("Enter UI Position (X,Y,Z, e.g., 0.5,-100,0.5,-25)", default_params["ui_position"], "ui_position")
222
+ ui_size = text_input_with_default("Enter UI Size (X,Y,Z, e.g., 0,200,0,50)", default_params["ui_size"], "ui_size")
223
+ ui_color = text_input_with_default("Enter UI Color (RGB, e.g., 255,255,255)", default_params["ui_color"], "ui_color")
224
+ ui_font = selectbox_with_default("Select UI Font", config["fonts"], default_params["ui_font"], "ui_font")
225
+ ui_text_size = text_input_with_default("Enter UI Text Size", default_params["ui_text_size"], "ui_text_size")
226
  else:
227
  ui_text = None
228
  ui_position = None
 
233
 
234
  # Decals Inputs
235
  if decals_enabled:
236
+ texture_id = text_input_with_default("Enter Texture ID (e.g., rbxassetid://123456789)", default_params["texture_id"], "texture_id")
237
+ decal_position = selectbox_with_default("Select Decal Position", config["decal_positions"], default_params["decal_position"], "decal_position")
238
  else:
239
  texture_id = None
240
  decal_position = None
241
 
242
  # Particle Effects Inputs
243
  if particles_enabled:
244
+ particle_texture = text_input_with_default("Enter Particle Texture ID (e.g., rbxassetid://123456789)", default_params["particle_texture"], "particle_texture")
245
+ particle_lifetime = text_input_with_default("Enter Particle Lifetime (e.g., 1,2)", default_params["particle_lifetime"], "particle_lifetime")
246
+ particle_rate = text_input_with_default("Enter Particle Rate (e.g., 100)", default_params["particle_rate"], "particle_rate")
247
+ particle_speed = text_input_with_default("Enter Particle Speed (e.g., 10,20)", default_params["particle_speed"], "particle_speed")
248
+ particle_size = text_input_with_default("Enter Particle Size (e.g., 1,2)", default_params["particle_size"], "particle_size")
249
+ particle_acceleration = text_input_with_default("Enter Particle Acceleration (X,Y,Z, e.g., 0,-10,0)", default_params["particle_acceleration"], "particle_acceleration")
250
+ particle_rot_speed = text_input_with_default("Enter Particle Rotation Speed (e.g., 100,200)", default_params["particle_rot_speed"], "particle_rot_speed")
251
+ particle_color = text_input_with_default("Enter Particle Color (RGB, e.g., 255,255,255)", default_params["particle_color"], "particle_color")
252
  else:
253
  particle_texture = None
254
  particle_lifetime = None
 
259
  particle_rot_speed = None
260
  particle_color = None
261
 
262
+ custom_prompt_enabled = checkbox_with_default("Enable Custom Prompt", False, "custom_prompt_enabled")
263
 
264
  if custom_prompt_enabled:
265
+ custom_prompt = st.text_area("Enter Custom Prompt", key="custom_prompt")
266
  else:
267
  custom_prompt = None
268