I have moved this over to the Tech Interview Cheat Sheet Repo and has been expanded and even has code challenges you can run and practice against!
\
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; | |
public class SceneAttribute : PropertyAttribute | |
{ | |
public int selectedValue = 0; | |
public SceneAttribute () | |
{ | |
} | |
} |
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 UnityEditor; | |
using System.IO; | |
public class MultiScene | |
{ | |
[MenuItem ("File/Combine Scenes")] | |
static void Combine () | |
{ |
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.Collections; | |
public class DontDestroyObject : MonoBehaviour | |
{ | |
static DontDestroyObject instance; | |
void Awake () | |
{ | |
if (!instance) { |
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 System.IO; | |
using UnityEditor; | |
public static class SceneCreator | |
{ | |
[MenuItem( "Assets/Create/Empty Scene" )] | |
private static void CreateEmptyScene() | |
{ | |
CreateScene( |
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; | |
// Nine slice scaling using a Mesh. | |
// Original code by Asher Vollmer | |
// https://twitter.com/AsherVo | |
// http://ashervollmer.tumblr.com | |
// Modifications by Thomas Viktil | |
// https://twitter.com/mandarinx | |
// http://ma.ndar.in/ |
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.EventSystems; | |
using System.Collections; | |
using System.Reflection; | |
using System; | |
public class FadeInOut : MonoBehaviour { | |
[Serializable] |
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.Collections; | |
using UnityEditor; | |
/* by FVS - Ha Luan */ | |
public class StartWithSpecificScene : Editor | |
{ | |
const string settingKey = "FVSHaluanStartWithSpecificScene"; | |
const string firstScenePath = "Assets/Scenes/Login.unity"; |
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.EventSystems; | |
public class Player1CtrlRemap : MonoBehaviour | |
{ | |
// Initialisation of player's controls. | |
public GameObject upBtn, downBtn, lftBtn, rightBtn; | |
public btnInit bI; |
OlderNewer