// Use this for initialization void Start() { m_camera = GetComponentInChildren <Camera>(); controller = ControllerInterface.GetController(indexSoldier); Debug.Log("Received " + controller.name + "game controller"); m_anim = transform.Find("soldier").animation; switch (colorType) { case ColorType.Bleu: mesh.renderer.material = materials[0]; break; case ColorType.Rouge: mesh.renderer.material = materials[1]; break; case ColorType.Vert: mesh.renderer.material = materials[2]; break; case ColorType.Jaune: mesh.renderer.material = materials[3]; break; } InitCamera(); }