BeardedManStudios.Network.NetworkedMonoBehavior.KeyUpRequest C# (CSharp) Method

KeyUpRequest() private method

private KeyUpRequest ( int keyCode, int frame ) : void
keyCode int
frame int
return void
		protected void KeyUpRequest(int keyCode, int frame)
		{
			if (!OwningNetWorker.IsServer && !clientSidePrediction)
				return;

			if (!currentKeys.Contains((KeyCode)keyCode))
			{
				keyUpBuffer.Add(keyCode);
				return;
			}

			if (inputUpRequest != null)
				inputUpRequest((KeyCode)keyCode, frame);
#if UNITY_EDITOR
			else
				Debug.LogError("The input key " + ((KeyCode)keyCode).ToString() + " was requested from the client but no input request inputUpRequest has not been assigned");
#endif

			currentKeys.Remove((KeyCode)keyCode);
		}