- Bowling feel: impulse contact solver, string pinsetter cycle, in-world lengthwise return rack and visible ball return lift - Ball weights: 4/5/6/7 kg selection with equal launch work physics, momentum balance, and projected picking - Audio: dedicated MCI channels with 7 synthesized waveaudio cues (release, rolling, impacts, applause, pinsetter, return) - First-person animations: 33-frame player underarm throw/follow-through sequence (player-underarm-v2) - Visitors: 10 persistent shared cast identities with exclusive reservations, activity transitions, and chair sit/rise animations - Tests & verification: comprehensive native regression test suites and updated documentation - Synchronize binaries and update launcher hash to 536E23BED4055562BC63871826FF44FFED037923A9BE8E0F591131DB4FBD104B
164 lines
3.5 KiB
PHP
164 lines
3.5 KiB
PHP
; Return the actual roll offset of a frame, including incomplete frames.
|
|
BowlingFrameIndex3D PROC uses ebx esi edi owner:DWORD,wanted:DWORD
|
|
mov ebx,owner
|
|
imul eax,ebx,96
|
|
lea esi,bwRolls3D[eax]
|
|
xor edi,edi
|
|
xor ecx,ecx
|
|
bp_index_frame:
|
|
cmp ecx,wanted
|
|
je bp_index_ready
|
|
cmp edi,bwRollCount3D[ebx*4]
|
|
jae bp_index_missing
|
|
cmp DWORD PTR [esi+edi*4],10
|
|
je @F
|
|
inc edi
|
|
@@:
|
|
inc edi
|
|
inc ecx
|
|
jmp bp_index_frame
|
|
bp_index_ready:
|
|
mov eax,edi
|
|
ret
|
|
bp_index_missing:
|
|
mov eax,-1
|
|
ret
|
|
BowlingFrameIndex3D ENDP
|
|
|
|
BowlingRollGlyph3D PROC uses ebx esi edi owner:DWORD,frame:DWORD,slot:DWORD
|
|
invoke BowlingFrameIndex3D,owner,frame
|
|
cmp eax,-1
|
|
je bp_glyph_blank
|
|
mov edi,eax
|
|
mov ebx,owner
|
|
imul eax,ebx,96
|
|
lea esi,bwRolls3D[eax]
|
|
mov ecx,slot
|
|
cmp frame,9
|
|
je bp_glyph_tenth
|
|
cmp ecx,2
|
|
jae bp_glyph_blank
|
|
cmp DWORD PTR [esi+edi*4],10
|
|
jne bp_glyph_available
|
|
test ecx,ecx
|
|
jnz bp_glyph_blank
|
|
jmp bp_glyph_available
|
|
bp_glyph_tenth:
|
|
cmp ecx,3
|
|
jae bp_glyph_blank
|
|
cmp ecx,2
|
|
jne bp_glyph_available
|
|
mov eax,[esi+edi*4]
|
|
cmp eax,10
|
|
je bp_glyph_available
|
|
add eax,[esi+edi*4+4]
|
|
cmp eax,10
|
|
jne bp_glyph_blank
|
|
bp_glyph_available:
|
|
add edi,ecx
|
|
cmp edi,bwRollCount3D[ebx*4]
|
|
jae bp_glyph_blank
|
|
mov eax,[esi+edi*4]
|
|
test ecx,ecx
|
|
jz bp_glyph_digit
|
|
cmp ecx,1
|
|
jne bp_glyph_bonus_spare
|
|
cmp DWORD PTR [esi+edi*4-4],10
|
|
je bp_glyph_digit
|
|
jmp bp_glyph_spare
|
|
bp_glyph_bonus_spare:
|
|
cmp DWORD PTR [esi+edi*4-8],10
|
|
jne bp_glyph_digit
|
|
cmp DWORD PTR [esi+edi*4-4],10
|
|
je bp_glyph_digit
|
|
bp_glyph_spare:
|
|
mov edx,eax
|
|
add edx,[esi+edi*4-4]
|
|
cmp edx,10
|
|
jne bp_glyph_digit
|
|
mov eax,'/'
|
|
ret
|
|
bp_glyph_digit:
|
|
cmp eax,10
|
|
je bp_glyph_strike
|
|
test eax,eax
|
|
jz bp_glyph_miss
|
|
add eax,'0'
|
|
ret
|
|
bp_glyph_miss:
|
|
mov eax,'-'
|
|
ret
|
|
bp_glyph_strike:
|
|
mov eax,'X'
|
|
ret
|
|
bp_glyph_blank:
|
|
mov eax,' '
|
|
ret
|
|
BowlingRollGlyph3D ENDP
|
|
|
|
DrawBowlingPlayScores3D PROC uses ebx esi edi
|
|
local x:DWORD,y:DWORD,owner:DWORD,slot:DWORD
|
|
invoke DrawBoxBorder,4,47,312,160,00151F26h,005BC9BEh,1
|
|
invoke DrawString8x8,12,55,OFFSET bpScoreText,00E8D7ADh
|
|
xor esi,esi
|
|
bp_card_header:
|
|
imul eax,esi,26
|
|
add eax,44
|
|
mov x,eax
|
|
invoke DrawBox,x,88,1,108,00425D64h
|
|
lea eax,[esi+1]
|
|
invoke FormatNumber,eax,OFFSET bpText3D
|
|
invoke DrawString8x8,x,73,OFFSET bpText3D,00AABDB6h
|
|
inc esi
|
|
cmp esi,10
|
|
jb bp_card_header
|
|
invoke DrawBox,6,137,308,1,005BC9BEh
|
|
xor edi,edi
|
|
bp_card_player:
|
|
imul eax,edi,54
|
|
add eax,95
|
|
mov y,eax
|
|
mov eax,OFFSET bpYou
|
|
test edi,edi
|
|
jz @F
|
|
mov eax,OFFSET bpBot
|
|
@@:
|
|
invoke DrawString8x8,8,y,eax,005BC9BEh
|
|
mov eax,bpLane3D
|
|
shl eax,1
|
|
add eax,edi
|
|
mov owner,eax
|
|
xor esi,esi
|
|
bp_card_frame:
|
|
mov slot,0
|
|
bp_card_roll:
|
|
invoke BowlingRollGlyph3D,owner,esi,slot
|
|
mov bpGlyph3D,al
|
|
imul eax,esi,26
|
|
add eax,45
|
|
mov ecx,slot
|
|
lea eax,[eax+ecx*8]
|
|
mov x,eax
|
|
invoke DrawString8x8,x,y,OFFSET bpGlyph3D,00E8D7ADh
|
|
inc slot
|
|
cmp slot,3
|
|
jb bp_card_roll
|
|
imul eax,esi,26
|
|
add eax,45
|
|
mov x,eax
|
|
invoke BowlingFrameTotal3D,owner,esi
|
|
cmp eax,-1
|
|
je bp_card_next
|
|
invoke FormatNumber,eax,OFFSET bpText3D
|
|
mov eax,y
|
|
add eax,22
|
|
invoke DrawString8x8,x,eax,OFFSET bpText3D,00FFFFFFh
|
|
bp_card_next:
|
|
inc esi
|
|
cmp esi,10
|
|
jb bp_card_frame
|
|
inc edi
|
|
cmp edi,2
|
|
jb bp_card_player
|
|
ret
|
|
DrawBowlingPlayScores3D ENDP
|