This repository has been archived on 2026-05-24. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
AgrarianGameArchive/Scripts/verify_mvp_death_respawn_ui.py
T
2026-05-18 21:13:31 -07:00

58 lines
1.8 KiB
Python

from pathlib import Path
ROOT = Path(__file__).resolve().parents[1]
FILES = {
"AgrarianDebugHUD.h": ROOT / "Source" / "AgrarianGame" / "AgrarianDebugHUD.h",
"AgrarianDebugHUD.cpp": ROOT / "Source" / "AgrarianGame" / "AgrarianDebugHUD.cpp",
"AgrarianGamePlayerController.h": ROOT / "Source" / "AgrarianGame" / "AgrarianGamePlayerController.h",
"AgrarianGamePlayerController.cpp": ROOT / "Source" / "AgrarianGame" / "AgrarianGamePlayerController.cpp",
"AGRARIAN_DEVELOPMENT_ROADMAP.md": ROOT / "AGRARIAN_DEVELOPMENT_ROADMAP.md",
}
EXPECTED = {
"AgrarianDebugHUD.h": [
"bShowDeathRespawnUI",
"DrawDeathRespawnPanel",
],
"AgrarianDebugHUD.cpp": [
"DrawDeathRespawnPanel(AgrarianCharacter)",
"Survival.bIsDead",
"YOU DID NOT SURVIVE",
"LastDeathReason",
"Respawn will return you to Ground Zero",
],
"AgrarianGamePlayerController.h": [
"AgrarianToggleDeathRespawnUI",
"AgrarianRespawn",
],
"AgrarianGamePlayerController.cpp": [
"AgrarianToggleDeathRespawnUI",
"bShowDeathRespawnUI = !AgrarianHUD->bShowDeathRespawnUI",
"MVP death/respawn UI shown.",
"ServerAgrarianRespawn_Implementation",
],
"AGRARIAN_DEVELOPMENT_ROADMAP.md": [
"[x] Add death/respawn UI.",
"`AgrarianToggleDeathRespawnUI`",
],
}
def main():
missing = []
for label, path in FILES.items():
text = path.read_text(encoding="utf-8")
for snippet in EXPECTED[label]:
if snippet not in text:
missing.append(f"{label}: {snippet}")
if missing:
raise RuntimeError("MVP death/respawn UI verification failed: " + "; ".join(missing))
print("Agrarian MVP death/respawn UI verification complete.")
if __name__ == "__main__":
main()