TileMap – How To Get ALL The Tiles Effortlessly!

If you're building a 2D game in Unity3D, odds are you've come across the TileMap component. The TileMap is a powerful tool that allows you to create a grid of tiles that you can render your tiles with instead of hand-placing individual game objects with sprites. It has a host of built in functionality that you might otherwise find yourself manually writing, like mapping coordinates to particular cells on a map. And what's even cooler about using a TileMap? You don't need to handroll your own editor to paint tiles! I think I'd pass on having to do that. But have you found yourself in a situation where you want to get all of the painted tiles on a TileMap? You may have found it's not quite as obvious as you'd have hoped! What We Have To Work With On…

0 Comments

Using Autofac With Unity3D

Why Consider Using Autofac With Unity3D? I think using a dependency injection framework is really valuable when you're building a complex application, and in my opinion, a game built in Unity is a great example of this. Using Autofac with Unity3D doesn't need to be a special case. I wrote a primer for using Autofac, and in it I discuss reasons why it's valuable and some of the reasons you'd consider switching to using a dependency container framework. Now it doesn't need to be Autofac, but I love the API and the usability, so that's my weapon of choice. Building a game can result in many complex systems working together. Not only that, if you intend to build many games it's a great opportunity to refactor code into different libraries for re-usability. If we're practicing writing good code using constructor…

2 Comments

Unity3D and .NET 4.x Framework

Unity3D Default .NET Framework I recently wrote that I wanted to start writing more Unity3D articles because I'm starting to pick up more Unity3D hobby work. It felt like a good opportunity to share some of my learnings so that anyone searching across the web might stumble upon this and get answers to the same problems I had. Unity3D as of 2018.1.1f1 (which is the version I'm currently using), still defaults to using .NET 3.5 as the framework version. Nothing wrong with that either. I'm sure there are reasons that they have for staying at that version, probably because of Mono and cross platform reasons if I were to guess, so I'm not complaining. For reference, this setting in Unity3D is referred to as "Scripting Runtime Version". So if you're googling more about this later, that's what Unity calls it.…

0 Comments

End of content

No more pages to load