This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
namespace YounGenTech.VoxelTech { | |
[System.Serializable] | |
public struct Block { | |
public static Block Empty { get { return new Block(0); } } | |
public static Block Air { get { return new Block(1); } } | |
public static Block Solid { get { return new Block(2); } } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
public static class MathHelper { | |
/// <summary> | |
/// Get which face of a rotated block will be on a side (face parameter) | |
/// </summary> | |
public static int GetRotatedFace(this int rotationIndex, int face) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using UnityEngine; | |
public enum Direction { | |
Left = 0, | |
Right = 1, | |
Bottom = 2, Down = 2, | |
Top = 3, Up = 3, | |
Backward = 4, Back = 4, | |
Forward = 5, Front = 5 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System; | |
using System.Collections; | |
using System.Collections.Generic; | |
[System.Serializable] | |
public struct VectorI3 { | |
#region Constants | |
public static VectorI3 back { get { return new VectorI3(0, 0, -1); } } | |
public static VectorI3 bottom { get { return new VectorI3(0, -1, 0); } } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.UI; | |
/* | |
Radial Layout Group by Just a Pixel (Danny Goodayle) - http://www.justapixel.co.uk | |
Copyright (c) 2015 | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.UI; | |
using UnityEngine.Events; | |
using UnityEngine.EventSystems; | |
using System.Collections; | |
#if UNITY_EDITOR | |
using UnityEditor; | |
#endif |