Ejemplo n.º 1
0
        private IEnumerator SpawnNeoSatan()
        {
            BossFightController.SetActive(true);

            if (DisableHUD)
            {
                MainHUD.SetActive(false);
            }

            // APPLY KNOCKBACK TO NEOSATAN SPAWN AREA
            foreach (Point item in LoadSpawnArea())
            {
                handler.Execute(controller, NeoSatanSpawnPosition, item, 1);
            }

            handler.Execute(controller, new Point(this.NeoSatanSpawnPosition.x - 1, this.NeoSatanSpawnPosition.y, this.NeoSatanSpawnPosition.z), NeoSatanSpawnPosition, 1);

            do
            {
                yield return(null);
            } while (map.Contains(NeoSatanSpawnPosition));
            ActivateSoulSphere();
            // SPAWN NEO-SATAN
            NeoSatanReference = AIPlacementHelper.AddUnit(null, NeoSatanSpawnPosition, NeoSatan);
            BossFightController.GetComponent <BossFightController>().SetNeoSatanRef(NeoSatanReference);
            OnNeoSatanSpawn?.Invoke();
        }
Ejemplo n.º 2
0
        public void UpdatePoint(Point point)
        {
            this.xPosition = point.x;
            this.yPosition = point.z;

            if (keyboardUnit != null && !whelpPrefab.UnitsMap.Contains(point))
            {
                AIPlacementHelper.AddUnit(this.transform, new Point(this.xPosition, 0, this.yPosition), keyboardUnit);
                keyboardUnit = null;
            }
        }
Ejemplo n.º 3
0
        private void PlaceIntestines()
        {
            this.intestines = new List <Unit>();
            List <Point> middlePoints = PointUtils.GetVerticalMiddlePoints(this.Unit.GetPosition(), this.maskPosition);

            foreach (var item in middlePoints)
            {
                Unit intestine = AIPlacementHelper.AddUnit(this.transform.parent, item, udeukedefrukeIntestinePrefab);
                intestines.Add(intestine);
            }
        }
Ejemplo n.º 4
0
        private IEnumerator Rebirth()
        {
            Unit prefab = GetUnit(lastEnemyKilled);

            if (prefab == null)
            {
                yield return(null);
            }

            Unit unit = AIPlacementHelper.AddUnit(null, this.Unit.GetPosition(), prefab);

            unit?.Health.SetMaxHealth(this.Unit.Health.GetTotalHealth());
            //// TODO CHECK unit?.GetComponent<IncarnatedState>()?.SwitchMaterials();
            this.transform.parent.gameObject.SetActive(false);
        }
Ejemplo n.º 5
0
        public void SpawnWeakenedNeoSatan()
        {
            MusicController.Instance.StopCurrentManual();
            AmbienceController.Instance.StopCurrentManual();

            SoulSphere.SetActive(false);
            // Flash white
            EffectsPostProcessingController.Instance.ApplyEffect(EffectType.ExposureFlash, 1.5f, 0.7f, 20f);
            NeoSatanRoar.PlayAudio();

            foreach (GameObject item in UiElements)
            {
                item.SetActive(false);
            }

            // Delete NeoSatan after flashing white
            neoSatanPosition = NeoSatan.GetPosition();
            RemoveNeoSatan();
            NeoSatan.GetComponentInChildren <AnimationStateUpdater>().Attack(NeoSatan.Health);

            // Spawn weakened version of neo-satan
            WeakenedNeoSatanRef = AIPlacementHelper.AddUnit(null, neoSatanPosition, WeakenedNeoSatan);
        }
Ejemplo n.º 6
0
 public void Spawn()
 {
     AIPlacementHelper.AddUnit(this.transform, new Point(this.xPosition, 0, this.yPosition), this.GetUnit(this.EnemyType));
 }
Ejemplo n.º 7
0
 private void PlaceMask()
 {
     mask = AIPlacementHelper.AddUnit(this.transform.parent, maskPosition, udeukedefrukeMaskPrefab);
     mask.GetComponent <UdeukedefrukeBodyBehaviour>().SetUp(this.Unit.Health);
 }