this post was submitted on 14 Oct 2024
1 points (100.0% liked)

Godot: The open source game engine

21 readers
1 users here now

A community for discussion and support in development with the Godot game engine.

founded 1 year ago
MODERATORS
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/TaianYT on 2024-10-14 07:52:42+00:00.


Everything is in the title: is there any downsides to Autoload/Singletons ?

I'm quite new when it comes to GameDev and Godot in general, and I learnt about autoloads a few months ago. I've tried not to use them too much and really push forward the usage of class with static functions/variables, signals and other methods to keep my code organized.

But when I look at Autoloads, it just seems so powerfull and it seems like it could be used to pretty much anything. So here's my question, apart from the fact that you could easily end up with a messy code structure, is there any downsides with them ? For example does it take more memory to run, more performances ? Something else ? Or is it just a very handy option I should use more often ?

I'm really curious about it, thanks !

no comments (yet)
sorted by: hot top controversial new old
there doesn't seem to be anything here