1
0
Fork 0

[AttemptCounter] support area lock

This commit is contained in:
sup39 2022-11-12 19:55:37 +09:00
parent 22ceb9893b
commit 2769030b58
4 changed files with 48 additions and 30 deletions

View file

@ -9,11 +9,12 @@ by setting the format to
1 1
or something else or something else
$ AttemptCounter (v0.2, 2022/11/02) [sup39] $ AttemptCounter (v0.3, 2022/11/12) [sup39]
040EAB7C 4970F3F5
0410C3C8 496EDB45 0410C3C8 496EDB45
040EDB34 4970C41D 040EDB34 4970C41D
04206898 495F36D8 04206898 495F36F0
077F9F0C 000000B4 077F9F0C 000000CC
7C7E1B78 3D808180 7C7E1B78 3D808180
A40C9F08 A17E007C A40C9F08 A17E007C
7C005800 B16C0000 7C005800 B16C0000
@ -22,11 +23,14 @@ A40C9F08 A17E007C
40820010 816CFFFC 40820010 816CFFFC
396B0001 814CFFF8 396B0001 814CFFF8
916CFFFC 914CFFF8 916CFFFC 914CFFF8
4E800020 3D808180 4E800020 39000000
856C9F00 396B0001 3D808180 856C9F00
916C0000 3960003C 396B0001 916C0000
B16C000A 39000000 3960003C B16C000A
4E800020 4A83B2B9 4E800020 3B836000
A19C000E A17C000A
7C0C5800 4D820020
4BFFFFD0 4A83B2A1
3D808180 A46C9F0A 3D808180 A46C9F0A
3463FFFF 4180003C 3463FFFF 4180003C
B06C0000 3860xxxx B06C0000 3860xxxx
@ -35,5 +39,5 @@ B06C0000 3860xxxx
7CC73378 4800000D 7CC73378 4800000D
25640A25 64000000 25640A25 64000000
7D0802A6 812CFFF6 7D0802A6 812CFFF6
814CFFFA 4BFF6281 814CFFFA 4BFF6269
4AA0C8E0 00000000 4AA0C8C8 00000000

View file

@ -1,8 +1,9 @@
$ AttemptCounter (v0.2, 2022/11/02) [sup39] $ AttemptCounter (v0.3, 2022/11/12) [sup39]
040EAB7C 4970F3F5
0410C3C8 496EDB45 0410C3C8 496EDB45
040EDB34 4970C41D 040EDB34 4970C41D
04206898 495F36D8 04206898 495F36F0
077F9F0C 000000B4 077F9F0C 000000C8
7C7E1B78 3D808180 7C7E1B78 3D808180
A40C9F08 A17E007C A40C9F08 A17E007C
7C005800 B16C0000 7C005800 B16C0000
@ -11,18 +12,20 @@ A40C9F08 A17E007C
40820010 816CFFFC 40820010 816CFFFC
396B0001 814CFFF8 396B0001 814CFFF8
916CFFFC 914CFFF8 916CFFFC 914CFFF8
4E800020 3D808180 4E800020 39000000
856C9F00 396B0001 3D808180 856C9F00
916C0000 3960003C 396B0001 916C0000
B16C000A 39000000 3960003C B16C000A
4E800020 4A83B2B9 4E800020 3B836000
A19C000E A17C000A
7C0C5800 4D820020
4BFFFFD0 4A83B2A1
3D808180 A46C9F0A 3D808180 A46C9F0A
3463FFFF 4180003C 3463FFFF 41800038
B06C0000 38600090 B06C0000 38600090
3880007C 38A0001C 3880007C 38A0001C
3CC0FFFF 60C6FFFF 38C0FFFF 7CC73378
7CC73378 4800000D 4800000D 25640A25
25640A25 64000000 64000000 7D0802A6
7D0802A6 812CFFF6 812CFFF6 814CFFFA
814CFFFA 4BFF6281 4BFF626D 4AA0C8CC
4AA0C8E0 00000000

View file

@ -2,6 +2,7 @@ $$ = 0x817f9f0c;
$bl$.onStart = 0x8010c3c8; $bl$.onStart = 0x8010c3c8;
$bl$.onShineGet = 0x800edb34; $bl$.onShineGet = 0x800edb34;
$bl$.onMoveStage = 0x3C + TMarDirector.moveStage;
$b$.onRender = 0x80206898; $b$.onRender = 0x80206898;
drawText = 0x817f0238; drawText = 0x817f0238;

View file

@ -44,6 +44,9 @@
blr blr
.onShineGet: .onShineGet:
## orig
li r8, 0
.doSuccess:
.set r$$, 12 .set r$$, 12
.set off$$, off$succnt .set off$$, off$succnt
.set a$$, $data+off$$ .set a$$, $data+off$$
@ -55,10 +58,19 @@
## set freeze ## set freeze
li r11, freezeDuration li r11, freezeDuration
sth r11, off$freeze-off$$(r$$) sth r11, off$freeze-off$$(r$$)
## orig
li r8, 0
blr blr
.onMoveStage:
## orig
addi r28, r3, gpApplication@l # TODO check version
## r31 = this
## r12, r11 = curArea, prevArea
lhz r12, 0xe(r28)
lhz r11, 0xa(r28)
cmpw r12, r11
beqlr # same area -> reset -> not success
b .doSuccess
.onRender: .onRender:
## orig (setup2D) ## orig (setup2D)
bl setup2D bl setup2D
@ -79,9 +91,7 @@
li r3, x li r3, x
li r4, y li r4, y
li r5, fontSize li r5, fontSize
#liDX r6, color # colorTop liDX r6, color
lis r6, color@h
ori r6, r6, color@l
mr r7, r6 # colorBot mr r7, r6 # colorBot
bl .onRender.fmt; .string "%d\n%d"; .align 2; .onRender.fmt: mflr r8 bl .onRender.fmt; .string "%d\n%d"; .align 2; .onRender.fmt: mflr r8
lwz r9, off$succnt-off$$(r$$) lwz r9, off$succnt-off$$(r$$)