NullReferenceException: Object reference not set to an instance of an object

This is a problem I face so many times that I need to write it as a reminder for my future self. How to fix Null Reference Exceptions: What does it mean that an object reference is not set to an instance of an object. Let’s say we have a method we want to call, this function is in script B, and you want to … Continue reading NullReferenceException: Object reference not set to an instance of an object

Advertisements

Roguelike C# in Unity (3/13): Generating a dungeon

Welcome to the 3rd part of the tutorial! The original Python tutorial can be found here. Previous posts for C# in Unity: 1- RogueLike C# in Unity (1/13): Drawing the ‘@’ symbol and moving it around 2- RogueLike C# in Unity (2/13): The generic Entity, the render functions, and the map This is starting to get complex, in this tutorial we’ll keep working in our … Continue reading Roguelike C# in Unity (3/13): Generating a dungeon

RogueLike C# in Unity (2/13): The generic Entity, the render functions, and the map

Part 2 is here. This week we’ll create a generic Entity from where we’ll create all our entities, we’ll skip the original render functions from the original Python version, as won’t be used here, and finally we’ll create a basic map where we’ll be moving around. Don’t forget to check out the previous parts of the tutorial: Part 1: RogueLike C# in Unity (1/13): Drawing … Continue reading RogueLike C# in Unity (2/13): The generic Entity, the render functions, and the map

Starting June 18th RoguelikeDev Does The Complete Roguelike Tutorial 2019

Since few years back the folks at /r/roguelikedev have been going through the Complete Roguelike Tutorial together, working on a couple parts each week for a total of 8 weeks. It’s great for beginners because it helps give them the little push they might need to start. And because everyone is going through it at the same time the weekly threads are a good place … Continue reading Starting June 18th RoguelikeDev Does The Complete Roguelike Tutorial 2019

Prototype for the character selection screen

Learning Game Dev #3: Fixing bugs, development mode, UI, Lists vs Arrays, and renaming GameObject instances

At the beginning of the week I ended fixing multiple bugs just by changing one little thing, when I check if the menus/UI is enabled/disabled I set the game Time.timeScale to 0 , this was causing a wide variety of issues: The time counter was starting before expected, for example: The time left to complete a level was running through the GameOver screen even if … Continue reading Learning Game Dev #3: Fixing bugs, development mode, UI, Lists vs Arrays, and renaming GameObject instances