コード例 #1
0
 public float OnFire(out FireEventData eventData)
 {
     eventData = new FireEventData(this, -1);
     if (validatedItemIndex != -1)
     {
         var cooldown = items[validatedItemIndex].weapon.OnFire();
         items[validatedItemIndex].ClearInput();
         eventData = new FireEventData(this, validatedItemIndex);
         return(cooldown);
     }
     return(-1.0f);
 }
コード例 #2
0
        private void WebViewControlScriptNotify(FireEventData message)
        {
            var bridgeMessage = JsonConvert.DeserializeObject <BridgeMessage>((string)message.JsonData);

            this.OnMessageReceived(bridgeMessage);
        }