sm64

A Super Mario 64 decompilation
Log | Files | Refs | README | LICENSE

model.inc.c (11927B)


      1 // 0x0701A0F0 - 0x0701A108
      2 static const Lights1 bbh_seg7_lights_0701A0F0 = gdSPDefLights1(
      3     0x20, 0x20, 0x20,
      4     0x50, 0x50, 0x50, 0x28, 0x28, 0x28
      5 );
      6 
      7 // 0x0701A108 - 0x0701A120
      8 static const Lights1 bbh_seg7_lights_0701A108 = gdSPDefLights1(
      9     0x66, 0x66, 0x66,
     10     0xff, 0xff, 0xff, 0x28, 0x28, 0x28
     11 );
     12 
     13 // 0x0701A120 - 0x0701A160
     14 static const Vtx bbh_seg7_vertex_0701A120[] = {
     15     {{{  -306,  -2457,   2150}, 0, { 24496,      0}, {0x00, 0x7f, 0x00, 0xff}}},
     16     {{{   307,  -2457,   4608}, 0, {     0,   6098}, {0x00, 0x7f, 0x00, 0xff}}},
     17     {{{   307,  -2457,   2150}, 0, { 24496,   6098}, {0x00, 0x7f, 0x00, 0xff}}},
     18     {{{  -306,  -2457,   4608}, 0, {     0,      0}, {0x00, 0x7f, 0x00, 0xff}}},
     19 };
     20 
     21 // 0x0701A160 - 0x0701A260
     22 static const Vtx bbh_seg7_vertex_0701A160[] = {
     23     {{{   -76,  -2457,   2099}, 0, {   990,    478}, {0x00, 0x7f, 0x00, 0xff}}},
     24     {{{   -76,  -2457,   2150}, 0, {   990,      0}, {0x00, 0x7f, 0x00, 0xff}}},
     25     {{{    77,  -2457,   2150}, 0, {     0,      0}, {0x00, 0x7f, 0x00, 0xff}}},
     26     {{{   -76,  -2457,   4608}, 0, {   990,    990}, {0x00, 0x7f, 0x00, 0xff}}},
     27     {{{   -76,  -2457,   4659}, 0, {   990,    478}, {0x00, 0x7f, 0x00, 0xff}}},
     28     {{{    77,  -2457,   4659}, 0, {     0,    480}, {0x00, 0x7f, 0x00, 0xff}}},
     29     {{{    77,  -2457,   4608}, 0, {     0,   2012}, {0x00, 0x7f, 0x00, 0xff}}},
     30     {{{    77,  -2201,   4608}, 0, {     0,    990}, {0x00, 0x81, 0x00, 0xff}}},
     31     {{{    77,  -2201,   4659}, 0, {     0,    480}, {0x00, 0x81, 0x00, 0xff}}},
     32     {{{   -76,  -2201,   4659}, 0, {   990,    478}, {0x00, 0x81, 0x00, 0xff}}},
     33     {{{   -76,  -2201,   4608}, 0, {   990,    990}, {0x00, 0x81, 0x00, 0xff}}},
     34     {{{    77,  -2201,   2099}, 0, {     0,    478}, {0x00, 0x81, 0x00, 0xff}}},
     35     {{{    77,  -2201,   2150}, 0, {     0,      0}, {0x00, 0x81, 0x00, 0xff}}},
     36     {{{   -76,  -2201,   2150}, 0, {   990,      0}, {0x00, 0x81, 0x00, 0xff}}},
     37     {{{   -76,  -2201,   2099}, 0, {   990,    478}, {0x00, 0x81, 0x00, 0xff}}},
     38     {{{    77,  -2457,   2099}, 0, {     0,    478}, {0x00, 0x7f, 0x00, 0xff}}},
     39 };
     40 
     41 // 0x0701A260 - 0x0701A360
     42 static const Vtx bbh_seg7_vertex_0701A260[] = {
     43     {{{   -76,  -2201,   2099}, 0, {   480,      0}, {0x7f, 0x00, 0x00, 0xff}}},
     44     {{{   -76,  -2201,   2150}, 0, {   990,      0}, {0x7f, 0x00, 0x00, 0xff}}},
     45     {{{   -76,  -2457,   2150}, 0, {   990,   2012}, {0x7f, 0x00, 0x00, 0xff}}},
     46     {{{   -76,  -2201,   4608}, 0, {     0,      0}, {0x7f, 0x00, 0x00, 0xff}}},
     47     {{{   -76,  -2457,   4659}, 0, {   478,   2012}, {0x7f, 0x00, 0x00, 0xff}}},
     48     {{{   -76,  -2457,   4608}, 0, {     0,   2012}, {0x7f, 0x00, 0x00, 0xff}}},
     49     {{{   -76,  -2201,   4659}, 0, {   478,      0}, {0x7f, 0x00, 0x00, 0xff}}},
     50     {{{    77,  -2457,   4608}, 0, {     0,   2012}, {0x81, 0x00, 0x00, 0xff}}},
     51     {{{    77,  -2201,   4659}, 0, {   478,      0}, {0x81, 0x00, 0x00, 0xff}}},
     52     {{{    77,  -2201,   4608}, 0, {     0,      0}, {0x81, 0x00, 0x00, 0xff}}},
     53     {{{    77,  -2457,   4659}, 0, {   478,   2012}, {0x81, 0x00, 0x00, 0xff}}},
     54     {{{    77,  -2457,   2099}, 0, {   480,   2012}, {0x81, 0x00, 0x00, 0xff}}},
     55     {{{    77,  -2457,   2150}, 0, {   990,   2012}, {0x81, 0x00, 0x00, 0xff}}},
     56     {{{    77,  -2201,   2150}, 0, {   990,      0}, {0x81, 0x00, 0x00, 0xff}}},
     57     {{{    77,  -2201,   2099}, 0, {   480,      0}, {0x81, 0x00, 0x00, 0xff}}},
     58     {{{   -76,  -2457,   2099}, 0, {   480,   2012}, {0x7f, 0x00, 0x00, 0xff}}},
     59 };
     60 
     61 // 0x0701A360 - 0x0701A450
     62 static const Vtx bbh_seg7_vertex_0701A360[] = {
     63     {{{   307,  -2457,   2150}, 0, {     0,    990}, {0x81, 0x00, 0x00, 0xff}}},
     64     {{{   307,  -2047,   4608}, 0, { 12232,  -1054}, {0x81, 0x00, 0x00, 0xff}}},
     65     {{{   307,  -2047,   2150}, 0, {     0,  -1054}, {0x81, 0x00, 0x00, 0xff}}},
     66     {{{  -101,  -1842,   2150}, 0, { 12232,   -456}, {0x59, 0xa7, 0x00, 0xff}}},
     67     {{{  -306,  -2047,   4608}, 0, {     0,    990}, {0x59, 0xa7, 0x00, 0xff}}},
     68     {{{  -306,  -2047,   2150}, 0, { 12232,    990}, {0x59, 0xa7, 0x00, 0xff}}},
     69     {{{  -101,  -1842,   4608}, 0, {     0,   -456}, {0x59, 0xa7, 0x00, 0xff}}},
     70     {{{   102,  -1842,   2150}, 0, { 12232,      0}, {0x00, 0x81, 0x00, 0xff}}},
     71     {{{   102,  -1842,   4608}, 0, {     0,      0}, {0x00, 0x81, 0x00, 0xff}}},
     72     {{{  -101,  -1842,   4608}, 0, {     0,    990}, {0x00, 0x81, 0x00, 0xff}}},
     73     {{{  -101,  -1842,   2150}, 0, { 12232,    990}, {0x00, 0x81, 0x00, 0xff}}},
     74     {{{   307,  -2047,   2150}, 0, {     0,    990}, {0xa7, 0xa7, 0x00, 0xff}}},
     75     {{{   307,  -2047,   4608}, 0, { 12232,    990}, {0xa7, 0xa7, 0x00, 0xff}}},
     76     {{{   102,  -1842,   4608}, 0, { 12232,   -456}, {0xa7, 0xa7, 0x00, 0xff}}},
     77     {{{   102,  -1842,   2150}, 0, {     0,   -456}, {0xa7, 0xa7, 0x00, 0xff}}},
     78 };
     79 
     80 // 0x0701A450 - 0x0701A550
     81 static const Vtx bbh_seg7_vertex_0701A450[] = {
     82     {{{   -76,  -2201,   4608}, 0, {  1884,   -288}, {0x00, 0x00, 0x81, 0xff}}},
     83     {{{  -306,  -2047,   4608}, 0, {  3032,  -1054}, {0x00, 0x00, 0x81, 0xff}}},
     84     {{{   102,  -1842,   4608}, 0, {   988,  -2076}, {0x00, 0x00, 0x81, 0xff}}},
     85     {{{   307,  -2457,   2150}, 0, {     0,    990}, {0x81, 0x00, 0x00, 0xff}}},
     86     {{{   307,  -2457,   4608}, 0, { 12232,    990}, {0x81, 0x00, 0x00, 0xff}}},
     87     {{{   307,  -2047,   4608}, 0, { 12232,  -1054}, {0x81, 0x00, 0x00, 0xff}}},
     88     {{{  -306,  -2047,   2150}, 0, {  7632,  -1054}, {0x7f, 0x00, 0x00, 0xff}}},
     89     {{{  -306,  -2047,   4608}, 0, { -4628,  -1054}, {0x7f, 0x00, 0x00, 0xff}}},
     90     {{{  -306,  -2457,   4608}, 0, { -4628,    990}, {0x7f, 0x00, 0x00, 0xff}}},
     91     {{{  -306,  -2457,   2150}, 0, {  7632,    990}, {0x7f, 0x00, 0x00, 0xff}}},
     92     {{{   -76,  -2457,   4608}, 0, {  1884,    990}, {0x00, 0x00, 0x81, 0xff}}},
     93     {{{  -306,  -2457,   4608}, 0, {  3032,    990}, {0x00, 0x00, 0x81, 0xff}}},
     94     {{{    77,  -2201,   4608}, 0, {  1116,   -288}, {0x00, 0x00, 0x81, 0xff}}},
     95     {{{  -101,  -1842,   4608}, 0, {  2012,  -2076}, {0x00, 0x00, 0x81, 0xff}}},
     96     {{{   307,  -2047,   4608}, 0, {     0,  -1054}, {0x00, 0x00, 0x81, 0xff}}},
     97     {{{   307,  -2457,   4608}, 0, {     0,    990}, {0x00, 0x00, 0x81, 0xff}}},
     98 };
     99 
    100 // 0x0701A550 - 0x0701A620
    101 static const Vtx bbh_seg7_vertex_0701A550[] = {
    102     {{{   307,  -2457,   4608}, 0, {     0,    990}, {0x00, 0x00, 0x81, 0xff}}},
    103     {{{    77,  -2457,   4608}, 0, {  1116,    990}, {0x00, 0x00, 0x81, 0xff}}},
    104     {{{    77,  -2201,   4608}, 0, {  1116,   -288}, {0x00, 0x00, 0x81, 0xff}}},
    105     {{{   307,  -2047,   2150}, 0, {  3032,  -1054}, {0x00, 0x00, 0x7f, 0xff}}},
    106     {{{    77,  -2201,   2150}, 0, {  1884,   -288}, {0x00, 0x00, 0x7f, 0xff}}},
    107     {{{   307,  -2457,   2150}, 0, {  3032,    990}, {0x00, 0x00, 0x7f, 0xff}}},
    108     {{{   102,  -1842,   2150}, 0, {  2012,  -2076}, {0x00, 0x00, 0x7f, 0xff}}},
    109     {{{   -76,  -2201,   2150}, 0, {  1116,   -288}, {0x00, 0x00, 0x7f, 0xff}}},
    110     {{{    77,  -2457,   2150}, 0, {  1884,    990}, {0x00, 0x00, 0x7f, 0xff}}},
    111     {{{  -306,  -2457,   2150}, 0, {     0,    990}, {0x00, 0x00, 0x7f, 0xff}}},
    112     {{{   -76,  -2457,   2150}, 0, {  1116,    990}, {0x00, 0x00, 0x7f, 0xff}}},
    113     {{{  -306,  -2047,   2150}, 0, {     0,  -1054}, {0x00, 0x00, 0x7f, 0xff}}},
    114     {{{  -101,  -1842,   2150}, 0, {   988,  -2076}, {0x00, 0x00, 0x7f, 0xff}}},
    115 };
    116 
    117 // 0x0701A620 - 0x0701A668
    118 static const Gfx bbh_seg7_dl_0701A620[] = {
    119     gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, spooky_0900A000),
    120     gsDPLoadSync(),
    121     gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 32 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)),
    122     gsSPLight(&bbh_seg7_lights_0701A0F0.l, 1),
    123     gsSPLight(&bbh_seg7_lights_0701A0F0.a, 2),
    124     gsSPVertex(bbh_seg7_vertex_0701A120, 4, 0),
    125     gsSP2Triangles( 0,  1,  2, 0x0,  0,  3,  1, 0x0),
    126     gsSPEndDisplayList(),
    127 };
    128 
    129 // 0x0701A668 - 0x0701A6E0
    130 static const Gfx bbh_seg7_dl_0701A668[] = {
    131     gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, spooky_09008800),
    132     gsDPLoadSync(),
    133     gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 32 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)),
    134     gsSPLight(&bbh_seg7_lights_0701A108.l, 1),
    135     gsSPLight(&bbh_seg7_lights_0701A108.a, 2),
    136     gsSPVertex(bbh_seg7_vertex_0701A160, 16, 0),
    137     gsSP2Triangles( 0,  1,  2, 0x0,  3,  4,  5, 0x0),
    138     gsSP2Triangles( 3,  5,  6, 0x0,  7,  8,  9, 0x0),
    139     gsSP2Triangles( 7,  9, 10, 0x0, 11, 12, 13, 0x0),
    140     gsSP2Triangles(11, 13, 14, 0x0,  0,  2, 15, 0x0),
    141     gsSPEndDisplayList(),
    142 };
    143 
    144 // 0x0701A6E0 - 0x0701A748
    145 static const Gfx bbh_seg7_dl_0701A6E0[] = {
    146     gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, spooky_09003800),
    147     gsDPLoadSync(),
    148     gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 32 * 64 - 1, CALC_DXT(32, G_IM_SIZ_16b_BYTES)),
    149     gsSPVertex(bbh_seg7_vertex_0701A260, 16, 0),
    150     gsSP2Triangles( 0,  1,  2, 0x0,  3,  4,  5, 0x0),
    151     gsSP2Triangles( 3,  6,  4, 0x0,  7,  8,  9, 0x0),
    152     gsSP2Triangles( 7, 10,  8, 0x0, 11, 12, 13, 0x0),
    153     gsSP2Triangles(11, 13, 14, 0x0,  0,  2, 15, 0x0),
    154     gsSPEndDisplayList(),
    155 };
    156 
    157 // 0x0701A748 - 0x0701A850
    158 static const Gfx bbh_seg7_dl_0701A748[] = {
    159     gsDPSetTextureImage(G_IM_FMT_RGBA, G_IM_SIZ_16b, 1, spooky_09007000),
    160     gsDPLoadSync(),
    161     gsDPLoadBlock(G_TX_LOADTILE, 0, 0, 64 * 32 - 1, CALC_DXT(64, G_IM_SIZ_16b_BYTES)),
    162     gsSPVertex(bbh_seg7_vertex_0701A360, 15, 0),
    163     gsSP2Triangles( 0,  1,  2, 0x0,  3,  4,  5, 0x0),
    164     gsSP2Triangles( 3,  6,  4, 0x0,  7,  8,  9, 0x0),
    165     gsSP2Triangles( 7,  9, 10, 0x0, 11, 12, 13, 0x0),
    166     gsSP1Triangle(11, 13, 14, 0x0),
    167     gsSPVertex(bbh_seg7_vertex_0701A450, 16, 0),
    168     gsSP2Triangles( 0,  1,  2, 0x0,  3,  4,  5, 0x0),
    169     gsSP2Triangles( 6,  7,  8, 0x0,  6,  8,  9, 0x0),
    170     gsSP2Triangles( 0, 10, 11, 0x0,  0, 11,  1, 0x0),
    171     gsSP2Triangles(12,  0,  2, 0x0,  1, 13,  2, 0x0),
    172     gsSP2Triangles(12,  2, 14, 0x0, 15, 12, 14, 0x0),
    173     gsSPVertex(bbh_seg7_vertex_0701A550, 13, 0),
    174     gsSP2Triangles( 0,  1,  2, 0x0,  3,  4,  5, 0x0),
    175     gsSP2Triangles( 3,  6,  4, 0x0,  6,  7,  4, 0x0),
    176     gsSP2Triangles( 4,  8,  5, 0x0,  9, 10,  7, 0x0),
    177     gsSP2Triangles(11,  9,  7, 0x0,  6, 11,  7, 0x0),
    178     gsSP1Triangle( 6, 12, 11, 0x0),
    179     gsSPEndDisplayList(),
    180 };
    181 
    182 // 0x0701A850 - 0x0701A920
    183 const Gfx bbh_seg7_dl_0701A850[] = {
    184     gsDPPipeSync(),
    185     gsDPSetCombineMode(G_CC_MODULATERGB, G_CC_MODULATERGB),
    186     gsSPClearGeometryMode(G_SHADING_SMOOTH),
    187     gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 0, 0, G_TX_LOADTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, G_TX_NOMASK, G_TX_NOLOD),
    188     gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON),
    189     gsDPTileSync(),
    190     gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 8, 0, G_TX_RENDERTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, 5, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, 5, G_TX_NOLOD),
    191     gsDPSetTileSize(0, 0, 0, (32 - 1) << G_TEXTURE_IMAGE_FRAC, (32 - 1) << G_TEXTURE_IMAGE_FRAC),
    192     gsSPDisplayList(bbh_seg7_dl_0701A620),
    193     gsDPTileSync(),
    194     gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 8, 0, G_TX_RENDERTILE, 0, G_TX_CLAMP, 5, G_TX_NOLOD, G_TX_CLAMP, 5, G_TX_NOLOD),
    195     gsDPSetTileSize(0, 0, 0, (32 - 1) << G_TEXTURE_IMAGE_FRAC, (32 - 1) << G_TEXTURE_IMAGE_FRAC),
    196     gsSPDisplayList(bbh_seg7_dl_0701A668),
    197     gsDPTileSync(),
    198     gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 8, 0, G_TX_RENDERTILE, 0, G_TX_CLAMP, 6, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, 5, G_TX_NOLOD),
    199     gsDPSetTileSize(0, 0, 0, (32 - 1) << G_TEXTURE_IMAGE_FRAC, (64 - 1) << G_TEXTURE_IMAGE_FRAC),
    200     gsSPDisplayList(bbh_seg7_dl_0701A6E0),
    201     gsDPTileSync(),
    202     gsDPSetTile(G_IM_FMT_RGBA, G_IM_SIZ_16b, 16, 0, G_TX_RENDERTILE, 0, G_TX_WRAP | G_TX_NOMIRROR, 5, G_TX_NOLOD, G_TX_WRAP | G_TX_NOMIRROR, 6, G_TX_NOLOD),
    203     gsDPSetTileSize(0, 0, 0, (64 - 1) << G_TEXTURE_IMAGE_FRAC, (32 - 1) << G_TEXTURE_IMAGE_FRAC),
    204     gsSPDisplayList(bbh_seg7_dl_0701A748),
    205     gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_OFF),
    206     gsDPPipeSync(),
    207     gsDPSetCombineMode(G_CC_SHADE, G_CC_SHADE),
    208     gsSPSetGeometryMode(G_SHADING_SMOOTH),
    209     gsSPEndDisplayList(),
    210 };