Beispiel #1
0
    private void OnTriggerEnter(Collider other)
    {
        ColorBall tempColorBall = other.gameObject.GetComponent <ColorBall>();

        if (tempColorBall)
        {
            // Don't case equal for now lol
            if ((int)type > (int)tempColorBall.type)
            {
                type      = GeneralTable.Combine(type, tempColorBall.type);
                BallColor = GeneralTable.GetColor(type);

                GamePlayManager.Instance.centerPoint.RemoveEstimateColorBallNum();
            }
            else
            {
                Destroy(this.gameObject);
            }
        }
        CenterPoint tempCenterPoint = other.gameObject.GetComponent <CenterPoint>();

        if (tempCenterPoint)
        {
            nextCenterPoint.match(type);
            ballCollider.enabled = false;
        }
    }
Beispiel #2
0
 public void EnType(GeneralTable.Type type)
 {
     myType = GeneralTable.Combine(myType, type);
     waypointMeshRenderer.material.color = GeneralTable.GetColor(myType);
     if (colorLine)
     {
         colorLine.AddType(type);
     }
     if (colorLines.Length > 0)
     {
         colorLines[nextWaypointIndex].AddType(type);
     }
 }
Beispiel #3
0
 public void AddType(GeneralTable.Type type)
 {
     colorType = GeneralTable.Combine(type, colorType);
     colorLineRenderer.material.color = GeneralTable.GetColor(colorType);
 }