private void Awake() { place = FindObjectOfType <PlaceObjects>(); tool = FindObjectOfType <MultiTool>(); tileLayout = FindObjectOfType <TileLayout>(); player = GameObject.FindGameObjectWithTag("Player"); indicatorRenderer = indicator.GetComponent <SpriteRenderer>(); }
private void Awake() { tool = FindObjectOfType <MultiTool>(); if (!tool) { gameObject.SetActive(false); Debug.LogWarning("no tool found!!"); } player = GameObject.FindGameObjectWithTag("Player"); }
private void Start() { rotateMe = GetComponentInChildren <RotateMe>(); var keyboardCommand = GetComponent <KeyboardCommand>(); if (keyboardCommand != null) { keyboardCommand.enabled = false; } multiTool = GetComponentInChildren <MultiTool>(); Temperment = (Personality)Random.Range(0, 5); myShip = GetComponent <Ship>(); }
//Singleton private void Awake() { if (_instance != null && _instance != this) { Destroy(this.gameObject); } else { _instance = this; } multiTool = FindObjectOfType <MultiTool>(); timeSystem = FindObjectOfType <TimeSystem>(); }
private void Start() { mode = ToolModes.defaultMode; multiTool = FindObjectOfType <MultiTool>(); wheel = GameObject.FindWithTag("wheel"); topLeft = wheel.transform.Find("TopLeft").GetComponent <Image>(); topRight = wheel.transform.Find("TopRight").GetComponent <Image>(); bottomLeft = wheel.transform.Find("BottomLeft").GetComponent <Image>(); bottomRight = wheel.transform.Find("BottomRight").GetComponent <Image>(); currentImage = null; selectedImage = null; blue = new Color32(182, 205, 242, 190); darkBlue = new Color32(34, 90, 200, 190); white = new Color32(255, 255, 255, 190); resetColors(); wheel.SetActive(false); }
// Start is called before the first frame update void Start() { _tool = GetComponentInChildren <MultiTool>(); _ship = GetComponentInChildren <RotateMe>(); }
private void Awake() { tool = FindObjectOfType <MultiTool>(); player = GameObject.FindGameObjectWithTag("Player"); direction = FindObjectOfType <PlayerDirection_>(); }
private void Awake() { tool = FindObjectOfType <MultiTool>(); indicator = GameObject.FindWithTag("indicator"); }
private void Awake() { multiTool = FindObjectOfType <MultiTool>(); }
public static void ShowWindow() { MultiTool mTool = (MultiTool)GetWindow(typeof(MultiTool), false, "Multi-Tool"); mTool.Show(); }