Ejemplo n.º 1
0
 public void RpcExecute(IntVector2 direction)
 {
     Action[] actions = this.GetComponents <Action>();
     for (int i = 0; i < actions.Length; i++)
     {
         Action action = actions[i];
         if (action == this)
         {
             NetManager.S.SendServerMessageToGroup(new NetMessage_ActionOccupant(intTransform.GetPos(), intTransform.GetLevel(), i, direction), ConnectionGroup.game);
             return;
         }
     }
     Debug.LogError("Tried to do an action that didn't exist " + this.GetType().ToString());
 }
Ejemplo n.º 2
0
    public void Bump(IntVector2 target)
    {
        IntVector2 pos = intTransform.GetPos();

        StartCoroutine(JuicyBump(pos, target));
    }