KAZIK/tools/tests/darts_ui.inc
Artvasil09 23dc40ee5c feat: implement native darts mini-game, AI observer mode, and fortune session assets
- Darts: native 500-point match against Max with sway/fatigue mouse aim, parabolic throw camera, raster arm animations, and 16 camera-relative flying dart views

- AI Observer: autonomous spectator mode for Hold'em, Blackjack, Durak, and Billiards with profile isolation and playback controls

- Fortune Session: raster sprite packs, mist/orb animations, tarot divination spreads, and pack tools

- Hall Integration: wall dartboard in lounge, observer terminal dispatch, and bot turn hooks

- Packaging & Verification: updated installer streaming hash, synchronized launcher, passing check suites and release smoke checks
2026-10-24 22:10:25 +03:00

64 lines
1.4 KiB
PHP

; Interactive fixture reuses the actual native scene, window events and presenter.
.code
DartsUiStart PROC
call InitPaths3D
call Create3DWindow
test eax,eax
jz dt_ui_fail
invoke SetWindowLongA,h3DWnd,-4,OFFSET WindowEvents3D
call ToggleFullscreen3D
call BeginDarts3D
call RenderDarts3D
invoke ShowWindow,h3DWnd,1
call Present3D
invoke SetForegroundWindow,h3DWnd
invoke GetTickCount
mov previousTick3D,eax
dt_ui_loop:
invoke PeekMessageA,OFFSET msg3D,0,0,0,1
test eax,eax
jz dt_ui_frame
cmp dword ptr msg3D[4],12h
je dt_ui_close
invoke TranslateMessage,OFFSET msg3D
invoke DispatchMessageA,OFFSET msg3D
jmp dt_ui_loop
dt_ui_frame:
invoke GetTickCount
mov frameStart3D,eax
sub eax,previousTick3D
cmp eax,50
jbe @F
mov eax,50
@@:
mov deltaTime3D,eax
mov eax,frameStart3D
mov previousTick3D,eax
invoke GetForegroundWindow
cmp eax,h3DWnd
jne dt_ui_idle
invoke Pressed3D,1Bh
test eax,eax
jnz dt_ui_close
invoke Pressed3D,7Ah
test eax,eax
jz @F
call ToggleFullscreen3D
@@:
call HandleDarts3D
call RenderDarts3D
call Present3D
dt_ui_idle:
invoke Sleep,16
jmp dt_ui_loop
dt_ui_close:
call FreeDarts3D
invoke ReleaseDC,h3DWnd,h3DDC
invoke DestroyWindow,h3DWnd
dt_ui_exit:
invoke ExitProcess,0
ret
dt_ui_fail:
invoke ExitProcess,8503
ret
DartsUiStart ENDP