Exemplo n.º 1
0
    //Generating the floor of the maze using the plane primitive
    //The plane floor will containa a box collider so that the player, start and finish marker won't fall from the maze
    void mazeFloor()
    {
        planeMaze = new GameObject();
        planeMaze.transform.position = Vector3.zero;
        planeMaze.transform.SetParent(parentMaze.transform);
        planeMaze.name = "Plane";

        planeMaze.AddComponent <BoxCollider>();

        planeMaze.AddComponent <PlaneMaker>();

        PlaneMaker planeMaker = planeMaze.GetComponent <PlaneMaker>();

        planeMaker.PrimitiveColour = new Color32(166, 195, 201, 255);

        planeMaze.GetComponent <BoxCollider>().size   = new Vector3(30, 0.1f, 30);
        planeMaze.GetComponent <BoxCollider>().center = new Vector3(15, 0, 15);
    }
Exemplo n.º 2
0
        public virtual void AssignPlaneMakers()
        {
            IAirport benGurion = this.airportManager.GetAirport("Ben Gurion");

            benGurion.ChangeInState += RaiseChangeInStateEvent;
            IAirport ovda = this.airportManager.GetAirport("Ovda");

            ovda.ChangeInState += RaiseChangeInStateEvent;

            IdManager.Id = dalService.GetIdCount();

            IPlaneMaker planeMaker = new PlaneMaker(benGurion);

            planeMaker.ConfigureTimer(TimeSpan.FromSeconds(15));
            planeMaker.StartTimer();

            IPlaneMaker ovdaPlaneMaker = new OvdaPlaneMaker(ovda, ovda.Routes.ToArray());

            ovdaPlaneMaker.ConfigureTimer(TimeSpan.FromSeconds(25));
            ovdaPlaneMaker.StartTimer();
        }