Fixed overlapping

This commit is contained in:
rendo 2026-04-07 11:39:29 +05:00
commit 1ad1bd0ad2

View file

@ -61,8 +61,8 @@ impl INode2D for Plant {
impl Plant {
#[func]
fn restructure(&mut self) {
if let Some(mut child) = self.base().get_child(0) {
child.queue_free();
for i in 0..self.base().get_children().len() {
self.base_mut().get_child(i as i32).unwrap().queue_free();
}
let Some(godot_genome) = self.genome.clone() else { return; };