15 Commits

Author SHA1 Message Date
341e6895c9 Config/Tags: ZeusServerTags.ini gerado (tags do server p/ o GAS) [Change-Set: TAGS-SYNC-2026-06-12]
80 GameplayTags do ZeusServer (Zeus.Status/Ability/Effect/Cue/Attribute/Cooldown)
geradas pelo pipeline build-time (par com o commit de mesmo Change-Set no repo
ZeusServerEngine). O UE le Config/Tags/*.ini no boot e registra as tags, pro
cliente resolver os hashes de GE/Tag/Cue (FNV-1a64) -- fim do "tag nao resolvida".
Regeravel com sync_tags.ps1; nao editar a mao.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-12 23:44:05 -03:00
e87b2cec6c fix(zmmo-client): guard HandlePlayerSpawned ignore proprio entityId + ZeusV1 config
Acompanha commit server 54f2f9a (P10-FIX-LEGACY). Resolve bug "vejo proxy
de UM mas o outro NAO ve" + "proxy fantasma do proprio player" -- causado
por server emitir S_SPAWN_PLAYER local=0 do proprio entityId via AOI re-emit
(workflow wcyeqgrad finding).

Source/ZMMO/Game/Network/ZeusWorldSubsystem.cpp
================================================
HandlePlayerSpawned guard novo logo apos EntityId==0 check:

  if (LocalEntityId != 0 && EntityId == LocalEntityId)
  {
      UE_LOG(LogZMMO, Verbose,
          TEXT("ignoring S_SPAWN_PLAYER for own LocalEntityId=%lld (bIsLocal=%d)"),
          LocalEntityId, bIsLocal ? 1 : 0);
      return;
  }

Sem o guard, server re-emit S_SPAWN_PLAYER local=0 do proprio entityId
(via AOI SetOnEnter callback em catch-up cross-server ou recompute pos-
handoff) criava proxy fantasma do proprio player. GAS/HUD/PlayerArray
roteava via fantasma e o pawn real perdia vinculo de identidade visivel
pros outros players.

Defesa em profundidade -- complementa fix server-side
(AoiReplicationHelpers.cpp:28 SendSpawnPlayerToConn agora tem skip-self
guard antes de construir payload) + SpawnKey dedupe sem IsLocal no plugin
(ZeusNetworkSubsystem.cpp:949 removeu IsLocal do hash).

Config/DefaultZeusV1.ini
=========================
Config inicial para UZeusNetworkingClientSubsystem (P9-6/P9-7 plugin V1).
Aponta para Gateway 127.0.0.1:7777 (fluxo padrao producao). Documenta
alternativa de direct connect 9001 (debug only -- bug Windows multi-NIC
loopback). bUseZeusNetworkingV1=True ativa V1 plugin em paralelo ao
legacy (transport V1 hoje quebrado via Gateway -- channelId nao eh
routing key, Phase 12 territory; gameplay continua via legacy ate la).

Validado smoke 2 PIE 2026-06-08 20:32
======================================
* SP_01: players=2 conns=2 + AOI players=2 maxSet=1 enters=5 hyst=92 stable
* UE: [PIE0] e [PIE1] prefix funcionando (commit server 54f2f9a ZNET_PIE_PREFIX)
* "S_SPAWN_PLAYER duplicate ignored" dedupe pegando re-emit (Batch 2)
* S_CHAR_INFO trocado correto: PIE0 ve Olatudook, PIE1 ve Mateuus
* Saida limpa: UnregisterViewer + Broadcast S_DESPAWN_PLAYER targets=1

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-08 20:33:41 -03:00
8d73cc9df8 feat(gas): SM6 client EntityId u64 + M8 cue assets + UI/data tweaks (sessao 1+2) 2026-06-03 18:18:02 -03:00
98dce2f855 feat(zeus-gas): M7 - migrate HUD/Status to UZeusGASComponent + delete legacy
- ZeusHudWidget: porta de UZeusAttributeComponent legacy pra UZeusGASComponent
  (delegate OnSnapshotAppliedRaw via AddUObject; FZeusAttributesSnapshot
  construido pelo helper estatico FromPayload do plugin ZeusGAS). Logs
  diagnosticos no bind.
- UIPlayerStatus_Window: mesmo porte (snapshot raw + StatAllocReply). Lock
  de spam-click preservado.
- ZeusHudHpSpWidget: movido do plugin ZeusAttributes (deletado) pra ZMMO
  /Game/UI/InGame/. API preservada (WBP filhos nao precisam mudar).
- ZeusCharacter: tira o dual-seed legacy; so' seedea UZeusGASComponent
  via FindComponentByClass no HandleLocalSpawnReady.
- ZeusPlayerState/ZeusCharacter: comentarios atualizados pra refletir o
  UZeusGASComponent como dono unico.
- ZMMO.Build.cs: remove dep "ZeusAttributes", adiciona "ZeusGAS" +
  "GameplayAbilities".
- ZMMO.uproject: remove module "ZeusAttributes" (delete completo).
- DefaultGame.ini: remove linha legacy comentada do Component Registry.
- DefaultEngine.ini: adiciona [CoreRedirects] pra:
  * ZMMOJobs module + ZMMOJobDataAsset class (Package+Class) — 7 DA_Job_*
  * ZMMO.ZMMOMapDef struct (DT_Maps row)
  * ZMMO.ZMMOLoadingTipRow struct (DT_LoadingTips row)
  * ZMMO.ZMMOLoadingProfile/StepDef structs + EZMMOLoadingContext/StepStatus
    enums (DA_LoadingProfiles)
- DELETE: Source/ZeusAttributes/ inteiro (5 .cpp + 5 .h + Build.cs +
  module.json).

Pegadinha aprendida: ActiveClassRedirects so' renomeia classe (sem
package); CoreRedirects (ClassRedirects/StructRedirects/EnumRedirects/
PackageRedirects) e' obrigatorio quando muda modulo OU quando o asset
referencia USTRUCT/UENUM. Tipo errado nao da erro mas tambem nao funciona.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-03 01:26:04 -03:00
6a6a28a086 refactor: prefixo ZMMO -> Zeus em classes/módulos C++ do cliente
- Renomeia ~50 classes UCLASS/USTRUCT/UENUM/UINTERFACE pra Zeus*
  (AZeusGameMode, AZeusCharacter, UZeusGameInstance, IZeusEntityInterface,
  UZeusWorldSubsystem, FZeusEntitySnapshot, etc.)
- Encurta AZMMOPlayerCharacter -> AZeusCharacter
- Renomeia módulos satélite ZMMOAttributes -> ZeusAttributes e
  ZMMOJobs -> ZeusJobs (pasta + .Build.cs + .uproject)
- Mantém módulo principal ZMMO (renomeia depois quando jogo ganhar nome)
- DefaultEngine.ini: ActiveClassRedirects ZMMOX -> ZeusX (preserva BPs/assets)
- DefaultGame.ini: sections atualizadas pra ZeusThemeSubsystem/ZeusPlayerState
- Category="ZMMO|..." -> "Zeus|..." em UPROPERTYs
- Preserva LogZMMO, ZMMO_API, /Script/ZMMO., /Game/ZMMO/, classes Target

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-02 17:24:38 -03:00
e771aec259 wip: UI Button Base + content/config in-progress
Snapshot do trabalho em andamento na branch feat/ui-system: refinamentos do
UIButton_Base (header+impl), atualizacao de styles/themes do botao, mapa de
teste L_ZeusIATest, e demais .uasset/Config tocados durante a sessao de
playtest do meshing. Commit conjunto a pedido do usuario pra deixar a branch
limpa antes do proximo batch.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-02 12:56:28 -03:00
5d44647170 refactor(ui/panel): TMap<EUIPanelTexture> -> TMap<FName> com PostSerialize migration
FUIStylePanel migra de TMap<EUIPanelTexture, FSlateBrush> (enum legacy) para
TMap<FName, FSlateBrush>. Permite adicionar/remover categorias diretamente
no DT_UI_Styles via dropdown (meta=GetOptions) sem mexer no enum em C++.

PanelBackground, PanelOutline e PanelOutlineEffect viraram *_DEPRECATED.
Versoes novas: PanelBackgroundByName, PanelOutlineByName,
PanelOutlineEffectByName.

PostSerialize migra os legacy -> ByName no PostLoad de cada FUIStyleRow.
Apos o primeiro re-save no editor os deprecated ficam vazios e o codigo
vira no-op. PropertyRedirects em DefaultEngine.ini preservam a leitura
do asset antigo (3 entries: PanelBackground, PanelOutline, PanelOutlineEffect).

Atualiza UIPanel_Base pra ler ByName + DT_UI_Styles, UI_Panel_Master e
UI_PlayerStatus_Window resalvos. Inclui nova textura
T_Panel_Outline_Effect_Square_02.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-27 19:30:48 -03:00
079d05c117 feat(ui/loading): tela de loading dinamica data-driven (etapas + dicas)
- UUILoadingScreen_Base (Game/UI/Common/) generica: Configure(Context),
  MarkStepRunning/Done/Failed, OnLoadingComplete delegate, progress bar
  reativa e rotacao automatica de dicas via timer.
- Etapas configuradas por contexto em UZMMOLoadingProfilesDataAsset
  (DA_LoadingProfiles). Perfil inicial FrontEndEnteringWorld:
  Travel -> MapLoaded -> Spawn.
- Dicas em DT_LoadingTips (FText localizavel + filtro por contexto +
  GameplayTag de categoria). 4 dicas seed.
- UIFrontEndFlowSubsystem agora bloqueia a transicao InWorld ate o
  HandlePlayerSpawned (bIsLocal=true) — usuario nao ve mundo vazio.
- WBP_Loading em /UI/Shared/Loading/ (neutro, reusavel pelo InGame futuro);
  DA_FrontEndScreenSet[EnteringWorld] aponta pra ele.
- DefaultGame.ini wire LoadingProfilesAsset + LoadingTipsAsset.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-26 02:24:48 -03:00
396223e2a8 feat(ui-ingame): UI in-game system + PlayerState + Component Registry + HUD composite
Espelho simétrico do front-end pattern (UUIFrontEndFlowSubsystem +
DA_FrontEndScreenSet + UUIPrimaryGameLayout_Base) para a UI in-game.
Pavimenta caminho pra Inventory, Skills, StatusWindow, EscapeMenu, etc.

## UI in-game system (Source/ZMMO/Game/UI/InGame/)

- EZMMOInGameUIState enum (None, Playing, StatusWindow, Inventory,
  SkillTree, EscapeMenu, Loading) em Data/UI/InGameTypes.h
- UUIInGameScreenSet DataAsset: TMap<EZMMOInGameUIState, TSoftClassPtr<...>>
- UUIInGameFlowSubsystem (GameInstanceSubsystem) com SetState/ToggleScreen
- DA_InGameScreenSet em Content/ZMMO/UI/InGame/ mapeia Playing->WBP_HUD
- Layer routing: Playing -> UI.Layer.Game | menus -> GameMenu | loading -> Modal

## AHUD pattern (idiomatic UE5)

- AZMMOHUD : AHUD em Source/ZMMO/Game/Modes/
- AZMMOGameMode::HUDClass = AZMMOHUD::StaticClass()
- AZMMOHUD::BeginPlay chama UIInGameFlowSubsystem::StartInGame
- Pawn não cria mais HUD (separação de responsabilidades)

## PlayerState + Component Registry (Open-Closed)

- AZMMOPlayerState : APlayerState em Source/ZMMO/Game/Modes/
- AZMMOGameMode::PlayerStateClass = AZMMOPlayerState::StaticClass()
- UPROPERTY Config TArray<TSubclassOf<UActorComponent>> ComponentClasses
- DefaultGame.ini: +ComponentClasses=/Script/ZMMOAttributes.ZMMOAttributeComponent
- Ctor lê via GConfig (mais robusto que UPROPERTY Config + parsing) e
  instancia cada componente como CreateDefaultSubobject

Por que componentes no PlayerState e não no Pawn:
- Sobrevive ao despawn (morte/respawn)
- Spectator-friendly
- 1:1 com player (Pawn pode trocar: vehicle, mount, possession)
- Padrão MMO clássico (rathena, TrinityCore)

Adicionar novo módulo (Inventory, Skills, Guild) = 1 linha no
DefaultGame.ini, sem editar AZMMOPlayerState.cpp.

## HUD composite

- UZMMOHudWidget : UCommonActivatableWidget em ZMMO core (UI/InGame/)
- WBP_HUD em Content/ZMMO/UI/HUD/ herda UZMMOHudWidget
- HpSpBar (UZMMOHudHpSpWidget — sub-modulo ZMMOAttributes) embedded via
  BindWidgetOptional. Sub-widgets futuros: PlayerInfo, Minimap, QuickBar,
  Buffs, Chat, TargetInfo
- UZMMOHudHpSpWidget volta a ser UUserWidget puro (sub-widget, não root)
- UZMMOHudWidget::NativeOnActivated:
  - SetVisibility(HitTestInvisible) — mouse passa direto pro Pawn
  - BindToLocalPlayer: busca AttributeComponent no PC->PlayerState
  - Subscreve OnAttributesChanged/OnHpSpChanged/OnLevelUp
  - Propaga snapshots pra sub-widgets via HpSpBar->ApplySnapshot
- GetDesiredInputConfig override: ECommonInputMode::Game (sem cursor,
  movimento livre). Menus override pra GameAndMenu/Menu.

## NetworkHandler refatorado (AttributeComponent agora no PlayerState)

- ZMMOAttributeNetworkHandler::FindComponentForEntity: busca via
  GameState->PlayerArray (O(N_players)), não TActorIterator (O(N_actors))
- ZMMOAttributes.Build.cs += CommonUI, CommonInput

## EnsureRootLayout (fix crítico)

- OpenLevel invalida widgets no viewport ("InvalidateAllWidgets")
- RootLayout (criado pelo FrontEndFlow no boot) sobrevive como UObject
  (LocalPlayerSubsystem) mas fica órfão fora do viewport
- Push do WBP_HUD no Stack_Game funcionava mas widget pai (RootLayout)
  estava fora do viewport → invisível
- UUIFrontEndFlowSubsystem::EnsureRootLayout (público) recria via
  UIManagerSubsystem (idempotente)
- UUIInGameFlowSubsystem::StartInGame chama EnsureRootLayout antes do push

## PlayerCharacter simplificado

- Removido AttributeComponent (vai pro PlayerState via Registry)
- Removido HudHpSpWidgetClass + spawn manual de HUD
- HandleLocalSpawnReady só faz seed do EntityId via PlayerState
- UI lifecycle agora é responsabilidade do AZMMOHUD::BeginPlay

## Verificação (smoke test)

PIE: Login -> CharSelect -> Lobby -> EnterWorld
  ↓
LogZMMO: AZMMOPlayerState ctor: 1 componente(s) no registry
LogZMMO: ZMMOPlayerState: componente registrado [0] ZMMOAttributeComponent
LogZMMO: FrontEndFlow::EnsureRootLayout: RootLayout recriado
LogZMMO: InGameFlow: state None -> Playing
LogZMMO: InGameFlow: tela Playing pushed em UI.Layer.Game (widget=WBP_HUD_C_0)
LogZMMO: ZMMOHudWidget activated (HpSpBar=WBP_HUD_HpSpBar_C_0)
  ↓
HUD aparece com Lv 5 / HP 10/200 / SP 5/20 (valores do DB)
Regen funciona (HP/SP enchem a cada 6s/8s)
Movimento normal (input flui pro Pawn)

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-23 05:27:41 -03:00
0e96956a17 feat(char-spawn): Fase 4 client + UI WBPs paralelo (#2)
Co-authored-by: Mateus Rodrigues <mateuus27@outlook.com>
Co-committed-by: Mateus Rodrigues <mateuus27@outlook.com>
2026-05-23 02:16:27 -03:00
bc07c47557 feat(frontend): esqueleto CommonUI de MainMenu (boot→login→lobby)
Estrutura principal de front-end estilo Lyra portada para C++ proprio do
ZMMO (sem CommonGame), seguindo o padrao C++ Abstract -> WBP concreto:

- EZMMOFrontEndState / EZMMOLobbyPage e GameplayTags UI.Layer.* nativos
- UUIActivatableScreen_Base: base de tela (input config, hook de tema,
  voltar) espelhando o padrao de UUIButton_Base
- UUIPrimaryGameLayout_Base: switch principal (4 stacks CommonUI/camada)
- UUIManagerSubsystem (LocalPlayer): dono do root layout, idempotente
- UUIFrontEndFlowSubsystem (GameInstance): maquina de estados + driver
  de rede (Boot->Connecting->Login->ServerSelect->Lobby->EnteringWorld
  ->InWorld); Lobby e o hub logado, paginas internas = EZMMOLobbyPage
- UUIFrontEndScreenSet (DataAsset): mapa estado->tela, forge-ready
- AZMMOFrontEndGameMode + AZMMOFrontEndPlayerController
- GameInstance: bAutoConnectOnStart=false (conexao dirigida pelo fluxo)
- Build.cs: +GameplayTags; ARQUITETURA.md PR-first (s2.1/2.2/3.3/4.8/5)
- Assets: L_FrontEnd (GameMode via World Settings), WBP_PrimaryGameLayout,
  DA_FrontEndScreenSet; Config wiring

WBPs de pagina (Boot/Login/...) virao do Zeus UMG Forge depois (s4.8).
Smoke test PIE OK: root layout no viewport, fluxo Boot->Connecting,
no-op+log para telas nao configuradas, sem crash.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-19 01:56:16 -03:00
ab74ef8b17 feat(ui): fundacao CommonUI + UUIButton_Base (Abstract)
Habilita CommonUI como base da UI do ZMMO (decisao de arquitetura): modulos CommonUI/CommonInput no Build.cs + include path Game/UI/Widgets; CommonGameViewportClient no DefaultEngine.ini. Adiciona EUIButtonVariant (Primary/Secondary/Danger/Ghost). Cria UUIButton_Base (UCLASS Abstract : UCommonButtonBase): CommonUI cuida de input/foco/click; o C++ resolve os tokens via UZMMOThemeSubsystem::GetActiveUIStyle() e reage a OnThemeChanged; entrega ao WBP por BP_ApplyUIStyle (split contrato C++ / visual Blueprint). CommonInput data/settings deferido p/ a fiacao de input.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-18 21:28:45 -03:00
1c06d69174 feat(ui): sistema de UI Style (tokens C++ por tema) + fontes Aurora Arcana
Camada de estilo data-driven do cliente ZMMO, portando o nucleo do projeto de referencia (Hyper) para C++ conforme ARQUITETURA.md (BP Struct proibido):

- Source/ZMMO/Data/UI: UIStyleTypes.h (enums EUI*), UIStyleTokens.h (tokens primitive/semantic/component), UIStyleRow.h (FUIStyle + FUIStyleRow). - ZMMOThemeSubsystem: GetActiveUIStyle() resolve DT_UI_Styles por ThemeId com fallback Default. - Fontes: 8 UFontFace Inline (Cinzel/Rajdhani) em Content/ZMMO/UI/Fonts + DT_UI_Styles preenchido. - ARQUITETURA.md: prefixo de widget UI_, classes base UUI*_Base (UCLASS Abstract) sem prefixo ZMMO. - Config/DefaultGame.ini: UIStyleTable apontando DT_UI_Styles. - Scripts/import_fonts.py (importador idempotente). Inclui tambem o scaffolding do modulo ZMMO ainda nao versionado (Source/ZMMO/Data, Game/UI, Content/ZMMO, uproject, Build.cs).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-18 21:21:32 -03:00
50471831a2 chore: remove conteudo template da Epic (Variant_*)
Remove os pacotes de exemplo Variant_Combat, Variant_Platforming e Variant_SideScrolling (mais os External Actors/Objects associados) que vieram do template Third Person e nao fazem parte do cliente ZMMO. Ajusta Config/DefaultEditor.ini de acordo.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-18 21:21:01 -03:00
3d4d0de40b feat: ZMMO client base (Game/Entity|Controller|Modes|Network)
Estrutura inicial do cliente Unreal Zeus MMO alinhada ao padrao
"cliente solto + servidor valida input/velocidade" (ADR 0038):

- Source/ZMMO/Game/Entity/ — IZMMOEntityInterface, AZMMOEntity (base
  AActor para Mob/NPC/Object), AZMMOPlayerCharacter (player local com
  CMC livre, Enhanced Input, envio de C_INPUT_AXIS), AZMMOPlayerProxy
  (snapshot-only para players remotos).
- Source/ZMMO/Game/Controller/ — AZMMOPlayerController com IMC defaults
  (IMC_Default + IMC_MouseLook) e suporte opcional a virtual joystick.
- Source/ZMMO/Game/Modes/ — AZMMOGameMode (defaults para PlayerCharacter
  / PlayerController), UZMMOGameInstance (auto-connect ao servidor Zeus
  em Init e logging dos eventos OnConnected/OnDisconnected/...).
- Source/ZMMO/Game/Network/ — UZMMOWorldSubsystem (registry
  EntityId -> AActor*, dispatch dos delegates OnPlayerSpawned/Despawned/
  StateUpdate; ignora snapshots locais do cliente solto).
- Config/DefaultEngine.ini — GlobalDefaultGameMode aponta para
  /Script/ZMMO.ZMMOGameMode; GameInstanceClass para
  /Script/ZMMO.ZMMOGameInstance; redirects para a nova hierarquia.
- ZMMO.Build.cs — depende de ZeusNetwork; PublicIncludePaths para a
  nova arvore Game/Entity|Controller|Modes|Network.
- Content — assets do template ThirdPerson (Mannequins, IAs/IMCs,
  Lvl_ThirdPerson + TestWorld). Os Variant_* levels ficam no commit
  inicial mas serao limpos numa proxima sessao com aprovacao explicita
  (Master Rule para .umap/.uasset).

Notas:
- BP_ThirdPersonCharacter/GameMode/PlayerController ainda apontam para
  a hierarquia antiga e estao a aguardar aprovacao para remocao
  (Master Rule).
- README.md descreve a arquitectura e o smoke test de conexao.
2026-05-07 20:21:21 -03:00