public override void _Ready() { Path2D path1 = GetNode <Path2D>("/root/Node2D/Path2D"); Path2D path2 = GetNode <Path2D>("/root/Node2D/Path2D2"); Path2D path3 = GetNode <Path2D>("/root/Node2D/Path2D3"); paths.Add(path1); paths.Add(path2); paths.Add(path3); label = GetNode <Godot.RichTextLabel>("/root/Node2D/MoneyLabel"); trainsLabel = GetNode <Godot.RichTextLabel>("/root/Node2D/TrainsDestroyedLabel"); this.updateLabels(); }
// Called when the node enters the scene tree for the first time. public override void _Ready() { hpLabel = GetNode <Godot.RichTextLabel>("HpLabel"); updateLabel(); }