コード例 #1
0
    public PlayerController GetOwner(ColorType type)
    {
        switch (type)
        {
        case ColorType.Red:
            return(redColor.GetOwner());

        case ColorType.Yellow:
            return(yellowColor.GetOwner());

        case ColorType.Green:
            return(greenColor.GetOwner());

        default:
            return(null);
        }
    }