Tuesday, 2 January 2018

Defeating the Coding Demons!

Iteration v0.1

Iteration v0.12
Iteration v0.13



I've been working on creating a runtime Arena Editor within Unity over the past month, which allows players to place objects into a scene and edit their position, rotation and scale all at runtime, very much like the Unity editor itself. Above are 3 separate iterations of my progress.

The first was simply getting a camera to move around and the ability to place different placeholder objects. I also added in a simple 'Delete All' function that wipes the slate clean.

The second expanded upon this, and fixed a few starting inconsistencies, IE spawning objects with an offset so they aren't instantiated in the floor, and adding physic enabled objects, along with the ability to select each individual object for editing. This included changing the objects material and instantiating a axis gizmo to the selected objects transform location.

The third iteration I coded a few runtime object editor scripts that uses these gizmos to allow the player to freely move, rotate and scale the selected object freely by clicking the axis and moving the mouse. Its not perfect but there is still a fair amount to add to the editor as a whole, and many tweaks and additions to be made. This was just the process of getting basic functionality up and running.

I learnt alot, surprised by the complexity of something I think alot of developers take for granted is that little gizmo we use in lots of 3D editing programs/game engines.