Godot Version
4.2.2
Question
Hello everyone!
I’m reaching the end of developing my first game in Godot (very simple sudoku-like game).
I was intending to learn Godot this way (and I absolutely learnt a lot!). However my code is a mess, definitely not maintainable, not very scalable, tight coupling everywhere, globals everywhere…
It’s yucky!
I’d like to share with you some of the problems I’m still facing by the end of development and maybe you can point me towards useful resources to tackle those issues.
FYI I’ve been a professional Java developer for 18 years so don’t be afraid to use advanced terms ^^
#1: Tight coupling between objects
So I’ve done some research and it seems signals are the way to go, and the root tree should be the one connecting emitters and receivers is that correct?
#2: Loading time for the levels is quite long
I have a certain number of generated levels as text files (generated with some java code) that I import as assets in my game. There’s approximately 4000+ levels and creating the level selection screen is therefore quite long.
I think the time of creating each button for each level is what takes the longest time. Or maybe it’s the opening / reading of all the files?
I tried multithreading but failed to implement it correctly.
Any resources on this kind of problematic?
#3: Loading save games
To give the possibility to continue a puzzle, I save the state of the puzzle. I convert each object tile as Json and then save it.
The problem is when I load back the file, it is loaded as a dictionary. I’m quite used to Jackson libraries (auto converting from and back to Json / Objects).
Any similar mechanism in Godot?
#4: Code organization
This one is quite simple: how do you guys organize your files in the folder hierarchy? What is the best practice as to regrouping scenes / scripts / assets?
Those are the main questions that still remains (I have a lot more but if I could have an answer for those ones It would really help)
Thanks for reading!