b3agz / Code-A-Game-Like-Minecraft-In-Unity

Project files for a Youtube tutorial series on coding a game like Minecraft in Unity.
304 stars 236 forks source link

Suggestion: Blocks Enumeration #6

Open Garethp opened 5 years ago

Garethp commented 5 years ago

Hey, I have a quick suggestion, something that I did as I'm following your series. I went ahead and created a BlockIndexes enum so that I could refer to my blocks by name rather than trying to remember what byte they were assigned to. So when adding dirt, I add (byte) BlockIndexes.Dirt. I don't know if it'll help or not, but it might be a nice addition to make the code a bit more readable

oliviathevampire commented 1 year ago

Do you have a repo with this?