CDN Integration Mobs
This commit is contained in:
+7
-3
@@ -254,6 +254,10 @@ func add_log_entry(text: String, color: Color):
|
||||
label.queue_free()
|
||||
)
|
||||
|
||||
# Keep log from getting too long
|
||||
while event_log.get_child_count() > 10:
|
||||
event_log.get_child(0).queue_free()
|
||||
# Keep log from getting too long (use call_deferred to avoid modifying during iteration)
|
||||
if event_log.get_child_count() > 10:
|
||||
var to_remove = event_log.get_child_count() - 10
|
||||
for i in range(to_remove):
|
||||
var child = event_log.get_child(0)
|
||||
if is_instance_valid(child):
|
||||
child.queue_free()
|
||||
|
||||
Reference in New Issue
Block a user