Exemplo n.º 1
0
 private void itemActived(bool actived, Global.typeOfPlayer player,
                          Global.typeOfPlayer playerThatCanActived,
                          Global.InteractiveItem item, Vector3 positionOfItem)
 {
     if (tipo.Equals(playerThatCanActived) && actived && Global.InteractiveItem.CheckPoint.Equals(item))
     {
         respawnPosition = positionOfItem;
     }
 }
Exemplo n.º 2
0
 private bool checkWhoCanCatchItem(Global.typeOfPlayer player)
 {
     if (allPlayersCanCatch)
     {
         return(true);
     }
     else
     {
         return(typeOfPlayerThatCanCatchItem.Equals(player));
     }
 }
Exemplo n.º 3
0
 void OnTriggerExit2D(Collider2D outro)
 {
     Global.typeOfPlayer tipo = Global.getTypeOfPlayerByTag(outro.tag);
     if (!tipo.Equals(Global.typeOfPlayer.Player_None))
     {
         StartCoroutine("PararEm2Segudos");
     }
 }
Exemplo n.º 4
0
 void OnTriggerStay2D(Collider2D outro)
 {
     Global.typeOfPlayer tipo = Global.getTypeOfPlayerByTag(outro.tag);
     if (!tipo.Equals(Global.typeOfPlayer.Player_None))
     {
         startMovimento();
     }
 }
Exemplo n.º 5
0
 private bool checkWhoCanIterateWithItem(Global.typeOfPlayer player)
 {
     if (allPlayersCanCatch)
     {
         return(true);
     }
     else
     {
         return(typeOfPlayerCanActived.Equals(player));
     }
 }
Exemplo n.º 6
0
 private void soundItemActived(bool actived, Global.typeOfPlayer player, Global.typeOfPlayer playerThatCanActived, Global.InteractiveItem item, Vector3 position)
 {
     if (player.Equals(playerThatCanActived))
     {
         if (actived)
         {
             interactiveItemOn.Play();
         }
         else
         {
             interactiveItemOff.Play();
         }
     }
 }