Difference between revisions of "Initialise Drawing & Display Environments"

From Final Fantasy Hacktics Wiki
Jump to navigation Jump to search
 
(One intermediate revision by the same user not shown)
Line 40: Line 40:
 
  0004162c: 0c00746a jal 0x0001d1a8                    [[Store Screen offsets to GTE]]
 
  0004162c: 0c00746a jal 0x0001d1a8                    [[Store Screen offsets to GTE]]
 
  00041630: 00052843 sra r5,r5,0x01
 
  00041630: 00052843 sra r5,r5,0x01
  00041634: 0c007472 jal 0x0001d1c8                    [[Store Projection plane distance in GTE
+
  00041634: 0c007472 jal 0x0001d1c8                    [[Store Projection plane distance in GTE]]
 
  00041638: 02602021 addu r4,r19,r0
 
  00041638: 02602021 addu r4,r19,r0
 
  0004163c: 3c148005 lui r20,0x8005
 
  0004163c: 3c148005 lui r20,0x8005

Latest revision as of 11:36, 25 September 2024

Initialises drawing and display environments? reminds me of the now loading builder.

00041598: 27bdffb8 addiu r29,r29,0xffb8
0004159c: afb60038 sw r22,0x0038(r29)
000415a0: 93b60058 lbu r22,0x0058(r29)
000415a4: afb7003c sw r23,0x003c(r29)
000415a8: 93b7005c lbu r23,0x005c(r29)
000415ac: afb20028 sw r18,0x0028(r29)
000415b0: 00809021 addu r18,r4,r0
000415b4: afb10024 sw r17,0x0024(r29)
000415b8: 00a08821 addu r17,r5,r0
000415bc: afb3002c sw r19,0x002c(r29)
000415c0: 00c09821 addu r19,r6,r0
000415c4: afbf0040 sw r31,0x0040(r29)
000415c8: afb50034 sw r21,0x0034(r29)
000415cc: afb40030 sw r20,0x0030(r29)
000415d0: afb00020 sw r16,0x0020(r29)
000415d4: 3c058004 lui r5,0x8004
000415d8: 24a5091c addiu r5,r5,0x091c
000415dc: 88a20003 lwl r2,0x0003(r5)
000415e0: 98a20000 lwr r2,0x0000(r5)
000415e4: 88a30007 lwl r3,0x0007(r5)
000415e8: 98a30004 lwr r3,0x0004(r5)
000415ec: aba2001b swl r2,0x001b(r29)
000415f0: bba20018 swr r2,0x0018(r29)
000415f4: aba3001f swl r3,0x001f(r29)
000415f8: bba3001c swr r3,0x001c(r29)
000415fc: 00002021 addu r4,r0,r0                     turn off display mask
00041600: 00e0a821 addu r21,r7,r0
00041604: 3a3001e0 xori r16,r17,0x01e0
00041608: 0010802b sltu r16,r0,r16
0004160c: 00108023 subu r16,r0,r16
00041610: 0c00918e jal 0x00024638                    SYS SetDispMask
00041614: 321000f0 andi r16,r16,0x00f0
00041618: 001227c2 srl r4,r18,0x1f
0004161c: 02442021 addu r4,r18,r4
00041620: 00042043 sra r4,r4,0x01
00041624: 00112fc2 srl r5,r17,0x1f
00041628: 02252821 addu r5,r17,r5
0004162c: 0c00746a jal 0x0001d1a8                    Store Screen offsets to GTE
00041630: 00052843 sra r5,r5,0x01
00041634: 0c007472 jal 0x0001d1c8                    Store Projection plane distance in GTE
00041638: 02602021 addu r4,r19,r0
0004163c: 3c148005 lui r20,0x8005
00041640: 2694ea14 addiu r20,r20,0xea14              draw environment 1
00041644: 02802021 addu r4,r20,r0
00041648: 00002821 addu r5,r0,r0
0004164c: 00003021 addu r6,r0,r0
00041650: 02403821 addu r7,r18,r0
00041654: 0c008b78 jal 0x00022de0                    E03 SetDefDrawEnv
00041658: afb10010 sw r17,0x0010(r29)
0004165c: 3c138005 lui r19,0x8005
00041660: 2673eacc addiu r19,r19,0xeacc              display environment 1
00041664: 02602021 addu r4,r19,r0
00041668: 00002821 addu r5,r0,r0
0004166c: 02003021 addu r6,r16,r0
00041670: 02403821 addu r7,r18,r0
00041674: 0c008bac jal 0x00022eb0                    E04 SetDefDispEnv
00041678: afb10010 sw r17,0x0010(r29)
0004167c: 2684005c addiu r4,r20,0x005c               draw environment 2
00041680: 00002821 addu r5,r0,r0
00041684: 02003021 addu r6,r16,r0
00041688: 02403821 addu r7,r18,r0
0004168c: 0c008b78 jal 0x00022de0                    E03 SetDefDrawEnv
00041690: afb10010 sw r17,0x0010(r29)
00041694: 26640014 addiu r4,r19,0x0014               display environment 2
00041698: 00002821 addu r5,r0,r0
0004169c: 00003021 addu r6,r0,r0
000416a0: 02403821 addu r7,r18,r0
000416a4: 0c008bac jal 0x00022eb0                    E04 SetDefDispEnv
000416a8: afb10010 sw r17,0x0010(r29)
000416ac: 3c038004 lui r3,0x8004
000416b0: 8c63597c lw r3,0x597c(r3)
000416b4: 34020001 ori r2,r0,0x0001
000416b8: 3c018005 lui r1,0x8005
000416bc: a020ea86 sb r0,-0x157a(r1)
000416c0: 3c018005 lui r1,0x8005
000416c4: a020ea2a sb r0,-0x15d6(r1)
000416c8: 3c018005 lui r1,0x8005
000416cc: a022ea88 sb r2,-0x1578(r1)
000416d0: 3c018005 lui r1,0x8005
000416d4: a022ea2c sb r2,-0x15d4(r1)
000416d8: 3c018005 lui r1,0x8005
000416dc: a035ea2d sb r21,-0x15d3(r1)
000416e0: 3c018005 lui r1,0x8005
000416e4: a035ea89 sb r21,-0x1577(r1)
000416e8: 00032080 sll r4,r3,0x02
000416ec: 00832021 addu r4,r4,r3
000416f0: 00042080 sll r4,r4,0x02
000416f4: 3c018005 lui r1,0x8005
000416f8: a036ea2e sb r22,-0x15d2(r1)
000416fc: 3c018005 lui r1,0x8005
00041700: a037ea2f sb r23,-0x15d1(r1)
00041704: 3c018005 lui r1,0x8005
00041708: a036ea8a sb r22,-0x1576(r1)
0004170c: 3c018005 lui r1,0x8005
00041710: a037ea8b sb r23,-0x1575(r1)
00041714: 0c0093a1 jal 0x00024e84                     SYS PutDispEnv
00041718: 00932021 addu r4,r4,r19
0004171c: 3c028004 lui r2,0x8004
00041720: 8c42597c lw r2,0x597c(r2)
00041724: 00000000 nop
00041728: 00022040 sll r4,r2,0x01
0004172c: 00822021 addu r4,r4,r2
00041730: 000420c0 sll r4,r4,0x03
00041734: 00822023 subu r4,r4,r2
00041738: 00042080 sll r4,r4,0x02
0004173c: 0c00932b jal 0x00024cac                     SYS PutDrawEnv
00041740: 00942021 addu r4,r4,r20
00041744: 8fbf0040 lw r31,0x0040(r29)
00041748: 8fb7003c lw r23,0x003c(r29)
0004174c: 8fb60038 lw r22,0x0038(r29)
00041750: 8fb50034 lw r21,0x0034(r29)
00041754: 8fb40030 lw r20,0x0030(r29)
00041758: 8fb3002c lw r19,0x002c(r29)
0004175c: 8fb20028 lw r18,0x0028(r29)
00041760: 8fb10024 lw r17,0x0024(r29)
00041764: 8fb00020 lw r16,0x0020(r29)
00041768: 27bd0048 addiu r29,r29,0x0048
0004176c: 03e00008 jr r31
00041770: 00000000 nop