/// <summary>
 /// Initialize all gameObjects and controllers for the gameplay controller.
 /// </summary>
 private void InitializeGameplayController()
 {
     gameData = GameObject.Find("Game Data").GetComponent <GameData>();
     liftTrackerController = GameObject.Find("Lift Tracker Controller").GetComponent <LiftTrackerController>();
     lightsController      = GameObject.Find("Lights Controller").GetComponent <LightsController>();
     infoTextController    = GameObject.Find("Info Text Controller").GetComponent <InfoTextController>();
     experienceController  = GameObject.Find("Experience Controller").GetComponent <ExperienceController>();
 }
Пример #2
0
 void Awake()
 {
     ballController   = GetComponent <BallController> ();
     lightsController = GetComponent <LightsController> ();
     if (currentTransform == null)
     {
         currentTransform = standardTransform;
     }
 }
Пример #3
0
 public CreateMenu(DebugInfoFactory outLineFactory, WaypointFactory waypointFactory,
                   ProjectorFactory projectorFactory, ContentManager content, LightsController lightsController)
 {
     this.OutlineFactory   = outLineFactory;
     this.WaypointFactory  = waypointFactory;
     this.ProjectorFactory = projectorFactory;
     this.Texture          = content.Load <Texture2D>("Debug");
     this.LightsController = lightsController;
     this.State            = new UIState();
 }
Пример #4
0
    public override void OnInspectorGUI()
    {
        base.OnInspectorGUI();
        LightsController lights = target as LightsController;

        if (GUILayout.Button("Flicker Random Light"))
        {
            lights.FlickerRandomLight();
        }
        if (GUILayout.Button("Flicker All Lights"))
        {
            lights.FlashAllWrapper();
        }
    }
Пример #5
0
 private void CheckForGameCompletion()
 {
     for (int i = 0; i < rows; i++)
     {
         for (int j = 0; j < colunms; j++)
         {
             LightsController temp = grid[i, j].GetComponent <LightsController>();
             Debug.Log("State : " + temp.GetCurrentState);
             if (temp.GetCurrentState != LightStatesEnum.Dead)
             {
                 return;
             }
         }
     }
     gameOverPanel.gameObject.SetActive(true);
 }
 void Awake()
 {
     lightsController = GetComponent<LightsController>();
     messageController = GetComponent<WallMsgController>();
     musicController = GetComponent<MusicController> ();
 }
Пример #7
0
 // Use this for initialization
 void Start()
 {
     controller = this.transform.root.GetComponent <LightsController>();
     lightID    = this.transform.parent.gameObject.GetComponent <TrafficLightBehaviour>().lightID;
 }
Пример #8
0
 // Use this for initialization
 void Start()
 {
     controller    = this.transform.root.GetComponent <LightsController>();
     trafficLights = GetComponentsInChildren <TrafficLightBehaviour>();
     bridgeShape   = transform.GetChild(0);
 }
Пример #9
0
        public Lights(LightsController controller)

        {
            LightsController = controller;
            InitializeComponent();
        }
Пример #10
0
 void Awake()
 {
     _instance = this;
 }
Пример #11
0
 private void Awake()
 {
     _controller = GetComponentInParent <LightsController>();
     CrossLane   = GetComponentInChildren <CrossLane>();
     Front       = GetComponentInChildren <Front>();
 }