Skip to main content

Posts

Showing posts from August, 2018

Unity Editor Window (Part 3)

Unity Editor Hello, Unity Dev’s I am back again with Part 3 of Creating custom editor window in unity. In today’s blog we will look around: “How to load Textures files from resource folder and create our buttons.” Step1. Gather some images related to the headers of our sub-toolbars or if you are good at photoshop create some, btw I have zero skills when it comes to photoshop so I am goanna gather images from internet. Once we have are images ready drag them into respected folder under root folder Resources. It will look something like this: Step2. Scripting   Now we need to create a function which will be called once whenever we will switch from sub-tabs. Hmmmm, so how to do that!!! First create a function and name it as per your want’s I have named mine as: “MakeWindow” Then write down these lines: Create two variables a list: to store our loaded texture...

Special Blog- Tic Tac Toe Game in Unity.

One can create a game in many ways the way used in this blog is not absolute. The purpose of this blog is to let the users understand unity and coding a bit better than before. Step1: Images needed for the project. We will be needing 4 images to create this game. 1-Cross 2-Circle 3-Board 4-Background Step2: Setting up the Scene. Set the game view to 2d. 1. MainCamera- Select the main camera and under Camera component it has a property named Projection set it to Orthographic. 2.   GameOver- Create an empty gameobject and add sprite renderer to it. Add a sprite image to it by clicking on sprite property. Set the Color to black or any other color as per your preference. Import the image by simply dragging the script from explorer to unity under project panel. Select the image and change it texture type to sprite 2D and UI. 3.   BackGround- Used to...