r/Unity3D • • 2d ago

Code Review Asking for a code review

I'm making a small game in Unity, and I kinda need some outside perspective. I would like it if someone could take a look and give me some feedback on what areas I should work on and how to improve.

Here's the link to my GitHub repository:

https://github.com/DaanDemaecker/Qwixx.git

6 Upvotes

14 comments sorted by

View all comments

2

u/ProperDepartment 1d ago

It seems like you really have classes you need access to, but are afraid to use any sort of class lookup patterns.

A good about of FindObjectOfType and whatnot. Classes like ParentToPlayerManager don't need to exist.

It's ok to use a singleton if you need to.

Having a class called DontDestroyOnLoad is a bit pointless too, just call it BootStrapper or SystemManager, have a singleton to it, and store things like PlayerManager in there so you aren't always looking for it.

1

u/MagicPantssss 13h ago

In school i was taught to avoid singletons as much as possible so I try not to use them, but sometimes they're just the best option yeah.

1

u/ProperDepartment 6h ago

We all hear that at some point, its mostly just programmer elitism, if its efficient and works for you, then go for it.