/* 
 * 変換日付 Wed Aug 30 14:20:54 2000
 * 2000/6/28 var2.04
 * パレット有効
 * XXコードの頂点破棄
 * 使用テキスチャ─チェック
 * 頂点カラーを評価しない
 * ビュア─の設定対応
 */
#include <mbi.h>
#include <u64macro.h>

extern unsigned char hi_light_txt[];
extern Mtx	softsprite_mtx;
static unsigned short act_m_kiageha_pal[] = {
0x2900,0x2901,0x41c5,0x5247,0x6b09,0x9449,0xe981,0x4ae7,
0xd5c9,0xe649,0xff49,0x7b87,0xb54b,0xfd29,0xfd29,0xfd29,
};
/* texture = 1 */
static unsigned char act_m_kiageha[] = {
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x00,0x00,0x01,0x11,0x11,0x11,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
0x00,0x01,0x13,0xb3,0x8a,0xab,0xb1,0x11,0x10,0x00,0x00,0x00,0xcb,0x10,0x00,0x00,
0x00,0x12,0x8b,0x33,0x2b,0xb8,0xaa,0x82,0x41,0x11,0x00,0x00,0x00,0x01,0x10,0x00,
0x00,0x1c,0xaa,0x21,0x3c,0xaa,0xb2,0x2c,0xaa,0x52,0x11,0x10,0x00,0x00,0x01,0x00,
0x00,0x02,0x41,0xc3,0x11,0x8b,0xca,0x18,0xaa,0xaa,0xb2,0x21,0x10,0x00,0x00,0x10,
0x00,0x00,0x14,0xab,0x23,0x1c,0xaa,0xb1,0x28,0xac,0x2c,0xa5,0x11,0x10,0x00,0x0b,
0x00,0x00,0x01,0x2c,0xa2,0x11,0x9b,0x2c,0xa2,0xc2,0xca,0xaa,0xc2,0x11,0x10,0x19,
0x00,0x00,0x00,0x01,0xc1,0x23,0x11,0xca,0xaa,0x21,0xaa,0xac,0x22,0x41,0x22,0x9a,
0x00,0x00,0x00,0x00,0x1b,0xa1,0x11,0x2a,0xa2,0xc2,0x1a,0xc2,0x44,0x24,0x12,0xb3,
0x00,0x00,0x00,0x00,0x01,0x49,0x23,0x12,0xbc,0xaa,0xc1,0x22,0x22,0x42,0x41,0x91,
0x00,0x00,0x00,0x00,0x00,0x1b,0x12,0x31,0x2a,0xaa,0x2c,0x24,0x44,0x22,0x21,0xa1,
0x00,0x00,0x00,0x00,0x00,0x01,0xba,0x12,0x12,0x92,0xca,0xc2,0x22,0x44,0x12,0xa1,
0x00,0x00,0x00,0x00,0x00,0x00,0x15,0x92,0x13,0x1c,0xaa,0xbc,0x24,0x41,0x34,0xa3,
0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xb1,0xb1,0x31,0x82,0xca,0xc2,0x1c,0xa4,0xa3,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1b,0xa1,0x13,0x1b,0xaa,0xbc,0x3a,0xa3,0xa3,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xb9,0x21,0x32,0xa2,0xca,0x3a,0xa3,0x9c,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1b,0x22,0x11,0x21,0xba,0x3c,0xac,0x4c,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x11,0x12,0x77,0x1c,0xa3,0xca,0x3c,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x19,0xa1,0x31,0x71,0xca,0x33,0x1a,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x15,0x91,0x17,0x77,0x12,0xcc,0x19,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x15,0x13,0x71,0x77,0x11,0x1c,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x4a,0xa1,0x13,0x76,0x62,0x01,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1c,0xa4,0x11,0x36,0x62,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x41,0x3c,0xac,0x20,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x11,0xca,0xc2,0x00,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xac,0x00,0x00,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xa0,0x00,0x00,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x90,0x00,0x00,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xb0,0x00,0x00,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x10,0x00,0x00,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
}; /* act_m_kiageha */


/* ビュア─設定のパレット */
/* ビュア─設定のテキスチャ─ */
/* vretex = 12 */
static Vtx act_m_kiageha_v[] = {
/* 0番目 */ {-1250,    0,  750,    0, 2048,    0,  -44,  111,    0,  206},
/* 1番目 */ {   0,  500,  750,    0, 1024,    0,    0,  120,    0,  255},
/* 2番目 */ {   0,  500, -750,    0, 1024, 1024,    0,  120,    0,  255},
/* 3番目 */ {-1250,    0, -750,    0, 2048, 1024,  -44,  111,    0,  206},
/* 4番目 */ {1250,    0,  750,    0,    0,    0,   44,  111,    0,  255},
/* 5番目 */ {1250,    0, -750,    0,    0, 1024,   44,  111,    0,  255},
/* 6番目 */ {   0,  500,  750,    0, 1024,    0,    0,  120,    0,  255},
/* 7番目 */ { 875, 1625,  750,    0,    0,    0,  -44,  111,    0,  206},
/* 8番目 */ { 875, 1625, -750,    0,    0, 1024,  -44,  111,    0,  206},
/* 9番目 */ {   0,  500, -750,    0, 1024, 1024,    0,  120,    0,  255},
/* 10番目 */ {-875, 1625,  750,    0, 2048,    0,   44,  111,    0,  255},
/* 11番目 */ {-875, 1625, -750,    0, 2048, 1024,   44,  111,    0,  255},

};

extern Gfx act_m_test1T_model[] = {
	gsSPTexture( 0xffff, 0xffff, 0, 0, G_ON),
	gsDPPipeSync(),
	gsDPSetCombineLERP(
		TEXEL0, 0, PRIMITIVE, 0,
		TEXEL0, 0, ENVIRONMENT, 0,
		COMBINED, 0, SHADE, 0,
		0, 0, 0, COMBINED
	),
	gsDPSetPrimColor(0, 255, 255, 255, 255, 255),
//	gsDPSetEnvColor(255, 255, 255, 255),
	gsDPSetRenderMode(G_RM_FOG_SHADE_A,G_RM_ZB_XLU_SURF2),
/* repeat = (1,1)  mirror = (1,1) clamp = (0,1) */
	gsDPPipeSync(),
	gsDPSetTextureLUT(G_TT_RGBA16),
	gsDPLoadTLUT_pal16(15,act_m_kiageha_pal),
	gsDPLoadTextureBlock_4b(
			act_m_kiageha,
			G_IM_FMT_CI,
			32, 32, 15,
			G_TX_MIRROR | G_TX_WRAP, G_TX_MIRROR | G_TX_CLAMP,
			5, 5, 0, 0),
/* act_m_kiageha1T_1 */
	gsSPLoadGeometryMode(G_LIGHTING | G_FOG | G_SHADE | G_SHADING_SMOOTH | G_ZBUFFER),
	gsSPVertex(&act_m_kiageha_v[0],6,0),
	gsSP2Triangles( 0, 1, 2, 0, 0, 2, 3, 0 ),
	gsSP2Triangles( 1, 4, 5, 0, 1, 5, 2, 0 ),
	gsSPEndDisplayList(),
};

extern Gfx act_m_test2T_model[] = {
	gsSPTexture( 0xffff, 0xffff, 0, 0, G_ON),
	gsDPPipeSync(),
	gsDPSetCombineLERP(
		TEXEL0, 0, PRIMITIVE, 0,
		TEXEL0, 0, ENVIRONMENT, 0,
		COMBINED, 0, SHADE, 0,
		0, 0, 0, COMBINED
	),
	gsDPSetPrimColor(0, 255, 255, 255, 255, 255),
//	gsDPSetEnvColor(255, 255, 255, 255),
	gsDPSetRenderMode(G_RM_FOG_SHADE_A,G_RM_ZB_XLU_SURF2),
/* repeat = (1,1)  mirror = (1,1) clamp = (0,1) */
	gsDPPipeSync(),
	gsDPSetTextureLUT(G_TT_RGBA16),
	gsDPLoadTLUT_pal16(15,act_m_kiageha_pal),
	gsDPLoadTextureBlock_4b(
			act_m_kiageha,
			G_IM_FMT_CI,
			32, 32, 15,
			G_TX_MIRROR | G_TX_WRAP, G_TX_MIRROR | G_TX_CLAMP,
			5, 5, 0, 0),
/* act_m_kiageha2T_1 */
	gsSPLoadGeometryMode(G_LIGHTING | G_FOG | G_SHADE | G_SHADING_SMOOTH | G_ZBUFFER),
	gsSPVertex(&act_m_kiageha_v[6],6,0),
	gsSP2Triangles( 0, 1, 2, 0, 0, 2, 3, 0 ),
	gsSP2Triangles( 4, 0, 3, 0, 4, 3, 5, 0 ),
	gsSPEndDisplayList(),
};

