示例#1
0
文件: Score.cs 项目: lalugue/3DPong
    void OnCollisionEnter(Collision collision)
    {
        Debug.Log("Score detected!");



        Destroy(ball);
        Debug.Log("Ball destroyed!");



        //set next direction of ball
        ballscript.SetPlayerDirection(scorer.name);

        //update scores
        StartCoroutine(manager.UpdateScore(scorer));
    }