When a user does not select a game object for the tool, a null pointer is thrown.
Expected output: User does not select an optional game object, the tool generates the full tilemap.
Current output: User does not select an optional game object, the map generates up until the code trys to add the null game object and then a null pointer is thrown.
simple fix, handle the game object being passed in and if its null don't try to add it to the scene.
When a user does not select a game object for the tool, a null pointer is thrown.
Expected output: User does not select an optional game object, the tool generates the full tilemap.
Current output: User does not select an optional game object, the map generates up until the code trys to add the null game object and then a null pointer is thrown.
simple fix, handle the game object being passed in and if its null don't try to add it to the scene.