示例#1
0
 private void Start()
 {
     movement = GetComponent <PlayerMovement>();
     player   = ReInput.players.GetPlayer((int)playerNumber - 1);
     grabCog  = GetComponent <GrabCog>();
     playerNumberText.text = "P " + (int)playerNumber;
 }
示例#2
0
文件: CogWheel.cs 项目: fshh/GGJ2020
 public void IgnorePlayers(GrabCog thrower)
 {
     if (thrower.gameObject.layer == LayerMask.NameToLayer("Team1"))
     {
         gameObject.layer = LayerMask.NameToLayer("Ball1");
     }
     else if (thrower.gameObject.layer == LayerMask.NameToLayer("Team2"))
     {
         gameObject.layer = LayerMask.NameToLayer("Ball2");
     }
 }