void Awake () { if(InputParser_rightClick.instance == null) { instance = this; } else { Debug.LogWarning("Multiple instance of InputParser_rightClick singleton found, disabling this one : " + this.gameObject.name.ToString()); this.enabled = false; } if(raycast_Cameras.Count == 0) { Debug.LogWarning("There are no cameras assigned to raycast from the InputParser_rightClick, disabling this : " + this.gameObject.name.ToString()); this.enabled = false; } if(LayersForInput == _layerSet_Nothing) { Debug.LogWarning("InputParser_rightClick - no layers assigned for input : This is not an issue if you intend to assign new LayerMask objects to the InputParser's public mask object 'LayersForInput' during runtime."); Debug.LogWarning("InputParser_rightClick - no layers assigned for input : Currently no renderers are going to be raycasted or sent input messages!"); } //Clicks should never be delayed by this script for flow of control purposes, only enough to properly process inputs _time_ClickUnDelayed = Time.time; //Store screen dimensions so we can easily tell if the mouse is in the screen or not _screenW = Screen.width; _screenH = Screen.height; //If this is built to use mouse, we will add a single internalInputTracker to our list so that we don't have to worry about it later //There will only ever be this one tracker in the List (for the mouse); the List remains because it makes the code uniform in FixedUpdate() when // sending messages, eliminating the need to handle them differently in FixedUpdate() _ongoing_Inputs.Add(new internalInputTracker(Vector3.zero)); }
void Awake() { if(InputParser_rightClick.instance == null) { instance = this; } else { Debug.LogWarning("Multiple instance of InputParser_rightClick singleton found, disabling this one : " + this.gameObject.name.ToString()); this.enabled = false; } if(raycast_Cameras.Count == 0) { Debug.LogWarning("There are no cameras assigned to raycast from the InputParser_rightClick, disabling this : " + this.gameObject.name.ToString()); this.enabled = false; } if(LayersForInput == _layerSet_Nothing) { Debug.LogWarning("InputParser_rightClick - no layers assigned for input : This is not an issue if you intend to assign new LayerMask objects to the InputParser's public mask object 'LayersForInput' during runtime."); Debug.LogWarning("InputParser_rightClick - no layers assigned for input : Currently no renderers are going to be raycasted or sent input messages!"); } //Clicks should never be delayed by this script for flow of control purposes, only enough to properly process inputs _time_ClickUnDelayed = Time.time; //Store screen dimensions so we can easily tell if the mouse is in the screen or not _screenW = Screen.width; _screenH = Screen.height; //If this is built to use mouse, we will add a single internalInputTracker to our list so that we don't have to worry about it later //There will only ever be this one tracker in the List (for the mouse); the List remains because it makes the code uniform in FixedUpdate() when // sending messages, eliminating the need to handle them differently in FixedUpdate() _ongoing_Inputs.Add(new internalInputTracker(Vector3.zero)); }