예제 #1
0
 private void SpawnFrontTrooper()
 {
     Debug.Log("Attempting to spawn front trooper.");
     if (far[LevelScene.POSITION_FRONT_INDEX] == null)
     {
         Debug.Log("Spawning front trooper at far range.");
         StormTrooper trooper = troopersFront[trooperFrontIndex];
         far[LevelScene.POSITION_FRONT_INDEX] = trooper;
         trooperFrontIndex++;
         trooper.Rotate(frontSpawnTurnPoint.transform.position);
         trooper.Move(frontSpawnTurnPoint.transform.position);
         trooper.Rotate(player.GetFarFront());
         trooper.Move(player.GetFarFront());
     }
     else if (near[LevelScene.POSITION_FRONT_INDEX] == null)
     {
         Debug.Log("Spawning front trooper at near range.");
         StormTrooper trooper = troopersFront[trooperFrontIndex];
         near[LevelScene.POSITION_FRONT_INDEX] = trooper;
         trooperFrontIndex++;
         trooper.Rotate(frontSpawnTurnPoint.transform.position);
         trooper.Move(frontSpawnTurnPoint.transform.position);
         trooper.Rotate(player.GetFront().transform.position);
         trooper.Move(player.GetFront().transform.position);
     }
 }
예제 #2
0
    private void SpawnRightTrooper()
    {
        Debug.Log("Spawning Right Stormtrooper.");
        StormTrooper trooper = troopers[LevelScene.POSITION_RIGHT_INDEX];

        trooper.Rotate(turnPoint.transform.position);
        trooper.Move(turnPoint.transform.position);
        trooper.Rotate(player.GetFarRight());
        trooper.Move(player.GetFarRight());
    }
예제 #3
0
    private void SpawnLeftTrooper()
    {
        timer = 0;
        Debug.Log("Spawning Left Stormtrooper.");
        StormTrooper trooper = troopers[LevelScene.POSITION_LEFT_INDEX];

        trooper.Rotate(turnPoint.transform.position);
        trooper.Move(turnPoint.transform.position);
        trooper.Rotate(player.GetFarLeft());
        trooper.Move(player.GetFarLeft());
    }
예제 #4
0
    public override void OpenScene()
    {
        PlayVoiceInstruction();
        ResetHologram();

        hologram.Rotate(Destination);
        hologram.Move(Destination);
        status = Status.Opening;
    }
예제 #5
0
 private void SpawnRightTrooper()
 {
     Debug.Log("Attempting to spawn right trooper.");
     if (far[LevelScene.POSITION_RIGHT_INDEX] == null)
     {
         Debug.Log("Spawning right trooper at far range.");
         StormTrooper trooper = troopersRight[trooperRightIndex];
         far[LevelScene.POSITION_RIGHT_INDEX] = trooper;
         trooperRightIndex++;
         trooper.Rotate(player.GetFarRight());
         trooper.Move(player.GetFarRight());
     }
     else if (near[LevelScene.POSITION_RIGHT_INDEX] == null)
     {
         Debug.Log("Spawning right trooper at near range.");
         StormTrooper trooper = troopersRight[trooperRightIndex];
         near[LevelScene.POSITION_RIGHT_INDEX] = trooper;
         trooperRightIndex++;
         trooper.Rotate(player.GetRight().transform.position);
         trooper.Move(player.GetRight().transform.position);
     }
 }
예제 #6
0
 private void SpawnLeftTrooper()
 {
     Debug.Log("Attempting to spawn left trooper.");
     if (far[LevelScene.POSITION_LEFT_INDEX] == null)
     {
         Debug.Log("Spawning left trooper at far range.");
         StormTrooper trooper = troopersLeft[trooperLeftIndex];
         far[LevelScene.POSITION_LEFT_INDEX] = trooper;
         trooperLeftIndex++;
         trooper.Rotate(player.GetFarLeft());
         trooper.Move(player.GetFarLeft());
     }
     else if (near[LevelScene.POSITION_LEFT_INDEX] == null)
     {
         Debug.Log("Spawning left trooper at near range.");
         StormTrooper trooper = troopersLeft[trooperLeftIndex];
         near[LevelScene.POSITION_LEFT_INDEX] = trooper;
         trooperLeftIndex++;
         trooper.Rotate(player.GetLeft().transform.position);
         trooper.Move(player.GetLeft().transform.position);
     }
 }