Files
VRProject/Assets/_Scripts/Bossdebug.cs
2026-07-14 14:14:48 +09:00

44 lines
1.4 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
using UnityEngine;
public class BossDebugController : MonoBehaviour
{
private BossController bossController;
private void Awake()
{
// 同一オブジェクトにあるBossControllerを自動取得
bossController = GetComponent<BossController>();
}
private void Update()
{
// ─── ★キーボードの『UUltimate』キーを押したら強制発動 ───
if (Input.GetKeyDown(KeyCode.U))
{
TriggerDebugUltimate();
}
// ─── ついでにあると便利な機能『SStun』キーで即座にパリィスタン ───
if (Input.GetKeyDown(KeyCode.S))
{
TriggerDebugStun();
}
}
private void TriggerDebugUltimate()
{
if (bossController == null) return;
Debug.Log("🛠️ 【キーボードデバッグ】強制的に必殺技(天井ジャンプ)を発動します。");
bossController.PendingUltimate = true;
bossController.ChangeState<SpiderJumpToCeilingState>();
}
private void TriggerDebugStun()
{
if (bossController == null) return;
Debug.Log("🛡️ 【キーボードデバッグ】強制的にパリィスタン(チャンスタイム)を発動します。");
bossController.ChangeState<SpiderStunState>();
}
}