chore(BT12-Dev): 진단 Debug.Log 회수 (PD 정합 작동 확인 후)
회수 5종: - ProjectileSpawner.Trigger — [ProjectileSpawner] Trigger - Projectile.Initialize — [Projectile][Initialize] - Projectile.SelfDestruct — [Projectile][SelfDestruct] - Projectile.OnDestroy (메서드 자체) — [Projectile][OnDestroy] - EnemyController.Update — [EnemyHit][Intersect]·[EnemyHit][Decrement] 보존: - Projectile.Update lifetime backup SelfDestruct (Log 영역 제거·동작 영역 유지·잔존 차단) - Initialize 시 CancelInvoke (안전망 유지) feedback_pm_root_diagnosis_priority 정합 — 근본 원인 (Time.timeScale=0 영역 Invoke 정지·NullReferenceException race) 확정·fix 정합 후 진단 Log revert. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
705d943e38
commit
41fa4e4ce7
|
|
@ -386,18 +386,13 @@ namespace Platformer.Mechanics
|
||||||
}
|
}
|
||||||
if (_cachedPlayer != null && _cachedPlayer.health != null && _cachedPlayer.health.IsAlive)
|
if (_cachedPlayer != null && _cachedPlayer.health != null && _cachedPlayer.health.IsAlive)
|
||||||
{
|
{
|
||||||
// PD 지시 2026-05-13 — "닿아도 X" 재 보고. Bounds.Intersects 영역 너무 좁은 가능성 → distance 기반 fix.
|
// PD 지시 2026-05-13 — VisualBounds.Intersects OR distance < 1.5f 단일 조건·ground·공중 무관 피격
|
||||||
// 진단 Debug.Log 추가 (회수 의무·PD Console 측정 후 본 PM revert).
|
|
||||||
float dist = Vector2.Distance(transform.position, _cachedPlayer.transform.position);
|
float dist = Vector2.Distance(transform.position, _cachedPlayer.transform.position);
|
||||||
bool boundsHit = VisualBounds.Intersects(_cachedPlayer.Bounds);
|
bool boundsHit = VisualBounds.Intersects(_cachedPlayer.Bounds);
|
||||||
bool distHit = dist < 1.5f;
|
bool distHit = dist < 1.5f;
|
||||||
if (boundsHit || distHit)
|
if ((boundsHit || distHit) && !_cachedPlayer.health.IsInvulnerable)
|
||||||
{
|
{
|
||||||
Debug.Log($"[EnemyHit] enemy={name} dist={dist:F2} boundsHit={boundsHit} distHit={distHit} invuln={_cachedPlayer.health.IsInvulnerable} enemyPos=({transform.position.x:F2},{transform.position.y:F2}) playerPos=({_cachedPlayer.transform.position.x:F2},{_cachedPlayer.transform.position.y:F2}) t={Time.time:F2}");
|
_cachedPlayer.health.Decrement();
|
||||||
if (!_cachedPlayer.health.IsInvulnerable)
|
|
||||||
{
|
|
||||||
_cachedPlayer.health.Decrement();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -88,9 +88,6 @@ namespace EerieVillage.Skills.Effectors
|
||||||
// PD 지시 2026-05-13 — Invoke 폐기 (Time.timeScale=0 영역 호출 X·영구 잔존 원인)·unscaledTime backup 영역 lifetime 영역 보장
|
// PD 지시 2026-05-13 — Invoke 폐기 (Time.timeScale=0 영역 호출 X·영구 잔존 원인)·unscaledTime backup 영역 lifetime 영역 보장
|
||||||
// CancelInvoke 호출 영역 추가 안전 (이전 영역 영역 Invoke 영역 잔존 차단)
|
// CancelInvoke 호출 영역 추가 안전 (이전 영역 영역 Invoke 영역 잔존 차단)
|
||||||
CancelInvoke();
|
CancelInvoke();
|
||||||
|
|
||||||
// PD 지시 2026-05-13 — 진단 (회수 의무·잔존 추적)
|
|
||||||
Debug.Log($"[Projectile][Initialize] name={name} dir=({_direction.x:F2},{_direction.y:F2}) speed={_speed:F2} maxRange={_maxRange:F2} lifetime={_lifetime:F2} t={Time.unscaledTime:F2}");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// BT12-Dev 2026-05-13 — 사거리 80~100% 영역 scale·alpha 보간 (PD 지시)
|
// BT12-Dev 2026-05-13 — 사거리 80~100% 영역 scale·alpha 보간 (PD 지시)
|
||||||
|
|
@ -139,7 +136,6 @@ namespace EerieVillage.Skills.Effectors
|
||||||
// PD 지시 2026-05-13 — unscaledTime 영역 lifetime check (Time.timeScale=0 영역 Time.time 정지 영역 회피·재시작 시 영구 잔존 차단)
|
// PD 지시 2026-05-13 — unscaledTime 영역 lifetime check (Time.timeScale=0 영역 Time.time 정지 영역 회피·재시작 시 영구 잔존 차단)
|
||||||
if (_spawnTime > 0f && Time.unscaledTime - _spawnTime > _lifetime)
|
if (_spawnTime > 0f && Time.unscaledTime - _spawnTime > _lifetime)
|
||||||
{
|
{
|
||||||
Debug.Log($"[Projectile][LifetimeForce] name={name} spawn={_spawnTime:F2} now={Time.unscaledTime:F2} lifetime={_lifetime:F2}");
|
|
||||||
SelfDestruct();
|
SelfDestruct();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
@ -253,18 +249,10 @@ namespace EerieVillage.Skills.Effectors
|
||||||
|
|
||||||
protected void SelfDestruct()
|
protected void SelfDestruct()
|
||||||
{
|
{
|
||||||
// PD 지시 2026-05-13 — 투사체 잔상 진단 (회수 의무)
|
|
||||||
Debug.Log($"[Projectile][SelfDestruct] name={name} pos=({transform.position.x:F2},{transform.position.y:F2}) t={Time.time:F2}");
|
|
||||||
CancelInvoke(nameof(SelfDestruct));
|
CancelInvoke(nameof(SelfDestruct));
|
||||||
Destroy(gameObject);
|
Destroy(gameObject);
|
||||||
}
|
}
|
||||||
|
|
||||||
// PD 지시 2026-05-13 — 투사체 잔상 진단 (회수 의무·Destroy 호출 외 경로 영역 영역 영역 검출)
|
|
||||||
void OnDestroy()
|
|
||||||
{
|
|
||||||
Debug.Log($"[Projectile][OnDestroy] name={name} t={Time.time:F2}");
|
|
||||||
}
|
|
||||||
|
|
||||||
// PD 지시 2026-05-13 — 시각화 박스 자식 reference (Update 영역 매 frame Inspector 정합 갱신용)
|
// PD 지시 2026-05-13 — 시각화 박스 자식 reference (Update 영역 매 frame Inspector 정합 갱신용)
|
||||||
protected Transform _debugBoxTransform;
|
protected Transform _debugBoxTransform;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -82,8 +82,6 @@ namespace EerieVillage.Skills.Effectors
|
||||||
|
|
||||||
proj.Initialize(runtime, inventory, dir);
|
proj.Initialize(runtime, inventory, dir);
|
||||||
}
|
}
|
||||||
// PD 지시 2026-05-13 — 진단 (회수 의무·잔존 추적)
|
|
||||||
UnityEngine.Debug.Log($"[ProjectileSpawner] Trigger card={data.CardId} count={count} facing=({facing.x:F2},{facing.y:F2}) t={Time.time:F2}");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue