public void saveTools() { if (toolHub == null) { toolHub = GameObject.Find("ToolMenu").GetComponent <ToolHub>(); } for (int i = 0; i < GameData.toolSum; i++) { currentData.tools[i] = toolHub.getToolName(i); } }
protected override void Start() { base.Start(); lastPos = gameObject.transform.position; toolHub = GameObject.Find("ToolMenu").GetComponent <ToolHub>(); if (state >= 10) { end(); } }
public void loadTools() { if (toolHub == null) { toolHub = GameObject.Find("ToolMenu").GetComponent <ToolHub>(); } for (int i = 0; i < GameData.toolSum; i++) { if (currentData.tools[i] == null) { currentData.tools[i] = ""; } toolHub.addObject(currentData.tools[i]); } }
// Start is called before the first frame update protected override void Start() { base.Start(); animator = this.GetComponent <Animator>(); toolHub = GameObject.Find("ToolMenu").GetComponent <ToolHub>(); if (state == 1) { animator.SetInteger("state", state); } if (state == 2) { Destroy(gameObject); } }
private void Start() { toolHub = GameObject.Find("ToolMenu").GetComponent <ToolHub>(); #if UNITY_STANDALONE platform = PLATFORM.STANDALONE; Debug.Log("UNITY_STANDALONE.STANDALONE"); #endif #if UNITY_ANDROID platform = PLATFORM.PHONE; //Debug.Log("UNITY_ANDROID.PHONE"); #endif #if UNITY_IPHONE platform = PLATFORM.PHONE; Debug.Log("UNITY_IPHONE.PHONE"); #endif #if UNITY_EDITOR platform = PLATFORM.STANDALONE; //Debug.Log("UNITY_EDITOR.STANDALONE"); #endif }
void Start() { toolHub = GetComponentInParent <ToolHub> (); }
private void Start() { toolHub = GameObject.Find("ToolMenu").GetComponent <ToolHub>(); IlluMenu = GameObject.Find("FuncButton").GetComponent <IllustrationMenu>(); oldScale = gameObject.transform.localScale; }