Compare commits
21 Commits
f0e895bf31
...
bac6ec5f34
Author | SHA1 | Date | |
---|---|---|---|
bac6ec5f34 | |||
|
791e4b901c | ||
|
27598b1f82 | ||
e4bfba9780 | |||
|
7823d44746 | ||
|
a946eed728 | ||
|
5f8080ff9c | ||
|
8b1b1c1a15 | ||
b09110f8c1 | |||
34f63352e2 | |||
7ed35864cb | |||
|
47d19aa428 | ||
33e356f678 | |||
|
fe521317c1 | ||
6ed9548735 | |||
ab99c57847 | |||
|
35fdb77717 | ||
ff455a3885 | |||
81336b02ec | |||
0215ca6c2d | |||
|
21f6739a54 |
@ -341,6 +341,16 @@ public class PlayerController : CharacterBase, IObserver<GameObject>
|
||||
effect.transform.localScale = scale;
|
||||
}
|
||||
}
|
||||
|
||||
public void OnAttackButtonPressed()
|
||||
{
|
||||
if ((_currentAction == null || !_currentAction.IsActive) &&
|
||||
CurrentState != PlayerState.Win && CurrentState != PlayerState.Dead)
|
||||
{
|
||||
GameManager.Instance.PlayPlayerAttackSound();
|
||||
StartAttackAction();
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
@ -352,9 +362,9 @@ public class PlayerController : CharacterBase, IObserver<GameObject>
|
||||
return dir.sqrMagnitude > 0.01f ? dir.normalized : transform.forward;
|
||||
}
|
||||
|
||||
public void DashButtonPressed()
|
||||
public void OnDashButtonPressed()
|
||||
{
|
||||
if (!_actionDash.IsActive)
|
||||
if (!_actionDash.IsActive && CurrentState != PlayerState.Win && CurrentState != PlayerState.Dead)
|
||||
{
|
||||
StartDashAction();
|
||||
}
|
||||
|
BIN
Assets/JYY/Materials/MagicMissaile.mat
(Stored with Git LFS)
Normal file
BIN
Assets/JYY/Materials/MagicMissaile.mat
(Stored with Git LFS)
Normal file
Binary file not shown.
8
Assets/JYY/Materials/MagicMissaile.mat.meta
Normal file
8
Assets/JYY/Materials/MagicMissaile.mat.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 396a4d0e1fb987e4e8f12e4480ecd48d
|
||||
NativeFormatImporter:
|
||||
externalObjects: {}
|
||||
mainObjectFileID: 2100000
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/JYY/Prefabs/Alien Big Blink.prefab
(Stored with Git LFS)
BIN
Assets/JYY/Prefabs/Alien Big Blink.prefab
(Stored with Git LFS)
Binary file not shown.
BIN
Assets/JYY/Prefabs/Bullets/Dummy Magic Missaile.prefab
(Stored with Git LFS)
BIN
Assets/JYY/Prefabs/Bullets/Dummy Magic Missaile.prefab
(Stored with Git LFS)
Binary file not shown.
BIN
Assets/JYY/Prefabs/Bullets/Magic Missaile.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/JYY/Prefabs/Bullets/Magic Missaile.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
Assets/JYY/Prefabs/[Enemy] PldDog.prefab
(Stored with Git LFS)
BIN
Assets/JYY/Prefabs/[Enemy] PldDog.prefab
(Stored with Git LFS)
Binary file not shown.
BIN
Assets/JYY/Scenes/MonsterTest.unity
(Stored with Git LFS)
BIN
Assets/JYY/Scenes/MonsterTest.unity
(Stored with Git LFS)
Binary file not shown.
BIN
Assets/KSH/ReDungeon.unity
(Stored with Git LFS)
BIN
Assets/KSH/ReDungeon.unity
(Stored with Git LFS)
Binary file not shown.
Binary file not shown.
BIN
Assets/KSH/ReHousing.unity
(Stored with Git LFS)
BIN
Assets/KSH/ReHousing.unity
(Stored with Git LFS)
Binary file not shown.
@ -13,7 +13,17 @@ public class MenuPanelController : PanelController
|
||||
popupPanel.GetComponent<PopupPanelController>().Show("정말 나가시겠습니까?",
|
||||
() =>
|
||||
{
|
||||
//todo: 메인으로 가거나 하우징 으로 감
|
||||
GameManager.Instance.ResumeGame();
|
||||
if (SceneManager.GetActiveScene().name == "ReDungeon")
|
||||
{
|
||||
GameManager.Instance.ChangeToHomeScene();
|
||||
}
|
||||
|
||||
if (SceneManager.GetActiveScene().name == "ReHousing")
|
||||
{
|
||||
//todo: 메인화면
|
||||
|
||||
}
|
||||
},
|
||||
() =>
|
||||
{
|
||||
@ -29,6 +39,7 @@ public class MenuPanelController : PanelController
|
||||
|
||||
public void OnClickBackButton()
|
||||
{
|
||||
GameManager.Instance.ResumeGame();
|
||||
Hide();
|
||||
}
|
||||
}
|
||||
|
@ -20,7 +20,7 @@ public class PanelController : MonoBehaviour
|
||||
public void Show()
|
||||
{
|
||||
if (_canvasGroup == null) return;
|
||||
_canvasGroup.DOFade(1, 0.5f);
|
||||
_canvasGroup.DOFade(1, 0.5f).SetUpdate(true);
|
||||
}
|
||||
|
||||
public void Hide(bool doDestroy = true)
|
||||
|
@ -6,7 +6,7 @@ public class PauseButton : MonoBehaviour
|
||||
{
|
||||
public void OnClicked()
|
||||
{
|
||||
//todo: 게임 일시정지 필요
|
||||
GameManager.Instance.PauseGame();
|
||||
var menuPanel = GameManager.Instance.PanelManager.GetPanel("MenuPanel");
|
||||
menuPanel.GetComponent<MenuPanelController>().Show();
|
||||
}
|
||||
|
8
Assets/Prefabs/ReDungeon.meta
Normal file
8
Assets/Prefabs/ReDungeon.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 82c315512bfc10d4fb967a510a7a8920
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/Canvas.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/Canvas.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/Canvas.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/Canvas.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: c536ba54292bdd447bc0b2d3a36efdf3
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/Directional Light.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/Directional Light.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/Directional Light.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/Directional Light.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 69165d36595b137468c30ddf556aaba7
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/DungeonLogic.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/DungeonLogic.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/DungeonLogic.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/DungeonLogic.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5a8e95e1909a4454c98e4e1dfb56eb14
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/EffectManager.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/EffectManager.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/EffectManager.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/EffectManager.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f8462795d095a4642835dc6048e3e6f2
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/EventSystem.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/EventSystem.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/EventSystem.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/EventSystem.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: bf787b5379d37a04fae426019a17e50a
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/Light.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/Light.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/Light.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/Light.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e9dff1594c9fc8b429e720ace647e2af
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/Main Camera.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/Main Camera.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/Main Camera.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/Main Camera.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 00a74f435b1b5b44e8fdb048b1b1a5a2
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/Player.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/Player.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/Player.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/Player.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b88cac8fe5c8c0241986a80d35db997f
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/Prefab.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/Prefab.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/Prefab.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/Prefab.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7fed050970daa5546b8304fc003275a2
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReDungeon/SpawnPoint.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReDungeon/SpawnPoint.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReDungeon/SpawnPoint.prefab.meta
Normal file
7
Assets/Prefabs/ReDungeon/SpawnPoint.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 977850f571e11a64781ab874e973d49a
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
8
Assets/Prefabs/ReHousing.meta
Normal file
8
Assets/Prefabs/ReHousing.meta
Normal file
@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1988d7f6f99d88c4aa2e4ff1bf6ed217
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/Canvas.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/Canvas.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/Canvas.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/Canvas.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: e6246c48cab2202468d046bc0eb3f282
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/Cat.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/Cat.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/Cat.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/Cat.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 5f04b03d40fc5804a99bb7b32f8b105a
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/Directional Light.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/Directional Light.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/Directional Light.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/Directional Light.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: d111880718f5372408e1576f0a0f6ac8
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/EventSystem.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/EventSystem.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/EventSystem.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/EventSystem.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7c81ff6b78ef4684baf71340620968cc
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/Global Volume.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/Global Volume.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/Global Volume.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/Global Volume.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 9b70533f6892e9c469843ec124f1a048
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/Interior.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/Interior.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/Interior.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/Interior.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 55dec1d1037251447b3810359677a0d9
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/Main Camera.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/Main Camera.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/Main Camera.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/Main Camera.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: db3f5ad1f383fc844b9b1f596ba6dd0f
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/Player (1).prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/Player (1).prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/Player (1).prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/Player (1).prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 40c45ae89d2b8184da32fcb724072824
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/PlayerStat.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/PlayerStat.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/PlayerStat.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/PlayerStat.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 1cc1e598032448e46b411f728bb092a1
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/Room.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/Room.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/Room.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/Room.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 7782bbf175adbf0459c425490772d0dd
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
BIN
Assets/Prefabs/ReHousing/SoundManager.prefab
(Stored with Git LFS)
Normal file
BIN
Assets/Prefabs/ReHousing/SoundManager.prefab
(Stored with Git LFS)
Normal file
Binary file not shown.
7
Assets/Prefabs/ReHousing/SoundManager.prefab.meta
Normal file
7
Assets/Prefabs/ReHousing/SoundManager.prefab.meta
Normal file
@ -0,0 +1,7 @@
|
||||
fileFormatVersion: 2
|
||||
guid: f05acbd3a05f5b1418c7d255221cf49c
|
||||
PrefabImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
@ -5,6 +5,8 @@ using Random = UnityEngine.Random;
|
||||
|
||||
public class CasterDemonController : EnemyController
|
||||
{
|
||||
|
||||
|
||||
// Animation
|
||||
public static readonly int Cast = Animator.StringToHash("Cast");
|
||||
public static readonly int Flee = Animator.StringToHash("Flee");
|
||||
@ -12,7 +14,6 @@ public class CasterDemonController : EnemyController
|
||||
public static readonly int Telepo = Animator.StringToHash("Telepo");
|
||||
public static readonly int Spin = Animator.StringToHash("Spin");
|
||||
|
||||
[SerializeField] private Transform teleportTransform;
|
||||
[SerializeField] private Transform bulletShotPosition;
|
||||
[SerializeField] private GameObject magicMissilePrefab;
|
||||
[SerializeField] private GameObject teleportEffectPrefab;
|
||||
@ -26,6 +27,15 @@ public class CasterDemonController : EnemyController
|
||||
[SerializeField] private GameObject slowFieldWarning;
|
||||
[SerializeField] private GameObject slowFieldEffect;
|
||||
[SerializeField] private GameObject knockbackEffect;
|
||||
|
||||
// SFX
|
||||
[Space(10)]
|
||||
[Header("SFX")]
|
||||
[SerializeField] private AudioClip magicMissileShotSound;
|
||||
[SerializeField] private AudioClip teleportSound;
|
||||
[SerializeField] private AudioClip spinSound;
|
||||
[SerializeField] private AudioClip slowFieldSound;
|
||||
|
||||
private float _knockbackTimer = 10f;
|
||||
private const float KnockBackThresholdTime = 10f;
|
||||
|
||||
@ -198,7 +208,7 @@ public class CasterDemonController : EnemyController
|
||||
// 플레이어 위치를 바라보고
|
||||
transform.LookAt(aimPosition);
|
||||
SetAnimation(MagicMissile);
|
||||
|
||||
SFXPlayer(magicMissileShotSound);
|
||||
// 미사일 생성 및 초기화
|
||||
var missile = Instantiate(
|
||||
magicMissilePrefab,
|
||||
@ -239,22 +249,31 @@ public class CasterDemonController : EnemyController
|
||||
private void Teleport()
|
||||
{
|
||||
Vector3 startPos = transform.position;
|
||||
if (teleportEffectPrefab != null)
|
||||
Instantiate(teleportEffectPrefab, startPos, Quaternion.identity);
|
||||
|
||||
var startTelepoEffect = Instantiate(teleportEffectPrefab, startPos, Quaternion.identity);
|
||||
|
||||
// 텔레포트와 함께 시전하는 범위 공격
|
||||
var aoe = Instantiate(chariotWarning, startPos, Quaternion.identity).GetComponent<ChariotAoeController>();
|
||||
|
||||
|
||||
|
||||
aoe.SetEffect(TeleportEffectData, null, null);
|
||||
|
||||
SFXPlayer(teleportSound);
|
||||
// 텔레포트 타겟 위치로 이동
|
||||
Agent.Warp(teleportTargetPosition);
|
||||
SetAnimation(Telepo);
|
||||
|
||||
if (teleportEffectPrefab != null)
|
||||
Instantiate(teleportEffectPrefab, teleportTargetPosition, Quaternion.identity);
|
||||
var endTelepoEffect = Instantiate(teleportEffectPrefab, teleportTargetPosition, Quaternion.identity);
|
||||
|
||||
StartCoroutine(DelayedEffectDestroyer(startTelepoEffect, endTelepoEffect));
|
||||
}
|
||||
|
||||
private IEnumerator DelayedEffectDestroyer(GameObject effect, GameObject effect2)
|
||||
{
|
||||
yield return Wait.For(1f);
|
||||
Destroy(effect);
|
||||
|
||||
yield return Wait.For(0.4f);
|
||||
Destroy(effect2);
|
||||
}
|
||||
|
||||
private IEnumerator SlowFieldSpell()
|
||||
@ -263,9 +282,10 @@ public class CasterDemonController : EnemyController
|
||||
// 1. 시전 애니메이션
|
||||
transform.LookAt(aimPosition);
|
||||
SetAnimation(Cast);
|
||||
SFXPlayer(slowFieldSound);
|
||||
|
||||
// 2. 장판 생성과 세팅
|
||||
var fixedPos = new Vector3(aimPosition.x, 0, aimPosition.z);
|
||||
var fixedPos = new Vector3(aimPosition.x, aimPosition.y, aimPosition.z);
|
||||
var warning = Instantiate(chariotWarning, fixedPos, Quaternion.identity).GetComponent<MagicAoEField>();
|
||||
|
||||
warning.SetEffect(SlowFieldEffectData, null, null);
|
||||
@ -278,6 +298,7 @@ public class CasterDemonController : EnemyController
|
||||
{
|
||||
// 시전 애니메이션
|
||||
SetAnimation(Spin);
|
||||
SFXPlayer(spinSound);
|
||||
|
||||
// 넉백 발생
|
||||
var knockback = Instantiate(chariotWarning, transform).GetComponent<MagicAoEField>();
|
||||
@ -286,6 +307,11 @@ public class CasterDemonController : EnemyController
|
||||
yield return Wait.For(1f);
|
||||
}
|
||||
|
||||
private void SFXPlayer(AudioClip clip)
|
||||
{
|
||||
SoundManager.Instance.PlaySFX(clip);
|
||||
}
|
||||
|
||||
#region 유틸리티
|
||||
private void SetSequence(Func<IEnumerator> newSequence)
|
||||
{
|
||||
|
@ -37,6 +37,12 @@ public class PldDogController : EnemyController
|
||||
[SerializeField] private GameObject horizontalWarning;
|
||||
[SerializeField] private GameObject horizontalSlash;
|
||||
|
||||
// SFX
|
||||
[Space(10)]
|
||||
[Header("SFX")]
|
||||
[SerializeField] private AudioClip slashSound;
|
||||
[SerializeField] private AudioClip boomSound;
|
||||
|
||||
private float _patternTimer = 0f;
|
||||
private int _lastPatternIndex = -1;
|
||||
private bool _isPatternRunning = false;
|
||||
@ -110,13 +116,14 @@ public class PldDogController : EnemyController
|
||||
{
|
||||
Debug.Log("BombThrowPattern: 보스가 폭탄을 던집니다.");
|
||||
SetAnimation(BoomShot);
|
||||
SoundManager.Instance.PlaySFX(boomSound);
|
||||
_isPatternRunning = true;
|
||||
Agent.isStopped = true;
|
||||
|
||||
for (int i = 0; i < bombCount; i++)
|
||||
{
|
||||
Vector3 targetPos = TraceTargetTransform.position;
|
||||
targetPos.y = 0.1f; // 지면에 맞춤
|
||||
targetPos.y += 0.1f; // 지면에 맞춤
|
||||
|
||||
var warning = Instantiate(chariotSlashWarning, targetPos, Quaternion.identity);
|
||||
warning.transform.localScale = bombScale;
|
||||
@ -203,6 +210,7 @@ public class PldDogController : EnemyController
|
||||
private void SlashAnimationPlay()
|
||||
{
|
||||
SetAnimation(Slash);
|
||||
SoundManager.Instance.PlaySFX(slashSound);
|
||||
}
|
||||
|
||||
private void PatternClear()
|
||||
|
@ -49,6 +49,17 @@ public partial class GameManager : Singleton<GameManager>
|
||||
|
||||
#endregion
|
||||
|
||||
//일시 정지
|
||||
public void PauseGame()
|
||||
{
|
||||
Time.timeScale = 0;
|
||||
}
|
||||
|
||||
public void ResumeGame()
|
||||
{
|
||||
Time.timeScale = 1;
|
||||
}
|
||||
|
||||
// 날짜 진행
|
||||
public void AdvanceDay()
|
||||
{
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user