Poobslag / frog-finder

A Godot game. Can you find the frog?
MIT License
3 stars 1 forks source link

Refactor: Demos use unique Godot 4.x 'unique names'. #274

Closed Poobslag closed 8 months ago

Poobslag commented 8 months ago

Demos now use Godot 4.x 'unique names'. These utilize a node cache, so we don't need onready variables. They avoid initialization errors where onready variables are temporarily null, so we don't need workarounds such as the workaround in BeachBallDemo.

UniqueNames specifically search for nodes within the same scene. For this reason, I've split out BackgroundDemoCustom and BackgroundDemoPreset into their own scenes to reduce the scope of their unique named nodes.