#include <openb3d.mod/openb3dex.mod/.bmx/openb3dex.bmx.release.mt.win32.x86.h>
static BBString _s120={
	&bbStringClass,
	1,
	{32}
};
static BBString _s131={
	&bbStringClass,
	19,
	{32,32,76,105,110,107,105,110,103,8230,32,80,114,111,103,114,97
	,109,61}
};
static BBString _s138={
	&bbStringClass,
	3,
	{32,45,32}
};
static BBString _s65={
	&bbStringClass,
	7,
	{32,66,114,117,115,104,58}
};
static BBString _s134={
	&bbStringClass,
	17,
	{32,83,104,97,100,101,114,32,108,105,110,107,101,100,32,79,75
}
};
static BBString _s124={
	&bbStringClass,
	29,
	{32,99,111,109,112,105,108,101,32,67,114,101,97,116,101,32,80
	,114,111,103,114,97,109,79,98,106,101,99,116}
};
static BBString _s130={
	&bbStringClass,
	26,
	{32,108,105,110,107,32,67,114,101,97,116,101,32,80,114,111,103
	,114,97,109,79,98,106,101,99,116}
};
static BBString _s140={
	&bbStringClass,
	1,
	{39}
};
static BBString _s121={
	&bbStringClass,
	9,
	{45,32,82,101,97,100,121,32,45}
};
static BBString _s145={
	&bbStringClass,
	2,
	{45,49}
};
static BBString _s143={
	&bbStringClass,
	1,
	{46}
};
static BBString _s43={
	&bbStringClass,
	9,
	{46,32,67,108,97,115,115,58,32}
};
static BBString _s42={
	&bbStringClass,
	8,
	{46,32,78,97,109,101,58,32}
};
static BBString _s21={
	&bbStringClass,
	1,
	{47}
};
static BBString _s146={
	&bbStringClass,
	1,
	{48}
};
static BBString _s144={
	&bbStringClass,
	6,
	{48,46,48,48,48,49}
};
static BBString _s147={
	&bbStringClass,
	1,
	{49}
};
static BBString _s46={
	&bbStringClass,
	23,
	{49,46,32,69,110,116,105,116,121,32,80,111,115,105,116,105,111
	,110,32,73,110,102,111}
};
static BBString _s148={
	&bbStringClass,
	1,
	{50}
};
static BBString _s55={
	&bbStringClass,
	15,
	{50,46,32,83,117,114,102,97,99,101,32,73,110,102,111}
};
static BBString _s149={
	&bbStringClass,
	1,
	{51}
};
static BBString _s64={
	&bbStringClass,
	13,
	{51,46,32,66,114,117,115,104,32,73,110,102,111}
};
static BBString _s87={
	&bbStringClass,
	14,
	{51,46,32,67,97,109,101,114,97,32,73,110,102,111}
};
static BBString _s23={
	&bbStringClass,
	1,
	{58}
};
static BBString _s59={
	&bbStringClass,
	15,
	{65,108,112,104,97,32,69,110,97,98,108,101,100,58,32}
};
static BBString _s70={
	&bbStringClass,
	7,
	{65,108,112,104,97,58,32}
};
static BBString _s71={
	&bbStringClass,
	7,
	{66,108,101,110,100,58,32}
};
static BBString _s69={
	&bbStringClass,
	6,
	{66,108,117,101,58,32}
};
static BBString _s40={
	&bbStringClass,
	7,
	{66,111,110,101,115,58,32}
};
static BBString _s89={
	&bbStringClass,
	28,
	{67,97,109,101,114,97,32,101,110,116,105,116,121,32,110,111,116
	,32,115,112,101,99,105,102,105,101,100,33}
};
static BBString _s35={
	&bbStringClass,
	9,
	{67,97,109,101,114,97,115,58,32}
};
static BBString _s27={
	&bbStringClass,
	18,
	{68,101,108,32,84,65,110,105,109,97,116,105,111,110,75,101,121
	,115}
};
static BBString _s13={
	&bbStringClass,
	9,
	{68,101,108,32,84,66,111,110,101}
};
static BBString _s25={
	&bbStringClass,
	10,
	{68,101,108,32,84,66,114,117,115,104}
};
static BBString _s3={
	&bbStringClass,
	11,
	{68,101,108,32,84,67,97,109,101,114,97}
};
static BBString _s1={
	&bbStringClass,
	11,
	{68,101,108,32,84,69,110,116,105,116,121}
};
static BBString _s5={
	&bbStringClass,
	10,
	{68,101,108,32,84,76,105,103,104,116}
};
static BBString _s31={
	&bbStringClass,
	11,
	{68,101,108,32,84,77,97,116,114,105,120}
};
static BBString _s9={
	&bbStringClass,
	9,
	{68,101,108,32,84,77,101,115,104}
};
static BBString _s7={
	&bbStringClass,
	10,
	{68,101,108,32,84,80,105,118,111,116}
};
static BBString _s33={
	&bbStringClass,
	15,
	{68,101,108,32,84,81,117,97,116,101,114,110,105,111,110}
};
static BBString _s11={
	&bbStringClass,
	11,
	{68,101,108,32,84,83,112,114,105,116,101}
};
static BBString _s15={
	&bbStringClass,
	12,
	{68,101,108,32,84,83,117,114,102,97,99,101}
};
static BBString _s17={
	&bbStringClass,
	12,
	{68,101,108,32,84,84,101,120,116,117,114,101}
};
static BBString _s29={
	&bbStringClass,
	11,
	{68,101,108,32,84,86,101,99,116,111,114}
};
static BBString _s111={
	&bbStringClass,
	8,
	{68,101,112,116,104,58,32,32}
};
static BBString _s22={
	&bbStringClass,
	28,
	{69,82,82,79,82,58,32,67,97,110,110,111,116,32,102,105,110
	,100,32,116,101,120,116,117,114,101,58,32}
};
static BBString _s34={
	&bbStringClass,
	10,
	{69,110,116,105,116,105,101,115,58,32}
};
static BBString _s86={
	&bbStringClass,
	13,
	{69,110,116,105,116,121,32,66,114,117,115,104,58}
};
static BBString _s63={
	&bbStringClass,
	21,
	{69,110,116,105,116,121,32,105,115,32,110,111,116,32,97,32,109
	,101,115,104,33}
};
static BBString _s41={
	&bbStringClass,
	8,
	{69,110,116,105,116,121,58,32}
};
static BBString _s88={
	&bbStringClass,
	14,
	{69,110,116,105,116,121,73,110,86,105,101,119,58,32}
};
static BBString _s136={
	&bbStringClass,
	31,
	{69,114,114,111,114,32,105,110,32,102,114,97,103,109,101,110,116
	,32,115,104,97,100,101,114,46,32,76,105,110,101,32}
};
static BBString _s137={
	&bbStringClass,
	51,
	{69,114,114,111,114,32,105,110,32,108,105,110,107,105,110,103,32
	,118,101,114,116,101,120,32,97,110,100,32,102,114,97,103,109
	,101,110,116,32,115,104,97,100,101,114,115,46,32,76,105,110
	,101,32}
};
static BBString _s135={
	&bbStringClass,
	29,
	{69,114,114,111,114,32,105,110,32,118,101,114,116,101,120,32,115
	,104,97,100,101,114,46,32,76,105,110,101,32}
};
static BBString _s72={
	&bbStringClass,
	4,
	{70,88,58,32}
};
static BBString _s96={
	&bbStringClass,
	20,
	{71,76,95,65,82,66,95,100,101,112,116,104,95,116,101,120,116
	,117,114,101}
};
static BBString _s99={
	&bbStringClass,
	23,
	{71,76,95,65,82,66,95,102,114,97,103,109,101,110,116,95,112
	,114,111,103,114,97,109}
};
static BBString _s102={
	&bbStringClass,
	22,
	{71,76,95,65,82,66,95,102,114,97,103,109,101,110,116,95,115
	,104,97,100,101,114}
};
static BBString _s93={
	&bbStringClass,
	19,
	{71,76,95,65,82,66,95,109,117,108,116,105,116,101,120,116,117
	,114,101}
};
static BBString _s100={
	&bbStringClass,
	21,
	{71,76,95,65,82,66,95,115,104,97,100,101,114,95,111,98,106
	,101,99,116,115}
};
static BBString _s103={
	&bbStringClass,
	27,
	{71,76,95,65,82,66,95,115,104,97,100,105,110,103,95,108,97
	,110,103,117,97,103,101,95,49,48,48}
};
static BBString _s90={
	&bbStringClass,
	26,
	{71,76,95,65,82,66,95,116,101,120,116,117,114,101,95,99,111
	,109,112,114,101,115,115,105,111,110}
};
static BBString _s95={
	&bbStringClass,
	23,
	{71,76,95,65,82,66,95,116,101,120,116,117,114,101,95,99,117
	,98,101,95,109,97,112}
};
static BBString _s106={
	&bbStringClass,
	26,
	{71,76,95,65,82,66,95,116,101,120,116,117,114,101,95,101,110
	,118,95,99,111,109,98,105,110,101}
};
static BBString _s97={
	&bbStringClass,
	27,
	{71,76,95,65,82,66,95,118,101,114,116,101,120,95,98,117,102
	,102,101,114,95,111,98,106,101,99,116}
};
static BBString _s98={
	&bbStringClass,
	21,
	{71,76,95,65,82,66,95,118,101,114,116,101,120,95,112,114,111
	,103,114,97,109}
};
static BBString _s101={
	&bbStringClass,
	20,
	{71,76,95,65,82,66,95,118,101,114,116,101,120,95,115,104,97
	,100,101,114}
};
static BBString _s104={
	&bbStringClass,
	25,
	{71,76,95,69,88,84,95,102,114,97,109,101,98,117,102,102,101
	,114,95,111,98,106,101,99,116}
};
static BBString _s105={
	&bbStringClass,
	27,
	{71,76,95,69,88,84,95,112,97,99,107,101,100,95,100,101,112
	,116,104,95,115,116,101,110,99,105,108}
};
static BBString _s91={
	&bbStringClass,
	31,
	{71,76,95,69,88,84,95,116,101,120,116,117,114,101,95,99,111
	,109,112,114,101,115,115,105,111,110,95,115,51,116,99}
};
static BBString _s94={
	&bbStringClass,
	26,
	{71,76,95,69,88,84,95,116,101,120,116,117,114,101,95,101,110
	,118,95,99,111,109,98,105,110,101}
};
static BBString _s92={
	&bbStringClass,
	33,
	{71,76,95,69,88,84,95,116,101,120,116,117,114,101,95,102,105
	,108,116,101,114,95,97,110,105,115,111,116,114,111,112,105,99
}
};
static BBString _s47={
	&bbStringClass,
	7,
	{71,108,111,98,97,108,58}
};
static BBString _s68={
	&bbStringClass,
	7,
	{71,114,101,101,110,58,32}
};
static BBString _s107={
	&bbStringClass,
	16,
	{72,97,114,100,119,97,114,101,73,110,102,111,46,116,120,116}
};
static BBString _s108={
	&bbStringClass,
	13,
	{72,97,114,100,119,97,114,101,105,110,102,111,58}
};
static BBString _s110={
	&bbStringClass,
	8,
	{72,101,105,103,104,116,58,32}
};
static BBString _s112={
	&bbStringClass,
	8,
	{72,101,114,116,122,58,32,32}
};
static BBString _s36={
	&bbStringClass,
	8,
	{76,105,103,104,116,115,58,32}
};
static BBString _s123={
	&bbStringClass,
	22,
	{76,111,97,100,105,110,103,32,102,114,97,103,109,101,110,116,32
	,102,105,108,101,32}
};
static BBString _s122={
	&bbStringClass,
	20,
	{76,111,97,100,105,110,103,32,118,101,114,116,101,120,32,102,105
	,108,101,32}
};
static BBString _s54={
	&bbStringClass,
	6,
	{76,111,99,97,108,58}
};
static BBString _s118={
	&bbStringClass,
	19,
	{77,97,120,32,76,105,103,104,116,115,58,32,32,32,32,32,32
	,32,32}
};
static BBString _s117={
	&bbStringClass,
	19,
	{77,97,120,32,84,101,120,116,117,114,101,32,83,105,122,101,58
	,32,32}
};
static BBString _s116={
	&bbStringClass,
	19,
	{77,97,120,32,84,101,120,116,117,114,101,32,85,110,105,116,115
	,58,32}
};
static BBString _s38={
	&bbStringClass,
	8,
	{77,101,115,104,101,115,58,32}
};
static BBString _s66={
	&bbStringClass,
	6,
	{78,97,109,101,58,32}
};
static BBString _s26={
	&bbStringClass,
	18,
	{78,101,119,32,84,65,110,105,109,97,116,105,111,110,75,101,121
	,115}
};
static BBString _s12={
	&bbStringClass,
	9,
	{78,101,119,32,84,66,111,110,101}
};
static BBString _s24={
	&bbStringClass,
	10,
	{78,101,119,32,84,66,114,117,115,104}
};
static BBString _s2={
	&bbStringClass,
	11,
	{78,101,119,32,84,67,97,109,101,114,97}
};
static BBString _s0={
	&bbStringClass,
	11,
	{78,101,119,32,84,69,110,116,105,116,121}
};
static BBString _s4={
	&bbStringClass,
	10,
	{78,101,119,32,84,76,105,103,104,116}
};
static BBString _s30={
	&bbStringClass,
	11,
	{78,101,119,32,84,77,97,116,114,105,120}
};
static BBString _s8={
	&bbStringClass,
	9,
	{78,101,119,32,84,77,101,115,104}
};
static BBString _s6={
	&bbStringClass,
	10,
	{78,101,119,32,84,80,105,118,111,116}
};
static BBString _s32={
	&bbStringClass,
	15,
	{78,101,119,32,84,81,117,97,116,101,114,110,105,111,110}
};
static BBString _s10={
	&bbStringClass,
	11,
	{78,101,119,32,84,83,112,114,105,116,101}
};
static BBString _s14={
	&bbStringClass,
	12,
	{78,101,119,32,84,83,117,114,102,97,99,101}
};
static BBString _s16={
	&bbStringClass,
	12,
	{78,101,119,32,84,84,101,120,116,117,114,101}
};
static BBString _s28={
	&bbStringClass,
	11,
	{78,101,119,32,84,86,101,99,116,111,114}
};
static BBString _s85={
	&bbStringClass,
	8,
	{78,111,32,98,114,117,115,104}
};
static BBString _s62={
	&bbStringClass,
	10,
	{78,111,32,115,117,114,102,97,99,101}
};
static BBString _s45={
	&bbStringClass,
	1,
	{79}
};
static BBString _s119={
	&bbStringClass,
	18,
	{79,112,101,110,71,76,32,69,120,116,101,110,115,105,111,110,115
	,58}
};
static BBString _s115={
	&bbStringClass,
	16,
	{79,112,101,110,71,76,45,86,101,114,115,105,111,110,58,32}
};
static BBString _s51={
	&bbStringClass,
	7,
	{80,105,116,99,104,58,32}
};
static BBString _s37={
	&bbStringClass,
	8,
	{80,105,118,111,116,115,58,32}
};
static BBString _s142={
	&bbStringClass,
	35,
	{80,114,111,98,108,101,109,32,83,101,116,116,105,110,103,32,85
	,110,105,102,111,114,109,32,40,105,110,116,41,32,86,97,114
	,32,39}
};
static BBString _s139={
	&bbStringClass,
	41,
	{80,114,111,98,108,101,109,32,83,101,116,116,105,110,103,32,85
	,110,105,102,111,114,109,32,70,108,111,97,116,32,65,114,114
	,97,121,32,86,97,114,32,39}
};
static BBString _s141={
	&bbStringClass,
	29,
	{80,114,111,98,108,101,109,32,83,101,116,116,105,110,103,32,85
	,110,105,102,111,114,109,32,86,97,114,32,39}
};
static BBString _s67={
	&bbStringClass,
	5,
	{82,101,100,58,32}
};
static BBString _s114={
	&bbStringClass,
	16,
	{82,101,110,100,101,114,101,114,58,32,32,32,32,32,32,32}
};
static BBString _s53={
	&bbStringClass,
	6,
	{82,111,108,108,58,32}
};
static BBString _s39={
	&bbStringClass,
	9,
	{83,112,114,105,116,101,115,58,32}
};
static BBString _s61={
	&bbStringClass,
	11,
	{83,117,114,102,32,86,109,97,120,58,32}
};
static BBString _s60={
	&bbStringClass,
	11,
	{83,117,114,102,32,86,109,105,110,58,32}
};
static BBString _s56={
	&bbStringClass,
	8,
	{83,117,114,102,97,99,101,32}
};
static BBString _s75={
	&bbStringClass,
	12,
	{84,101,120,48,32,66,108,101,110,100,58,32}
};
static BBString _s74={
	&bbStringClass,
	12,
	{84,101,120,48,32,70,108,97,103,115,58,32}
};
static BBString _s73={
	&bbStringClass,
	11,
	{84,101,120,48,32,78,97,109,101,58,32}
};
static BBString _s78={
	&bbStringClass,
	12,
	{84,101,120,49,32,66,108,101,110,100,58,32}
};
static BBString _s77={
	&bbStringClass,
	12,
	{84,101,120,49,32,70,108,97,103,115,58,32}
};
static BBString _s76={
	&bbStringClass,
	11,
	{84,101,120,49,32,78,97,109,101,58,32}
};
static BBString _s81={
	&bbStringClass,
	12,
	{84,101,120,50,32,66,108,101,110,100,58,32}
};
static BBString _s80={
	&bbStringClass,
	12,
	{84,101,120,50,32,70,108,97,103,115,58,32}
};
static BBString _s79={
	&bbStringClass,
	11,
	{84,101,120,50,32,78,97,109,101,58,32}
};
static BBString _s84={
	&bbStringClass,
	12,
	{84,101,120,51,32,66,108,101,110,100,58,32}
};
static BBString _s83={
	&bbStringClass,
	12,
	{84,101,120,51,32,70,108,97,103,115,58,32}
};
static BBString _s82={
	&bbStringClass,
	11,
	{84,101,120,51,32,78,97,109,101,58,32}
};
static BBString _s58={
	&bbStringClass,
	11,
	{84,114,105,97,110,103,108,101,115,58,32}
};
static BBString _s113={
	&bbStringClass,
	16,
	{86,101,110,100,111,114,58,32,32,32,32,32,32,32,32,32}
};
static BBString _s57={
	&bbStringClass,
	10,
	{86,101,114,116,105,99,101,115,58,32}
};
static BBString _s109={
	&bbStringClass,
	8,
	{87,105,100,116,104,58,32,32}
};
static BBString _s44={
	&bbStringClass,
	1,
	{88}
};
static BBString _s48={
	&bbStringClass,
	3,
	{88,58,32}
};
static BBString _s49={
	&bbStringClass,
	3,
	{89,58,32}
};
static BBString _s52={
	&bbStringClass,
	5,
	{89,97,119,58,32}
};
static BBString _s50={
	&bbStringClass,
	3,
	{90,58,32}
};
static BBString _s20={
	&bbStringClass,
	1,
	{92}
};
static BBString _s129={
	&bbStringClass,
	10,
	{99,111,109,112,105,108,101,32,111,107}
};
static BBString _s128={
	&bbStringClass,
	21,
	{99,111,109,112,105,108,105,110,103,32,102,114,97,103,109,101,110
	,116,46,46,46}
};
static BBString _s126={
	&bbStringClass,
	19,
	{99,111,109,112,105,108,105,110,103,32,118,101,114,116,101,120,46
	,46,46}
};
static BBString _s19={
	&bbStringClass,
	4,
	{106,112,101,103}
};
static BBString _s18={
	&bbStringClass,
	3,
	{106,112,103}
};
static BBString _s132={
	&bbStringClass,
	6,
	{108,105,110,107,32,50}
};
static BBString _s133={
	&bbStringClass,
	6,
	{108,105,110,107,32,51}
};
static BBString _s127={
	&bbStringClass,
	19,
	{108,111,97,100,105,110,103,32,102,114,97,103,109,101,110,116,46
	,46,46}
};
static BBString _s125={
	&bbStringClass,
	17,
	{108,111,97,100,105,110,103,32,118,101,114,116,101,120,46,46,46
}
};
struct BBDebugScope_12{int kind; const char *name; BBDebugDecl decls[13]; };
struct BBDebugScope_15{int kind; const char *name; BBDebugDecl decls[16]; };
struct BBDebugScope_16{int kind; const char *name; BBDebugDecl decls[17]; };
struct BBDebugScope_18{int kind; const char *name; BBDebugDecl decls[19]; };
struct BBDebugScope_185{int kind; const char *name; BBDebugDecl decls[186]; };
struct BBDebugScope_2{int kind; const char *name; BBDebugDecl decls[3]; };
struct BBDebugScope_20{int kind; const char *name; BBDebugDecl decls[21]; };
struct BBDebugScope_21{int kind; const char *name; BBDebugDecl decls[22]; };
struct BBDebugScope_3{int kind; const char *name; BBDebugDecl decls[4]; };
struct BBDebugScope_30{int kind; const char *name; BBDebugDecl decls[31]; };
struct BBDebugScope_31{int kind; const char *name; BBDebugDecl decls[32]; };
struct BBDebugScope_32{int kind; const char *name; BBDebugDecl decls[33]; };
struct BBDebugScope_33{int kind; const char *name; BBDebugDecl decls[34]; };
struct BBDebugScope_34{int kind; const char *name; BBDebugDecl decls[35]; };
struct BBDebugScope_37{int kind; const char *name; BBDebugDecl decls[38]; };
struct BBDebugScope_39{int kind; const char *name; BBDebugDecl decls[40]; };
struct BBDebugScope_4{int kind; const char *name; BBDebugDecl decls[5]; };
struct BBDebugScope_44{int kind; const char *name; BBDebugDecl decls[45]; };
struct BBDebugScope_5{int kind; const char *name; BBDebugDecl decls[6]; };
struct BBDebugScope_6{int kind; const char *name; BBDebugDecl decls[7]; };
struct BBDebugScope_65{int kind; const char *name; BBDebugDecl decls[66]; };
struct BBDebugScope_7{int kind; const char *name; BBDebugDecl decls[8]; };
struct BBDebugScope_71{int kind; const char *name; BBDebugDecl decls[72]; };
struct BBDebugScope_75{int kind; const char *name; BBDebugDecl decls[76]; };
struct BBDebugScope_8{int kind; const char *name; BBDebugDecl decls[9]; };
void _openb3d_openb3dex_TGlobal_New(struct openb3d_openb3dex_TGlobal_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TGlobal;
}
BBINT openb3d_openb3dex_TGlobal_InitGlobals_i(){
	openb3d_openb3dex_TGlobal_width=StaticInt(21,1);
	openb3d_openb3dex_TGlobal_height=StaticInt(21,2);
	openb3d_openb3dex_TGlobal_Mode=StaticInt(21,3);
	openb3d_openb3dex_TGlobal_depth=StaticInt(21,4);
	openb3d_openb3dex_TGlobal_rate=StaticInt(21,5);
	openb3d_openb3dex_TGlobal_ambient_red=StaticFloat(21,6);
	openb3d_openb3dex_TGlobal_ambient_green=StaticFloat(21,7);
	openb3d_openb3dex_TGlobal_ambient_blue=StaticFloat(21,8);
	openb3d_openb3dex_TGlobal_vbo_enabled=StaticInt(21,10);
	openb3d_openb3dex_TGlobal_vbo_min_tris=StaticInt(21,11);
	openb3d_openb3dex_TGlobal_Shadows_enabled=StaticInt(21,12);
	openb3d_openb3dex_TGlobal_anim_speed=StaticFloat(21,13);
	openb3d_openb3dex_TGlobal_fog_enabled=StaticInt(21,14);
	openb3d_openb3dex_TGlobal_root_ent=openb3d_openb3dex_TPivot_CreateObject_TTPivot_pb(StaticPivot(21,15));
	openb3d_openb3dex_TGlobal_alpha_enable=StaticInt(21,17);
	openb3d_openb3dex_TGlobal_blend_mode=StaticInt(21,18);
	openb3d_openb3dex_TGlobal_fx1=StaticInt(21,19);
	openb3d_openb3dex_TGlobal_fx2=StaticInt(21,20);
	openb3d_openb3dex_TCamera_InitGlobals_i();
	openb3d_openb3dex_TEntity_InitGlobals_i();
	openb3d_openb3dex_TLight_InitGlobals_i();
	openb3d_openb3dex_TPick_InitGlobals_i();
	openb3d_openb3dex_TShadowObject_InitGlobals_i();
	openb3d_openb3dex_TTerrain_InitGlobals_i();
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_CopyList_i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TCamera_cam_list){
		openb3d_openb3dex_TCamera_CopyList__i_TTList(openb3d_openb3dex_TCamera_cam_list);
	}else{
		if(bbt_==openb3d_openb3dex_TEntity_entity_list){
			openb3d_openb3dex_TEntity_CopyList__i_TTList(openb3d_openb3dex_TEntity_entity_list);
		}else{
			if(bbt_==openb3d_openb3dex_TEntity_animate_list){
				openb3d_openb3dex_TEntity_CopyList__i_TTList(openb3d_openb3dex_TEntity_animate_list);
			}else{
				if(bbt_==openb3d_openb3dex_TLight_light_list){
					openb3d_openb3dex_TLight_CopyList__i_TTList(openb3d_openb3dex_TLight_light_list);
				}else{
					if(bbt_==openb3d_openb3dex_TPick_ent_list){
						openb3d_openb3dex_TPick_CopyList__i_TTList(openb3d_openb3dex_TPick_ent_list);
					}else{
						if(bbt_==openb3d_openb3dex_TShadowObject_shadow_list){
							openb3d_openb3dex_TShadowObject_CopyList__i_TTList(openb3d_openb3dex_TShadowObject_shadow_list);
						}else{
							if(bbt_==openb3d_openb3dex_TTerrain_terrain_list){
								openb3d_openb3dex_TTerrain_CopyList__i_TTList(openb3d_openb3dex_TTerrain_terrain_list);
							}else{
								if(bbt_==openb3d_openb3dex_TTexture_tex_list){
									openb3d_openb3dex_TTexture_CopyList__i_TTList(openb3d_openb3dex_TTexture_tex_list);
								}
							}
						}
					}
				}
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_ListPushBack_i_TTListTObjectTTEntity(struct brl_linkedlist_TList_obj* bbt_list,BBOBJECT bbt_value,struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_mesh=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh));
	if(bbt_mesh!= &bbNullObject){
		(bbt_mesh)->clas->m_ListPushBack_TTListTObject(bbt_mesh,bbt_list,bbt_value);
	}else{
		(bbt_ent)->clas->m_ListPushBack_TTListTObject(bbt_ent,bbt_list,bbt_value);
	}
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_Graphics3D_i_iiiiiii(BBINT bbt_w,BBINT bbt_h,BBINT bbt_d,BBINT bbt_m,BBINT bbt_r,BBINT bbt_flags,BBINT bbt_usecanvas){
	BBINT bbt_=bbt_flags;
	if(bbt_==-1){
		bbt_flags=62;
	}else{
		if(bbt_==-2){
			bbt_flags=30;
		}else{
			if(bbt_==-3){
				bbt_flags=6;
			}else{
				if(bbt_==-4){
					bbt_flags=10;
				}else{
					if(bbt_==-5){
						bbt_flags=18;
					}else{
						if(bbt_==-6){
							bbt_flags=34;
						}else{
							bbt_flags=2;
						}
					}
				}
			}
		}
	}
	openb3d_openb3dex_TGlobal_InitGlobals_i();
	openb3d_openb3dex_TGlobal_width[0U]=bbt_w;
	openb3d_openb3dex_TGlobal_height[0U]=bbt_h;
	openb3d_openb3dex_TGlobal_depth[0U]=bbt_d;
	openb3d_openb3dex_TGlobal_Mode[0U]=bbt_m;
	openb3d_openb3dex_TGlobal_rate[0U]=bbt_r;
	brl_graphics_SetGraphicsDriver(((struct brl_graphics_TGraphicsDriver_obj*)bbObjectDowncast(brl_glmax2d_GLMax2DDriver(),&brl_graphics_TGraphicsDriver)),bbt_flags);
	if(bbt_usecanvas==0){
		openb3d_openb3dex_TGlobal_gfx=brl_graphics_Graphics(bbt_w,bbt_h,bbt_d,bbt_r,bbt_flags);
	}
	openb3d_openb3dex_TGlobal_GraphicsInit_i();
	Graphics3D(bbt_w,bbt_h,bbt_d,bbt_m,bbt_r);
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_GraphicsInit_i(){
	openb3d_openb3dex_TextureFilter(&bbEmptyString,9);
	glewInit();
	openb3d_openb3dex_THardwareInfo_GetInfo_i();
	openb3d_openb3dex_TGlobal_vbo_enabled[0U]=openb3d_openb3dex_THardwareInfo_VBOSupport;
	glPushAttrib((GLbitfield)1048575);
	glPushClientAttrib((GLbitfield)-1);
	glMatrixMode((GLenum)5888);
	glPushMatrix();
	glMatrixMode((GLenum)5889);
	glPushMatrix();
	glMatrixMode((GLenum)5890);
	glPushMatrix();
	glMatrixMode((GLenum)6144);
	glPushMatrix();
	openb3d_openb3dex_TGlobal_EnableStates_i();
	glLightModeli((GLenum)33272,(GLint)33274);
	glLightModeli((GLenum)2897,(GLint)1);
	glClearDepth((GLclampd)1.0000000000000000);
	glDepthFunc((GLenum)515);
	glHint((GLenum)3152,(GLenum)4354);
	glAlphaFunc((GLenum)518,(GLclampf)0.5f);
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_EnableStates_i(){
	glEnable((GLenum)2896);
	glEnable((GLenum)2929);
	glEnable((GLenum)2912);
	glEnable((GLenum)2884);
	glEnable((GLenum)3089);
	glEnable((GLenum)2977);
	glEnableClientState((GLenum)32884);
	glEnableClientState((GLenum)32886);
	glEnableClientState((GLenum)32885);
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_Wireframe_i_i(BBINT bbt_enable){
	Wireframe(bbt_enable);
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_AmbientLight_i_fff(BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	AmbientLight(bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_ClearCollisions_i(){
	ClearCollisions();
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_Collisions_i_iiii(BBINT bbt_src_no,BBINT bbt_dest_no,BBINT bbt_method_no,BBINT bbt_response_no){
	Collisions(bbt_src_no,bbt_dest_no,bbt_method_no,bbt_response_no);
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_ClearWorld_i_iii(BBINT bbt_entities,BBINT bbt_brushes,BBINT bbt_textures){
	if(bbt_entities!=0){
		brl_linkedlist_ClearList(openb3d_openb3dex_TGlobal_root_ent->_openb3d_openb3dex_tentity_child_list );
		openb3d_openb3dex_TGlobal_root_ent->_openb3d_openb3dex_tentity_child_list_id =0;
		brl_linkedlist_ClearList(openb3d_openb3dex_TEntity_entity_list);
		openb3d_openb3dex_TEntity_entity_list_id=0;
		brl_linkedlist_ClearList(openb3d_openb3dex_TEntity_animate_list);
		openb3d_openb3dex_TEntity_animate_list_id=0;
		brl_linkedlist_ClearList(openb3d_openb3dex_TCamera_cam_list);
		openb3d_openb3dex_TCamera_cam_list_id=0;
		brl_linkedlist_ClearList(openb3d_openb3dex_TPick_ent_list);
		openb3d_openb3dex_TPick_ent_list_id=0;
	}
	if(bbt_textures!=0){
		struct brl_linkedlist_TListEnum_obj* volatile bbt_=(openb3d_openb3dex_TTexture_tex_list)->clas->m_ObjectEnumerator(openb3d_openb3dex_TTexture_tex_list);
		while((bbt_)->clas->m_HasNext(bbt_)!=0){
			struct openb3d_openb3dex_TTexture_obj* volatile bbt_tex=((struct openb3d_openb3dex_TTexture_obj*)bbObjectDowncast((bbt_)->clas->m_NextObject(bbt_),&openb3d_openb3dex_TTexture));
			if(bbt_tex==&bbNullObject){
				continue;
			}
			openb3d_openb3dex_TTexture_FreeObject_i_pb(openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex));
		}
		brl_linkedlist_ClearList(openb3d_openb3dex_TTexture_tex_list);
		openb3d_openb3dex_TTexture_tex_list_id=0;
	}
	ClearWorld(bbt_entities,bbt_brushes,bbt_textures);
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_UpdateWorld_i_f(BBFLOAT bbt_anim_speed){
	UpdateWorld(bbt_anim_speed);
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_RenderWorld_i(){
	RenderWorld();
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_RenderCamera_i_TTCamera(struct openb3d_openb3dex_TCamera_obj* bbt_cam){
	CameraRender(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_cam,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT openb3d_openb3dex_TGlobal_UpdateEntityAnim_i_TTMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	UpdateEntityAnim(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT* openb3d_openb3dex_TGlobal_alpha_enable;
BBINT* openb3d_openb3dex_TGlobal_blend_mode;
BBINT* openb3d_openb3dex_TGlobal_fx1;
BBINT* openb3d_openb3dex_TGlobal_fx2;
struct openb3d_openb3dex_TCamera_obj* openb3d_openb3dex_TGlobal_camera_in_use;
BBINT* openb3d_openb3dex_TGlobal_fog_enabled;
struct openb3d_openb3dex_TPivot_obj* openb3d_openb3dex_TGlobal_root_ent;
BBINT* openb3d_openb3dex_TGlobal_Shadows_enabled;
BBINT* openb3d_openb3dex_TGlobal_height;
struct openb3d_openb3dex_TShader_obj* openb3d_openb3dex_TGlobal_ambient_shader;
BBINT* openb3d_openb3dex_TGlobal_width;
BBINT* openb3d_openb3dex_TGlobal_Mode;
BBINT* openb3d_openb3dex_TGlobal_depth;
BBINT* openb3d_openb3dex_TGlobal_rate;
BBFLOAT* openb3d_openb3dex_TGlobal_ambient_red;
BBFLOAT* openb3d_openb3dex_TGlobal_ambient_green;
BBFLOAT* openb3d_openb3dex_TGlobal_ambient_blue;
BBINT* openb3d_openb3dex_TGlobal_vbo_enabled;
BBINT* openb3d_openb3dex_TGlobal_vbo_min_tris;
BBFLOAT* openb3d_openb3dex_TGlobal_anim_speed;
struct brl_graphics_TGraphics_obj* openb3d_openb3dex_TGlobal_gfx;
struct BBDebugScope_37 openb3d_openb3dex_TGlobal_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TGlobal",
	{
		{
			BBDEBUGDECL_GLOBAL,
			"width",
			"*i",
			&openb3d_openb3dex_TGlobal_width
		},
		{
			BBDEBUGDECL_GLOBAL,
			"height",
			"*i",
			&openb3d_openb3dex_TGlobal_height
		},
		{
			BBDEBUGDECL_GLOBAL,
			"Mode",
			"*i",
			&openb3d_openb3dex_TGlobal_Mode
		},
		{
			BBDEBUGDECL_GLOBAL,
			"depth",
			"*i",
			&openb3d_openb3dex_TGlobal_depth
		},
		{
			BBDEBUGDECL_GLOBAL,
			"rate",
			"*i",
			&openb3d_openb3dex_TGlobal_rate
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ambient_red",
			"*f",
			&openb3d_openb3dex_TGlobal_ambient_red
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ambient_green",
			"*f",
			&openb3d_openb3dex_TGlobal_ambient_green
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ambient_blue",
			"*f",
			&openb3d_openb3dex_TGlobal_ambient_blue
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ambient_shader",
			":TShader",
			&openb3d_openb3dex_TGlobal_ambient_shader
		},
		{
			BBDEBUGDECL_GLOBAL,
			"vbo_enabled",
			"*i",
			&openb3d_openb3dex_TGlobal_vbo_enabled
		},
		{
			BBDEBUGDECL_GLOBAL,
			"vbo_min_tris",
			"*i",
			&openb3d_openb3dex_TGlobal_vbo_min_tris
		},
		{
			BBDEBUGDECL_GLOBAL,
			"Shadows_enabled",
			"*i",
			&openb3d_openb3dex_TGlobal_Shadows_enabled
		},
		{
			BBDEBUGDECL_GLOBAL,
			"anim_speed",
			"*f",
			&openb3d_openb3dex_TGlobal_anim_speed
		},
		{
			BBDEBUGDECL_GLOBAL,
			"fog_enabled",
			"*i",
			&openb3d_openb3dex_TGlobal_fog_enabled
		},
		{
			BBDEBUGDECL_GLOBAL,
			"root_ent",
			":TPivot",
			&openb3d_openb3dex_TGlobal_root_ent
		},
		{
			BBDEBUGDECL_GLOBAL,
			"camera_in_use",
			":TCamera",
			&openb3d_openb3dex_TGlobal_camera_in_use
		},
		{
			BBDEBUGDECL_GLOBAL,
			"alpha_enable",
			"*i",
			&openb3d_openb3dex_TGlobal_alpha_enable
		},
		{
			BBDEBUGDECL_GLOBAL,
			"blend_mode",
			"*i",
			&openb3d_openb3dex_TGlobal_blend_mode
		},
		{
			BBDEBUGDECL_GLOBAL,
			"fx1",
			"*i",
			&openb3d_openb3dex_TGlobal_fx1
		},
		{
			BBDEBUGDECL_GLOBAL,
			"fx2",
			"*i",
			&openb3d_openb3dex_TGlobal_fx2
		},
		{
			BBDEBUGDECL_GLOBAL,
			"gfx",
			":TGraphics",
			&openb3d_openb3dex_TGlobal_gfx
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TGlobal_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"InitGlobals",
			"()i",
			&openb3d_openb3dex_TGlobal_InitGlobals_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList",
			"(:TList)i",
			&openb3d_openb3dex_TGlobal_CopyList_i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ListPushBack",
			"(:TList,:Object,:TEntity)i",
			&openb3d_openb3dex_TGlobal_ListPushBack_i_TTListTObjectTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Graphics3D",
			"(i,i,i,i,i,i,i)i",
			&openb3d_openb3dex_TGlobal_Graphics3D_i_iiiiiii
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GraphicsInit",
			"()i",
			&openb3d_openb3dex_TGlobal_GraphicsInit_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"EnableStates",
			"()i",
			&openb3d_openb3dex_TGlobal_EnableStates_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Wireframe",
			"(i)i",
			&openb3d_openb3dex_TGlobal_Wireframe_i_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AmbientLight",
			"(f,f,f)i",
			&openb3d_openb3dex_TGlobal_AmbientLight_i_fff
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ClearCollisions",
			"()i",
			&openb3d_openb3dex_TGlobal_ClearCollisions_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Collisions",
			"(i,i,i,i)i",
			&openb3d_openb3dex_TGlobal_Collisions_i_iiii
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ClearWorld",
			"(i,i,i)i",
			&openb3d_openb3dex_TGlobal_ClearWorld_i_iii
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UpdateWorld",
			"(f)i",
			&openb3d_openb3dex_TGlobal_UpdateWorld_i_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"RenderWorld",
			"()i",
			&openb3d_openb3dex_TGlobal_RenderWorld_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"RenderCamera",
			"(:TCamera)i",
			&openb3d_openb3dex_TGlobal_RenderCamera_i_TTCamera
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UpdateEntityAnim",
			"(:TMesh)i",
			&openb3d_openb3dex_TGlobal_UpdateEntityAnim_i_TTMesh
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TGlobal openb3d_openb3dex_TGlobal={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TGlobal_scope,
	sizeof(struct openb3d_openb3dex_TGlobal_obj),
	_openb3d_openb3dex_TGlobal_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,openb3d_openb3dex_TGlobal_InitGlobals_i
	,openb3d_openb3dex_TGlobal_CopyList_i_TTList
	,openb3d_openb3dex_TGlobal_ListPushBack_i_TTListTObjectTTEntity
	,openb3d_openb3dex_TGlobal_Graphics3D_i_iiiiiii
	,openb3d_openb3dex_TGlobal_GraphicsInit_i
	,openb3d_openb3dex_TGlobal_EnableStates_i
	,openb3d_openb3dex_TGlobal_Wireframe_i_i
	,openb3d_openb3dex_TGlobal_AmbientLight_i_fff
	,openb3d_openb3dex_TGlobal_ClearCollisions_i
	,openb3d_openb3dex_TGlobal_Collisions_i_iiii
	,openb3d_openb3dex_TGlobal_ClearWorld_i_iii
	,openb3d_openb3dex_TGlobal_UpdateWorld_i_f
	,openb3d_openb3dex_TGlobal_RenderWorld_i
	,openb3d_openb3dex_TGlobal_RenderCamera_i_TTCamera
	,openb3d_openb3dex_TGlobal_UpdateEntityAnim_i_TTMesh
};

void _openb3d_openb3dex_TEntity_New(struct openb3d_openb3dex_TEntity_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TEntity;
	o->_openb3d_openb3dex_tentity_child_list = brl_linkedlist_CreateList();
	o->_openb3d_openb3dex_tentity_parent = &bbNullObject;
	o->_openb3d_openb3dex_tentity_mat = &bbNullObject;
	o->_openb3d_openb3dex_tentity_rotmat = &bbNullObject;
	o->_openb3d_openb3dex_tentity_px = 0;
	o->_openb3d_openb3dex_tentity_py = 0;
	o->_openb3d_openb3dex_tentity_pz = 0;
	o->_openb3d_openb3dex_tentity_sx = 0;
	o->_openb3d_openb3dex_tentity_sy = 0;
	o->_openb3d_openb3dex_tentity_sz = 0;
	o->_openb3d_openb3dex_tentity_rx = 0;
	o->_openb3d_openb3dex_tentity_ry = 0;
	o->_openb3d_openb3dex_tentity_rz = 0;
	o->_openb3d_openb3dex_tentity_qw = 0;
	o->_openb3d_openb3dex_tentity_qx = 0;
	o->_openb3d_openb3dex_tentity_qy = 0;
	o->_openb3d_openb3dex_tentity_qz = 0;
	o->_openb3d_openb3dex_tentity_brush = &bbNullObject;
	o->_openb3d_openb3dex_tentity_order = 0;
	o->_openb3d_openb3dex_tentity_alpha_order = 0;
	o->_openb3d_openb3dex_tentity_hide = 0;
	o->_openb3d_openb3dex_tentity_cull_radius = 0;
	o->_openb3d_openb3dex_tentity_name = 0;
	o->_openb3d_openb3dex_tentity_class_name = 0;
	o->_openb3d_openb3dex_tentity_anim = 0;
	o->_openb3d_openb3dex_tentity_anim_render = 0;
	o->_openb3d_openb3dex_tentity_anim_mode = 0;
	o->_openb3d_openb3dex_tentity_anim_time = 0;
	o->_openb3d_openb3dex_tentity_anim_speed = 0;
	o->_openb3d_openb3dex_tentity_anim_seq = 0;
	o->_openb3d_openb3dex_tentity_anim_trans = 0;
	o->_openb3d_openb3dex_tentity_anim_dir = 0;
	o->_openb3d_openb3dex_tentity_anim_seqs_first = 0;
	o->_openb3d_openb3dex_tentity_anim_seqs_last = 0;
	o->_openb3d_openb3dex_tentity_no_seqs = 0;
	o->_openb3d_openb3dex_tentity_anim_update = 0;
	o->_openb3d_openb3dex_tentity_anim_list = 0;
	o->_openb3d_openb3dex_tentity_collision_type = 0;
	o->_openb3d_openb3dex_tentity_radius_x = 0;
	o->_openb3d_openb3dex_tentity_radius_y = 0;
	o->_openb3d_openb3dex_tentity_box_x = 0;
	o->_openb3d_openb3dex_tentity_box_y = 0;
	o->_openb3d_openb3dex_tentity_box_z = 0;
	o->_openb3d_openb3dex_tentity_box_w = 0;
	o->_openb3d_openb3dex_tentity_box_h = 0;
	o->_openb3d_openb3dex_tentity_box_d = 0;
	o->_openb3d_openb3dex_tentity_no_collisions = 0;
	o->_openb3d_openb3dex_tentity_old_x = 0;
	o->_openb3d_openb3dex_tentity_old_y = 0;
	o->_openb3d_openb3dex_tentity_old_z = 0;
	o->_openb3d_openb3dex_tentity_old_pitch = 0;
	o->_openb3d_openb3dex_tentity_old_yaw = 0;
	o->_openb3d_openb3dex_tentity_old_roll = 0;
	o->_openb3d_openb3dex_tentity_new_x = 0;
	o->_openb3d_openb3dex_tentity_new_y = 0;
	o->_openb3d_openb3dex_tentity_new_z = 0;
	o->_openb3d_openb3dex_tentity_new_no = 0;
	o->_openb3d_openb3dex_tentity_old_mat = &bbNullObject;
	o->_openb3d_openb3dex_tentity_dynamic = 0;
	o->_openb3d_openb3dex_tentity_dynamic_x = 0;
	o->_openb3d_openb3dex_tentity_dynamic_y = 0;
	o->_openb3d_openb3dex_tentity_dynamic_z = 0;
	o->_openb3d_openb3dex_tentity_dynamic_yaw = 0;
	o->_openb3d_openb3dex_tentity_dynamic_pitch = 0;
	o->_openb3d_openb3dex_tentity_dynamic_roll = 0;
	o->_openb3d_openb3dex_tentity_pick_mode = 0;
	o->_openb3d_openb3dex_tentity_obscurer = 0;
	o->_openb3d_openb3dex_tentity_instance = 0;
	o->_openb3d_openb3dex_tentity_child_list_id = 0;
	o->_openb3d_openb3dex_tentity_exists = 0;
}
void _openb3d_openb3dex_TEntity_Delete(struct openb3d_openb3dex_TEntity_obj* o) {
	bbObjectDtor(o);
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_CopyEntity_TTEntity(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	printf("Abstract method called : CopyEntity\n");fflush(stdout);
	brl_blitz_NullMethodError();
}
BBINT _openb3d_openb3dex_TEntity_Update(struct openb3d_openb3dex_TEntity_obj* o){
	printf("Abstract method called : Update\n");fflush(stdout);
	brl_blitz_NullMethodError();
}
BBINT openb3d_openb3dex_TEntity_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Remove_TObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast((openb3d_openb3dex_TEntity_ent_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TEntity));
}
BBBYTE* openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tentity_instance ;
}
BBINT openb3d_openb3dex_TEntity_InitGlobals_i(){
	openb3d_openb3dex_TEntity_tformed_x=StaticFloat(12,71);
	openb3d_openb3dex_TEntity_tformed_y=StaticFloat(12,72);
	openb3d_openb3dex_TEntity_tformed_z=StaticFloat(12,73);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_InitFields(struct openb3d_openb3dex_TEntity_obj* o){
	o->_openb3d_openb3dex_tentity_order =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),20);
	o->_openb3d_openb3dex_tentity_hide =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),22);
	o->_openb3d_openb3dex_tentity_anim =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),27);
	o->_openb3d_openb3dex_tentity_anim_render =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),28);
	o->_openb3d_openb3dex_tentity_anim_mode =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),29);
	o->_openb3d_openb3dex_tentity_anim_seq =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),32);
	o->_openb3d_openb3dex_tentity_anim_trans =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),33);
	o->_openb3d_openb3dex_tentity_anim_dir =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),34);
	o->_openb3d_openb3dex_tentity_anim_seqs_first =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),35);
	o->_openb3d_openb3dex_tentity_anim_seqs_last =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),36);
	o->_openb3d_openb3dex_tentity_no_seqs =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),37);
	o->_openb3d_openb3dex_tentity_anim_update =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),38);
	o->_openb3d_openb3dex_tentity_anim_list =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),39);
	o->_openb3d_openb3dex_tentity_collision_type =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),40);
	o->_openb3d_openb3dex_tentity_no_collisions =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),49);
	o->_openb3d_openb3dex_tentity_new_no =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),60);
	o->_openb3d_openb3dex_tentity_dynamic =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),62);
	o->_openb3d_openb3dex_tentity_pick_mode =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),69);
	o->_openb3d_openb3dex_tentity_obscurer =EntityInt(o->clas->f_GetInstance_pb_TTEntity(o),70);
	o->_openb3d_openb3dex_tentity_px =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),6);
	o->_openb3d_openb3dex_tentity_py =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),7);
	o->_openb3d_openb3dex_tentity_pz =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),8);
	o->_openb3d_openb3dex_tentity_sx =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),9);
	o->_openb3d_openb3dex_tentity_sy =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),10);
	o->_openb3d_openb3dex_tentity_sz =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),11);
	o->_openb3d_openb3dex_tentity_rx =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),12);
	o->_openb3d_openb3dex_tentity_ry =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),13);
	o->_openb3d_openb3dex_tentity_rz =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),14);
	o->_openb3d_openb3dex_tentity_qw =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),15);
	o->_openb3d_openb3dex_tentity_qx =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),16);
	o->_openb3d_openb3dex_tentity_qy =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),17);
	o->_openb3d_openb3dex_tentity_qz =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),18);
	o->_openb3d_openb3dex_tentity_alpha_order =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),21);
	o->_openb3d_openb3dex_tentity_cull_radius =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),23);
	o->_openb3d_openb3dex_tentity_anim_time =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),30);
	o->_openb3d_openb3dex_tentity_anim_speed =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),31);
	o->_openb3d_openb3dex_tentity_radius_x =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),41);
	o->_openb3d_openb3dex_tentity_radius_y =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),42);
	o->_openb3d_openb3dex_tentity_box_x =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),43);
	o->_openb3d_openb3dex_tentity_box_y =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),44);
	o->_openb3d_openb3dex_tentity_box_z =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),45);
	o->_openb3d_openb3dex_tentity_box_w =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),46);
	o->_openb3d_openb3dex_tentity_box_h =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),47);
	o->_openb3d_openb3dex_tentity_box_d =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),48);
	o->_openb3d_openb3dex_tentity_old_x =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),51);
	o->_openb3d_openb3dex_tentity_old_y =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),52);
	o->_openb3d_openb3dex_tentity_old_z =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),53);
	o->_openb3d_openb3dex_tentity_old_pitch =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),54);
	o->_openb3d_openb3dex_tentity_old_yaw =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),55);
	o->_openb3d_openb3dex_tentity_old_roll =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),56);
	o->_openb3d_openb3dex_tentity_new_x =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),57);
	o->_openb3d_openb3dex_tentity_new_y =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),58);
	o->_openb3d_openb3dex_tentity_new_z =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),59);
	o->_openb3d_openb3dex_tentity_dynamic_x =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),63);
	o->_openb3d_openb3dex_tentity_dynamic_y =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),64);
	o->_openb3d_openb3dex_tentity_dynamic_z =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),65);
	o->_openb3d_openb3dex_tentity_dynamic_yaw =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),66);
	o->_openb3d_openb3dex_tentity_dynamic_pitch =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),67);
	o->_openb3d_openb3dex_tentity_dynamic_roll =EntityFloat(o->clas->f_GetInstance_pb_TTEntity(o),68);
	o->_openb3d_openb3dex_tentity_name =EntityString(o->clas->f_GetInstance_pb_TTEntity(o),24);
	o->_openb3d_openb3dex_tentity_class_name =EntityString(o->clas->f_GetInstance_pb_TTEntity(o),25);
	BBBYTE* bbt_inst=EntityEntity(o->clas->f_GetInstance_pb_TTEntity(o),3);
	o->_openb3d_openb3dex_tentity_parent =o->clas->f_GetObject_TTEntity_pb(bbt_inst);
	bbt_inst=EntityMatrix(o->clas->f_GetInstance_pb_TTEntity(o),4);
	o->_openb3d_openb3dex_tentity_mat =openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tentity_mat ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tentity_mat =openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb(bbt_inst);
	}
	bbt_inst=EntityMatrix(o->clas->f_GetInstance_pb_TTEntity(o),5);
	o->_openb3d_openb3dex_tentity_rotmat =openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tentity_rotmat ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tentity_rotmat =openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb(bbt_inst);
	}
	bbt_inst=EntityMatrix(o->clas->f_GetInstance_pb_TTEntity(o),61);
	o->_openb3d_openb3dex_tentity_old_mat =openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tentity_old_mat ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tentity_old_mat =openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb(bbt_inst);
	}
	bbt_inst=EntityBrush(o->clas->f_GetInstance_pb_TTEntity(o),19);
	o->_openb3d_openb3dex_tentity_brush =openb3d_openb3dex_TBrush_GetObject_TTBrush_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tentity_brush ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tentity_brush =openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(bbt_inst);
	}
	o->clas->f_AddList__i_TTList(openb3d_openb3dex_TEntity_entity_list);
	((struct openb3d_openb3dex_TEntity_obj*)o)->clas->m_CopyList_TTList(o,o->_openb3d_openb3dex_tentity_child_list );
	o->clas->f_AddList__i_TTList(openb3d_openb3dex_TEntity_animate_list);
	if(openb3d_openb3dex_TGlobal_root_ent!= &bbNullObject){
		((struct openb3d_openb3dex_TEntity_obj*)o)->clas->m_AddList_TTList(o,openb3d_openb3dex_TGlobal_root_ent->_openb3d_openb3dex_tentity_child_list );
	}
	o->_openb3d_openb3dex_tentity_exists =1;
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_AddList_TTList(struct openb3d_openb3dex_TEntity_obj* o,struct brl_linkedlist_TList_obj* bbt_list){
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==o->_openb3d_openb3dex_tentity_child_list ){
		if(EntityListSize(o->clas->f_GetInstance_pb_TTEntity(o),2)!=0){
			BBBYTE* bbt_inst=EntityIterListEntity(o->clas->f_GetInstance_pb_TTEntity(o),2,(&o->_openb3d_openb3dex_tentity_child_list_id ));
			struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj=o->clas->f_GetObject_TTEntity_pb(bbt_inst);
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}else{
		if(bbt_==openb3d_openb3dex_TGlobal_root_ent->_openb3d_openb3dex_tentity_child_list ){
			if(EntityListSize(o->clas->f_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(openb3d_openb3dex_TGlobal_root_ent,&openb3d_openb3dex_TEntity)),2)!=0){
				BBBYTE* bbt_inst2=EntityIterListEntity(o->clas->f_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(openb3d_openb3dex_TGlobal_root_ent,&openb3d_openb3dex_TEntity)),2,(&openb3d_openb3dex_TGlobal_root_ent->_openb3d_openb3dex_tentity_child_list_id ));
				struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj2=o->clas->f_GetObject_TTEntity_pb(bbt_inst2);
				if((bbt_obj2!= &bbNullObject) && (brl_linkedlist_ListContains(bbt_list,bbt_obj2)==0)){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj2);
				}
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TEntity_AddList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TEntity_entity_list){
		if(StaticListSize(12,1)!=0){
			BBBYTE* bbt_inst=StaticIterListEntity(12,1,(&openb3d_openb3dex_TEntity_entity_list_id));
			struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj=openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}else{
		if(bbt_==openb3d_openb3dex_TEntity_animate_list){
			if(StaticListSize(12,26)!=0){
				BBBYTE* bbt_inst2=StaticIterListEntity(12,26,(&openb3d_openb3dex_TEntity_animate_list_id));
				struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj2=openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst2);
				if((bbt_obj2!= &bbNullObject) && (brl_linkedlist_ListContains(bbt_list,bbt_obj2)==0)){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj2);
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_CopyList_TTList(struct openb3d_openb3dex_TEntity_obj* o,struct brl_linkedlist_TList_obj* bbt_list){
	brl_linkedlist_ClearList(bbt_list);
	BBINT bbt_created=0;
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==o->_openb3d_openb3dex_tentity_child_list ){
		o->_openb3d_openb3dex_tentity_child_list_id =0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(EntityListSize(o->clas->f_GetInstance_pb_TTEntity(o),2)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=EntityIterListEntity(o->clas->f_GetInstance_pb_TTEntity(o),2,(&o->_openb3d_openb3dex_tentity_child_list_id ));
				struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj=o->clas->f_GetObject_TTEntity_pb(bbt_inst);
				if(((bbt_obj==&bbNullObject) && (bbt_inst!=0)) && (brl_linkedlist_ListContains(openb3d_openb3dex_TEntity_child_list_queue,o)==0)){
					brl_linkedlist_ListAddLast(openb3d_openb3dex_TEntity_child_list_queue,o);
				}
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
		struct brl_linkedlist_TListEnum_obj* volatile bbt_3=(openb3d_openb3dex_TEntity_child_list_queue)->clas->m_ObjectEnumerator(openb3d_openb3dex_TEntity_child_list_queue);
		while((bbt_3)->clas->m_HasNext(bbt_3)!=0){
			struct openb3d_openb3dex_TEntity_obj* volatile bbt_ent=((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast((bbt_3)->clas->m_NextObject(bbt_3),&openb3d_openb3dex_TEntity));
			if(bbt_ent==&bbNullObject){
				continue;
			}
			bbt_ent->_openb3d_openb3dex_tentity_child_list_id =0;
			bbt_created=1;
			{
				BBINT bbt_id2=0;
				BBINT bbt_4=(EntityListSize(o->clas->f_GetInstance_pb_TTEntity(bbt_ent),2)-1);
				for(bbt_id2;(bbt_id2<=bbt_4);bbt_id2=(bbt_id2+1)){
					BBBYTE* bbt_inst2=EntityIterListEntity(o->clas->f_GetInstance_pb_TTEntity(bbt_ent),2,(&bbt_ent->_openb3d_openb3dex_tentity_child_list_id ));
					struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj2=o->clas->f_GetObject_TTEntity_pb(bbt_inst2);
					if(bbt_obj2==&bbNullObject){
						bbt_created=0;
						break;
					}
				}
			}
			if(bbt_created!=0){
				bbt_ent->_openb3d_openb3dex_tentity_child_list_id =0;
				brl_linkedlist_ListRemove(openb3d_openb3dex_TEntity_child_list_queue,bbt_ent);
				{
					BBINT bbt_id3=0;
					BBINT bbt_5=(EntityListSize(o->clas->f_GetInstance_pb_TTEntity(bbt_ent),2)-1);
					for(bbt_id3;(bbt_id3<=bbt_5);bbt_id3=(bbt_id3+1)){
						BBBYTE* bbt_inst3=EntityIterListEntity(o->clas->f_GetInstance_pb_TTEntity(bbt_ent),2,(&bbt_ent->_openb3d_openb3dex_tentity_child_list_id ));
						struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj3=o->clas->f_GetObject_TTEntity_pb(bbt_inst3);
						if(bbt_obj3!= &bbNullObject){
							brl_linkedlist_ListAddLast(bbt_ent->_openb3d_openb3dex_tentity_child_list ,bbt_obj3);
						}
					}
				}
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TEntity_CopyList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	brl_linkedlist_ClearList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TEntity_entity_list){
		openb3d_openb3dex_TEntity_entity_list_id=0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(StaticListSize(12,1)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=StaticIterListEntity(12,1,(&openb3d_openb3dex_TEntity_entity_list_id));
				struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj=openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}else{
		if(bbt_==openb3d_openb3dex_TEntity_animate_list){
			openb3d_openb3dex_TEntity_animate_list_id=0;
			{
				BBINT bbt_id2=0;
				BBINT bbt_3=(StaticListSize(12,26)-1);
				for(bbt_id2;(bbt_id2<=bbt_3);bbt_id2=(bbt_id2+1)){
					BBBYTE* bbt_inst2=StaticIterListEntity(12,26,(&openb3d_openb3dex_TEntity_animate_list_id));
					struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj2=openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst2);
					if(bbt_obj2!= &bbNullObject){
						brl_linkedlist_ListAddLast(bbt_list,bbt_obj2);
					}
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_ListPushBack_TTListTObject(struct openb3d_openb3dex_TEntity_obj* o,struct brl_linkedlist_TList_obj* bbt_list,BBOBJECT bbt_value){
	struct openb3d_openb3dex_TEntity_obj* volatile bbt_ent=((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_value,&openb3d_openb3dex_TEntity));
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==o->_openb3d_openb3dex_tentity_child_list ){
		if(bbt_ent!= &bbNullObject){
			EntityListPushBackEntity(o->clas->f_GetInstance_pb_TTEntity(o),2,o->clas->f_GetInstance_pb_TTEntity(bbt_ent));
			((struct openb3d_openb3dex_TEntity_obj*)o)->clas->m_AddList_TTList(o,bbt_list);
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_AddAnimSeq_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_length){
	return AddAnimSeq(o->clas->f_GetInstance_pb_TTEntity(o),bbt_length);
}
BBINT _openb3d_openb3dex_TEntity_SetAnimKey_fiii(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_frame,BBINT bbt_pos_key,BBINT bbt_rot_key,BBINT bbt_scale_key){
	SetAnimKey(o->clas->f_GetInstance_pb_TTEntity(o),bbt_frame,bbt_pos_key,bbt_rot_key,bbt_scale_key);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_AlignToVector_fffif(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_axis,BBFLOAT bbt_rate){
	AlignToVector(o->clas->f_GetInstance_pb_TTEntity(o),bbt_x,bbt_y,bbt_z,bbt_axis,bbt_rate);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_FreeEntity(struct openb3d_openb3dex_TEntity_obj* o){
	if(o->_openb3d_openb3dex_tentity_exists !=0){
		BBBYTE* bbt_inst=o->clas->f_GetInstance_pb_TTEntity(o);
		((struct openb3d_openb3dex_TEntity_obj*)o)->clas->m_FreeEntityList(o);
		FreeEntity(bbt_inst);
		o->_openb3d_openb3dex_tentity_exists =0;
	}
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_FreeEntityList(struct openb3d_openb3dex_TEntity_obj* o){
	openb3d_openb3dex_TMatrix_FreeObject_i_pb(openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(o->_openb3d_openb3dex_tentity_mat ));
	o->_openb3d_openb3dex_tentity_mat =&bbNullObject;
	openb3d_openb3dex_TMatrix_FreeObject_i_pb(openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(o->_openb3d_openb3dex_tentity_rotmat ));
	o->_openb3d_openb3dex_tentity_rotmat =&bbNullObject;
	openb3d_openb3dex_TMatrix_FreeObject_i_pb(openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(o->_openb3d_openb3dex_tentity_old_mat ));
	o->_openb3d_openb3dex_tentity_old_mat =&bbNullObject;
	openb3d_openb3dex_TBrush_FreeObject_i_pb(openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(o->_openb3d_openb3dex_tentity_brush ));
	o->_openb3d_openb3dex_tentity_brush =&bbNullObject;
	brl_linkedlist_ListRemove(openb3d_openb3dex_TEntity_entity_list,o);
	openb3d_openb3dex_TEntity_entity_list_id-=1;
	if(o->_openb3d_openb3dex_tentity_anim_update [0U]!=0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TEntity_animate_list,o);
		openb3d_openb3dex_TEntity_animate_list_id-=1;
	}
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TPick_ent_list,o);
		openb3d_openb3dex_TPick_ent_list_id-=1;
	}
	if(o->_openb3d_openb3dex_tentity_parent != &bbNullObject){
		brl_linkedlist_ListRemove(o->_openb3d_openb3dex_tentity_parent ->_openb3d_openb3dex_tentity_child_list ,o);
		o->_openb3d_openb3dex_tentity_parent ->_openb3d_openb3dex_tentity_child_list_id -=1;
	}else{
		if(brl_linkedlist_ListContains(openb3d_openb3dex_TGlobal_root_ent->_openb3d_openb3dex_tentity_child_list ,o)!=0){
			brl_linkedlist_ListRemove(openb3d_openb3dex_TGlobal_root_ent->_openb3d_openb3dex_tentity_child_list ,o);
			openb3d_openb3dex_TGlobal_root_ent->_openb3d_openb3dex_tentity_child_list_id -=1;
		}
	}
	struct brl_linkedlist_TListEnum_obj* volatile bbt_=(o->_openb3d_openb3dex_tentity_child_list )->clas->m_ObjectEnumerator(o->_openb3d_openb3dex_tentity_child_list );
	while((bbt_)->clas->m_HasNext(bbt_)!=0){
		struct openb3d_openb3dex_TEntity_obj* volatile bbt_ent=((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast((bbt_)->clas->m_NextObject(bbt_),&openb3d_openb3dex_TEntity));
		if(bbt_ent==&bbNullObject){
			continue;
		}
		if(bbt_ent!= &bbNullObject){
			(bbt_ent)->clas->m_FreeEntityList(bbt_ent);
		}
	}
	brl_linkedlist_ClearList(o->_openb3d_openb3dex_tentity_child_list );
	o->_openb3d_openb3dex_tentity_child_list_id =0;
	o->clas->f_FreeObject_i_pb(o->clas->f_GetInstance_pb_TTEntity(o));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_PositionEntity_fffi(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	PositionEntity(o->clas->f_GetInstance_pb_TTEntity(o),bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_MoveEntity_fff(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	MoveEntity(o->clas->f_GetInstance_pb_TTEntity(o),bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_TranslateEntity_fffi(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	TranslateEntity(o->clas->f_GetInstance_pb_TTEntity(o),bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_ScaleEntity_fffi(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	ScaleEntity(o->clas->f_GetInstance_pb_TTEntity(o),bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_RotateEntity_fffi(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	RotateEntity(o->clas->f_GetInstance_pb_TTEntity(o),-bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_TurnEntity_fffi(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	TurnEntity(o->clas->f_GetInstance_pb_TTEntity(o),-bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_PointEntity_TTEntityf(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_target_ent,BBFLOAT bbt_roll){
	PointEntity(o->clas->f_GetInstance_pb_TTEntity(o),o->clas->f_GetInstance_pb_TTEntity(bbt_target_ent),bbt_roll);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_LoadAnimSeq_S(struct openb3d_openb3dex_TEntity_obj* o,BBSTRING bbt_file){
	BBBYTE* bbt_cString=bbStringToCString(bbt_file);
	BBINT bbt_seqnum=LoadAnimSeq(o->clas->f_GetInstance_pb_TTEntity(o),bbt_cString);
	bbMemFree((void*)bbt_cString);
	return bbt_seqnum;
}
BBINT _openb3d_openb3dex_TEntity_ExtractAnimSeq_iii(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_first_frame,BBINT bbt_last_frame,BBINT bbt_seq){
	return ExtractAnimSeq(o->clas->f_GetInstance_pb_TTEntity(o),bbt_first_frame,bbt_last_frame,bbt_seq);
}
BBINT _openb3d_openb3dex_TEntity_Animate_ifii(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_Mode,BBFLOAT bbt_speed,BBINT bbt_seq,BBINT bbt_trans){
	if(o->_openb3d_openb3dex_tentity_anim_list [0U]==0){
		brl_linkedlist_ListAddLast(openb3d_openb3dex_TEntity_animate_list,o);
		openb3d_openb3dex_TEntity_animate_list_id+=1;
	}
	Animate(o->clas->f_GetInstance_pb_TTEntity(o),bbt_Mode,bbt_speed,bbt_seq,bbt_trans);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_SetAnimTime_fi(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_time,BBINT bbt_seq){
	if(bbt_time!=0.0f){
		SetAnimTime(o->clas->f_GetInstance_pb_TTEntity(o),bbt_time,bbt_seq);
	}
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_AnimSeq(struct openb3d_openb3dex_TEntity_obj* o){
	return AnimSeq(o->clas->f_GetInstance_pb_TTEntity(o));
}
BBINT _openb3d_openb3dex_TEntity_AnimLength(struct openb3d_openb3dex_TEntity_obj* o){
	return AnimLength(o->clas->f_GetInstance_pb_TTEntity(o));
}
BBFLOAT _openb3d_openb3dex_TEntity_AnimTime(struct openb3d_openb3dex_TEntity_obj* o){
	return AnimTime(o->clas->f_GetInstance_pb_TTEntity(o));
}
BBINT _openb3d_openb3dex_TEntity_Animating(struct openb3d_openb3dex_TEntity_obj* o){
	return Animating(o->clas->f_GetInstance_pb_TTEntity(o));
}
BBINT _openb3d_openb3dex_TEntity_EntityColor_fff(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_red,BBFLOAT bbt_green,BBFLOAT bbt_blue){
	EntityColor(o->clas->f_GetInstance_pb_TTEntity(o),bbt_red,bbt_green,bbt_blue);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityAlpha_f(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_alpha){
	EntityAlpha(o->clas->f_GetInstance_pb_TTEntity(o),bbt_alpha);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityShininess_f(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_shine){
	EntityShininess(o->clas->f_GetInstance_pb_TTEntity(o),bbt_shine);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityTexture_TTTextureii(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_frame,BBINT bbt_index){
	EntityTexture(o->clas->f_GetInstance_pb_TTEntity(o),openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex),bbt_frame,bbt_index);
	if(o->_openb3d_openb3dex_tentity_brush !=&bbNullObject){
		(o->_openb3d_openb3dex_tentity_brush )->clas->m_InitFields(o->_openb3d_openb3dex_tentity_brush );
	}
	struct brl_linkedlist_TListEnum_obj* volatile bbt_=(o->_openb3d_openb3dex_tentity_child_list )->clas->m_ObjectEnumerator(o->_openb3d_openb3dex_tentity_child_list );
	while((bbt_)->clas->m_HasNext(bbt_)!=0){
		struct openb3d_openb3dex_TEntity_obj* volatile bbt_ent=((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast((bbt_)->clas->m_NextObject(bbt_),&openb3d_openb3dex_TEntity));
		if(bbt_ent==&bbNullObject){
			continue;
		}
		if(bbt_ent->_openb3d_openb3dex_tentity_brush !=&bbNullObject){
			(((struct openb3d_openb3dex_TBrush_obj*)bbt_ent->_openb3d_openb3dex_tentity_brush )->clas)->m_InitFields(bbt_ent->_openb3d_openb3dex_tentity_brush );
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityBlend_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_blend){
	EntityBlend(o->clas->f_GetInstance_pb_TTEntity(o),bbt_blend);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityFX_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_fx){
	EntityFX(o->clas->f_GetInstance_pb_TTEntity(o),bbt_fx);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_PaintEntity_TTBrush(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TBrush_obj* bbt_bru){
	PaintEntity(o->clas->f_GetInstance_pb_TTEntity(o),openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_bru));
	if(o->_openb3d_openb3dex_tentity_brush !=&bbNullObject){
		(o->_openb3d_openb3dex_tentity_brush )->clas->m_InitFields(o->_openb3d_openb3dex_tentity_brush );
	}
	return 0;
}
struct openb3d_openb3dex_TBrush_obj* _openb3d_openb3dex_TEntity_GetEntityBrush(struct openb3d_openb3dex_TEntity_obj* o){
	BBBYTE* bbt_inst=GetEntityBrush(o->clas->f_GetInstance_pb_TTEntity(o));
	struct openb3d_openb3dex_TBrush_obj* volatile bbt_brush=openb3d_openb3dex_TBrush_GetObject_TTBrush_pb(bbt_inst);
	if((bbt_brush==&bbNullObject) && (bbt_inst!=0)){
		bbt_brush=openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(bbt_inst);
	}
	return bbt_brush;
}
BBINT _openb3d_openb3dex_TEntity_EntityOrder_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_order){
	EntityOrder(o->clas->f_GetInstance_pb_TTEntity(o),bbt_order);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_ShowEntity(struct openb3d_openb3dex_TEntity_obj* o){
	if(((struct openb3d_openb3dex_TCamera_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TCamera))!= &bbNullObject){
		openb3d_openb3dex_TGlobal_camera_in_use=((struct openb3d_openb3dex_TCamera_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TCamera));
	}
	ShowEntity(o->clas->f_GetInstance_pb_TTEntity(o));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_HideEntity(struct openb3d_openb3dex_TEntity_obj* o){
	HideEntity(o->clas->f_GetInstance_pb_TTEntity(o));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_NameEntity_S(struct openb3d_openb3dex_TEntity_obj* o,BBSTRING bbt_name){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	NameEntity(o->clas->f_GetInstance_pb_TTEntity(o),bbt_cString);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityParent_TTEntityi(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent,BBINT bbt_glob){
	EntityParent(o->clas->f_GetInstance_pb_TTEntity(o),o->clas->f_GetInstance_pb_TTEntity(bbt_parent_ent),bbt_glob);
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_GetParent(struct openb3d_openb3dex_TEntity_obj* o){
	BBBYTE* bbt_inst=GetParentEntity(o->clas->f_GetInstance_pb_TTEntity(o));
	return o->clas->f_GetObject_TTEntity_pb(bbt_inst);
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityX_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return EntityX(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityY_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return EntityY(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityZ_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return EntityZ(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityPitch_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return -EntityPitch(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityYaw_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return EntityYaw(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityRoll_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return EntityRoll(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBSTRING _openb3d_openb3dex_TEntity_EntityClass(struct openb3d_openb3dex_TEntity_obj* o){
	return bbStringFromCString(EntityClass(o->clas->f_GetInstance_pb_TTEntity(o)));
}
BBSTRING _openb3d_openb3dex_TEntity_EntityName(struct openb3d_openb3dex_TEntity_obj* o){
	return bbStringFromCString(EntityName(o->clas->f_GetInstance_pb_TTEntity(o)));
}
BBINT _openb3d_openb3dex_TEntity_CountChildren(struct openb3d_openb3dex_TEntity_obj* o){
	return CountChildren(o->clas->f_GetInstance_pb_TTEntity(o));
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_GetChild_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_child_no){
	BBBYTE* bbt_inst=GetChild(o->clas->f_GetInstance_pb_TTEntity(o),bbt_child_no);
	return o->clas->f_GetObject_TTEntity_pb(bbt_inst);
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_FindChild_S(struct openb3d_openb3dex_TEntity_obj* o,BBSTRING bbt_child_name){
	BBBYTE* bbt_cString=bbStringToCString(bbt_child_name);
	BBBYTE* bbt_inst=FindChild(o->clas->f_GetInstance_pb_TTEntity(o),bbt_cString);
	bbMemFree((void*)bbt_cString);
	return o->clas->f_GetObject_TTEntity_pb(bbt_inst);
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_EntityPick_f(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_Range){
	BBBYTE* bbt_inst=EntityPick(o->clas->f_GetInstance_pb_TTEntity(o),bbt_Range);
	return o->clas->f_GetObject_TTEntity_pb(bbt_inst);
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_LinePick_fffffff(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_dx,BBFLOAT bbt_dy,BBFLOAT bbt_dz,BBFLOAT bbt_radius){
	BBBYTE* bbt_inst=LinePick(bbt_x,bbt_y,bbt_z,bbt_dx,bbt_dy,bbt_dz,bbt_radius);
	return o->clas->f_GetObject_TTEntity_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	return EntityVisible(o->clas->f_GetInstance_pb_TTEntity(bbt_src_ent),o->clas->f_GetInstance_pb_TTEntity(bbt_dest_ent));
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityDistance_TTEntity(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_ent2){
	return EntityDistance(o->clas->f_GetInstance_pb_TTEntity(o),o->clas->f_GetInstance_pb_TTEntity(bbt_ent2));
}
BBFLOAT _openb3d_openb3dex_TEntity_DeltaYaw_TTEntity(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_ent2){
	return DeltaYaw(o->clas->f_GetInstance_pb_TTEntity(o),o->clas->f_GetInstance_pb_TTEntity(bbt_ent2));
}
BBFLOAT _openb3d_openb3dex_TEntity_DeltaPitch_TTEntity(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_ent2){
	return -DeltaPitch(o->clas->f_GetInstance_pb_TTEntity(o),o->clas->f_GetInstance_pb_TTEntity(bbt_ent2));
}
BBINT openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	TFormPoint(bbt_x,bbt_y,bbt_z,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_src_ent),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_dest_ent));
	return 0;
}
BBINT openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	TFormVector(bbt_x,bbt_y,bbt_z,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_src_ent),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_dest_ent));
	return 0;
}
BBINT openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	TFormNormal(bbt_x,bbt_y,bbt_z,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_src_ent),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_dest_ent));
	return 0;
}
BBFLOAT openb3d_openb3dex_TEntity_TFormedX_f(){
	return TFormedX();
}
BBFLOAT openb3d_openb3dex_TEntity_TFormedY_f(){
	return TFormedY();
}
BBFLOAT openb3d_openb3dex_TEntity_TFormedZ_f(){
	return TFormedZ();
}
BBFLOAT _openb3d_openb3dex_TEntity_GetMatElement_ii(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_row,BBINT bbt_col){
	return o->_openb3d_openb3dex_tentity_mat ->_openb3d_openb3dex_tmatrix_grid [((BBUINT)((4*bbt_row)+bbt_col))];
}
BBINT _openb3d_openb3dex_TEntity_ResetEntity(struct openb3d_openb3dex_TEntity_obj* o){
	ResetEntity(o->clas->f_GetInstance_pb_TTEntity(o));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityRadius_ff(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_radius_x,BBFLOAT bbt_radius_y){
	EntityRadius(o->clas->f_GetInstance_pb_TTEntity(o),bbt_radius_x,bbt_radius_y);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityBox_ffffff(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_w,BBFLOAT bbt_h,BBFLOAT bbt_d){
	EntityBox(o->clas->f_GetInstance_pb_TTEntity(o),bbt_x,bbt_y,bbt_z,bbt_w,bbt_h,bbt_d);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityType_ii(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_type_no,BBINT bbt_recursive){
	EntityType(o->clas->f_GetInstance_pb_TTEntity(o),bbt_type_no,bbt_recursive);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_EntityPickMode_ii(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_pick_mode_no,BBINT bbt_obscurer){
	EntityPickMode(o->clas->f_GetInstance_pb_TTEntity(o),bbt_pick_mode_no,bbt_obscurer);
	if(bbt_pick_mode_no!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	if(bbt_pick_mode_no==0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TPick_ent_list,o);
		openb3d_openb3dex_TPick_ent_list_id-=1;
	}
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_EntityCollided_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_type_no){
	BBBYTE* bbt_inst=EntityCollided(o->clas->f_GetInstance_pb_TTEntity(o),bbt_type_no);
	return o->clas->f_GetObject_TTEntity_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TEntity_CountCollisions(struct openb3d_openb3dex_TEntity_obj* o){
	return CountCollisions(o->clas->f_GetInstance_pb_TTEntity(o));
}
BBFLOAT _openb3d_openb3dex_TEntity_CollisionX_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	return CollisionX(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
}
BBFLOAT _openb3d_openb3dex_TEntity_CollisionY_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	return CollisionY(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
}
BBFLOAT _openb3d_openb3dex_TEntity_CollisionZ_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	return CollisionZ(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
}
BBFLOAT _openb3d_openb3dex_TEntity_CollisionNX_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	return CollisionNX(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
}
BBFLOAT _openb3d_openb3dex_TEntity_CollisionNY_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	return CollisionNY(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
}
BBFLOAT _openb3d_openb3dex_TEntity_CollisionNZ_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	return CollisionNZ(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
}
BBFLOAT _openb3d_openb3dex_TEntity_CollisionTime_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	return CollisionTime(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_CollisionEntity_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	BBBYTE* bbt_inst=CollisionEntity(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
	return o->clas->f_GetObject_TTEntity_pb(bbt_inst);
}
struct openb3d_openb3dex_TSurface_obj* _openb3d_openb3dex_TEntity_CollisionSurface_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	BBBYTE* bbt_inst=CollisionSurface(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
	return openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TEntity_CollisionTriangle_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_index){
	return CollisionTriangle(o->clas->f_GetInstance_pb_TTEntity(o),bbt_index);
}
BBINT _openb3d_openb3dex_TEntity_GetEntityType(struct openb3d_openb3dex_TEntity_obj* o){
	return GetEntityType(o->clas->f_GetInstance_pb_TTEntity(o));
}
BBINT _openb3d_openb3dex_TEntity_MeshCullRadius_f(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_radius){
	MeshCullRadius(o->clas->f_GetInstance_pb_TTEntity(o),bbt_radius);
	return 0;
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityScaleX_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return EntityScaleX(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityScaleY_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return EntityScaleY(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityScaleZ_i(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_glob){
	return EntityScaleZ(o->clas->f_GetInstance_pb_TTEntity(o),bbt_glob);
}
BBINT _openb3d_openb3dex_TEntity_Hidden(struct openb3d_openb3dex_TEntity_obj* o){
	return Hidden(o->clas->f_GetInstance_pb_TTEntity(o));
}
BBINT openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_no_children){
	return CountAllChildren(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_no_children);
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity(struct openb3d_openb3dex_TEntity_obj* o,BBINT bbt_child_no,BBINT* bbt_no_children,struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	BBBYTE* bbt_inst=GetChildFromAll(o->clas->f_GetInstance_pb_TTEntity(o),bbt_child_no,&(*bbt_no_children),o->clas->f_GetInstance_pb_TTEntity(bbt_ent));
	return o->clas->f_GetObject_TTEntity_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TEntity_ListParents_TTList(struct openb3d_openb3dex_TEntity_obj* o,struct brl_linkedlist_TList_obj* bbt_list){
	struct openb3d_openb3dex_TEntity_obj* volatile bbt_parent=((struct openb3d_openb3dex_TEntity_obj*)o)->clas->m_GetParent(o);
	if(bbt_parent!= &bbNullObject){
		brl_linkedlist_ListAddLast(bbt_list,bbt_parent);
		((struct openb3d_openb3dex_TEntity_obj*)o)->clas->m_ListParents_TTList(o,bbt_list);
	}
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_UpdateMat_b(struct openb3d_openb3dex_TEntity_obj* o,BBBYTE bbt_load_identity){
	UpdateMat(o->clas->f_GetInstance_pb_TTEntity(o),bbt_load_identity);
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_AddParent_TTEntity(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	AddParent(o->clas->f_GetInstance_pb_TTEntity(o),o->clas->f_GetInstance_pb_TTEntity(bbt_parent_ent));
	return 0;
}
BBINT openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent_p){
	UpdateChildren(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent_p));
	return 0;
}
BBFLOAT _openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_ent2){
	return EntityDistanceSquared(o->clas->f_GetInstance_pb_TTEntity(o),o->clas->f_GetInstance_pb_TTEntity(bbt_ent2));
}
BBINT _openb3d_openb3dex_TEntity_MQ_Update(struct openb3d_openb3dex_TEntity_obj* o){
	MQ_Update(o->clas->f_GetInstance_pb_TTEntity(o));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_mat0){
	MQ_GetInvMatrix(o->clas->f_GetInstance_pb_TTEntity(o),openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(bbt_mat0));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_mat3){
	MQ_GetMatrix(o->clas->f_GetInstance_pb_TTEntity(o),openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(bbt_mat3));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT* bbt_newtonMatrix){
	MQ_ApplyNewtonTransform(o->clas->f_GetInstance_pb_TTEntity(o),((BBBYTE*)bbt_newtonMatrix));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix(struct openb3d_openb3dex_TEntity_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_inputMatrix){
	MQ_SetMatrix(o->clas->f_GetInstance_pb_TTEntity(o),openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(bbt_inputMatrix));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT* bbt_width,BBFLOAT* bbt_height,BBFLOAT* bbt_depth){
	MQ_GetScaleXYZ(o->clas->f_GetInstance_pb_TTEntity(o),&(*bbt_width),&(*bbt_height),&(*bbt_depth));
	return 0;
}
BBINT _openb3d_openb3dex_TEntity_MQ_Turn_ffffi(struct openb3d_openb3dex_TEntity_obj* o,BBFLOAT bbt_ang,BBFLOAT bbt_vx,BBFLOAT bbt_vy,BBFLOAT bbt_vz,BBINT bbt_glob){
	MQ_Turn(o->clas->f_GetInstance_pb_TTEntity(o),bbt_ang,bbt_vx,bbt_vy,bbt_vz,bbt_glob);
	return 0;
}
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TEntity_entity_list;
BBINT openb3d_openb3dex_TEntity_entity_list_id;
struct brl_map_TMap_obj* openb3d_openb3dex_TEntity_ent_map;
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TEntity_animate_list;
BBINT openb3d_openb3dex_TEntity_animate_list_id;
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TEntity_child_list_queue;
BBFLOAT* openb3d_openb3dex_TEntity_tformed_x;
BBFLOAT* openb3d_openb3dex_TEntity_tformed_y;
BBFLOAT* openb3d_openb3dex_TEntity_tformed_z;
struct BBDebugScope_185 openb3d_openb3dex_TEntity_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TEntity",
	{
		{
			BBDEBUGDECL_FIELD,
			"child_list",
			":TList",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_child_list)
		},
		{
			BBDEBUGDECL_FIELD,
			"parent",
			":TEntity",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_parent)
		},
		{
			BBDEBUGDECL_FIELD,
			"mat",
			":TMatrix",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_mat)
		},
		{
			BBDEBUGDECL_FIELD,
			"rotmat",
			":TMatrix",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_rotmat)
		},
		{
			BBDEBUGDECL_FIELD,
			"px",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_px)
		},
		{
			BBDEBUGDECL_FIELD,
			"py",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_py)
		},
		{
			BBDEBUGDECL_FIELD,
			"pz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_pz)
		},
		{
			BBDEBUGDECL_FIELD,
			"sx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_sx)
		},
		{
			BBDEBUGDECL_FIELD,
			"sy",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_sy)
		},
		{
			BBDEBUGDECL_FIELD,
			"sz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_sz)
		},
		{
			BBDEBUGDECL_FIELD,
			"rx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_rx)
		},
		{
			BBDEBUGDECL_FIELD,
			"ry",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_ry)
		},
		{
			BBDEBUGDECL_FIELD,
			"rz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_rz)
		},
		{
			BBDEBUGDECL_FIELD,
			"qw",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_qw)
		},
		{
			BBDEBUGDECL_FIELD,
			"qx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_qx)
		},
		{
			BBDEBUGDECL_FIELD,
			"qy",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_qy)
		},
		{
			BBDEBUGDECL_FIELD,
			"qz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_qz)
		},
		{
			BBDEBUGDECL_FIELD,
			"brush",
			":TBrush",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_brush)
		},
		{
			BBDEBUGDECL_FIELD,
			"order",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_order)
		},
		{
			BBDEBUGDECL_FIELD,
			"alpha_order",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_alpha_order)
		},
		{
			BBDEBUGDECL_FIELD,
			"hide",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_hide)
		},
		{
			BBDEBUGDECL_FIELD,
			"cull_radius",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_cull_radius)
		},
		{
			BBDEBUGDECL_FIELD,
			"name",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_name)
		},
		{
			BBDEBUGDECL_FIELD,
			"class_name",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_class_name)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_render",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_render)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_mode",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_mode)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_time",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_time)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_speed",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_speed)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_seq",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_seq)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_trans",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_trans)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_dir",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_dir)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_seqs_first",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_seqs_first)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_seqs_last",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_seqs_last)
		},
		{
			BBDEBUGDECL_FIELD,
			"no_seqs",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_no_seqs)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_update",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_update)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_list",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_anim_list)
		},
		{
			BBDEBUGDECL_FIELD,
			"collision_type",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_collision_type)
		},
		{
			BBDEBUGDECL_FIELD,
			"radius_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_radius_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"radius_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_radius_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"box_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_box_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"box_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_box_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"box_z",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_box_z)
		},
		{
			BBDEBUGDECL_FIELD,
			"box_w",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_box_w)
		},
		{
			BBDEBUGDECL_FIELD,
			"box_h",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_box_h)
		},
		{
			BBDEBUGDECL_FIELD,
			"box_d",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_box_d)
		},
		{
			BBDEBUGDECL_FIELD,
			"no_collisions",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_no_collisions)
		},
		{
			BBDEBUGDECL_FIELD,
			"old_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_old_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"old_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_old_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"old_z",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_old_z)
		},
		{
			BBDEBUGDECL_FIELD,
			"old_pitch",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_old_pitch)
		},
		{
			BBDEBUGDECL_FIELD,
			"old_yaw",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_old_yaw)
		},
		{
			BBDEBUGDECL_FIELD,
			"old_roll",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_old_roll)
		},
		{
			BBDEBUGDECL_FIELD,
			"new_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_new_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"new_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_new_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"new_z",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_new_z)
		},
		{
			BBDEBUGDECL_FIELD,
			"new_no",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_new_no)
		},
		{
			BBDEBUGDECL_FIELD,
			"old_mat",
			":TMatrix",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_old_mat)
		},
		{
			BBDEBUGDECL_FIELD,
			"dynamic",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_dynamic)
		},
		{
			BBDEBUGDECL_FIELD,
			"dynamic_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_dynamic_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"dynamic_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_dynamic_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"dynamic_z",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_dynamic_z)
		},
		{
			BBDEBUGDECL_FIELD,
			"dynamic_yaw",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_dynamic_yaw)
		},
		{
			BBDEBUGDECL_FIELD,
			"dynamic_pitch",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_dynamic_pitch)
		},
		{
			BBDEBUGDECL_FIELD,
			"dynamic_roll",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_dynamic_roll)
		},
		{
			BBDEBUGDECL_FIELD,
			"pick_mode",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_pick_mode)
		},
		{
			BBDEBUGDECL_FIELD,
			"obscurer",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_obscurer)
		},
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_instance)
		},
		{
			BBDEBUGDECL_FIELD,
			"child_list_id",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_child_list_id)
		},
		{
			BBDEBUGDECL_FIELD,
			"exists",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_exists)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"entity_list",
			":TList",
			&openb3d_openb3dex_TEntity_entity_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"animate_list",
			":TList",
			&openb3d_openb3dex_TEntity_animate_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"tformed_x",
			"*f",
			&openb3d_openb3dex_TEntity_tformed_x
		},
		{
			BBDEBUGDECL_GLOBAL,
			"tformed_y",
			"*f",
			&openb3d_openb3dex_TEntity_tformed_y
		},
		{
			BBDEBUGDECL_GLOBAL,
			"tformed_z",
			"*f",
			&openb3d_openb3dex_TEntity_tformed_z
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ent_map",
			":TMap",
			&openb3d_openb3dex_TEntity_ent_map
		},
		{
			BBDEBUGDECL_GLOBAL,
			"entity_list_id",
			"i",
			&openb3d_openb3dex_TEntity_entity_list_id
		},
		{
			BBDEBUGDECL_GLOBAL,
			"animate_list_id",
			"i",
			&openb3d_openb3dex_TEntity_animate_list_id
		},
		{
			BBDEBUGDECL_GLOBAL,
			"child_list_queue",
			":TList",
			&openb3d_openb3dex_TEntity_child_list_queue
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TEntity_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TEntity_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TEntity",
			&openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TEntity)*b",
			&openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"InitGlobals",
			"()i",
			&openb3d_openb3dex_TEntity_InitGlobals_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TEntity_InitFields
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AddList",
			"(:TList)i",
			&_openb3d_openb3dex_TEntity_AddList_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AddList_",
			"(:TList)i",
			&openb3d_openb3dex_TEntity_AddList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyList",
			"(:TList)i",
			&_openb3d_openb3dex_TEntity_CopyList_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList_",
			"(:TList)i",
			&openb3d_openb3dex_TEntity_CopyList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ListPushBack",
			"(:TList,:Object)i",
			&_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AddAnimSeq",
			"(i)i",
			&_openb3d_openb3dex_TEntity_AddAnimSeq_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetAnimKey",
			"(f,i,i,i)i",
			&_openb3d_openb3dex_TEntity_SetAnimKey_fiii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AlignToVector",
			"(f,f,f,i,f)i",
			&_openb3d_openb3dex_TEntity_AlignToVector_fffif
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeEntity",
			"()i",
			&_openb3d_openb3dex_TEntity_FreeEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeEntityList",
			"()i",
			&_openb3d_openb3dex_TEntity_FreeEntityList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"PositionEntity",
			"(f,f,f,i)i",
			&_openb3d_openb3dex_TEntity_PositionEntity_fffi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MoveEntity",
			"(f,f,f)i",
			&_openb3d_openb3dex_TEntity_MoveEntity_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TranslateEntity",
			"(f,f,f,i)i",
			&_openb3d_openb3dex_TEntity_TranslateEntity_fffi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ScaleEntity",
			"(f,f,f,i)i",
			&_openb3d_openb3dex_TEntity_ScaleEntity_fffi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RotateEntity",
			"(f,f,f,i)i",
			&_openb3d_openb3dex_TEntity_RotateEntity_fffi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TurnEntity",
			"(f,f,f,i)i",
			&_openb3d_openb3dex_TEntity_TurnEntity_fffi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"PointEntity",
			"(:TEntity,f)i",
			&_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"LoadAnimSeq",
			"($)i",
			&_openb3d_openb3dex_TEntity_LoadAnimSeq_S
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ExtractAnimSeq",
			"(i,i,i)i",
			&_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Animate",
			"(i,f,i,i)i",
			&_openb3d_openb3dex_TEntity_Animate_ifii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetAnimTime",
			"(f,i)i",
			&_openb3d_openb3dex_TEntity_SetAnimTime_fi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AnimSeq",
			"()i",
			&_openb3d_openb3dex_TEntity_AnimSeq
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AnimLength",
			"()i",
			&_openb3d_openb3dex_TEntity_AnimLength
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AnimTime",
			"()f",
			&_openb3d_openb3dex_TEntity_AnimTime
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Animating",
			"()i",
			&_openb3d_openb3dex_TEntity_Animating
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityColor",
			"(f,f,f)i",
			&_openb3d_openb3dex_TEntity_EntityColor_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityAlpha",
			"(f)i",
			&_openb3d_openb3dex_TEntity_EntityAlpha_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityShininess",
			"(f)i",
			&_openb3d_openb3dex_TEntity_EntityShininess_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityTexture",
			"(:TTexture,i,i)i",
			&_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityBlend",
			"(i)i",
			&_openb3d_openb3dex_TEntity_EntityBlend_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityFX",
			"(i)i",
			&_openb3d_openb3dex_TEntity_EntityFX_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"PaintEntity",
			"(:TBrush)i",
			&_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetEntityBrush",
			"():TBrush",
			&_openb3d_openb3dex_TEntity_GetEntityBrush
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityOrder",
			"(i)i",
			&_openb3d_openb3dex_TEntity_EntityOrder_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ShowEntity",
			"()i",
			&_openb3d_openb3dex_TEntity_ShowEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"HideEntity",
			"()i",
			&_openb3d_openb3dex_TEntity_HideEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"NameEntity",
			"($)i",
			&_openb3d_openb3dex_TEntity_NameEntity_S
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityParent",
			"(:TEntity,i)i",
			&_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetParent",
			"():TEntity",
			&_openb3d_openb3dex_TEntity_GetParent
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityX",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityX_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityY",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityY_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityZ",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityZ_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityPitch",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityPitch_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityYaw",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityYaw_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityRoll",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityRoll_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityClass",
			"()$",
			&_openb3d_openb3dex_TEntity_EntityClass
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityName",
			"()$",
			&_openb3d_openb3dex_TEntity_EntityName
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CountChildren",
			"()i",
			&_openb3d_openb3dex_TEntity_CountChildren
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetChild",
			"(i):TEntity",
			&_openb3d_openb3dex_TEntity_GetChild_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FindChild",
			"($):TEntity",
			&_openb3d_openb3dex_TEntity_FindChild_S
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityPick",
			"(f):TEntity",
			&_openb3d_openb3dex_TEntity_EntityPick_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"LinePick",
			"(f,f,f,f,f,f,f):TEntity",
			&_openb3d_openb3dex_TEntity_LinePick_fffffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityVisible",
			"(:TEntity,:TEntity)i",
			&_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityDistance",
			"(:TEntity)f",
			&_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"DeltaYaw",
			"(:TEntity)f",
			&_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"DeltaPitch",
			"(:TEntity)f",
			&_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"TFormPoint",
			"(f,f,f,:TEntity,:TEntity)i",
			&openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"TFormVector",
			"(f,f,f,:TEntity,:TEntity)i",
			&openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"TFormNormal",
			"(f,f,f,:TEntity,:TEntity)i",
			&openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"TFormedX",
			"()f",
			&openb3d_openb3dex_TEntity_TFormedX_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"TFormedY",
			"()f",
			&openb3d_openb3dex_TEntity_TFormedY_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"TFormedZ",
			"()f",
			&openb3d_openb3dex_TEntity_TFormedZ_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetMatElement",
			"(i,i)f",
			&_openb3d_openb3dex_TEntity_GetMatElement_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ResetEntity",
			"()i",
			&_openb3d_openb3dex_TEntity_ResetEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityRadius",
			"(f,f)i",
			&_openb3d_openb3dex_TEntity_EntityRadius_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityBox",
			"(f,f,f,f,f,f)i",
			&_openb3d_openb3dex_TEntity_EntityBox_ffffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityType",
			"(i,i)i",
			&_openb3d_openb3dex_TEntity_EntityType_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityPickMode",
			"(i,i)i",
			&_openb3d_openb3dex_TEntity_EntityPickMode_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityCollided",
			"(i):TEntity",
			&_openb3d_openb3dex_TEntity_EntityCollided_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CountCollisions",
			"()i",
			&_openb3d_openb3dex_TEntity_CountCollisions
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionX",
			"(i)f",
			&_openb3d_openb3dex_TEntity_CollisionX_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionY",
			"(i)f",
			&_openb3d_openb3dex_TEntity_CollisionY_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionZ",
			"(i)f",
			&_openb3d_openb3dex_TEntity_CollisionZ_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionNX",
			"(i)f",
			&_openb3d_openb3dex_TEntity_CollisionNX_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionNY",
			"(i)f",
			&_openb3d_openb3dex_TEntity_CollisionNY_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionNZ",
			"(i)f",
			&_openb3d_openb3dex_TEntity_CollisionNZ_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionTime",
			"(i)f",
			&_openb3d_openb3dex_TEntity_CollisionTime_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionEntity",
			"(i):TEntity",
			&_openb3d_openb3dex_TEntity_CollisionEntity_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionSurface",
			"(i):TSurface",
			&_openb3d_openb3dex_TEntity_CollisionSurface_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollisionTriangle",
			"(i)i",
			&_openb3d_openb3dex_TEntity_CollisionTriangle_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetEntityType",
			"()i",
			&_openb3d_openb3dex_TEntity_GetEntityType
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshCullRadius",
			"(f)i",
			&_openb3d_openb3dex_TEntity_MeshCullRadius_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityScaleX",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityScaleX_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityScaleY",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityScaleY_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityScaleZ",
			"(i)f",
			&_openb3d_openb3dex_TEntity_EntityScaleZ_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Hidden",
			"()i",
			&_openb3d_openb3dex_TEntity_Hidden
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CountAllChildren",
			"(:TEntity,i)i",
			&openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetChildFromAll",
			"(i,i,:TEntity):TEntity",
			&_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ListParents",
			"(:TList)i",
			&_openb3d_openb3dex_TEntity_ListParents_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateMat",
			"(b)i",
			&_openb3d_openb3dex_TEntity_UpdateMat_b
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AddParent",
			"(:TEntity)i",
			&_openb3d_openb3dex_TEntity_AddParent_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UpdateChildren",
			"(:TEntity)i",
			&openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityDistanceSquared",
			"(:TEntity)f",
			&_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MQ_Update",
			"()i",
			&_openb3d_openb3dex_TEntity_MQ_Update
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MQ_GetInvMatrix",
			"(:TMatrix)i",
			&_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MQ_GetMatrix",
			"(:TMatrix)i",
			&_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MQ_ApplyNewtonTransform",
			"(*f)i",
			&_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MQ_SetMatrix",
			"(:TMatrix)i",
			&_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MQ_GetScaleXYZ",
			"(f,f,f)i",
			&_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MQ_Turn",
			"(f,f,f,f,i)i",
			&_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TEntity openb3d_openb3dex_TEntity={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TEntity_scope,
	sizeof(struct openb3d_openb3dex_TEntity_obj),
	_openb3d_openb3dex_TEntity_New,
	_openb3d_openb3dex_TEntity_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TEntity_obj,_openb3d_openb3dex_tentity_exists) - sizeof(void*) + sizeof(BBINT)
	,_openb3d_openb3dex_TEntity_CopyEntity_TTEntity
	,_openb3d_openb3dex_TEntity_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TEntity_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TEntity_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
};

void _openb3d_openb3dex_TCamera_New(struct openb3d_openb3dex_TCamera_obj* o) {
	_openb3d_openb3dex_TEntity_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TCamera;
	o->_openb3d_openb3dex_tcamera_vx = 0;
	o->_openb3d_openb3dex_tcamera_vy = 0;
	o->_openb3d_openb3dex_tcamera_vwidth = 0;
	o->_openb3d_openb3dex_tcamera_vheight = 0;
	o->_openb3d_openb3dex_tcamera_cls_r = 0;
	o->_openb3d_openb3dex_tcamera_cls_g = 0;
	o->_openb3d_openb3dex_tcamera_cls_b = 0;
	o->_openb3d_openb3dex_tcamera_cls_color = 0;
	o->_openb3d_openb3dex_tcamera_cls_zbuffer = 0;
	o->_openb3d_openb3dex_tcamera_range_near = 0;
	o->_openb3d_openb3dex_tcamera_range_far = 0;
	o->_openb3d_openb3dex_tcamera_zoom = 0;
	o->_openb3d_openb3dex_tcamera_proj_mode = 0;
	o->_openb3d_openb3dex_tcamera_fog_mode = 0;
	o->_openb3d_openb3dex_tcamera_fog_r = 0;
	o->_openb3d_openb3dex_tcamera_fog_g = 0;
	o->_openb3d_openb3dex_tcamera_fog_b = 0;
	o->_openb3d_openb3dex_tcamera_fog_range_near = 0;
	o->_openb3d_openb3dex_tcamera_fog_range_far = 0;
	o->_openb3d_openb3dex_tcamera_project_enabled = 0;
	o->_openb3d_openb3dex_tcamera_mod_mat = 0;
	o->_openb3d_openb3dex_tcamera_proj_mat = 0;
	o->_openb3d_openb3dex_tcamera_viewport = 0;
	o->_openb3d_openb3dex_tcamera_frustum = 0;
}
void _openb3d_openb3dex_TCamera_Delete(struct openb3d_openb3dex_TCamera_obj* o) {
	_openb3d_openb3dex_TEntity_Delete(o);
}
struct openb3d_openb3dex_TCamera_obj* openb3d_openb3dex_TCamera_CreateObject_TTCamera_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TCamera_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TCamera);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TCamera_InitGlobals_i(){
	openb3d_openb3dex_TCamera_projected_x=StaticFloat(6,26);
	openb3d_openb3dex_TCamera_projected_y=StaticFloat(6,27);
	openb3d_openb3dex_TCamera_projected_z=StaticFloat(6,28);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_InitFields(struct openb3d_openb3dex_TCamera_obj* o){
	(&openb3d_openb3dex_TCamera)->super->m_InitFields(o);
	o->_openb3d_openb3dex_tcamera_cls_color =CameraBool(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),10);
	o->_openb3d_openb3dex_tcamera_cls_zbuffer =CameraBool(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),11);
	o->_openb3d_openb3dex_tcamera_vx =CameraInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),3);
	o->_openb3d_openb3dex_tcamera_vy =CameraInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4);
	o->_openb3d_openb3dex_tcamera_vwidth =CameraInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),5);
	o->_openb3d_openb3dex_tcamera_vheight =CameraInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),6);
	o->_openb3d_openb3dex_tcamera_proj_mode =CameraInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),15);
	o->_openb3d_openb3dex_tcamera_fog_mode =CameraInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),16);
	o->_openb3d_openb3dex_tcamera_project_enabled =CameraInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),22);
	o->_openb3d_openb3dex_tcamera_viewport =CameraInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),25);
	o->_openb3d_openb3dex_tcamera_cls_r =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),7);
	o->_openb3d_openb3dex_tcamera_cls_g =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),8);
	o->_openb3d_openb3dex_tcamera_cls_b =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),9);
	o->_openb3d_openb3dex_tcamera_range_near =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),12);
	o->_openb3d_openb3dex_tcamera_range_far =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),13);
	o->_openb3d_openb3dex_tcamera_zoom =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),14);
	o->_openb3d_openb3dex_tcamera_fog_r =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),17);
	o->_openb3d_openb3dex_tcamera_fog_g =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),18);
	o->_openb3d_openb3dex_tcamera_fog_b =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),19);
	o->_openb3d_openb3dex_tcamera_fog_range_near =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),20);
	o->_openb3d_openb3dex_tcamera_fog_range_far =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),21);
	o->_openb3d_openb3dex_tcamera_mod_mat =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),23);
	o->_openb3d_openb3dex_tcamera_proj_mat =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),24);
	o->_openb3d_openb3dex_tcamera_frustum =CameraFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),29);
	o->clas->f_AddList__i_TTList(openb3d_openb3dex_TCamera_cam_list);
	return 0;
}
BBINT openb3d_openb3dex_TCamera_AddList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	openb3d_openb3dex_TEntity_AddList__i_TTList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TCamera_cam_list){
		if(StaticListSize(6,1)!=0){
			BBBYTE* bbt_inst=StaticIterListCamera(6,1,(&openb3d_openb3dex_TCamera_cam_list_id));
			struct openb3d_openb3dex_TCamera_obj* volatile bbt_obj=((struct openb3d_openb3dex_TCamera_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TCamera));
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TCamera_CopyList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	openb3d_openb3dex_TEntity_CopyList__i_TTList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TCamera_cam_list){
		openb3d_openb3dex_TCamera_cam_list_id=0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(StaticListSize(6,1)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=StaticIterListCamera(6,1,(&openb3d_openb3dex_TCamera_cam_list_id));
				struct openb3d_openb3dex_TCamera_obj* volatile bbt_obj=((struct openb3d_openb3dex_TCamera_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TCamera));
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_FreeEntity(struct openb3d_openb3dex_TCamera_obj* o){
	if(o->_openb3d_openb3dex_tentity_exists !=0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TCamera_cam_list,o);
		openb3d_openb3dex_TCamera_cam_list_id-=1;
		(&openb3d_openb3dex_TCamera)->super->m_FreeEntity(o);
	}
	return 0;
}
struct openb3d_openb3dex_TCamera_obj* openb3d_openb3dex_TCamera_CreateCamera_TTCamera_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateCamera(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TCamera_obj* volatile bbt_cam=openb3d_openb3dex_TCamera_CreateObject_TTCamera_pb(bbt_inst);
	openb3d_openb3dex_TGlobal_camera_in_use=bbt_cam;
	return bbt_cam;
}
BBINT _openb3d_openb3dex_TCamera_CameraViewport_iiii(struct openb3d_openb3dex_TCamera_obj* o,BBINT bbt_x,BBINT bbt_y,BBINT bbt_width,BBINT bbt_height){
	CameraViewport(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_y,bbt_width,bbt_height);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_CameraClsColor_fff(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	CameraClsColor(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_CameraClsMode_ii(struct openb3d_openb3dex_TCamera_obj* o,BBINT bbt_cls_depth,BBINT bbt_cls_zbuffer){
	CameraClsMode(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_cls_depth,bbt_cls_zbuffer);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_CameraRange_ff(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_nnear,BBFLOAT bbt_nfar){
	CameraRange(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_nnear,bbt_nfar);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_CameraZoom_f(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_zoom){
	CameraZoom(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_zoom);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_CameraProjMode_i(struct openb3d_openb3dex_TCamera_obj* o,BBINT bbt_Mode){
	CameraProjMode(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_Mode);
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* _openb3d_openb3dex_TCamera_CameraPick_ff(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y){
	BBBYTE* bbt_inst=CameraPick(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,(((BBFLOAT)brl_graphics_GraphicsHeight())-bbt_y));
	return openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TCamera_CameraFogMode_i(struct openb3d_openb3dex_TCamera_obj* o,BBINT bbt_Mode){
	CameraFogMode(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_Mode);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_CameraFogColor_fff(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	CameraFogColor(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_CameraFogRange_ff(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_nnear,BBFLOAT bbt_nfar){
	CameraFogRange(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_nnear,bbt_nfar);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_CameraProject_fff(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	CameraProject(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_y,bbt_z);
	return 0;
}
BBFLOAT openb3d_openb3dex_TCamera_ProjectedX_f(){
	return ProjectedX();
}
BBFLOAT openb3d_openb3dex_TCamera_ProjectedY_f(){
	return ProjectedY();
}
BBFLOAT openb3d_openb3dex_TCamera_ProjectedZ_f(){
	return ProjectedZ();
}
BBINT _openb3d_openb3dex_TCamera_EntityInView_TTEntity(struct openb3d_openb3dex_TCamera_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return EntityInView(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
}
struct openb3d_openb3dex_TCamera_obj* _openb3d_openb3dex_TCamera_CopyEntity_TTEntity(struct openb3d_openb3dex_TCamera_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TCamera_obj* volatile bbt_cam=o->clas->f_CreateObject_TTCamera_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_cam;
}
BBINT _openb3d_openb3dex_TCamera_Update(struct openb3d_openb3dex_TCamera_obj* o){
	CameraUpdate(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_Render(struct openb3d_openb3dex_TCamera_obj* o){
	CameraRender(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_UpdateSprite_TTSprite(struct openb3d_openb3dex_TCamera_obj* o,struct openb3d_openb3dex_TSprite_obj* bbt_sprite){
	UpdateSprite(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_sprite,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_AddTransformedSpriteToSurface_TTSpriteTTSurface(struct openb3d_openb3dex_TCamera_obj* o,struct openb3d_openb3dex_TSprite_obj* bbt_sprite,struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	AddTransformedSpriteToSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_sprite,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf));
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_RenderListAdd_TTMesh(struct openb3d_openb3dex_TCamera_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	RenderListAdd(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_ExtractFrustum(struct openb3d_openb3dex_TCamera_obj* o){
	ExtractFrustum(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBFLOAT _openb3d_openb3dex_TCamera_EntityInFrustum_TTEntity(struct openb3d_openb3dex_TCamera_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return EntityInFrustum(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent));
}
BBINT _openb3d_openb3dex_TCamera_accPerspective_fffffffff(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_fovy,BBFLOAT bbt_aspect,BBFLOAT bbt_zNear,BBFLOAT bbt_zFar,BBFLOAT bbt_pixdx,BBFLOAT bbt_pixdy,BBFLOAT bbt_eyedx,BBFLOAT bbt_eyedy,BBFLOAT bbt_focus){
	accPerspective(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_fovy,bbt_aspect,bbt_zNear,bbt_zFar,bbt_pixdx,bbt_pixdy,bbt_eyedx,bbt_eyedy,bbt_focus);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_accFrustum_fffffffffff(struct openb3d_openb3dex_TCamera_obj* o,BBFLOAT bbt_left_,BBFLOAT bbt_right_,BBFLOAT bbt_bottom,BBFLOAT bbt_top,BBFLOAT bbt_zNear,BBFLOAT bbt_zFar,BBFLOAT bbt_pixdx,BBFLOAT bbt_pixdy,BBFLOAT bbt_eyedx,BBFLOAT bbt_eyedy,BBFLOAT bbt_focus){
	accFrustum(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_left_,bbt_right_,bbt_bottom,bbt_top,bbt_zNear,bbt_zFar,bbt_pixdx,bbt_pixdy,bbt_eyedx,bbt_eyedy,bbt_focus);
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_UpdateProjMatrix(struct openb3d_openb3dex_TCamera_obj* o){
	UpdateProjMatrix(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT openb3d_openb3dex_TCamera_UpdateEntityRender_i_TTEntityTTCamera(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TCamera_obj* bbt_cam){
	CameraUpdateEntityRender(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_cam,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TCamera_UpdateFog(struct openb3d_openb3dex_TCamera_obj* o){
	if(openb3d_openb3dex_TGlobal_fog_enabled[0U]==1){
		glEnable((GLenum)2912);
		glFogf((GLenum)2917,(GLfloat)9729.00000f);
		glFogf((GLenum)2915,(GLfloat)o->_openb3d_openb3dex_tcamera_fog_range_near [0U]);
		glFogf((GLenum)2916,(GLfloat)o->_openb3d_openb3dex_tcamera_fog_range_far [0U]);
		BBFLOAT bbt_[]={o->_openb3d_openb3dex_tcamera_fog_r [0U],o->_openb3d_openb3dex_tcamera_fog_g [0U],o->_openb3d_openb3dex_tcamera_fog_b [0U]};
		BBARRAY bbt_2 = bbArrayFromData("f",3,bbt_);
		BBARRAY bbt_rgb=bbt_2;
		glFogfv((GLenum)2918,(const GLfloat*)((BBFLOAT*)BBARRAYDATA(bbt_rgb,bbt_rgb->dims)));
	}else{
		glDisable((GLenum)2912);
	}
	return 0;
}
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TCamera_cam_list;
BBINT openb3d_openb3dex_TCamera_cam_list_id;
BBFLOAT* openb3d_openb3dex_TCamera_projected_x;
BBFLOAT* openb3d_openb3dex_TCamera_projected_y;
BBFLOAT* openb3d_openb3dex_TCamera_projected_z;
struct BBDebugScope_65 openb3d_openb3dex_TCamera_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TCamera",
	{
		{
			BBDEBUGDECL_FIELD,
			"vx",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_vx)
		},
		{
			BBDEBUGDECL_FIELD,
			"vy",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_vy)
		},
		{
			BBDEBUGDECL_FIELD,
			"vwidth",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_vwidth)
		},
		{
			BBDEBUGDECL_FIELD,
			"vheight",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_vheight)
		},
		{
			BBDEBUGDECL_FIELD,
			"cls_r",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_cls_r)
		},
		{
			BBDEBUGDECL_FIELD,
			"cls_g",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_cls_g)
		},
		{
			BBDEBUGDECL_FIELD,
			"cls_b",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_cls_b)
		},
		{
			BBDEBUGDECL_FIELD,
			"cls_color",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_cls_color)
		},
		{
			BBDEBUGDECL_FIELD,
			"cls_zbuffer",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_cls_zbuffer)
		},
		{
			BBDEBUGDECL_FIELD,
			"range_near",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_range_near)
		},
		{
			BBDEBUGDECL_FIELD,
			"range_far",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_range_far)
		},
		{
			BBDEBUGDECL_FIELD,
			"zoom",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_zoom)
		},
		{
			BBDEBUGDECL_FIELD,
			"proj_mode",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_proj_mode)
		},
		{
			BBDEBUGDECL_FIELD,
			"fog_mode",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_fog_mode)
		},
		{
			BBDEBUGDECL_FIELD,
			"fog_r",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_fog_r)
		},
		{
			BBDEBUGDECL_FIELD,
			"fog_g",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_fog_g)
		},
		{
			BBDEBUGDECL_FIELD,
			"fog_b",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_fog_b)
		},
		{
			BBDEBUGDECL_FIELD,
			"fog_range_near",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_fog_range_near)
		},
		{
			BBDEBUGDECL_FIELD,
			"fog_range_far",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_fog_range_far)
		},
		{
			BBDEBUGDECL_FIELD,
			"project_enabled",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_project_enabled)
		},
		{
			BBDEBUGDECL_FIELD,
			"mod_mat",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_mod_mat)
		},
		{
			BBDEBUGDECL_FIELD,
			"proj_mat",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_proj_mat)
		},
		{
			BBDEBUGDECL_FIELD,
			"Viewport",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_viewport)
		},
		{
			BBDEBUGDECL_FIELD,
			"frustum",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_frustum)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"cam_list",
			":TList",
			&openb3d_openb3dex_TCamera_cam_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"projected_x",
			"*f",
			&openb3d_openb3dex_TCamera_projected_x
		},
		{
			BBDEBUGDECL_GLOBAL,
			"projected_y",
			"*f",
			&openb3d_openb3dex_TCamera_projected_y
		},
		{
			BBDEBUGDECL_GLOBAL,
			"projected_z",
			"*f",
			&openb3d_openb3dex_TCamera_projected_z
		},
		{
			BBDEBUGDECL_GLOBAL,
			"cam_list_id",
			"i",
			&openb3d_openb3dex_TCamera_cam_list_id
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TCamera_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TCamera",
			&openb3d_openb3dex_TCamera_CreateObject_TTCamera_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"InitGlobals",
			"()i",
			&openb3d_openb3dex_TCamera_InitGlobals_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TCamera_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AddList_",
			"(:TList)i",
			&openb3d_openb3dex_TCamera_AddList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList_",
			"(:TList)i",
			&openb3d_openb3dex_TCamera_CopyList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeEntity",
			"()i",
			&_openb3d_openb3dex_TCamera_FreeEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateCamera",
			"(:TEntity):TCamera",
			&openb3d_openb3dex_TCamera_CreateCamera_TTCamera_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraViewport",
			"(i,i,i,i)i",
			&_openb3d_openb3dex_TCamera_CameraViewport_iiii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraClsColor",
			"(f,f,f)i",
			&_openb3d_openb3dex_TCamera_CameraClsColor_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraClsMode",
			"(i,i)i",
			&_openb3d_openb3dex_TCamera_CameraClsMode_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraRange",
			"(f,f)i",
			&_openb3d_openb3dex_TCamera_CameraRange_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraZoom",
			"(f)i",
			&_openb3d_openb3dex_TCamera_CameraZoom_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraProjMode",
			"(i)i",
			&_openb3d_openb3dex_TCamera_CameraProjMode_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraPick",
			"(f,f):TEntity",
			&_openb3d_openb3dex_TCamera_CameraPick_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraFogMode",
			"(i)i",
			&_openb3d_openb3dex_TCamera_CameraFogMode_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraFogColor",
			"(f,f,f)i",
			&_openb3d_openb3dex_TCamera_CameraFogColor_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraFogRange",
			"(f,f)i",
			&_openb3d_openb3dex_TCamera_CameraFogRange_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraProject",
			"(f,f,f)i",
			&_openb3d_openb3dex_TCamera_CameraProject_fff
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ProjectedX",
			"()f",
			&openb3d_openb3dex_TCamera_ProjectedX_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ProjectedY",
			"()f",
			&openb3d_openb3dex_TCamera_ProjectedY_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ProjectedZ",
			"()f",
			&openb3d_openb3dex_TCamera_ProjectedZ_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityInView",
			"(:TEntity)i",
			&_openb3d_openb3dex_TCamera_EntityInView_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TCamera",
			&_openb3d_openb3dex_TCamera_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Update",
			"()i",
			&_openb3d_openb3dex_TCamera_Update
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Render",
			"()i",
			&_openb3d_openb3dex_TCamera_Render
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateSprite",
			"(:TSprite)i",
			&_openb3d_openb3dex_TCamera_UpdateSprite_TTSprite
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AddTransformedSpriteToSurface",
			"(:TSprite,:TSurface)i",
			&_openb3d_openb3dex_TCamera_AddTransformedSpriteToSurface_TTSpriteTTSurface
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RenderListAdd",
			"(:TMesh)i",
			&_openb3d_openb3dex_TCamera_RenderListAdd_TTMesh
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ExtractFrustum",
			"()i",
			&_openb3d_openb3dex_TCamera_ExtractFrustum
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EntityInFrustum",
			"(:TEntity)f",
			&_openb3d_openb3dex_TCamera_EntityInFrustum_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"accPerspective",
			"(f,f,f,f,f,f,f,f,f)i",
			&_openb3d_openb3dex_TCamera_accPerspective_fffffffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"accFrustum",
			"(f,f,f,f,f,f,f,f,f,f,f)i",
			&_openb3d_openb3dex_TCamera_accFrustum_fffffffffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateProjMatrix",
			"()i",
			&_openb3d_openb3dex_TCamera_UpdateProjMatrix
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UpdateEntityRender",
			"(:TEntity,:TCamera)i",
			&openb3d_openb3dex_TCamera_UpdateEntityRender_i_TTEntityTTCamera
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateFog",
			"()i",
			&_openb3d_openb3dex_TCamera_UpdateFog
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TCamera openb3d_openb3dex_TCamera={
	&openb3d_openb3dex_TEntity,
	bbObjectFree,
	&openb3d_openb3dex_TCamera_scope,
	sizeof(struct openb3d_openb3dex_TCamera_obj),
	_openb3d_openb3dex_TCamera_New,
	_openb3d_openb3dex_TCamera_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TCamera_obj,_openb3d_openb3dex_tcamera_frustum) - sizeof(void*) + sizeof(BBFLOAT*)
	,_openb3d_openb3dex_TCamera_CopyEntity_TTEntity
	,_openb3d_openb3dex_TCamera_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TCamera_InitGlobals_i
	,_openb3d_openb3dex_TCamera_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TCamera_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TCamera_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TCamera_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TCamera_CreateObject_TTCamera_pb
	,openb3d_openb3dex_TCamera_CreateCamera_TTCamera_TTEntity
	,_openb3d_openb3dex_TCamera_CameraViewport_iiii
	,_openb3d_openb3dex_TCamera_CameraClsColor_fff
	,_openb3d_openb3dex_TCamera_CameraClsMode_ii
	,_openb3d_openb3dex_TCamera_CameraRange_ff
	,_openb3d_openb3dex_TCamera_CameraZoom_f
	,_openb3d_openb3dex_TCamera_CameraProjMode_i
	,_openb3d_openb3dex_TCamera_CameraPick_ff
	,_openb3d_openb3dex_TCamera_CameraFogMode_i
	,_openb3d_openb3dex_TCamera_CameraFogColor_fff
	,_openb3d_openb3dex_TCamera_CameraFogRange_ff
	,_openb3d_openb3dex_TCamera_CameraProject_fff
	,openb3d_openb3dex_TCamera_ProjectedX_f
	,openb3d_openb3dex_TCamera_ProjectedY_f
	,openb3d_openb3dex_TCamera_ProjectedZ_f
	,_openb3d_openb3dex_TCamera_EntityInView_TTEntity
	,_openb3d_openb3dex_TCamera_Render
	,_openb3d_openb3dex_TCamera_UpdateSprite_TTSprite
	,_openb3d_openb3dex_TCamera_AddTransformedSpriteToSurface_TTSpriteTTSurface
	,_openb3d_openb3dex_TCamera_RenderListAdd_TTMesh
	,_openb3d_openb3dex_TCamera_ExtractFrustum
	,_openb3d_openb3dex_TCamera_EntityInFrustum_TTEntity
	,_openb3d_openb3dex_TCamera_accPerspective_fffffffff
	,_openb3d_openb3dex_TCamera_accFrustum_fffffffffff
	,_openb3d_openb3dex_TCamera_UpdateProjMatrix
	,openb3d_openb3dex_TCamera_UpdateEntityRender_i_TTEntityTTCamera
	,_openb3d_openb3dex_TCamera_UpdateFog
};

void _openb3d_openb3dex_TLight_New(struct openb3d_openb3dex_TLight_obj* o) {
	_openb3d_openb3dex_TEntity_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TLight;
	o->_openb3d_openb3dex_tlight_cast_shadow = 0;
	o->_openb3d_openb3dex_tlight_light_type = 0;
	o->_openb3d_openb3dex_tlight_range = 0;
	o->_openb3d_openb3dex_tlight_red = 0;
	o->_openb3d_openb3dex_tlight_green = 0;
	o->_openb3d_openb3dex_tlight_blue = 0;
	o->_openb3d_openb3dex_tlight_inner_ang = 0;
	o->_openb3d_openb3dex_tlight_outer_ang = 0;
}
void _openb3d_openb3dex_TLight_Delete(struct openb3d_openb3dex_TLight_obj* o) {
	_openb3d_openb3dex_TEntity_Delete(o);
}
struct openb3d_openb3dex_TLight_obj* openb3d_openb3dex_TLight_CreateObject_TTLight_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TLight_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TLight);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TLight_InitGlobals_i(){
	openb3d_openb3dex_TLight_light_no=StaticInt(25,1);
	openb3d_openb3dex_TLight_no_lights=StaticInt(25,2);
	openb3d_openb3dex_TLight_max_lights=StaticInt(25,3);
	openb3d_openb3dex_TLight_gl_light=StaticInt(25,4);
	return 0;
}
BBINT _openb3d_openb3dex_TLight_InitFields(struct openb3d_openb3dex_TLight_obj* o){
	(&openb3d_openb3dex_TLight)->super->m_InitFields(o);
	o->_openb3d_openb3dex_tlight_cast_shadow =LightChar(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),6);
	o->_openb3d_openb3dex_tlight_light_type =LightChar(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),7);
	o->_openb3d_openb3dex_tlight_range =LightFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),8);
	o->_openb3d_openb3dex_tlight_red =LightFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),9);
	o->_openb3d_openb3dex_tlight_green =LightFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),10);
	o->_openb3d_openb3dex_tlight_blue =LightFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),11);
	o->_openb3d_openb3dex_tlight_inner_ang =LightFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),12);
	o->_openb3d_openb3dex_tlight_outer_ang =LightFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),13);
	o->clas->f_AddList__i_TTList(openb3d_openb3dex_TLight_light_list);
	return 0;
}
BBINT openb3d_openb3dex_TLight_AddList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	openb3d_openb3dex_TEntity_AddList__i_TTList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TLight_light_list){
		if(StaticListSize(25,5)!=0){
			BBBYTE* bbt_inst=StaticIterVectorLight(25,5,(&openb3d_openb3dex_TLight_light_list_id));
			struct openb3d_openb3dex_TLight_obj* volatile bbt_obj=((struct openb3d_openb3dex_TLight_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TLight));
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TLight_CopyList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	openb3d_openb3dex_TEntity_CopyList__i_TTList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TLight_light_list){
		openb3d_openb3dex_TLight_light_list_id=0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(StaticListSize(25,5)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=StaticIterVectorLight(25,5,(&openb3d_openb3dex_TLight_light_list_id));
				struct openb3d_openb3dex_TLight_obj* volatile bbt_obj=((struct openb3d_openb3dex_TLight_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TLight));
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TLight_FreeEntity(struct openb3d_openb3dex_TLight_obj* o){
	if(o->_openb3d_openb3dex_tentity_exists !=0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TLight_light_list,o);
		openb3d_openb3dex_TLight_light_list_id-=1;
		(&openb3d_openb3dex_TLight)->super->m_FreeEntity(o);
	}
	return 0;
}
struct openb3d_openb3dex_TLight_obj* openb3d_openb3dex_TLight_CreateLight_TTLight_iTTEntity(BBINT bbt_light_type,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateLight(bbt_light_type,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TLight_CreateObject_TTLight_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TLight_LightRange_f(struct openb3d_openb3dex_TLight_obj* o,BBFLOAT bbt_Range){
	LightRange(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_Range);
	return 0;
}
BBINT _openb3d_openb3dex_TLight_LightColor_fff(struct openb3d_openb3dex_TLight_obj* o,BBFLOAT bbt_red,BBFLOAT bbt_green,BBFLOAT bbt_blue){
	LightColor(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_red,bbt_green,bbt_blue);
	return 0;
}
BBINT _openb3d_openb3dex_TLight_LightConeAngles_ff(struct openb3d_openb3dex_TLight_obj* o,BBFLOAT bbt_inner_ang,BBFLOAT bbt_outer_ang){
	LightConeAngles(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_inner_ang,bbt_outer_ang);
	return 0;
}
struct openb3d_openb3dex_TLight_obj* _openb3d_openb3dex_TLight_CopyEntity_TTEntity(struct openb3d_openb3dex_TLight_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TLight_obj* volatile bbt_light=o->clas->f_CreateObject_TTLight_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_light;
}
BBINT _openb3d_openb3dex_TLight_Update(struct openb3d_openb3dex_TLight_obj* o){
	LightUpdate(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT openb3d_openb3dex_TLight_GetLightValues_i(){
	{
		BBINT bbt_i=0;
		BBINT bbt_=(openb3d_openb3dex_TLight_no_lights[0U]-1);
		for(bbt_i;(bbt_i<=bbt_);bbt_i=(bbt_i+1)){
			BBUINT* bbt_2=((BBARRAY)openb3d_openb3dex_TLight_ambient)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4608,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_ambient),(openb3d_openb3dex_TLight_ambient)->dims))[(*(bbt_2)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_3=((BBARRAY)openb3d_openb3dex_TLight_diffuse)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4609,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_diffuse),(openb3d_openb3dex_TLight_diffuse)->dims))[(*(bbt_3)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_4=((BBARRAY)openb3d_openb3dex_TLight_specular)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4610,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_specular),(openb3d_openb3dex_TLight_specular)->dims))[(*(bbt_4)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_5=((BBARRAY)openb3d_openb3dex_TLight_position)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4611,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_position),(openb3d_openb3dex_TLight_position)->dims))[(*(bbt_5)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_6=((BBARRAY)openb3d_openb3dex_TLight_spotDirection)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4612,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_spotDirection),(openb3d_openb3dex_TLight_spotDirection)->dims))[(*(bbt_6)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_7=((BBARRAY)openb3d_openb3dex_TLight_spotExponent)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4613,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_spotExponent),(openb3d_openb3dex_TLight_spotExponent)->dims))[(*(bbt_7)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_8=((BBARRAY)openb3d_openb3dex_TLight_spotCutoff)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4614,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_spotCutoff),(openb3d_openb3dex_TLight_spotCutoff)->dims))[(*(bbt_8)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_9=((BBARRAY)openb3d_openb3dex_TLight_constantAtt)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4615,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_constantAtt),(openb3d_openb3dex_TLight_constantAtt)->dims))[(*(bbt_9)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_10=((BBARRAY)openb3d_openb3dex_TLight_linearAtt)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4616,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_linearAtt),(openb3d_openb3dex_TLight_linearAtt)->dims))[(*(bbt_10)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_11=((BBARRAY)openb3d_openb3dex_TLight_quadraticAtt)->scales + 1;
			glGetLightfv((GLenum)(16384+bbt_i),(GLenum)4617,(GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_quadraticAtt),(openb3d_openb3dex_TLight_quadraticAtt)->dims))[(*(bbt_11)) * ((BBUINT)bbt_i) + 0U]));
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TLight_SetLightValues_i(){
	{
		BBINT bbt_i=0;
		BBINT bbt_=(openb3d_openb3dex_TLight_no_lights[0U]-1);
		for(bbt_i;(bbt_i<=bbt_);bbt_i=(bbt_i+1)){
			BBUINT* bbt_2=((BBARRAY)openb3d_openb3dex_TLight_ambient)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4608,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_ambient),(openb3d_openb3dex_TLight_ambient)->dims))[(*(bbt_2)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_3=((BBARRAY)openb3d_openb3dex_TLight_diffuse)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4609,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_diffuse),(openb3d_openb3dex_TLight_diffuse)->dims))[(*(bbt_3)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_4=((BBARRAY)openb3d_openb3dex_TLight_specular)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4610,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_specular),(openb3d_openb3dex_TLight_specular)->dims))[(*(bbt_4)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_5=((BBARRAY)openb3d_openb3dex_TLight_position)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4611,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_position),(openb3d_openb3dex_TLight_position)->dims))[(*(bbt_5)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_6=((BBARRAY)openb3d_openb3dex_TLight_spotDirection)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4612,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_spotDirection),(openb3d_openb3dex_TLight_spotDirection)->dims))[(*(bbt_6)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_7=((BBARRAY)openb3d_openb3dex_TLight_spotExponent)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4613,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_spotExponent),(openb3d_openb3dex_TLight_spotExponent)->dims))[(*(bbt_7)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_8=((BBARRAY)openb3d_openb3dex_TLight_spotCutoff)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4614,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_spotCutoff),(openb3d_openb3dex_TLight_spotCutoff)->dims))[(*(bbt_8)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_9=((BBARRAY)openb3d_openb3dex_TLight_constantAtt)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4615,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_constantAtt),(openb3d_openb3dex_TLight_constantAtt)->dims))[(*(bbt_9)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_10=((BBARRAY)openb3d_openb3dex_TLight_linearAtt)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4616,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_linearAtt),(openb3d_openb3dex_TLight_linearAtt)->dims))[(*(bbt_10)) * ((BBUINT)bbt_i) + 0U]));
			BBUINT* bbt_11=((BBARRAY)openb3d_openb3dex_TLight_quadraticAtt)->scales + 1;
			glLightfv((GLenum)(16384+bbt_i),(GLenum)4617,(const GLfloat*)(&((BBFLOAT*)BBARRAYDATA((openb3d_openb3dex_TLight_quadraticAtt),(openb3d_openb3dex_TLight_quadraticAtt)->dims))[(*(bbt_11)) * ((BBUINT)bbt_i) + 0U]));
		}
	}
	return 0;
}
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TLight_light_list;
BBINT openb3d_openb3dex_TLight_light_list_id;
BBINT* openb3d_openb3dex_TLight_light_no;
BBINT* openb3d_openb3dex_TLight_no_lights;
BBINT* openb3d_openb3dex_TLight_max_lights;
BBINT* openb3d_openb3dex_TLight_gl_light;
BBARRAY openb3d_openb3dex_TLight_ambient;
BBARRAY openb3d_openb3dex_TLight_diffuse;
BBARRAY openb3d_openb3dex_TLight_specular;
BBARRAY openb3d_openb3dex_TLight_position;
BBARRAY openb3d_openb3dex_TLight_spotDirection;
BBARRAY openb3d_openb3dex_TLight_spotExponent;
BBARRAY openb3d_openb3dex_TLight_spotCutoff;
BBARRAY openb3d_openb3dex_TLight_constantAtt;
BBARRAY openb3d_openb3dex_TLight_linearAtt;
BBARRAY openb3d_openb3dex_TLight_quadraticAtt;
struct BBDebugScope_39 openb3d_openb3dex_TLight_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TLight",
	{
		{
			BBDEBUGDECL_FIELD,
			"cast_shadow",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_cast_shadow)
		},
		{
			BBDEBUGDECL_FIELD,
			"light_type",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_light_type)
		},
		{
			BBDEBUGDECL_FIELD,
			"Range",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_range)
		},
		{
			BBDEBUGDECL_FIELD,
			"red",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_red)
		},
		{
			BBDEBUGDECL_FIELD,
			"green",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_green)
		},
		{
			BBDEBUGDECL_FIELD,
			"blue",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_blue)
		},
		{
			BBDEBUGDECL_FIELD,
			"inner_ang",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_inner_ang)
		},
		{
			BBDEBUGDECL_FIELD,
			"outer_ang",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_outer_ang)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"light_no",
			"*i",
			&openb3d_openb3dex_TLight_light_no
		},
		{
			BBDEBUGDECL_GLOBAL,
			"no_lights",
			"*i",
			&openb3d_openb3dex_TLight_no_lights
		},
		{
			BBDEBUGDECL_GLOBAL,
			"max_lights",
			"*i",
			&openb3d_openb3dex_TLight_max_lights
		},
		{
			BBDEBUGDECL_GLOBAL,
			"gl_light",
			"*i",
			&openb3d_openb3dex_TLight_gl_light
		},
		{
			BBDEBUGDECL_GLOBAL,
			"light_list",
			":TList",
			&openb3d_openb3dex_TLight_light_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ambient",
			"[,]f",
			&openb3d_openb3dex_TLight_ambient
		},
		{
			BBDEBUGDECL_GLOBAL,
			"diffuse",
			"[,]f",
			&openb3d_openb3dex_TLight_diffuse
		},
		{
			BBDEBUGDECL_GLOBAL,
			"specular",
			"[,]f",
			&openb3d_openb3dex_TLight_specular
		},
		{
			BBDEBUGDECL_GLOBAL,
			"position",
			"[,]f",
			&openb3d_openb3dex_TLight_position
		},
		{
			BBDEBUGDECL_GLOBAL,
			"spotDirection",
			"[,]f",
			&openb3d_openb3dex_TLight_spotDirection
		},
		{
			BBDEBUGDECL_GLOBAL,
			"spotExponent",
			"[,]f",
			&openb3d_openb3dex_TLight_spotExponent
		},
		{
			BBDEBUGDECL_GLOBAL,
			"spotCutoff",
			"[,]f",
			&openb3d_openb3dex_TLight_spotCutoff
		},
		{
			BBDEBUGDECL_GLOBAL,
			"constantAtt",
			"[,]f",
			&openb3d_openb3dex_TLight_constantAtt
		},
		{
			BBDEBUGDECL_GLOBAL,
			"linearAtt",
			"[,]f",
			&openb3d_openb3dex_TLight_linearAtt
		},
		{
			BBDEBUGDECL_GLOBAL,
			"quadraticAtt",
			"[,]f",
			&openb3d_openb3dex_TLight_quadraticAtt
		},
		{
			BBDEBUGDECL_GLOBAL,
			"light_list_id",
			"i",
			&openb3d_openb3dex_TLight_light_list_id
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TLight_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TLight",
			&openb3d_openb3dex_TLight_CreateObject_TTLight_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"InitGlobals",
			"()i",
			&openb3d_openb3dex_TLight_InitGlobals_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TLight_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AddList_",
			"(:TList)i",
			&openb3d_openb3dex_TLight_AddList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList_",
			"(:TList)i",
			&openb3d_openb3dex_TLight_CopyList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeEntity",
			"()i",
			&_openb3d_openb3dex_TLight_FreeEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateLight",
			"(i,:TEntity):TLight",
			&openb3d_openb3dex_TLight_CreateLight_TTLight_iTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"LightRange",
			"(f)i",
			&_openb3d_openb3dex_TLight_LightRange_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"LightColor",
			"(f,f,f)i",
			&_openb3d_openb3dex_TLight_LightColor_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"LightConeAngles",
			"(f,f)i",
			&_openb3d_openb3dex_TLight_LightConeAngles_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TLight",
			&_openb3d_openb3dex_TLight_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Update",
			"()i",
			&_openb3d_openb3dex_TLight_Update
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetLightValues",
			"()i",
			&openb3d_openb3dex_TLight_GetLightValues_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"SetLightValues",
			"()i",
			&openb3d_openb3dex_TLight_SetLightValues_i
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TLight openb3d_openb3dex_TLight={
	&openb3d_openb3dex_TEntity,
	bbObjectFree,
	&openb3d_openb3dex_TLight_scope,
	sizeof(struct openb3d_openb3dex_TLight_obj),
	_openb3d_openb3dex_TLight_New,
	_openb3d_openb3dex_TLight_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TLight_obj,_openb3d_openb3dex_tlight_outer_ang) - sizeof(void*) + sizeof(BBFLOAT*)
	,_openb3d_openb3dex_TLight_CopyEntity_TTEntity
	,_openb3d_openb3dex_TLight_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TLight_InitGlobals_i
	,_openb3d_openb3dex_TLight_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TLight_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TLight_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TLight_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TLight_CreateObject_TTLight_pb
	,openb3d_openb3dex_TLight_CreateLight_TTLight_iTTEntity
	,_openb3d_openb3dex_TLight_LightRange_f
	,_openb3d_openb3dex_TLight_LightColor_fff
	,_openb3d_openb3dex_TLight_LightConeAngles_ff
	,openb3d_openb3dex_TLight_GetLightValues_i
	,openb3d_openb3dex_TLight_SetLightValues_i
};

void _openb3d_openb3dex_TPivot_New(struct openb3d_openb3dex_TPivot_obj* o) {
	_openb3d_openb3dex_TEntity_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TPivot;
}
void _openb3d_openb3dex_TPivot_Delete(struct openb3d_openb3dex_TPivot_obj* o) {
	_openb3d_openb3dex_TEntity_Delete(o);
}
struct openb3d_openb3dex_TPivot_obj* openb3d_openb3dex_TPivot_CreateObject_TTPivot_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TPivot_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TPivot);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TPivot_InitFields(struct openb3d_openb3dex_TPivot_obj* o){
	(&openb3d_openb3dex_TPivot)->super->m_InitFields(o);
	return 0;
}
BBINT _openb3d_openb3dex_TPivot_FreeEntity(struct openb3d_openb3dex_TPivot_obj* o){
	(&openb3d_openb3dex_TPivot)->super->m_FreeEntity(o);
	return 0;
}
struct openb3d_openb3dex_TPivot_obj* openb3d_openb3dex_TPivot_CreatePivot_TTPivot_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreatePivot(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TPivot_CreateObject_TTPivot_pb(bbt_inst);
}
struct openb3d_openb3dex_TPivot_obj* _openb3d_openb3dex_TPivot_CopyEntity_TTEntity(struct openb3d_openb3dex_TPivot_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TPivot_obj* volatile bbt_pivot=o->clas->f_CreateObject_TTPivot_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_pivot;
}
BBINT _openb3d_openb3dex_TPivot_Update(struct openb3d_openb3dex_TPivot_obj* o){
	return 0;
}
struct BBDebugScope_7 openb3d_openb3dex_TPivot_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TPivot",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TPivot_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TPivot",
			&openb3d_openb3dex_TPivot_CreateObject_TTPivot_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TPivot_InitFields
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeEntity",
			"()i",
			&_openb3d_openb3dex_TPivot_FreeEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreatePivot",
			"(:TEntity):TPivot",
			&openb3d_openb3dex_TPivot_CreatePivot_TTPivot_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TPivot",
			&_openb3d_openb3dex_TPivot_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Update",
			"()i",
			&_openb3d_openb3dex_TPivot_Update
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TPivot openb3d_openb3dex_TPivot={
	&openb3d_openb3dex_TEntity,
	bbObjectFree,
	&openb3d_openb3dex_TPivot_scope,
	sizeof(struct openb3d_openb3dex_TPivot_obj),
	_openb3d_openb3dex_TPivot_New,
	_openb3d_openb3dex_TPivot_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,_openb3d_openb3dex_TPivot_CopyEntity_TTEntity
	,_openb3d_openb3dex_TPivot_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TPivot_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TPivot_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TPivot_CreateObject_TTPivot_pb
	,openb3d_openb3dex_TPivot_CreatePivot_TTPivot_TTEntity
};

void _openb3d_openb3dex_TMesh_New(struct openb3d_openb3dex_TMesh_obj* o) {
	_openb3d_openb3dex_TEntity_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TMesh;
	o->_openb3d_openb3dex_tmesh_no_surfs = 0;
	o->_openb3d_openb3dex_tmesh_surf_list = brl_linkedlist_CreateList();
	o->_openb3d_openb3dex_tmesh_anim_surf_list = brl_linkedlist_CreateList();
	o->_openb3d_openb3dex_tmesh_bones = brl_linkedlist_CreateList();
	o->_openb3d_openb3dex_tmesh_mat_sp = &bbNullObject;
	o->_openb3d_openb3dex_tmesh_reset_col_tree = 0;
	o->_openb3d_openb3dex_tmesh_reset_bounds = 0;
	o->_openb3d_openb3dex_tmesh_min_x = 0;
	o->_openb3d_openb3dex_tmesh_min_y = 0;
	o->_openb3d_openb3dex_tmesh_min_z = 0;
	o->_openb3d_openb3dex_tmesh_max_x = 0;
	o->_openb3d_openb3dex_tmesh_max_y = 0;
	o->_openb3d_openb3dex_tmesh_max_z = 0;
	o->_openb3d_openb3dex_tmesh_surf_list_id = 0;
	o->_openb3d_openb3dex_tmesh_anim_surf_list_id = 0;
	o->_openb3d_openb3dex_tmesh_bones_id = 0;
}
void _openb3d_openb3dex_TMesh_Delete(struct openb3d_openb3dex_TMesh_obj* o) {
	_openb3d_openb3dex_TEntity_Delete(o);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TMesh);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TMesh_InitFields(struct openb3d_openb3dex_TMesh_obj* o){
	((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_CopyList_TTList(o,o->_openb3d_openb3dex_tmesh_surf_list );
	((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_CopyList_TTList(o,o->_openb3d_openb3dex_tmesh_anim_surf_list );
	((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_CopyList_TTList(o,o->_openb3d_openb3dex_tmesh_bones );
	(&openb3d_openb3dex_TMesh)->super->m_InitFields(o);
	o->_openb3d_openb3dex_tmesh_no_surfs =MeshInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),1);
	o->_openb3d_openb3dex_tmesh_reset_col_tree =MeshInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),7);
	o->_openb3d_openb3dex_tmesh_reset_bounds =MeshInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),8);
	o->_openb3d_openb3dex_tmesh_min_x =MeshFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),9);
	o->_openb3d_openb3dex_tmesh_min_y =MeshFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),10);
	o->_openb3d_openb3dex_tmesh_min_z =MeshFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),11);
	o->_openb3d_openb3dex_tmesh_max_x =MeshFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),12);
	o->_openb3d_openb3dex_tmesh_max_y =MeshFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),13);
	o->_openb3d_openb3dex_tmesh_max_z =MeshFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),14);
	BBBYTE* bbt_inst=MeshMatrix(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),5);
	o->_openb3d_openb3dex_tmesh_mat_sp =openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tmesh_mat_sp ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tmesh_mat_sp =openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb(bbt_inst);
	}
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_AddList_TTList(struct openb3d_openb3dex_TMesh_obj* o,struct brl_linkedlist_TList_obj* bbt_list){
	(&openb3d_openb3dex_TMesh)->super->m_AddList_TTList(o,bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==o->_openb3d_openb3dex_tmesh_surf_list ){
		if(MeshListSize(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),2)!=0){
			BBBYTE* bbt_inst=MeshIterListSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),2,(&o->_openb3d_openb3dex_tmesh_surf_list_id ));
			struct openb3d_openb3dex_TSurface_obj* volatile bbt_obj=openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(bbt_inst);
			if((bbt_obj==&bbNullObject) && (bbt_inst!=0)){
				bbt_obj=openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb(bbt_inst);
			}
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}else{
		if(bbt_==o->_openb3d_openb3dex_tmesh_anim_surf_list ){
			if(MeshListSize(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),3)!=0){
				BBBYTE* bbt_inst2=MeshIterListSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),3,(&o->_openb3d_openb3dex_tmesh_anim_surf_list_id ));
				struct openb3d_openb3dex_TSurface_obj* volatile bbt_obj2=openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(bbt_inst2);
				if((bbt_obj2==&bbNullObject) && (bbt_inst2!=0)){
					bbt_obj2=openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb(bbt_inst2);
				}
				if(bbt_obj2!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj2);
				}
			}
		}else{
			if(bbt_==o->_openb3d_openb3dex_tmesh_bones ){
				if(MeshListSize(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4)!=0){
					BBBYTE* bbt_inst3=MeshIterVectorBone(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4,(&o->_openb3d_openb3dex_tmesh_bones_id ));
					struct openb3d_openb3dex_TBone_obj* volatile bbt_obj3=((struct openb3d_openb3dex_TBone_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst3),&openb3d_openb3dex_TBone));
					if((bbt_obj3==&bbNullObject) && (bbt_inst3!=0)){
						bbt_obj3=openb3d_openb3dex_TBone_CreateObject_TTBone_pb(bbt_inst3);
					}
					if(bbt_obj3!= &bbNullObject){
						brl_linkedlist_ListAddLast(bbt_list,bbt_obj3);
					}
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_CopyList_TTList(struct openb3d_openb3dex_TMesh_obj* o,struct brl_linkedlist_TList_obj* bbt_list){
	(&openb3d_openb3dex_TMesh)->super->m_CopyList_TTList(o,bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==o->_openb3d_openb3dex_tmesh_surf_list ){
		o->_openb3d_openb3dex_tmesh_surf_list_id =0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(MeshListSize(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),2)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=MeshIterListSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),2,(&o->_openb3d_openb3dex_tmesh_surf_list_id ));
				struct openb3d_openb3dex_TSurface_obj* volatile bbt_obj=openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(bbt_inst);
				if((bbt_obj==&bbNullObject) && (bbt_inst!=0)){
					bbt_obj=openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb(bbt_inst);
				}
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}else{
		if(bbt_==o->_openb3d_openb3dex_tmesh_anim_surf_list ){
			o->_openb3d_openb3dex_tmesh_anim_surf_list_id =0;
			{
				BBINT bbt_id2=0;
				BBINT bbt_3=(MeshListSize(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),3)-1);
				for(bbt_id2;(bbt_id2<=bbt_3);bbt_id2=(bbt_id2+1)){
					BBBYTE* bbt_inst2=MeshIterListSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),3,(&o->_openb3d_openb3dex_tmesh_anim_surf_list_id ));
					struct openb3d_openb3dex_TSurface_obj* volatile bbt_obj2=openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(bbt_inst2);
					if((bbt_obj2==&bbNullObject) && (bbt_inst2!=0)){
						bbt_obj2=openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb(bbt_inst2);
					}
					if(bbt_obj2!= &bbNullObject){
						brl_linkedlist_ListAddLast(bbt_list,bbt_obj2);
					}
				}
			}
		}else{
			if(bbt_==o->_openb3d_openb3dex_tmesh_bones ){
				o->_openb3d_openb3dex_tmesh_bones_id =0;
				{
					BBINT bbt_id3=0;
					BBINT bbt_4=(MeshListSize(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4)-1);
					for(bbt_id3;(bbt_id3<=bbt_4);bbt_id3=(bbt_id3+1)){
						BBBYTE* bbt_inst3=MeshIterVectorBone(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4,(&o->_openb3d_openb3dex_tmesh_bones_id ));
						struct openb3d_openb3dex_TBone_obj* volatile bbt_obj3=((struct openb3d_openb3dex_TBone_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst3),&openb3d_openb3dex_TBone));
						if((bbt_obj3==&bbNullObject) && (bbt_inst3!=0)){
							bbt_obj3=openb3d_openb3dex_TBone_CreateObject_TTBone_pb(bbt_inst3);
						}
						if(bbt_obj3!= &bbNullObject){
							brl_linkedlist_ListAddLast(bbt_list,bbt_obj3);
						}
					}
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_ListPushBack_TTListTObject(struct openb3d_openb3dex_TMesh_obj* o,struct brl_linkedlist_TList_obj* bbt_list,BBOBJECT bbt_value){
	(&openb3d_openb3dex_TMesh)->super->m_ListPushBack_TTListTObject(o,bbt_list,bbt_value);
	struct openb3d_openb3dex_TSurface_obj* volatile bbt_surf=((struct openb3d_openb3dex_TSurface_obj*)bbObjectDowncast(bbt_value,&openb3d_openb3dex_TSurface));
	struct openb3d_openb3dex_TBone_obj* volatile bbt_bone=((struct openb3d_openb3dex_TBone_obj*)bbObjectDowncast(bbt_value,&openb3d_openb3dex_TBone));
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==o->_openb3d_openb3dex_tmesh_surf_list ){
		if(bbt_surf!= &bbNullObject){
			MeshListPushBackSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),2,openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf));
			((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_AddList_TTList(o,bbt_list);
			o->_openb3d_openb3dex_tmesh_no_surfs [0U]+=1;
		}
	}else{
		if(bbt_==o->_openb3d_openb3dex_tmesh_anim_surf_list ){
			if(bbt_surf!= &bbNullObject){
				MeshListPushBackSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),3,openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf));
				((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_AddList_TTList(o,bbt_list);
				o->_openb3d_openb3dex_tmesh_no_surfs [0U]+=1;
			}
		}else{
			if(bbt_==o->_openb3d_openb3dex_tmesh_bones ){
				if(bbt_bone!= &bbNullObject){
					MeshListPushBackBone(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_bone,&openb3d_openb3dex_TEntity)));
					((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_AddList_TTList(o,bbt_list);
				}
			}
		}
	}
	return 0;
}
struct openb3d_openb3dex_TBone_obj* _openb3d_openb3dex_TMesh_CreateBone_TTEntity(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	BBBYTE* bbt_inst=CreateBone(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent_ent));
	return openb3d_openb3dex_TBone_CreateObject_TTBone_pb(bbt_inst);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_CreatePlane_TTMesh_iTTEntity(BBINT bbt_divisions,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_mesh=openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity(bbt_parent);
	struct openb3d_openb3dex_TSurface_obj* volatile bbt_surf=(bbt_mesh)->clas->m_CreateSurface_TTBrush(bbt_mesh,&bbNullObject);
	BBFLOAT bbt_size=((BBFLOAT)(50000/bbt_divisions));
	BBFLOAT bbt_uvscale=10.0000000f;
	BBINT bbt_iv=0;
	BBINT bbt_ix=0;
	BBINT bbt_iz=0;
	BBFLOAT bbt_ptx=.0f;
	BBFLOAT bbt_ptz=.0f;
	BBINT bbt_=bbt_divisions;
	for(bbt_iz=0;(bbt_iz<=bbt_);bbt_iz=(bbt_iz+1)){
		BBINT bbt_2=bbt_divisions;
		for(bbt_ix=0;(bbt_ix<=bbt_2);bbt_ix=(bbt_ix+1)){
			bbt_ptx=((((BBFLOAT)bbt_ix)*bbt_size)-((((BBFLOAT)bbt_divisions)*bbt_size)*0.5f));
			bbt_ptz=((((BBFLOAT)bbt_iz)*bbt_size)-((((BBFLOAT)bbt_divisions)*bbt_size)*0.5f));
			bbt_iv=(bbt_ix+(bbt_iz*(bbt_divisions+1)));
			(bbt_surf)->clas->m_AddVertex_ffffff(bbt_surf,bbt_ptx,0.000000000f,bbt_ptz,0.000000000f,0.000000000f,0.000000000f);
			(bbt_surf)->clas->m_VertexTexCoords_ifffi(bbt_surf,bbt_iv,(((BBFLOAT)bbt_iz)*bbt_uvscale),(((BBFLOAT)bbt_ix)*bbt_uvscale),0.000000000f,0);
			(bbt_surf)->clas->m_VertexNormal_ifff(bbt_surf,bbt_iv,0.0f,1.0f,0.0f);
		}
	}
	BBINT bbt_3=(bbt_divisions-1);
	for(bbt_iz=0;(bbt_iz<=bbt_3);bbt_iz=(bbt_iz+1)){
		BBINT bbt_4=(bbt_divisions-1);
		for(bbt_ix=0;(bbt_ix<=bbt_4);bbt_ix=(bbt_ix+1)){
			bbt_iv=(bbt_ix+(bbt_iz*(bbt_divisions+1)));
			(bbt_surf)->clas->m_AddTriangle_iii(bbt_surf,bbt_iv,((bbt_iv+bbt_divisions)+1),((bbt_iv+bbt_divisions)+2));
			(bbt_surf)->clas->m_AddTriangle_iii(bbt_surf,((bbt_iv+bbt_divisions)+2),(bbt_iv+1),bbt_iv);
		}
	}
	(bbt_mesh)->clas->m_RotateMesh_fff(bbt_mesh,0.000000000f,-90.0000000f,0.000000000f);
	return bbt_mesh;
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_CreateQuad_TTMesh_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateQuad(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_MeshCSG_TTMesh_TTMeshTTMeshi(struct openb3d_openb3dex_TMesh_obj* bbt_m1,struct openb3d_openb3dex_TMesh_obj* bbt_m2,BBINT bbt_method_no){
	BBBYTE* bbt_inst=MeshCSG(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_m1,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_m2,&openb3d_openb3dex_TEntity)),bbt_method_no);
	return openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TMesh_MeshesIntersect_TTMesh(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_mesh2){
	return MeshesIntersect(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh2,&openb3d_openb3dex_TEntity)));
}
struct openb3d_openb3dex_TMesh_obj* _openb3d_openb3dex_TMesh_RepeatMesh_TTEntity(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=RepeatMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_mesh=o->clas->f_CreateObject_TTMesh_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_mesh;
}
BBINT _openb3d_openb3dex_TMesh_SkinMesh_iiifififif(struct openb3d_openb3dex_TMesh_obj* o,BBINT bbt_surf_no_get,BBINT bbt_vid,BBINT bbt_bone1,BBFLOAT bbt_weight1,BBINT bbt_bone2,BBFLOAT bbt_weight2,BBINT bbt_bone3,BBFLOAT bbt_weight3,BBINT bbt_bone4,BBFLOAT bbt_weight4){
	SkinMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_surf_no_get,bbt_vid,bbt_bone1,bbt_weight1,bbt_bone2,bbt_weight2,bbt_bone3,bbt_weight3,bbt_bone4,bbt_weight4);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_FreeEntity(struct openb3d_openb3dex_TMesh_obj* o){
	if(o->_openb3d_openb3dex_tentity_exists !=0){
		openb3d_openb3dex_TMatrix_FreeObject_i_pb(openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(o->_openb3d_openb3dex_tmesh_mat_sp ));
		o->_openb3d_openb3dex_tmesh_mat_sp =&bbNullObject;
		struct brl_linkedlist_TListEnum_obj* volatile bbt_=(o->_openb3d_openb3dex_tmesh_surf_list )->clas->m_ObjectEnumerator(o->_openb3d_openb3dex_tmesh_surf_list );
		while((bbt_)->clas->m_HasNext(bbt_)!=0){
			struct openb3d_openb3dex_TSurface_obj* volatile bbt_surf=((struct openb3d_openb3dex_TSurface_obj*)bbObjectDowncast((bbt_)->clas->m_NextObject(bbt_),&openb3d_openb3dex_TSurface));
			if(bbt_surf==&bbNullObject){
				continue;
			}
			openb3d_openb3dex_TBrush_FreeObject_i_pb(openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_surf->_openb3d_openb3dex_tsurface_brush ));
			bbt_surf->_openb3d_openb3dex_tsurface_brush =&bbNullObject;
			openb3d_openb3dex_TSurface_FreeObject_i_pb(openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf));
			bbt_surf=&bbNullObject;
		}
		struct brl_linkedlist_TListEnum_obj* volatile bbt_2=(o->_openb3d_openb3dex_tmesh_anim_surf_list )->clas->m_ObjectEnumerator(o->_openb3d_openb3dex_tmesh_anim_surf_list );
		while((bbt_2)->clas->m_HasNext(bbt_2)!=0){
			struct openb3d_openb3dex_TSurface_obj* volatile bbt_anim_surf=((struct openb3d_openb3dex_TSurface_obj*)bbObjectDowncast((bbt_2)->clas->m_NextObject(bbt_2),&openb3d_openb3dex_TSurface));
			if(bbt_anim_surf==&bbNullObject){
				continue;
			}
			openb3d_openb3dex_TBrush_FreeObject_i_pb(openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_anim_surf->_openb3d_openb3dex_tsurface_brush ));
			bbt_anim_surf->_openb3d_openb3dex_tsurface_brush =&bbNullObject;
			openb3d_openb3dex_TSurface_FreeObject_i_pb(openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_anim_surf));
			bbt_anim_surf=&bbNullObject;
		}
		struct brl_linkedlist_TListEnum_obj* volatile bbt_3=(o->_openb3d_openb3dex_tmesh_bones )->clas->m_ObjectEnumerator(o->_openb3d_openb3dex_tmesh_bones );
		while((bbt_3)->clas->m_HasNext(bbt_3)!=0){
			struct openb3d_openb3dex_TBone_obj* volatile bbt_bone=((struct openb3d_openb3dex_TBone_obj*)bbObjectDowncast((bbt_3)->clas->m_NextObject(bbt_3),&openb3d_openb3dex_TBone));
			if(bbt_bone==&bbNullObject){
				continue;
			}
			(bbt_bone)->clas->m_FreeEntity(bbt_bone);
		}
		brl_linkedlist_ClearList(o->_openb3d_openb3dex_tmesh_surf_list );
		o->_openb3d_openb3dex_tmesh_surf_list_id =0;
		brl_linkedlist_ClearList(o->_openb3d_openb3dex_tmesh_anim_surf_list );
		o->_openb3d_openb3dex_tmesh_anim_surf_list_id =0;
		brl_linkedlist_ClearList(o->_openb3d_openb3dex_tmesh_bones );
		o->_openb3d_openb3dex_tmesh_bones_id =0;
		(&openb3d_openb3dex_TMesh)->super->m_FreeEntity(o);
	}
	return 0;
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_LoadMesh_TTMesh_STTEntity(BBSTRING bbt_file,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_cString=bbStringToCString(bbt_file);
	BBBYTE* bbt_inst=LoadMesh(bbt_cString,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_mesh=openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	return bbt_mesh;
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_LoadAnimMesh_TTMesh_STTEntity(BBSTRING bbt_file,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_cString=bbStringToCString(bbt_file);
	BBBYTE* bbt_inst=LoadAnimMesh(bbt_cString,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_mesh=openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	return bbt_mesh;
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_CreateCube_TTMesh_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateCube(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity(BBINT bbt_segments,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateSphere(bbt_segments,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_CreateCylinder_TTMesh_iiTTEntity(BBINT bbt_segments,BBINT bbt_solid,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateCylinder(bbt_segments,bbt_solid,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TMesh_CreateCone_TTMesh_iiTTEntity(BBINT bbt_segments,BBINT bbt_solid,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateCone(bbt_segments,bbt_solid,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
}
struct openb3d_openb3dex_TMesh_obj* _openb3d_openb3dex_TMesh_CopyMesh_TTEntity(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return o->clas->f_CreateObject_TTMesh_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TMesh_AddMesh_TTMesh(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_mesh2){
	AddMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh2,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_FlipMesh(struct openb3d_openb3dex_TMesh_obj* o){
	FlipMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_PaintMesh_TTBrush(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TBrush_obj* bbt_bru){
	PaintMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_bru));
	struct brl_linkedlist_TListEnum_obj* volatile bbt_=(o->_openb3d_openb3dex_tmesh_surf_list )->clas->m_ObjectEnumerator(o->_openb3d_openb3dex_tmesh_surf_list );
	while((bbt_)->clas->m_HasNext(bbt_)!=0){
		struct openb3d_openb3dex_TSurface_obj* volatile bbt_surf=((struct openb3d_openb3dex_TSurface_obj*)bbObjectDowncast((bbt_)->clas->m_NextObject(bbt_),&openb3d_openb3dex_TSurface));
		if(bbt_surf==&bbNullObject){
			continue;
		}
		if(bbt_surf->_openb3d_openb3dex_tsurface_brush !=&bbNullObject){
			(((struct openb3d_openb3dex_TBrush_obj*)bbt_surf->_openb3d_openb3dex_tsurface_brush )->clas)->m_InitFields(bbt_surf->_openb3d_openb3dex_tsurface_brush );
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_FitMesh_ffffffi(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_width,BBFLOAT bbt_height,BBFLOAT bbt_depth,BBINT bbt_uniform){
	FitMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_y,bbt_z,bbt_width,bbt_height,bbt_depth,bbt_uniform);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_ScaleMesh_fff(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_sx,BBFLOAT bbt_sy,BBFLOAT bbt_sz){
	ScaleMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_sx,bbt_sy,bbt_sz);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_RotateMesh_fff(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_pitch,BBFLOAT bbt_yaw,BBFLOAT bbt_roll){
	RotateMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),-bbt_pitch,bbt_yaw,bbt_roll);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_PositionMesh_fff(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_px,BBFLOAT bbt_py,BBFLOAT bbt_pz){
	PositionMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_px,bbt_py,bbt_pz);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_UpdateNormals(struct openb3d_openb3dex_TMesh_obj* o){
	UpdateNormals(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
struct openb3d_openb3dex_TSurface_obj* _openb3d_openb3dex_TMesh_CreateSurface_TTBrush(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	BBBYTE* bbt_inst=CreateSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_brush));
	return openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb(bbt_inst);
}
BBFLOAT _openb3d_openb3dex_TMesh_MeshWidth(struct openb3d_openb3dex_TMesh_obj* o){
	return MeshWidth(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
}
BBFLOAT _openb3d_openb3dex_TMesh_MeshHeight(struct openb3d_openb3dex_TMesh_obj* o){
	return MeshHeight(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
}
BBFLOAT _openb3d_openb3dex_TMesh_MeshDepth(struct openb3d_openb3dex_TMesh_obj* o){
	return MeshDepth(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
}
BBINT _openb3d_openb3dex_TMesh_CountSurfaces(struct openb3d_openb3dex_TMesh_obj* o){
	return CountSurfaces(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
}
struct openb3d_openb3dex_TSurface_obj* _openb3d_openb3dex_TMesh_GetSurface_i(struct openb3d_openb3dex_TMesh_obj* o,BBINT bbt_surf_no){
	BBBYTE* bbt_inst=GetSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_surf_no);
	return openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(bbt_inst);
}
struct openb3d_openb3dex_TSurface_obj* _openb3d_openb3dex_TMesh_FindSurface_TTBrush(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	struct brl_linkedlist_TListEnum_obj* volatile bbt_=(o->_openb3d_openb3dex_tmesh_surf_list )->clas->m_ObjectEnumerator(o->_openb3d_openb3dex_tmesh_surf_list );
	while((bbt_)->clas->m_HasNext(bbt_)!=0){
		struct openb3d_openb3dex_TSurface_obj* volatile bbt_surf=((struct openb3d_openb3dex_TSurface_obj*)bbObjectDowncast((bbt_)->clas->m_NextObject(bbt_),&openb3d_openb3dex_TSurface));
		if(bbt_surf==&bbNullObject){
			continue;
		}
		if(openb3d_openb3dex_TBrush_CompareBrushes_i_TTBrushTTBrush(bbt_brush,bbt_surf->_openb3d_openb3dex_tsurface_brush )==1){
			return bbt_surf;
		}
	}
	return &bbNullObject;
}
struct openb3d_openb3dex_TMesh_obj* _openb3d_openb3dex_TMesh_CopyEntity_TTEntity(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_mesh=o->clas->f_CreateObject_TTMesh_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_mesh;
}
BBINT _openb3d_openb3dex_TMesh_Update(struct openb3d_openb3dex_TMesh_obj* o){
	MeshRender(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_CountVertices(struct openb3d_openb3dex_TMesh_obj* o){
	BBINT bbt_verts=0;
	{
		BBINT bbt_s=1;
		BBINT bbt_=((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_CountSurfaces(o);
		for(bbt_s;(bbt_s<=bbt_);bbt_s=(bbt_s+1)){
			struct openb3d_openb3dex_TSurface_obj* volatile bbt_surf=((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_GetSurface_i(o,bbt_s);
			bbt_verts=(bbt_verts+(bbt_surf)->clas->m_CountVertices(bbt_surf));
		}
	}
	return bbt_verts;
}
BBINT _openb3d_openb3dex_TMesh_CountTriangles(struct openb3d_openb3dex_TMesh_obj* o){
	BBINT bbt_tris=0;
	{
		BBINT bbt_s=1;
		BBINT bbt_=((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_CountSurfaces(o);
		for(bbt_s;(bbt_s<=bbt_);bbt_s=(bbt_s+1)){
			struct openb3d_openb3dex_TSurface_obj* volatile bbt_surf=((struct openb3d_openb3dex_TMesh_obj*)o)->clas->m_GetSurface_i(o,bbt_s);
			bbt_tris=(bbt_tris+(bbt_surf)->clas->m_CountTriangles(bbt_surf));
		}
	}
	return bbt_tris;
}
BBINT openb3d_openb3dex_TMesh_CopyBonesList_i_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	BBBYTE* bbt_inst=MeshVectorBone(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),4);
	CopyBonesList(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_inst);
	return 0;
}
struct openb3d_openb3dex_TMesh_obj* _openb3d_openb3dex_TMesh_CollapseAnimMesh_TTMesh(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	BBBYTE* bbt_inst=CollapseAnimMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)));
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_mesh2=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TMesh));
	if((bbt_mesh2==&bbNullObject) && (bbt_inst!=0)){
		bbt_mesh2=o->clas->f_CreateObject_TTMesh_pb(bbt_inst);
	}
	return bbt_mesh2;
}
struct openb3d_openb3dex_TMesh_obj* _openb3d_openb3dex_TMesh_CollapseChildren_TTEntityTTMesh(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_ent0,struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	BBBYTE* bbt_inst=CollapseChildren(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent0),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)));
	struct openb3d_openb3dex_TMesh_obj* volatile bbt_mesh2=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TMesh));
	if((bbt_mesh2==&bbNullObject) && (bbt_inst!=0)){
		bbt_mesh2=o->clas->f_CreateObject_TTMesh_pb(bbt_inst);
	}
	return bbt_mesh2;
}
BBINT _openb3d_openb3dex_TMesh_TransformMesh_TTMatrix(struct openb3d_openb3dex_TMesh_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_mat){
	TransformMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(bbt_mat));
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_GetBounds(struct openb3d_openb3dex_TMesh_obj* o){
	GetBounds(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_Alpha(struct openb3d_openb3dex_TMesh_obj* o){
	return Alpha(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
}
BBINT _openb3d_openb3dex_TMesh_MeshColor_ffff(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b,BBFLOAT bbt_a){
	MeshColor(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_r,bbt_g,bbt_b,bbt_a);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_MeshRed_f(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_r){
	MeshRed(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_r);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_MeshGreen_f(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_g){
	MeshGreen(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_g);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_MeshBlue_f(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_b){
	MeshBlue(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_b);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_MeshAlpha_f(struct openb3d_openb3dex_TMesh_obj* o,BBFLOAT bbt_a){
	MeshAlpha(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_a);
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_TreeCheck(struct openb3d_openb3dex_TMesh_obj* o){
	TreeCheck(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_Render(struct openb3d_openb3dex_TMesh_obj* o){
	MeshRender(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TMesh_UpdateShadow(struct openb3d_openb3dex_TMesh_obj* o){
	UpdateShadow(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
struct BBDebugScope_71 openb3d_openb3dex_TMesh_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TMesh",
	{
		{
			BBDEBUGDECL_FIELD,
			"no_surfs",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_no_surfs)
		},
		{
			BBDEBUGDECL_FIELD,
			"surf_list",
			":TList",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_surf_list)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_surf_list",
			":TList",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_anim_surf_list)
		},
		{
			BBDEBUGDECL_FIELD,
			"bones",
			":TList",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_bones)
		},
		{
			BBDEBUGDECL_FIELD,
			"mat_sp",
			":TMatrix",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_mat_sp)
		},
		{
			BBDEBUGDECL_FIELD,
			"reset_col_tree",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_reset_col_tree)
		},
		{
			BBDEBUGDECL_FIELD,
			"reset_bounds",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_reset_bounds)
		},
		{
			BBDEBUGDECL_FIELD,
			"min_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_min_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"min_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_min_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"min_z",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_min_z)
		},
		{
			BBDEBUGDECL_FIELD,
			"max_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_max_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"max_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_max_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"max_z",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_max_z)
		},
		{
			BBDEBUGDECL_FIELD,
			"surf_list_id",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_surf_list_id)
		},
		{
			BBDEBUGDECL_FIELD,
			"anim_surf_list_id",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_anim_surf_list_id)
		},
		{
			BBDEBUGDECL_FIELD,
			"bones_id",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_bones_id)
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TMesh_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TMesh",
			&openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TMesh_InitFields
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AddList",
			"(:TList)i",
			&_openb3d_openb3dex_TMesh_AddList_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyList",
			"(:TList)i",
			&_openb3d_openb3dex_TMesh_CopyList_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ListPushBack",
			"(:TList,:Object)i",
			&_openb3d_openb3dex_TMesh_ListPushBack_TTListTObject
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CreateBone",
			"(:TEntity):TBone",
			&_openb3d_openb3dex_TMesh_CreateBone_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreatePlane",
			"(i,:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_CreatePlane_TTMesh_iTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateQuad",
			"(:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_CreateQuad_TTMesh_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"MeshCSG",
			"(:TMesh,:TMesh,i):TMesh",
			&openb3d_openb3dex_TMesh_MeshCSG_TTMesh_TTMeshTTMeshi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshesIntersect",
			"(:TMesh)i",
			&_openb3d_openb3dex_TMesh_MeshesIntersect_TTMesh
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RepeatMesh",
			"(:TEntity):TMesh",
			&_openb3d_openb3dex_TMesh_RepeatMesh_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SkinMesh",
			"(i,i,i,f,i,f,i,f,i,f)i",
			&_openb3d_openb3dex_TMesh_SkinMesh_iiifififif
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeEntity",
			"()i",
			&_openb3d_openb3dex_TMesh_FreeEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateMesh",
			"(:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadMesh",
			"($,:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_LoadMesh_TTMesh_STTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadAnimMesh",
			"($,:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_LoadAnimMesh_TTMesh_STTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateCube",
			"(:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_CreateCube_TTMesh_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateSphere",
			"(i,:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateCylinder",
			"(i,i,:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_CreateCylinder_TTMesh_iiTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateCone",
			"(i,i,:TEntity):TMesh",
			&openb3d_openb3dex_TMesh_CreateCone_TTMesh_iiTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyMesh",
			"(:TEntity):TMesh",
			&_openb3d_openb3dex_TMesh_CopyMesh_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AddMesh",
			"(:TMesh)i",
			&_openb3d_openb3dex_TMesh_AddMesh_TTMesh
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FlipMesh",
			"()i",
			&_openb3d_openb3dex_TMesh_FlipMesh
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"PaintMesh",
			"(:TBrush)i",
			&_openb3d_openb3dex_TMesh_PaintMesh_TTBrush
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FitMesh",
			"(f,f,f,f,f,f,i)i",
			&_openb3d_openb3dex_TMesh_FitMesh_ffffffi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ScaleMesh",
			"(f,f,f)i",
			&_openb3d_openb3dex_TMesh_ScaleMesh_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RotateMesh",
			"(f,f,f)i",
			&_openb3d_openb3dex_TMesh_RotateMesh_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"PositionMesh",
			"(f,f,f)i",
			&_openb3d_openb3dex_TMesh_PositionMesh_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateNormals",
			"()i",
			&_openb3d_openb3dex_TMesh_UpdateNormals
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CreateSurface",
			"(:TBrush):TSurface",
			&_openb3d_openb3dex_TMesh_CreateSurface_TTBrush
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshWidth",
			"()f",
			&_openb3d_openb3dex_TMesh_MeshWidth
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshHeight",
			"()f",
			&_openb3d_openb3dex_TMesh_MeshHeight
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshDepth",
			"()f",
			&_openb3d_openb3dex_TMesh_MeshDepth
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CountSurfaces",
			"()i",
			&_openb3d_openb3dex_TMesh_CountSurfaces
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetSurface",
			"(i):TSurface",
			&_openb3d_openb3dex_TMesh_GetSurface_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FindSurface",
			"(:TBrush):TSurface",
			&_openb3d_openb3dex_TMesh_FindSurface_TTBrush
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TMesh",
			&_openb3d_openb3dex_TMesh_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Update",
			"()i",
			&_openb3d_openb3dex_TMesh_Update
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CountVertices",
			"()i",
			&_openb3d_openb3dex_TMesh_CountVertices
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CountTriangles",
			"()i",
			&_openb3d_openb3dex_TMesh_CountTriangles
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyBonesList",
			"(:TEntity)i",
			&openb3d_openb3dex_TMesh_CopyBonesList_i_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollapseAnimMesh",
			"(:TMesh):TMesh",
			&_openb3d_openb3dex_TMesh_CollapseAnimMesh_TTMesh
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CollapseChildren",
			"(:TEntity,:TMesh):TMesh",
			&_openb3d_openb3dex_TMesh_CollapseChildren_TTEntityTTMesh
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TransformMesh",
			"(:TMatrix)i",
			&_openb3d_openb3dex_TMesh_TransformMesh_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetBounds",
			"()i",
			&_openb3d_openb3dex_TMesh_GetBounds
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Alpha",
			"()i",
			&_openb3d_openb3dex_TMesh_Alpha
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshColor",
			"(f,f,f,f)i",
			&_openb3d_openb3dex_TMesh_MeshColor_ffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshRed",
			"(f)i",
			&_openb3d_openb3dex_TMesh_MeshRed_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshGreen",
			"(f)i",
			&_openb3d_openb3dex_TMesh_MeshGreen_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshBlue",
			"(f)i",
			&_openb3d_openb3dex_TMesh_MeshBlue_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"MeshAlpha",
			"(f)i",
			&_openb3d_openb3dex_TMesh_MeshAlpha_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TreeCheck",
			"()i",
			&_openb3d_openb3dex_TMesh_TreeCheck
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Render",
			"()i",
			&_openb3d_openb3dex_TMesh_Render
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateShadow",
			"()i",
			&_openb3d_openb3dex_TMesh_UpdateShadow
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TMesh openb3d_openb3dex_TMesh={
	&openb3d_openb3dex_TEntity,
	bbObjectFree,
	&openb3d_openb3dex_TMesh_scope,
	sizeof(struct openb3d_openb3dex_TMesh_obj),
	_openb3d_openb3dex_TMesh_New,
	_openb3d_openb3dex_TMesh_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TMesh_obj,_openb3d_openb3dex_tmesh_bones_id) - sizeof(void*) + sizeof(BBINT)
	,_openb3d_openb3dex_TMesh_CopyEntity_TTEntity
	,_openb3d_openb3dex_TMesh_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TMesh_InitFields
	,_openb3d_openb3dex_TMesh_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TMesh_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TMesh_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TMesh_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb
	,_openb3d_openb3dex_TMesh_CreateBone_TTEntity
	,openb3d_openb3dex_TMesh_CreatePlane_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateQuad_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_MeshCSG_TTMesh_TTMeshTTMeshi
	,_openb3d_openb3dex_TMesh_MeshesIntersect_TTMesh
	,_openb3d_openb3dex_TMesh_RepeatMesh_TTEntity
	,_openb3d_openb3dex_TMesh_SkinMesh_iiifififif
	,openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_LoadMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_LoadAnimMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_CreateCube_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateCylinder_TTMesh_iiTTEntity
	,openb3d_openb3dex_TMesh_CreateCone_TTMesh_iiTTEntity
	,_openb3d_openb3dex_TMesh_CopyMesh_TTEntity
	,_openb3d_openb3dex_TMesh_AddMesh_TTMesh
	,_openb3d_openb3dex_TMesh_FlipMesh
	,_openb3d_openb3dex_TMesh_PaintMesh_TTBrush
	,_openb3d_openb3dex_TMesh_FitMesh_ffffffi
	,_openb3d_openb3dex_TMesh_ScaleMesh_fff
	,_openb3d_openb3dex_TMesh_RotateMesh_fff
	,_openb3d_openb3dex_TMesh_PositionMesh_fff
	,_openb3d_openb3dex_TMesh_UpdateNormals
	,_openb3d_openb3dex_TMesh_CreateSurface_TTBrush
	,_openb3d_openb3dex_TMesh_MeshWidth
	,_openb3d_openb3dex_TMesh_MeshHeight
	,_openb3d_openb3dex_TMesh_MeshDepth
	,_openb3d_openb3dex_TMesh_CountSurfaces
	,_openb3d_openb3dex_TMesh_GetSurface_i
	,_openb3d_openb3dex_TMesh_FindSurface_TTBrush
	,_openb3d_openb3dex_TMesh_CountVertices
	,_openb3d_openb3dex_TMesh_CountTriangles
	,openb3d_openb3dex_TMesh_CopyBonesList_i_TTEntity
	,_openb3d_openb3dex_TMesh_CollapseAnimMesh_TTMesh
	,_openb3d_openb3dex_TMesh_CollapseChildren_TTEntityTTMesh
	,_openb3d_openb3dex_TMesh_TransformMesh_TTMatrix
	,_openb3d_openb3dex_TMesh_GetBounds
	,_openb3d_openb3dex_TMesh_Alpha
	,_openb3d_openb3dex_TMesh_MeshColor_ffff
	,_openb3d_openb3dex_TMesh_MeshRed_f
	,_openb3d_openb3dex_TMesh_MeshGreen_f
	,_openb3d_openb3dex_TMesh_MeshBlue_f
	,_openb3d_openb3dex_TMesh_MeshAlpha_f
	,_openb3d_openb3dex_TMesh_TreeCheck
	,_openb3d_openb3dex_TMesh_Render
	,_openb3d_openb3dex_TMesh_UpdateShadow
};

void _openb3d_openb3dex_TSprite_New(struct openb3d_openb3dex_TSprite_obj* o) {
	_openb3d_openb3dex_TMesh_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TSprite;
	o->_openb3d_openb3dex_tsprite_angle = 0;
	o->_openb3d_openb3dex_tsprite_scale_x = 0;
	o->_openb3d_openb3dex_tsprite_scale_y = 0;
	o->_openb3d_openb3dex_tsprite_handle_x = 0;
	o->_openb3d_openb3dex_tsprite_handle_y = 0;
	o->_openb3d_openb3dex_tsprite_view_mode = 0;
	o->_openb3d_openb3dex_tsprite_render_mode = 0;
}
void _openb3d_openb3dex_TSprite_Delete(struct openb3d_openb3dex_TSprite_obj* o) {
	_openb3d_openb3dex_TMesh_Delete(o);
}
struct openb3d_openb3dex_TSprite_obj* openb3d_openb3dex_TSprite_CreateObject_TTSprite_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TSprite_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TSprite);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TSprite_InitFields(struct openb3d_openb3dex_TSprite_obj* o){
	(&openb3d_openb3dex_TSprite)->super->m_InitFields(o);
	o->_openb3d_openb3dex_tsprite_view_mode =SpriteInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),6);
	o->_openb3d_openb3dex_tsprite_render_mode =SpriteInt(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),7);
	o->_openb3d_openb3dex_tsprite_angle =SpriteFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),1);
	o->_openb3d_openb3dex_tsprite_scale_x =SpriteFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),2);
	o->_openb3d_openb3dex_tsprite_scale_y =SpriteFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),3);
	o->_openb3d_openb3dex_tsprite_handle_x =SpriteFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4);
	o->_openb3d_openb3dex_tsprite_handle_y =SpriteFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),5);
	return 0;
}
BBINT _openb3d_openb3dex_TSprite_SpriteRenderMode_i(struct openb3d_openb3dex_TSprite_obj* o,BBINT bbt_Mode){
	SpriteRenderMode(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_Mode);
	return 0;
}
struct openb3d_openb3dex_TSprite_obj* openb3d_openb3dex_TSprite_CreateSprite_TTSprite_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateSprite(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TSprite_CreateObject_TTSprite_pb(bbt_inst);
}
struct openb3d_openb3dex_TSprite_obj* openb3d_openb3dex_TSprite_LoadSprite_TTSprite_SiTTEntity(BBSTRING bbt_tex_file,BBINT bbt_tex_flag,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_cString=bbStringToCString(bbt_tex_file);
	BBBYTE* bbt_inst=LoadSprite(bbt_cString,bbt_tex_flag,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TSprite_obj* volatile bbt_sprite=openb3d_openb3dex_TSprite_CreateObject_TTSprite_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	return bbt_sprite;
}
BBINT _openb3d_openb3dex_TSprite_RotateSprite_f(struct openb3d_openb3dex_TSprite_obj* o,BBFLOAT bbt_ang){
	RotateSprite(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_ang);
	return 0;
}
BBINT _openb3d_openb3dex_TSprite_ScaleSprite_ff(struct openb3d_openb3dex_TSprite_obj* o,BBFLOAT bbt_s_x,BBFLOAT bbt_s_y){
	ScaleSprite(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_s_x,bbt_s_y);
	return 0;
}
BBINT _openb3d_openb3dex_TSprite_HandleSprite_ff(struct openb3d_openb3dex_TSprite_obj* o,BBFLOAT bbt_h_x,BBFLOAT bbt_h_y){
	HandleSprite(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_h_x,bbt_h_y);
	return 0;
}
BBINT _openb3d_openb3dex_TSprite_SpriteViewMode_i(struct openb3d_openb3dex_TSprite_obj* o,BBINT bbt_Mode){
	SpriteViewMode(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_Mode);
	return 0;
}
struct openb3d_openb3dex_TSprite_obj* _openb3d_openb3dex_TSprite_CopyEntity_TTEntity(struct openb3d_openb3dex_TSprite_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TSprite_obj* volatile bbt_sprite=o->clas->f_CreateObject_TTSprite_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_sprite;
}
BBINT _openb3d_openb3dex_TSprite_SpriteTexCoords_iiiiiii(struct openb3d_openb3dex_TSprite_obj* o,BBINT bbt_cell_x,BBINT bbt_cell_y,BBINT bbt_cell_w,BBINT bbt_cell_h,BBINT bbt_tex_w,BBINT bbt_tex_h,BBINT bbt_uv_set){
	SpriteTexCoords(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_cell_x,bbt_cell_y,bbt_cell_w,bbt_cell_h,bbt_tex_w,bbt_tex_h,bbt_uv_set);
	return 0;
}
BBINT _openb3d_openb3dex_TSprite_SpriteVertexColor_ifff(struct openb3d_openb3dex_TSprite_obj* o,BBINT bbt_v,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	SpriteVertexColor(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_v,bbt_r,bbt_g,bbt_b);
	return 0;
}
struct BBDebugScope_20 openb3d_openb3dex_TSprite_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TSprite",
	{
		{
			BBDEBUGDECL_FIELD,
			"angle",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSprite_obj,_openb3d_openb3dex_tsprite_angle)
		},
		{
			BBDEBUGDECL_FIELD,
			"scale_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSprite_obj,_openb3d_openb3dex_tsprite_scale_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"scale_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSprite_obj,_openb3d_openb3dex_tsprite_scale_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"handle_x",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSprite_obj,_openb3d_openb3dex_tsprite_handle_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"handle_y",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSprite_obj,_openb3d_openb3dex_tsprite_handle_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"view_mode",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSprite_obj,_openb3d_openb3dex_tsprite_view_mode)
		},
		{
			BBDEBUGDECL_FIELD,
			"render_mode",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSprite_obj,_openb3d_openb3dex_tsprite_render_mode)
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TSprite_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TSprite",
			&openb3d_openb3dex_TSprite_CreateObject_TTSprite_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TSprite_InitFields
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SpriteRenderMode",
			"(i)i",
			&_openb3d_openb3dex_TSprite_SpriteRenderMode_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateSprite",
			"(:TEntity):TSprite",
			&openb3d_openb3dex_TSprite_CreateSprite_TTSprite_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadSprite",
			"($,i,:TEntity):TSprite",
			&openb3d_openb3dex_TSprite_LoadSprite_TTSprite_SiTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RotateSprite",
			"(f)i",
			&_openb3d_openb3dex_TSprite_RotateSprite_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ScaleSprite",
			"(f,f)i",
			&_openb3d_openb3dex_TSprite_ScaleSprite_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"HandleSprite",
			"(f,f)i",
			&_openb3d_openb3dex_TSprite_HandleSprite_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SpriteViewMode",
			"(i)i",
			&_openb3d_openb3dex_TSprite_SpriteViewMode_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TSprite",
			&_openb3d_openb3dex_TSprite_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SpriteTexCoords",
			"(i,i,i,i,i,i,i)i",
			&_openb3d_openb3dex_TSprite_SpriteTexCoords_iiiiiii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SpriteVertexColor",
			"(i,f,f,f)i",
			&_openb3d_openb3dex_TSprite_SpriteVertexColor_ifff
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TSprite openb3d_openb3dex_TSprite={
	&openb3d_openb3dex_TMesh,
	bbObjectFree,
	&openb3d_openb3dex_TSprite_scope,
	sizeof(struct openb3d_openb3dex_TSprite_obj),
	_openb3d_openb3dex_TSprite_New,
	_openb3d_openb3dex_TSprite_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TSprite_obj,_openb3d_openb3dex_tsprite_render_mode) - sizeof(void*) + sizeof(BBINT*)
	,_openb3d_openb3dex_TSprite_CopyEntity_TTEntity
	,_openb3d_openb3dex_TMesh_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TSprite_InitFields
	,_openb3d_openb3dex_TMesh_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TMesh_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TMesh_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TMesh_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TSprite_CreateObject_TTSprite_pb
	,_openb3d_openb3dex_TMesh_CreateBone_TTEntity
	,openb3d_openb3dex_TMesh_CreatePlane_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateQuad_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_MeshCSG_TTMesh_TTMeshTTMeshi
	,_openb3d_openb3dex_TMesh_MeshesIntersect_TTMesh
	,_openb3d_openb3dex_TMesh_RepeatMesh_TTEntity
	,_openb3d_openb3dex_TMesh_SkinMesh_iiifififif
	,openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_LoadMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_LoadAnimMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_CreateCube_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateCylinder_TTMesh_iiTTEntity
	,openb3d_openb3dex_TMesh_CreateCone_TTMesh_iiTTEntity
	,_openb3d_openb3dex_TMesh_CopyMesh_TTEntity
	,_openb3d_openb3dex_TMesh_AddMesh_TTMesh
	,_openb3d_openb3dex_TMesh_FlipMesh
	,_openb3d_openb3dex_TMesh_PaintMesh_TTBrush
	,_openb3d_openb3dex_TMesh_FitMesh_ffffffi
	,_openb3d_openb3dex_TMesh_ScaleMesh_fff
	,_openb3d_openb3dex_TMesh_RotateMesh_fff
	,_openb3d_openb3dex_TMesh_PositionMesh_fff
	,_openb3d_openb3dex_TMesh_UpdateNormals
	,_openb3d_openb3dex_TMesh_CreateSurface_TTBrush
	,_openb3d_openb3dex_TMesh_MeshWidth
	,_openb3d_openb3dex_TMesh_MeshHeight
	,_openb3d_openb3dex_TMesh_MeshDepth
	,_openb3d_openb3dex_TMesh_CountSurfaces
	,_openb3d_openb3dex_TMesh_GetSurface_i
	,_openb3d_openb3dex_TMesh_FindSurface_TTBrush
	,_openb3d_openb3dex_TMesh_CountVertices
	,_openb3d_openb3dex_TMesh_CountTriangles
	,openb3d_openb3dex_TMesh_CopyBonesList_i_TTEntity
	,_openb3d_openb3dex_TMesh_CollapseAnimMesh_TTMesh
	,_openb3d_openb3dex_TMesh_CollapseChildren_TTEntityTTMesh
	,_openb3d_openb3dex_TMesh_TransformMesh_TTMatrix
	,_openb3d_openb3dex_TMesh_GetBounds
	,_openb3d_openb3dex_TMesh_Alpha
	,_openb3d_openb3dex_TMesh_MeshColor_ffff
	,_openb3d_openb3dex_TMesh_MeshRed_f
	,_openb3d_openb3dex_TMesh_MeshGreen_f
	,_openb3d_openb3dex_TMesh_MeshBlue_f
	,_openb3d_openb3dex_TMesh_MeshAlpha_f
	,_openb3d_openb3dex_TMesh_TreeCheck
	,_openb3d_openb3dex_TMesh_Render
	,_openb3d_openb3dex_TMesh_UpdateShadow
	,_openb3d_openb3dex_TSprite_SpriteRenderMode_i
	,openb3d_openb3dex_TSprite_CreateSprite_TTSprite_TTEntity
	,openb3d_openb3dex_TSprite_LoadSprite_TTSprite_SiTTEntity
	,_openb3d_openb3dex_TSprite_RotateSprite_f
	,_openb3d_openb3dex_TSprite_ScaleSprite_ff
	,_openb3d_openb3dex_TSprite_HandleSprite_ff
	,_openb3d_openb3dex_TSprite_SpriteViewMode_i
	,_openb3d_openb3dex_TSprite_SpriteTexCoords_iiiiiii
	,_openb3d_openb3dex_TSprite_SpriteVertexColor_ifff
};

void _openb3d_openb3dex_TBone_New(struct openb3d_openb3dex_TBone_obj* o) {
	_openb3d_openb3dex_TEntity_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TBone;
	o->_openb3d_openb3dex_tbone_n_px = 0;
	o->_openb3d_openb3dex_tbone_n_py = 0;
	o->_openb3d_openb3dex_tbone_n_pz = 0;
	o->_openb3d_openb3dex_tbone_n_sx = 0;
	o->_openb3d_openb3dex_tbone_n_sy = 0;
	o->_openb3d_openb3dex_tbone_n_sz = 0;
	o->_openb3d_openb3dex_tbone_n_rx = 0;
	o->_openb3d_openb3dex_tbone_n_ry = 0;
	o->_openb3d_openb3dex_tbone_n_rz = 0;
	o->_openb3d_openb3dex_tbone_n_qw = 0;
	o->_openb3d_openb3dex_tbone_n_qx = 0;
	o->_openb3d_openb3dex_tbone_n_qy = 0;
	o->_openb3d_openb3dex_tbone_n_qz = 0;
	o->_openb3d_openb3dex_tbone_keys = &bbNullObject;
	o->_openb3d_openb3dex_tbone_mat2 = &bbNullObject;
	o->_openb3d_openb3dex_tbone_inv_mat = &bbNullObject;
	o->_openb3d_openb3dex_tbone_tform_mat = &bbNullObject;
	o->_openb3d_openb3dex_tbone_kx = 0;
	o->_openb3d_openb3dex_tbone_ky = 0;
	o->_openb3d_openb3dex_tbone_kz = 0;
	o->_openb3d_openb3dex_tbone_kqw = 0;
	o->_openb3d_openb3dex_tbone_kqx = 0;
	o->_openb3d_openb3dex_tbone_kqy = 0;
	o->_openb3d_openb3dex_tbone_kqz = 0;
}
void _openb3d_openb3dex_TBone_Delete(struct openb3d_openb3dex_TBone_obj* o) {
	_openb3d_openb3dex_TEntity_Delete(o);
}
struct openb3d_openb3dex_TBone_obj* openb3d_openb3dex_TBone_CreateObject_TTBone_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TBone_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TBone);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TBone_InitFields(struct openb3d_openb3dex_TBone_obj* o){
	(&openb3d_openb3dex_TBone)->super->m_InitFields(o);
	o->_openb3d_openb3dex_tbone_n_px =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),1);
	o->_openb3d_openb3dex_tbone_n_py =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),2);
	o->_openb3d_openb3dex_tbone_n_pz =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),3);
	o->_openb3d_openb3dex_tbone_n_sx =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4);
	o->_openb3d_openb3dex_tbone_n_sy =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),5);
	o->_openb3d_openb3dex_tbone_n_sz =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),6);
	o->_openb3d_openb3dex_tbone_n_rx =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),7);
	o->_openb3d_openb3dex_tbone_n_ry =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),8);
	o->_openb3d_openb3dex_tbone_n_rz =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),9);
	o->_openb3d_openb3dex_tbone_n_qw =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),10);
	o->_openb3d_openb3dex_tbone_n_qx =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),11);
	o->_openb3d_openb3dex_tbone_n_qy =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),12);
	o->_openb3d_openb3dex_tbone_n_qz =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),13);
	o->_openb3d_openb3dex_tbone_kx =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),18);
	o->_openb3d_openb3dex_tbone_ky =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),19);
	o->_openb3d_openb3dex_tbone_kz =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),20);
	o->_openb3d_openb3dex_tbone_kqw =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),21);
	o->_openb3d_openb3dex_tbone_kqx =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),22);
	o->_openb3d_openb3dex_tbone_kqy =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),23);
	o->_openb3d_openb3dex_tbone_kqz =BoneFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),24);
	BBBYTE* bbt_inst=BoneAnimationKeys(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),14);
	o->_openb3d_openb3dex_tbone_keys =openb3d_openb3dex_TAnimationKeys_GetObject_TTAnimationKeys_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tbone_keys ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tbone_keys =openb3d_openb3dex_TAnimationKeys_CreateObject_TTAnimationKeys_pb(bbt_inst);
	}
	bbt_inst=BoneMatrix(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),15);
	o->_openb3d_openb3dex_tbone_mat2 =openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tbone_mat2 ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tbone_mat2 =openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb(bbt_inst);
	}
	bbt_inst=BoneMatrix(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),16);
	o->_openb3d_openb3dex_tbone_inv_mat =openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tbone_inv_mat ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tbone_inv_mat =openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb(bbt_inst);
	}
	bbt_inst=BoneMatrix(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),17);
	o->_openb3d_openb3dex_tbone_tform_mat =openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tbone_tform_mat ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tbone_tform_mat =openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb(bbt_inst);
	}
	return 0;
}
struct openb3d_openb3dex_TBone_obj* openb3d_openb3dex_TBone_CreateBone_TTBone_TTMeshTTEntity(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	BBBYTE* bbt_inst=CreateBone(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent_ent));
	return openb3d_openb3dex_TBone_CreateObject_TTBone_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TBone_FreeEntity(struct openb3d_openb3dex_TBone_obj* o){
	if(o->_openb3d_openb3dex_tentity_exists !=0){
		openb3d_openb3dex_TAnimationKeys_FreeObject_i_pb(openb3d_openb3dex_TAnimationKeys_GetInstance_pb_TTAnimationKeys(o->_openb3d_openb3dex_tbone_keys ));
		o->_openb3d_openb3dex_tbone_keys =&bbNullObject;
		openb3d_openb3dex_TMatrix_FreeObject_i_pb(openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(o->_openb3d_openb3dex_tbone_mat2 ));
		o->_openb3d_openb3dex_tbone_mat2 =&bbNullObject;
		openb3d_openb3dex_TMatrix_FreeObject_i_pb(openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(o->_openb3d_openb3dex_tbone_inv_mat ));
		o->_openb3d_openb3dex_tbone_inv_mat =&bbNullObject;
		openb3d_openb3dex_TMatrix_FreeObject_i_pb(openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(o->_openb3d_openb3dex_tbone_tform_mat ));
		o->_openb3d_openb3dex_tbone_tform_mat =&bbNullObject;
		(&openb3d_openb3dex_TBone)->super->m_FreeEntity(o);
	}
	return 0;
}
struct openb3d_openb3dex_TBone_obj* _openb3d_openb3dex_TBone_CopyEntity_TTEntity(struct openb3d_openb3dex_TBone_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return o->clas->f_CreateObject_TTBone_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TBone_Update(struct openb3d_openb3dex_TBone_obj* o){
	return 0;
}
struct BBDebugScope_31 openb3d_openb3dex_TBone_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TBone",
	{
		{
			BBDEBUGDECL_FIELD,
			"n_px",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_px)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_py",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_py)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_pz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_pz)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_sx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_sx)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_sy",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_sy)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_sz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_sz)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_rx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_rx)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_ry",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_ry)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_rz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_rz)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_qw",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_qw)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_qx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_qx)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_qy",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_qy)
		},
		{
			BBDEBUGDECL_FIELD,
			"n_qz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_n_qz)
		},
		{
			BBDEBUGDECL_FIELD,
			"keys",
			":TAnimationKeys",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_keys)
		},
		{
			BBDEBUGDECL_FIELD,
			"mat2",
			":TMatrix",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_mat2)
		},
		{
			BBDEBUGDECL_FIELD,
			"inv_mat",
			":TMatrix",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_inv_mat)
		},
		{
			BBDEBUGDECL_FIELD,
			"tform_mat",
			":TMatrix",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_tform_mat)
		},
		{
			BBDEBUGDECL_FIELD,
			"kx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_kx)
		},
		{
			BBDEBUGDECL_FIELD,
			"ky",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_ky)
		},
		{
			BBDEBUGDECL_FIELD,
			"kz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_kz)
		},
		{
			BBDEBUGDECL_FIELD,
			"kqw",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_kqw)
		},
		{
			BBDEBUGDECL_FIELD,
			"kqx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_kqx)
		},
		{
			BBDEBUGDECL_FIELD,
			"kqy",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_kqy)
		},
		{
			BBDEBUGDECL_FIELD,
			"kqz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_kqz)
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TBone_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TBone",
			&openb3d_openb3dex_TBone_CreateObject_TTBone_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TBone_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateBone",
			"(:TMesh,:TEntity):TBone",
			&openb3d_openb3dex_TBone_CreateBone_TTBone_TTMeshTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeEntity",
			"()i",
			&_openb3d_openb3dex_TBone_FreeEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TBone",
			&_openb3d_openb3dex_TBone_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Update",
			"()i",
			&_openb3d_openb3dex_TBone_Update
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TBone openb3d_openb3dex_TBone={
	&openb3d_openb3dex_TEntity,
	bbObjectFree,
	&openb3d_openb3dex_TBone_scope,
	sizeof(struct openb3d_openb3dex_TBone_obj),
	_openb3d_openb3dex_TBone_New,
	_openb3d_openb3dex_TBone_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TBone_obj,_openb3d_openb3dex_tbone_kqz) - sizeof(void*) + sizeof(BBFLOAT*)
	,_openb3d_openb3dex_TBone_CopyEntity_TTEntity
	,_openb3d_openb3dex_TBone_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TBone_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TBone_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TBone_CreateObject_TTBone_pb
	,openb3d_openb3dex_TBone_CreateBone_TTBone_TTMeshTTEntity
};

void _openb3d_openb3dex_TSurface_New(struct openb3d_openb3dex_TSurface_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TSurface;
	o->_openb3d_openb3dex_tsurface_no_verts = 0;
	o->_openb3d_openb3dex_tsurface_no_tris = 0;
	o->_openb3d_openb3dex_tsurface_vert_coords = 0;
	o->_openb3d_openb3dex_tsurface_vert_norm = 0;
	o->_openb3d_openb3dex_tsurface_vert_tex_coords0 = 0;
	o->_openb3d_openb3dex_tsurface_vert_tex_coords1 = 0;
	o->_openb3d_openb3dex_tsurface_vert_col = 0;
	o->_openb3d_openb3dex_tsurface_tris = 0;
	o->_openb3d_openb3dex_tsurface_vert_bone1_no = 0;
	o->_openb3d_openb3dex_tsurface_vert_bone2_no = 0;
	o->_openb3d_openb3dex_tsurface_vert_bone3_no = 0;
	o->_openb3d_openb3dex_tsurface_vert_bone4_no = 0;
	o->_openb3d_openb3dex_tsurface_vert_weight1 = 0;
	o->_openb3d_openb3dex_tsurface_vert_weight2 = 0;
	o->_openb3d_openb3dex_tsurface_vert_weight3 = 0;
	o->_openb3d_openb3dex_tsurface_vert_weight4 = 0;
	o->_openb3d_openb3dex_tsurface_brush = &bbNullObject;
	o->_openb3d_openb3dex_tsurface_shadermat = &bbNullObject;
	o->_openb3d_openb3dex_tsurface_vbo_id = 0;
	o->_openb3d_openb3dex_tsurface_vert_array_size = 0;
	o->_openb3d_openb3dex_tsurface_tri_array_size = 0;
	o->_openb3d_openb3dex_tsurface_vmin = 0;
	o->_openb3d_openb3dex_tsurface_vmax = 0;
	o->_openb3d_openb3dex_tsurface_vbo_enabled = 0;
	o->_openb3d_openb3dex_tsurface_reset_vbo = 0;
	o->_openb3d_openb3dex_tsurface_alpha_enable = 0;
	o->_openb3d_openb3dex_tsurface_instance = 0;
}
void _openb3d_openb3dex_TSurface_Delete(struct openb3d_openb3dex_TSurface_obj* o) {
	bbObjectDtor(o);
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TSurface_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TSurface);
	(openb3d_openb3dex_TSurface_surf_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TSurface_surf_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tsurface_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TSurface_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TSurface_surf_map)->clas->m_Remove_TObject(openb3d_openb3dex_TSurface_surf_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TSurface_obj*)bbObjectDowncast((openb3d_openb3dex_TSurface_surf_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TSurface_surf_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TSurface));
}
BBBYTE* openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(struct openb3d_openb3dex_TSurface_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tsurface_instance ;
}
BBINT _openb3d_openb3dex_TSurface_InitFields(struct openb3d_openb3dex_TSurface_obj* o){
	o->_openb3d_openb3dex_tsurface_tris =SurfaceUShort(o->clas->f_GetInstance_pb_TTSurface(o),8);
	o->_openb3d_openb3dex_tsurface_no_verts =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),1);
	o->_openb3d_openb3dex_tsurface_no_tris =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),2);
	o->_openb3d_openb3dex_tsurface_vert_bone1_no =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),9);
	o->_openb3d_openb3dex_tsurface_vert_bone2_no =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),10);
	o->_openb3d_openb3dex_tsurface_vert_bone3_no =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),11);
	o->_openb3d_openb3dex_tsurface_vert_bone4_no =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),12);
	o->_openb3d_openb3dex_tsurface_vert_array_size =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),20);
	o->_openb3d_openb3dex_tsurface_tri_array_size =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),21);
	o->_openb3d_openb3dex_tsurface_vmin =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),22);
	o->_openb3d_openb3dex_tsurface_vmax =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),23);
	o->_openb3d_openb3dex_tsurface_vbo_enabled =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),24);
	o->_openb3d_openb3dex_tsurface_reset_vbo =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),25);
	o->_openb3d_openb3dex_tsurface_alpha_enable =SurfaceInt(o->clas->f_GetInstance_pb_TTSurface(o),26);
	o->_openb3d_openb3dex_tsurface_vbo_id =SurfaceUInt(o->clas->f_GetInstance_pb_TTSurface(o),19);
	o->_openb3d_openb3dex_tsurface_vert_coords =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),3);
	o->_openb3d_openb3dex_tsurface_vert_norm =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),4);
	o->_openb3d_openb3dex_tsurface_vert_tex_coords0 =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),5);
	o->_openb3d_openb3dex_tsurface_vert_tex_coords1 =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),6);
	o->_openb3d_openb3dex_tsurface_vert_col =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),7);
	o->_openb3d_openb3dex_tsurface_vert_weight1 =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),13);
	o->_openb3d_openb3dex_tsurface_vert_weight2 =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),14);
	o->_openb3d_openb3dex_tsurface_vert_weight3 =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),15);
	o->_openb3d_openb3dex_tsurface_vert_weight4 =SurfaceFloat(o->clas->f_GetInstance_pb_TTSurface(o),16);
	BBBYTE* bbt_inst=SurfaceBrush(o->clas->f_GetInstance_pb_TTSurface(o),17);
	o->_openb3d_openb3dex_tsurface_brush =openb3d_openb3dex_TBrush_GetObject_TTBrush_pb(bbt_inst);
	if((o->_openb3d_openb3dex_tsurface_brush ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tsurface_brush =openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(bbt_inst);
	}
	bbt_inst=SurfaceShader(o->clas->f_GetInstance_pb_TTSurface(o),18);
	o->_openb3d_openb3dex_tsurface_shadermat =openb3d_openb3dex_TShader_GetObject_TTShader_pb(bbt_inst);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_UpdateTexCoords(struct openb3d_openb3dex_TSurface_obj* o){
	UpdateTexCoords(o->clas->f_GetInstance_pb_TTSurface(o));
	return 0;
}
struct openb3d_openb3dex_TBrush_obj* _openb3d_openb3dex_TSurface_GetSurfaceBrush(struct openb3d_openb3dex_TSurface_obj* o){
	BBBYTE* bbt_inst=GetSurfaceBrush(o->clas->f_GetInstance_pb_TTSurface(o));
	struct openb3d_openb3dex_TBrush_obj* volatile bbt_brush=openb3d_openb3dex_TBrush_GetObject_TTBrush_pb(bbt_inst);
	if((bbt_brush==&bbNullObject) && (bbt_inst!=0)){
		bbt_brush=openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(bbt_inst);
	}
	return bbt_brush;
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_TSurface_CreateSurface_TTSurface_TTMeshTTBrush(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	BBBYTE* bbt_inst=CreateSurface(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_brush));
	return openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TSurface_PaintSurface_TTBrush(struct openb3d_openb3dex_TSurface_obj* o,struct openb3d_openb3dex_TBrush_obj* bbt_bru){
	PaintSurface(o->clas->f_GetInstance_pb_TTSurface(o),openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_bru));
	if(o->_openb3d_openb3dex_tsurface_brush !=&bbNullObject){
		(o->_openb3d_openb3dex_tsurface_brush )->clas->m_InitFields(o->_openb3d_openb3dex_tsurface_brush );
	}
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_ClearSurface_ii(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_clear_verts,BBINT bbt_clear_tris){
	ClearSurface(o->clas->f_GetInstance_pb_TTSurface(o),bbt_clear_verts,bbt_clear_tris);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_AddVertex_ffffff(struct openb3d_openb3dex_TSurface_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_u,BBFLOAT bbt_v,BBFLOAT bbt_w){
	return AddVertex(o->clas->f_GetInstance_pb_TTSurface(o),bbt_x,bbt_y,bbt_z,bbt_u,bbt_v,bbt_w);
}
BBINT _openb3d_openb3dex_TSurface_AddTriangle_iii(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_v0,BBINT bbt_v1,BBINT bbt_v2){
	return AddTriangle(o->clas->f_GetInstance_pb_TTSurface(o),bbt_v0,bbt_v1,bbt_v2);
}
BBINT _openb3d_openb3dex_TSurface_CountVertices(struct openb3d_openb3dex_TSurface_obj* o){
	return CountVertices(o->clas->f_GetInstance_pb_TTSurface(o));
}
BBINT _openb3d_openb3dex_TSurface_CountTriangles(struct openb3d_openb3dex_TSurface_obj* o){
	return CountTriangles(o->clas->f_GetInstance_pb_TTSurface(o));
}
BBINT _openb3d_openb3dex_TSurface_VertexCoords_ifff(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	VertexCoords(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid,bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_VertexColor_iffff(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b,BBFLOAT bbt_a){
	VertexColor(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid,bbt_r,bbt_g,bbt_b,bbt_a);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_VertexNormal_ifff(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid,BBFLOAT bbt_nx,BBFLOAT bbt_ny,BBFLOAT bbt_nz){
	VertexNormal(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid,bbt_nx,bbt_ny,bbt_nz);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_VertexTexCoords_ifffi(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid,BBFLOAT bbt_u,BBFLOAT bbt_v,BBFLOAT bbt_w,BBINT bbt_coord_set){
	VertexTexCoords(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid,bbt_u,bbt_v,bbt_w,bbt_coord_set);
	return 0;
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexX_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexX(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexY_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexY(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexZ_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexZ(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexRed_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexRed(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexGreen_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexGreen(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexBlue_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexBlue(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexAlpha_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexAlpha(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexNX_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexNX(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexNY_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexNY(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexNZ_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid){
	return VertexNZ(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexU_ii(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid,BBINT bbt_coord_set){
	return VertexU(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid,bbt_coord_set);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexV_ii(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid,BBINT bbt_coord_set){
	return VertexV(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid,bbt_coord_set);
}
BBFLOAT _openb3d_openb3dex_TSurface_VertexW_ii(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_vid,BBINT bbt_coord_set){
	return VertexW(o->clas->f_GetInstance_pb_TTSurface(o),bbt_vid,bbt_coord_set);
}
BBINT _openb3d_openb3dex_TSurface_TriangleVertex_ii(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_tri_no,BBINT bbt_corner){
	return TriangleVertex(o->clas->f_GetInstance_pb_TTSurface(o),bbt_tri_no,bbt_corner);
}
struct openb3d_openb3dex_TSurface_obj* _openb3d_openb3dex_TSurface_Copy(struct openb3d_openb3dex_TSurface_obj* o){
	BBBYTE* bbt_inst=SurfaceCopy(o->clas->f_GetInstance_pb_TTSurface(o));
	return o->clas->f_CreateObject_TTSurface_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TSurface_UpdateNormals(struct openb3d_openb3dex_TSurface_obj* o){
	SurfaceUpdateNormals(o->clas->f_GetInstance_pb_TTSurface(o));
	return 0;
}
BBFLOAT _openb3d_openb3dex_TSurface_TriangleNX_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_tri_no){
	return TriangleNX(o->clas->f_GetInstance_pb_TTSurface(o),bbt_tri_no);
}
BBFLOAT _openb3d_openb3dex_TSurface_TriangleNY_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_tri_no){
	return TriangleNY(o->clas->f_GetInstance_pb_TTSurface(o),bbt_tri_no);
}
BBFLOAT _openb3d_openb3dex_TSurface_TriangleNZ_i(struct openb3d_openb3dex_TSurface_obj* o,BBINT bbt_tri_no){
	return TriangleNZ(o->clas->f_GetInstance_pb_TTSurface(o),bbt_tri_no);
}
BBINT _openb3d_openb3dex_TSurface_UpdateVBO(struct openb3d_openb3dex_TSurface_obj* o){
	UpdateVBO(o->clas->f_GetInstance_pb_TTSurface(o));
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_FreeVBO(struct openb3d_openb3dex_TSurface_obj* o){
	FreeVBO(o->clas->f_GetInstance_pb_TTSurface(o));
	return 0;
}
BBINT openb3d_openb3dex_TSurface_RemoveTri_i_TTSurfacei(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_tri){
	RemoveTri(openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf),bbt_tri);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_SurfaceColor_ffff(struct openb3d_openb3dex_TSurface_obj* o,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b,BBFLOAT bbt_a){
	SurfaceColor(o->clas->f_GetInstance_pb_TTSurface(o),bbt_r,bbt_g,bbt_b,bbt_a);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_SurfaceRed_f(struct openb3d_openb3dex_TSurface_obj* o,BBFLOAT bbt_r){
	SurfaceRed(o->clas->f_GetInstance_pb_TTSurface(o),bbt_r);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_SurfaceGreen_f(struct openb3d_openb3dex_TSurface_obj* o,BBFLOAT bbt_g){
	SurfaceGreen(o->clas->f_GetInstance_pb_TTSurface(o),bbt_g);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_SurfaceBlue_f(struct openb3d_openb3dex_TSurface_obj* o,BBFLOAT bbt_b){
	SurfaceBlue(o->clas->f_GetInstance_pb_TTSurface(o),bbt_b);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_SurfaceAlpha_f(struct openb3d_openb3dex_TSurface_obj* o,BBFLOAT bbt_a){
	SurfaceAlpha(o->clas->f_GetInstance_pb_TTSurface(o),bbt_a);
	return 0;
}
BBINT _openb3d_openb3dex_TSurface_FreeSurface(struct openb3d_openb3dex_TSurface_obj* o){
	FreeSurface(o->clas->f_GetInstance_pb_TTSurface(o));
	o->clas->f_FreeObject_i_pb(o->clas->f_GetInstance_pb_TTSurface(o));
	return 0;
}
struct brl_map_TMap_obj* openb3d_openb3dex_TSurface_surf_map;
struct BBDebugScope_75 openb3d_openb3dex_TSurface_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TSurface",
	{
		{
			BBDEBUGDECL_FIELD,
			"no_verts",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_no_verts)
		},
		{
			BBDEBUGDECL_FIELD,
			"no_tris",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_no_tris)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_coords",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_coords)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_norm",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_norm)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_tex_coords0",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_tex_coords0)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_tex_coords1",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_tex_coords1)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_col",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_col)
		},
		{
			BBDEBUGDECL_FIELD,
			"tris",
			"*s",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_tris)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_bone1_no",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_bone1_no)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_bone2_no",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_bone2_no)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_bone3_no",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_bone3_no)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_bone4_no",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_bone4_no)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_weight1",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_weight1)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_weight2",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_weight2)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_weight3",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_weight3)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_weight4",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_weight4)
		},
		{
			BBDEBUGDECL_FIELD,
			"brush",
			":TBrush",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_brush)
		},
		{
			BBDEBUGDECL_FIELD,
			"ShaderMat",
			":TShader",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_shadermat)
		},
		{
			BBDEBUGDECL_FIELD,
			"vbo_id",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vbo_id)
		},
		{
			BBDEBUGDECL_FIELD,
			"vert_array_size",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vert_array_size)
		},
		{
			BBDEBUGDECL_FIELD,
			"tri_array_size",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_tri_array_size)
		},
		{
			BBDEBUGDECL_FIELD,
			"vmin",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vmin)
		},
		{
			BBDEBUGDECL_FIELD,
			"vmax",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vmax)
		},
		{
			BBDEBUGDECL_FIELD,
			"vbo_enabled",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_vbo_enabled)
		},
		{
			BBDEBUGDECL_FIELD,
			"reset_vbo",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_reset_vbo)
		},
		{
			BBDEBUGDECL_FIELD,
			"alpha_enable",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_alpha_enable)
		},
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_instance)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"surf_map",
			":TMap",
			&openb3d_openb3dex_TSurface_surf_map
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TSurface_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TSurface",
			&openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TSurface_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TSurface",
			&openb3d_openb3dex_TSurface_GetObject_TTSurface_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TSurface)*b",
			&openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TSurface_InitFields
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateTexCoords",
			"()i",
			&_openb3d_openb3dex_TSurface_UpdateTexCoords
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetSurfaceBrush",
			"():TBrush",
			&_openb3d_openb3dex_TSurface_GetSurfaceBrush
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateSurface",
			"(:TMesh,:TBrush):TSurface",
			&openb3d_openb3dex_TSurface_CreateSurface_TTSurface_TTMeshTTBrush
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"PaintSurface",
			"(:TBrush)i",
			&_openb3d_openb3dex_TSurface_PaintSurface_TTBrush
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ClearSurface",
			"(i,i)i",
			&_openb3d_openb3dex_TSurface_ClearSurface_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AddVertex",
			"(f,f,f,f,f,f)i",
			&_openb3d_openb3dex_TSurface_AddVertex_ffffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AddTriangle",
			"(i,i,i)i",
			&_openb3d_openb3dex_TSurface_AddTriangle_iii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CountVertices",
			"()i",
			&_openb3d_openb3dex_TSurface_CountVertices
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CountTriangles",
			"()i",
			&_openb3d_openb3dex_TSurface_CountTriangles
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexCoords",
			"(i,f,f,f)i",
			&_openb3d_openb3dex_TSurface_VertexCoords_ifff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexColor",
			"(i,f,f,f,f)i",
			&_openb3d_openb3dex_TSurface_VertexColor_iffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexNormal",
			"(i,f,f,f)i",
			&_openb3d_openb3dex_TSurface_VertexNormal_ifff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexTexCoords",
			"(i,f,f,f,i)i",
			&_openb3d_openb3dex_TSurface_VertexTexCoords_ifffi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexX",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexX_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexY",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexY_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexZ",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexZ_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexRed",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexRed_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexGreen",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexGreen_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexBlue",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexBlue_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexAlpha",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexAlpha_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexNX",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexNX_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexNY",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexNY_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexNZ",
			"(i)f",
			&_openb3d_openb3dex_TSurface_VertexNZ_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexU",
			"(i,i)f",
			&_openb3d_openb3dex_TSurface_VertexU_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexV",
			"(i,i)f",
			&_openb3d_openb3dex_TSurface_VertexV_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VertexW",
			"(i,i)f",
			&_openb3d_openb3dex_TSurface_VertexW_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TriangleVertex",
			"(i,i)i",
			&_openb3d_openb3dex_TSurface_TriangleVertex_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Copy",
			"():TSurface",
			&_openb3d_openb3dex_TSurface_Copy
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateNormals",
			"()i",
			&_openb3d_openb3dex_TSurface_UpdateNormals
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TriangleNX",
			"(i)f",
			&_openb3d_openb3dex_TSurface_TriangleNX_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TriangleNY",
			"(i)f",
			&_openb3d_openb3dex_TSurface_TriangleNY_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TriangleNZ",
			"(i)f",
			&_openb3d_openb3dex_TSurface_TriangleNZ_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateVBO",
			"()i",
			&_openb3d_openb3dex_TSurface_UpdateVBO
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeVBO",
			"()i",
			&_openb3d_openb3dex_TSurface_FreeVBO
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"RemoveTri",
			"(:TSurface,i)i",
			&openb3d_openb3dex_TSurface_RemoveTri_i_TTSurfacei
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SurfaceColor",
			"(f,f,f,f)i",
			&_openb3d_openb3dex_TSurface_SurfaceColor_ffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SurfaceRed",
			"(f)i",
			&_openb3d_openb3dex_TSurface_SurfaceRed_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SurfaceGreen",
			"(f)i",
			&_openb3d_openb3dex_TSurface_SurfaceGreen_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SurfaceBlue",
			"(f)i",
			&_openb3d_openb3dex_TSurface_SurfaceBlue_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SurfaceAlpha",
			"(f)i",
			&_openb3d_openb3dex_TSurface_SurfaceAlpha_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeSurface",
			"()i",
			&_openb3d_openb3dex_TSurface_FreeSurface
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TSurface openb3d_openb3dex_TSurface={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TSurface_scope,
	sizeof(struct openb3d_openb3dex_TSurface_obj),
	_openb3d_openb3dex_TSurface_New,
	_openb3d_openb3dex_TSurface_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TSurface_obj,_openb3d_openb3dex_tsurface_instance) - sizeof(void*) + sizeof(BBBYTE*)
	,openb3d_openb3dex_TSurface_CreateObject_TTSurface_pb
	,openb3d_openb3dex_TSurface_FreeObject_i_pb
	,openb3d_openb3dex_TSurface_GetObject_TTSurface_pb
	,openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface
	,_openb3d_openb3dex_TSurface_InitFields
	,_openb3d_openb3dex_TSurface_UpdateTexCoords
	,_openb3d_openb3dex_TSurface_GetSurfaceBrush
	,openb3d_openb3dex_TSurface_CreateSurface_TTSurface_TTMeshTTBrush
	,_openb3d_openb3dex_TSurface_PaintSurface_TTBrush
	,_openb3d_openb3dex_TSurface_ClearSurface_ii
	,_openb3d_openb3dex_TSurface_AddVertex_ffffff
	,_openb3d_openb3dex_TSurface_AddTriangle_iii
	,_openb3d_openb3dex_TSurface_CountVertices
	,_openb3d_openb3dex_TSurface_CountTriangles
	,_openb3d_openb3dex_TSurface_VertexCoords_ifff
	,_openb3d_openb3dex_TSurface_VertexColor_iffff
	,_openb3d_openb3dex_TSurface_VertexNormal_ifff
	,_openb3d_openb3dex_TSurface_VertexTexCoords_ifffi
	,_openb3d_openb3dex_TSurface_VertexX_i
	,_openb3d_openb3dex_TSurface_VertexY_i
	,_openb3d_openb3dex_TSurface_VertexZ_i
	,_openb3d_openb3dex_TSurface_VertexRed_i
	,_openb3d_openb3dex_TSurface_VertexGreen_i
	,_openb3d_openb3dex_TSurface_VertexBlue_i
	,_openb3d_openb3dex_TSurface_VertexAlpha_i
	,_openb3d_openb3dex_TSurface_VertexNX_i
	,_openb3d_openb3dex_TSurface_VertexNY_i
	,_openb3d_openb3dex_TSurface_VertexNZ_i
	,_openb3d_openb3dex_TSurface_VertexU_ii
	,_openb3d_openb3dex_TSurface_VertexV_ii
	,_openb3d_openb3dex_TSurface_VertexW_ii
	,_openb3d_openb3dex_TSurface_TriangleVertex_ii
	,_openb3d_openb3dex_TSurface_Copy
	,_openb3d_openb3dex_TSurface_UpdateNormals
	,_openb3d_openb3dex_TSurface_TriangleNX_i
	,_openb3d_openb3dex_TSurface_TriangleNY_i
	,_openb3d_openb3dex_TSurface_TriangleNZ_i
	,_openb3d_openb3dex_TSurface_UpdateVBO
	,_openb3d_openb3dex_TSurface_FreeVBO
	,openb3d_openb3dex_TSurface_RemoveTri_i_TTSurfacei
	,_openb3d_openb3dex_TSurface_SurfaceColor_ffff
	,_openb3d_openb3dex_TSurface_SurfaceRed_f
	,_openb3d_openb3dex_TSurface_SurfaceGreen_f
	,_openb3d_openb3dex_TSurface_SurfaceBlue_f
	,_openb3d_openb3dex_TSurface_SurfaceAlpha_f
	,_openb3d_openb3dex_TSurface_FreeSurface
};

void _openb3d_openb3dex_TTexture_New(struct openb3d_openb3dex_TTexture_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TTexture;
	o->_openb3d_openb3dex_ttexture_texture = 0;
	o->_openb3d_openb3dex_ttexture_file = 0;
	o->_openb3d_openb3dex_ttexture_frames = 0;
	o->_openb3d_openb3dex_ttexture_flags = 0;
	o->_openb3d_openb3dex_ttexture_blend = 0;
	o->_openb3d_openb3dex_ttexture_coords = 0;
	o->_openb3d_openb3dex_ttexture_u_scale = 0;
	o->_openb3d_openb3dex_ttexture_v_scale = 0;
	o->_openb3d_openb3dex_ttexture_u_pos = 0;
	o->_openb3d_openb3dex_ttexture_v_pos = 0;
	o->_openb3d_openb3dex_ttexture_angle = 0;
	o->_openb3d_openb3dex_ttexture_file_abs = 0;
	o->_openb3d_openb3dex_ttexture_width = 0;
	o->_openb3d_openb3dex_ttexture_height = 0;
	o->_openb3d_openb3dex_ttexture_no_frames = 0;
	o->_openb3d_openb3dex_ttexture_framebuffer = 0;
	o->_openb3d_openb3dex_ttexture_cube_face = 0;
	o->_openb3d_openb3dex_ttexture_cube_mode = 0;
	o->_openb3d_openb3dex_ttexture_instance = 0;
	o->_openb3d_openb3dex_ttexture_exists = 0;
}
void _openb3d_openb3dex_TTexture_Delete(struct openb3d_openb3dex_TTexture_obj* o) {
	bbObjectDtor(o);
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_TTexture_CreateObject_TTTexture_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TTexture_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TTexture);
	(openb3d_openb3dex_TTexture_tex_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TTexture_tex_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_ttexture_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TTexture_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TTexture_tex_map)->clas->m_Remove_TObject(openb3d_openb3dex_TTexture_tex_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_TTexture_GetObject_TTTexture_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TTexture_obj*)bbObjectDowncast((openb3d_openb3dex_TTexture_tex_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TTexture_tex_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TTexture));
}
BBBYTE* openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(struct openb3d_openb3dex_TTexture_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_ttexture_instance ;
}
BBINT _openb3d_openb3dex_TTexture_InitFields(struct openb3d_openb3dex_TTexture_obj* o){
	o->_openb3d_openb3dex_ttexture_flags =TextureInt(o->clas->f_GetInstance_pb_TTTexture(o),5);
	o->_openb3d_openb3dex_ttexture_blend =TextureInt(o->clas->f_GetInstance_pb_TTTexture(o),6);
	o->_openb3d_openb3dex_ttexture_coords =TextureInt(o->clas->f_GetInstance_pb_TTTexture(o),7);
	o->_openb3d_openb3dex_ttexture_width =TextureInt(o->clas->f_GetInstance_pb_TTTexture(o),14);
	o->_openb3d_openb3dex_ttexture_height =TextureInt(o->clas->f_GetInstance_pb_TTTexture(o),15);
	o->_openb3d_openb3dex_ttexture_no_frames =TextureInt(o->clas->f_GetInstance_pb_TTTexture(o),16);
	o->_openb3d_openb3dex_ttexture_cube_face =TextureInt(o->clas->f_GetInstance_pb_TTTexture(o),18);
	o->_openb3d_openb3dex_ttexture_cube_mode =TextureInt(o->clas->f_GetInstance_pb_TTTexture(o),19);
	o->_openb3d_openb3dex_ttexture_texture =TextureUInt(o->clas->f_GetInstance_pb_TTTexture(o),1);
	o->_openb3d_openb3dex_ttexture_frames =TextureUInt(o->clas->f_GetInstance_pb_TTTexture(o),4);
	o->_openb3d_openb3dex_ttexture_framebuffer =TextureUInt(o->clas->f_GetInstance_pb_TTTexture(o),17);
	o->_openb3d_openb3dex_ttexture_u_scale =TextureFloat(o->clas->f_GetInstance_pb_TTTexture(o),8);
	o->_openb3d_openb3dex_ttexture_v_scale =TextureFloat(o->clas->f_GetInstance_pb_TTTexture(o),9);
	o->_openb3d_openb3dex_ttexture_u_pos =TextureFloat(o->clas->f_GetInstance_pb_TTTexture(o),10);
	o->_openb3d_openb3dex_ttexture_v_pos =TextureFloat(o->clas->f_GetInstance_pb_TTTexture(o),11);
	o->_openb3d_openb3dex_ttexture_angle =TextureFloat(o->clas->f_GetInstance_pb_TTTexture(o),12);
	o->_openb3d_openb3dex_ttexture_file =TextureString(o->clas->f_GetInstance_pb_TTTexture(o),3);
	o->_openb3d_openb3dex_ttexture_file_abs =TextureString(o->clas->f_GetInstance_pb_TTTexture(o),13);
	o->clas->f_AddList__i_TTList(openb3d_openb3dex_TTexture_tex_list);
	o->_openb3d_openb3dex_ttexture_exists =1;
	return 0;
}
BBINT openb3d_openb3dex_TTexture_AddList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TTexture_tex_list){
		if(StaticListSize(52,2)!=0){
			BBBYTE* bbt_inst=StaticIterListTexture(52,2,(&openb3d_openb3dex_TTexture_tex_list_id));
			struct openb3d_openb3dex_TTexture_obj* volatile bbt_obj=openb3d_openb3dex_TTexture_GetObject_TTTexture_pb(bbt_inst);
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TTexture_CopyList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	brl_linkedlist_ClearList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TTexture_tex_list){
		openb3d_openb3dex_TTexture_tex_list_id=0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(StaticListSize(52,2)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=StaticIterListTexture(52,2,(&openb3d_openb3dex_TTexture_tex_list_id));
				struct openb3d_openb3dex_TTexture_obj* volatile bbt_obj=openb3d_openb3dex_TTexture_GetObject_TTTexture_pb(bbt_inst);
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_BufferToTex_pbi(struct openb3d_openb3dex_TTexture_obj* o,BBBYTE* bbt_buffer,BBINT bbt_frame){
	BufferToTex(o->clas->f_GetInstance_pb_TTTexture(o),bbt_buffer,bbt_frame);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_TexToBuffer_pbi(struct openb3d_openb3dex_TTexture_obj* o,BBBYTE* bbt_buffer,BBINT bbt_frame){
	TexToBuffer(o->clas->f_GetInstance_pb_TTTexture(o),bbt_buffer,bbt_frame);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_CameraToTex_TTCamerai(struct openb3d_openb3dex_TTexture_obj* o,struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBINT bbt_frame){
	if(__GLEW_VERSION_2_1!=0){
		CameraToTex(o->clas->f_GetInstance_pb_TTTexture(o),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_cam,&openb3d_openb3dex_TEntity)),bbt_frame);
	}else{
		((struct openb3d_openb3dex_TTexture_obj*)o)->clas->m_CameraToTexEXT_TTCamerai(o,bbt_cam,0);
	}
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_DepthBufferToTex_TTCamera(struct openb3d_openb3dex_TTexture_obj* o,struct openb3d_openb3dex_TCamera_obj* bbt_cam){
	if(__GLEW_VERSION_2_1!=0){
		DepthBufferToTex(o->clas->f_GetInstance_pb_TTTexture(o),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_cam,&openb3d_openb3dex_TEntity)));
	}else{
		((struct openb3d_openb3dex_TTexture_obj*)o)->clas->m_DepthBufferToTexEXT_TTCamerai(o,bbt_cam,0);
	}
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_FreeTexture(struct openb3d_openb3dex_TTexture_obj* o){
	if(o->_openb3d_openb3dex_ttexture_exists !=0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TTexture_tex_list,o);
		openb3d_openb3dex_TTexture_tex_list_id-=1;
		FreeTexture(o->clas->f_GetInstance_pb_TTTexture(o));
		o->clas->f_FreeObject_i_pb(o->clas->f_GetInstance_pb_TTTexture(o));
		o->_openb3d_openb3dex_ttexture_exists =0;
	}
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_TTexture_CreateTexture_TTTexture_iiii(BBINT bbt_width,BBINT bbt_height,BBINT bbt_flags,BBINT bbt_frames){
	BBBYTE* bbt_inst=CreateTexture(bbt_width,bbt_height,bbt_flags,bbt_frames);
	return openb3d_openb3dex_TTexture_CreateObject_TTTexture_pb(bbt_inst);
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_TTexture_LoadTexture_TTTexture_Si(BBSTRING bbt_file,BBINT bbt_flags){
	BBSTRING bbt_ext=bbStringToLower(brl_filesystem_ExtractExt(bbt_file));
	if(bbStringCompare(bbt_ext, &_s18)==0 || bbStringCompare(bbt_ext, &_s19)==0){
		return openb3d_openb3dex_TTexture_LoadTextureAlpha_TTTexture_Sii(bbt_file,bbt_flags,0);
	}else{
		BBBYTE* bbt_cString=bbStringToCString(bbt_file);
		BBBYTE* bbt_inst=LoadTexture(bbt_cString,bbt_flags);
		struct openb3d_openb3dex_TTexture_obj* volatile bbt_tex=openb3d_openb3dex_TTexture_CreateObject_TTTexture_pb(bbt_inst);
		bbMemFree((void*)bbt_cString);
		return bbt_tex;
	}
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_TTexture_LoadAnimTexture_TTTexture_Siiiii(BBSTRING bbt_file,BBINT bbt_flags,BBINT bbt_frame_width,BBINT bbt_frame_height,BBINT bbt_first_frame,BBINT bbt_frame_count){
	BBBYTE* bbt_cString=bbStringToCString(bbt_file);
	BBBYTE* bbt_inst=LoadAnimTexture(bbt_cString,bbt_flags,bbt_frame_width,bbt_frame_height,bbt_first_frame,bbt_frame_count);
	struct openb3d_openb3dex_TTexture_obj* volatile bbt_tex=openb3d_openb3dex_TTexture_CreateObject_TTTexture_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	return bbt_tex;
}
BBINT _openb3d_openb3dex_TTexture_TextureBlend_i(struct openb3d_openb3dex_TTexture_obj* o,BBINT bbt_blend){
	TextureBlend(o->clas->f_GetInstance_pb_TTTexture(o),bbt_blend);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_TextureCoords_i(struct openb3d_openb3dex_TTexture_obj* o,BBINT bbt_coords){
	TextureCoords(o->clas->f_GetInstance_pb_TTTexture(o),bbt_coords);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_ScaleTexture_ff(struct openb3d_openb3dex_TTexture_obj* o,BBFLOAT bbt_u_scale,BBFLOAT bbt_v_scale){
	ScaleTexture(o->clas->f_GetInstance_pb_TTTexture(o),bbt_u_scale,bbt_v_scale);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_PositionTexture_ff(struct openb3d_openb3dex_TTexture_obj* o,BBFLOAT bbt_u_pos,BBFLOAT bbt_v_pos){
	PositionTexture(o->clas->f_GetInstance_pb_TTTexture(o),bbt_u_pos,bbt_v_pos);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_RotateTexture_f(struct openb3d_openb3dex_TTexture_obj* o,BBFLOAT bbt_ang){
	RotateTexture(o->clas->f_GetInstance_pb_TTTexture(o),bbt_ang);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_TextureWidth(struct openb3d_openb3dex_TTexture_obj* o){
	return TextureWidth(o->clas->f_GetInstance_pb_TTTexture(o));
}
BBINT _openb3d_openb3dex_TTexture_TextureHeight(struct openb3d_openb3dex_TTexture_obj* o){
	return TextureHeight(o->clas->f_GetInstance_pb_TTTexture(o));
}
BBSTRING _openb3d_openb3dex_TTexture_TextureName(struct openb3d_openb3dex_TTexture_obj* o){
	return bbStringFromCString(TextureName(o->clas->f_GetInstance_pb_TTTexture(o)));
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_TTexture_GetBrushTexture_TTTexture_TTBrushi(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBINT bbt_index){
	BBBYTE* bbt_inst=GetBrushTexture(openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_brush),bbt_index);
	return openb3d_openb3dex_TTexture_GetObject_TTTexture_pb(bbt_inst);
}
BBINT openb3d_openb3dex_TTexture_ClearTextureFilters_i(){
	ClearTextureFilters();
	return 0;
}
BBINT openb3d_openb3dex_TTexture_TextureFilter_i_Si(BBSTRING bbt_match_text,BBINT bbt_flags){
	BBBYTE* bbt_cString=bbStringToCString(bbt_match_text);
	TextureFilter(bbt_cString,bbt_flags);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_SetCubeFace_i(struct openb3d_openb3dex_TTexture_obj* o,BBINT bbt_face){
	SetCubeFace(o->clas->f_GetInstance_pb_TTTexture(o),bbt_face);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_SetCubeMode_i(struct openb3d_openb3dex_TTexture_obj* o,BBINT bbt_Mode){
	SetCubeMode(o->clas->f_GetInstance_pb_TTTexture(o),bbt_Mode);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_BackBufferToTex_i(struct openb3d_openb3dex_TTexture_obj* o,BBINT bbt_frame){
	BackBufferToTex(o->clas->f_GetInstance_pb_TTTexture(o),bbt_frame);
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* _openb3d_openb3dex_TTexture_Copy(struct openb3d_openb3dex_TTexture_obj* o){
	BBBYTE* bbt_inst=TextureCopy(o->clas->f_GetInstance_pb_TTTexture(o));
	return o->clas->f_CreateObject_TTTexture_pb(bbt_inst);
}
struct openb3d_openb3dex_TTexture_obj* _openb3d_openb3dex_TTexture_TexInList(struct openb3d_openb3dex_TTexture_obj* o){
	BBBYTE* bbt_inst=TexInList(o->clas->f_GetInstance_pb_TTTexture(o));
	return o->clas->f_GetObject_TTTexture_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TTexture_FilterFlags(struct openb3d_openb3dex_TTexture_obj* o){
	FilterFlags(o->clas->f_GetInstance_pb_TTTexture(o));
	return 0;
}
BBINT openb3d_openb3dex_TTexture_FileFind_i_vS(BBSTRING* bbt_file){
	struct brl_stream_TStream_obj* volatile bbt_TS=brl_filesystem_OpenFile(*bbt_file,1,0);
	if(!(bbt_TS!= &bbNullObject)){
		do{
			*bbt_file=brl_retro_Right(*bbt_file,((*bbt_file)->length-brl_retro_Instr(*bbt_file,&_s20,1)));
		}while(!(brl_retro_Instr(*bbt_file,&_s20,1)==0));
		do{
			*bbt_file=brl_retro_Right(*bbt_file,((*bbt_file)->length-brl_retro_Instr(*bbt_file,&_s21,1)));
		}while(!(brl_retro_Instr(*bbt_file,&_s21,1)==0));
		bbt_TS=brl_stream_OpenStream(*bbt_file,1,0);
		if(!(bbt_TS!= &bbNullObject)){
			brl_blitz_DebugLog(bbStringConcat(&_s22,*bbt_file));
			return 0;
		}else{
			brl_stream_CloseStream(bbt_TS);
			bbt_TS=&bbNullObject;
		}
	}else{
		brl_stream_CloseStream(bbt_TS);
		bbt_TS=&bbNullObject;
	}
	return 1;
}
BBSTRING openb3d_openb3dex_TTexture_FileAbs_S_S(BBSTRING bbt_file){
	BBSTRING bbt_file_abs=&bbEmptyString;
	if(brl_retro_Instr(bbt_file,&_s23,1)==0){
		bbt_file_abs=bbStringConcat(bbStringConcat(brl_filesystem_CurrentDir(),&_s21),bbt_file);
	}else{
		bbt_file_abs=bbt_file;
	}
	bbt_file_abs=brl_retro_Replace(bbt_file_abs,&_s20,&_s21);
	return bbt_file_abs;
}
struct brl_pixmap_TPixmap_obj* openb3d_openb3dex_TTexture_AdjustPixmap_TTPixmap_TTPixmap(struct brl_pixmap_TPixmap_obj* bbt_pixmap){
	BBINT bbt_width=openb3d_openb3dex_TTexture_Pow2Size_i_i(bbt_pixmap->_brl_pixmap_tpixmap_width );
	BBINT bbt_height=openb3d_openb3dex_TTexture_Pow2Size_i_i(bbt_pixmap->_brl_pixmap_tpixmap_height );
	if((bbt_width!=bbt_pixmap->_brl_pixmap_tpixmap_width ) || (bbt_height!=bbt_pixmap->_brl_pixmap_tpixmap_height )){
		bbt_pixmap=brl_pixmap_ResizePixmap(bbt_pixmap,bbt_width,bbt_height);
	}
	return bbt_pixmap;
}
BBINT openb3d_openb3dex_TTexture_Pow2Size_i_i(BBINT bbt_n){
	BBINT bbt_t=1;
	while(bbt_t<bbt_n){
		bbt_t*=2;
	}
	return bbt_t;
}
struct brl_pixmap_TPixmap_obj* openb3d_openb3dex_TTexture_ApplyAlpha_TTPixmap_TTPixmap(struct brl_pixmap_TPixmap_obj* bbt_pixmap){
	struct brl_pixmap_TPixmap_obj* volatile bbt_tmp=bbt_pixmap;
	if(bbt_tmp->_brl_pixmap_tpixmap_format !=6){
		bbt_tmp=(bbt_tmp)->clas->m_Convert_i(bbt_tmp,6);
	}
	struct brl_pixmap_TPixmap_obj* volatile bbt_out=brl_pixmap_CreatePixmap(bbt_tmp->_brl_pixmap_tpixmap_width ,bbt_tmp->_brl_pixmap_tpixmap_height ,6,4);
	{
		BBINT bbt_y=0;
		BBINT bbt_=bbt_pixmap->_brl_pixmap_tpixmap_height ;
		for(bbt_y;(bbt_y<bbt_);bbt_y=(bbt_y+1)){
			BBBYTE* bbt_t=(bbt_tmp)->clas->m_PixelPtr_ii(bbt_tmp,0,bbt_y);
			BBBYTE* bbt_o=(bbt_out)->clas->m_PixelPtr_ii(bbt_out,0,bbt_y);
			{
				BBINT bbt_x=0;
				BBINT bbt_2=bbt_pixmap->_brl_pixmap_tpixmap_width ;
				for(bbt_x;(bbt_x<bbt_2);bbt_x=(bbt_x+1)){
					bbt_o[0U]=bbt_t[0U];
					bbt_o[1U]=bbt_t[1U];
					bbt_o[2U]=bbt_t[2U];
					bbt_o[3U]=((BBBYTE)(((BBFLOAT)((bbt_o[0U]+bbt_o[1U])+bbt_o[2U]))/3.0f));
					bbt_t+=4;
					bbt_o+=4;
				}
			}
		}
	}
	return bbt_out;
}
BBINT _openb3d_openb3dex_TTexture_CameraToTexEXT_TTCamerai(struct openb3d_openb3dex_TTexture_obj* o,struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBINT bbt_frame){
	openb3d_openb3dex_TGlobal_camera_in_use=bbt_cam;
	BBINT bbt_target=0;
	if(((unsigned int)(o->_openb3d_openb3dex_ttexture_flags [0U])&128)!=0){
		bbt_target=34067;
	}else{
		bbt_target=3553;
	}
	glBindTexture((GLenum)bbt_target,(GLuint)o->_openb3d_openb3dex_ttexture_texture [0U]);
	if(o->_openb3d_openb3dex_ttexture_framebuffer ==0){
		o->_openb3d_openb3dex_ttexture_framebuffer =((BBINT*)bbMemAlloc((size_t)8LL));
		__glewGenFramebuffersEXT(1,(&o->_openb3d_openb3dex_ttexture_framebuffer [0U]));
		__glewGenRenderbuffersEXT(1,(&o->_openb3d_openb3dex_ttexture_framebuffer [1U]));
		if(((unsigned int)(o->_openb3d_openb3dex_ttexture_flags [0U])&128)!=0){
			{
				BBINT bbt_i=0;
				for(bbt_i;(bbt_i<6);bbt_i=(bbt_i+1)){
					BBINT bbt_=bbt_i;
					if(bbt_==0){
						glTexImage2D((GLenum)34070,(GLint)0,(GLint)32856,(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0,(GLenum)6408,(GLenum)5121,(const GLvoid*)0);
					}else{
						if(bbt_==1){
							glTexImage2D((GLenum)34073,(GLint)0,(GLint)32856,(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0,(GLenum)6408,(GLenum)5121,(const GLvoid*)0);
						}else{
							if(bbt_==2){
								glTexImage2D((GLenum)34069,(GLint)0,(GLint)32856,(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0,(GLenum)6408,(GLenum)5121,(const GLvoid*)0);
							}else{
								if(bbt_==3){
									glTexImage2D((GLenum)34074,(GLint)0,(GLint)32856,(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0,(GLenum)6408,(GLenum)5121,(const GLvoid*)0);
								}else{
									if(bbt_==4){
										glTexImage2D((GLenum)34071,(GLint)0,(GLint)32856,(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0,(GLenum)6408,(GLenum)5121,(const GLvoid*)0);
									}else{
										if(bbt_==5){
											glTexImage2D((GLenum)34072,(GLint)0,(GLint)32856,(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0,(GLenum)6408,(GLenum)5121,(const GLvoid*)0);
										}
									}
								}
							}
						}
					}
				}
			}
		}else{
			glTexImage2D((GLenum)3553,(GLint)0,(GLint)32856,(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0,(GLenum)6408,(GLenum)5121,(const GLvoid*)0);
		}
	}
	__glewBindFramebufferEXT(36160,o->_openb3d_openb3dex_ttexture_framebuffer [0U]);
	if(((unsigned int)(o->_openb3d_openb3dex_ttexture_flags [0U])&128)!=0){
		BBINT bbt_2=o->_openb3d_openb3dex_ttexture_cube_face [0U];
		if(bbt_2==0){
			__glewFramebufferTexture2DEXT(36160,36064,34070,o->_openb3d_openb3dex_ttexture_texture [0U],0);
		}else{
			if(bbt_2==1){
				__glewFramebufferTexture2DEXT(36160,36064,34073,o->_openb3d_openb3dex_ttexture_texture [0U],0);
			}else{
				if(bbt_2==2){
					__glewFramebufferTexture2DEXT(36160,36064,34069,o->_openb3d_openb3dex_ttexture_texture [0U],0);
				}else{
					if(bbt_2==3){
						__glewFramebufferTexture2DEXT(36160,36064,34074,o->_openb3d_openb3dex_ttexture_texture [0U],0);
					}else{
						if(bbt_2==4){
							__glewFramebufferTexture2DEXT(36160,36064,34072,o->_openb3d_openb3dex_ttexture_texture [0U],0);
						}else{
							if(bbt_2==5){
								__glewFramebufferTexture2DEXT(36160,36064,34071,o->_openb3d_openb3dex_ttexture_texture [0U],0);
							}
						}
					}
				}
			}
		}
	}else{
		__glewFramebufferTexture2DEXT(36160,36064,3553,o->_openb3d_openb3dex_ttexture_texture [0U],0);
	}
	__glewBindRenderbufferEXT(36161,o->_openb3d_openb3dex_ttexture_framebuffer [1U]);
	if(openb3d_openb3dex_THardwareInfo_DepthStencil==0){
		__glewRenderbufferStorageEXT(36161,6402,o->_openb3d_openb3dex_ttexture_width [0U],o->_openb3d_openb3dex_ttexture_height [0U]);
	}
	if(openb3d_openb3dex_THardwareInfo_DepthStencil==1){
		__glewRenderbufferStorageEXT(36161,35056,o->_openb3d_openb3dex_ttexture_width [0U],o->_openb3d_openb3dex_ttexture_height [0U]);
	}
	__glewFramebufferRenderbufferEXT(36160,36096,36161,o->_openb3d_openb3dex_ttexture_framebuffer [1U]);
	if(openb3d_openb3dex_THardwareInfo_DepthStencil==1){
		__glewFramebufferRenderbufferEXT(36160,36128,36161,o->_openb3d_openb3dex_ttexture_framebuffer [1U]);
	}
	(bbt_cam)->clas->m_Render(bbt_cam);
	if(openb3d_openb3dex_TGlobal_Shadows_enabled[0U]==1){
		openb3d_openb3dex_TShadowObject_Update_i_TTCamera(bbt_cam);
	}
	glBindTexture((GLenum)bbt_target,(GLuint)o->_openb3d_openb3dex_ttexture_texture [0U]);
	__glewGenerateMipmapEXT(bbt_target);
	__glewBindFramebufferEXT(36160,0);
	__glewBindRenderbufferEXT(36161,0);
	return 0;
}
BBINT _openb3d_openb3dex_TTexture_DepthBufferToTexEXT_TTCamerai(struct openb3d_openb3dex_TTexture_obj* o,struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBINT bbt_frame){
	glBindTexture((GLenum)3553,(GLuint)o->_openb3d_openb3dex_ttexture_texture [0U]);
	if(bbt_cam==&bbNullObject){
		glCopyTexImage2D((GLenum)3553,(GLint)0,(GLenum)6402,(GLint)0,(GLint)(openb3d_openb3dex_TGlobal_height[0U]-o->_openb3d_openb3dex_ttexture_height [0U]),(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0);
		glTexParameteri((GLenum)3553,(GLenum)33169,(GLint)1);
	}else{
		openb3d_openb3dex_TGlobal_camera_in_use=bbt_cam;
		if(o->_openb3d_openb3dex_ttexture_framebuffer ==0){
			o->_openb3d_openb3dex_ttexture_framebuffer =((BBINT*)bbMemAlloc((size_t)8LL));
			__glewGenFramebuffersEXT(1,(&o->_openb3d_openb3dex_ttexture_framebuffer [0U]));
			__glewGenRenderbuffersEXT(1,(&o->_openb3d_openb3dex_ttexture_framebuffer [1U]));
			glTexImage2D((GLenum)3553,(GLint)0,(GLint)32856,(GLsizei)o->_openb3d_openb3dex_ttexture_width [0U],(GLsizei)o->_openb3d_openb3dex_ttexture_height [0U],(GLint)0,(GLenum)6408,(GLenum)5121,(const GLvoid*)0);
		}
		__glewBindFramebufferEXT(36160,o->_openb3d_openb3dex_ttexture_framebuffer [0U]);
		__glewFramebufferTexture2DEXT(36160,36064,3553,o->_openb3d_openb3dex_ttexture_texture [0U],0);
		__glewBindRenderbufferEXT(36161,o->_openb3d_openb3dex_ttexture_framebuffer [1U]);
		if(openb3d_openb3dex_THardwareInfo_DepthStencil==0){
			__glewRenderbufferStorageEXT(36161,6402,o->_openb3d_openb3dex_ttexture_width [0U],o->_openb3d_openb3dex_ttexture_height [0U]);
		}
		if(openb3d_openb3dex_THardwareInfo_DepthStencil==1){
			__glewRenderbufferStorageEXT(36161,35056,o->_openb3d_openb3dex_ttexture_width [0U],o->_openb3d_openb3dex_ttexture_height [0U]);
		}
		__glewFramebufferRenderbufferEXT(36160,36096,36161,o->_openb3d_openb3dex_ttexture_framebuffer [1U]);
		if(openb3d_openb3dex_THardwareInfo_DepthStencil==1){
			__glewFramebufferRenderbufferEXT(36160,36128,36161,o->_openb3d_openb3dex_ttexture_framebuffer [1U]);
		}
		(bbt_cam)->clas->m_Render(bbt_cam);
		if(openb3d_openb3dex_TGlobal_Shadows_enabled[0U]==1){
			openb3d_openb3dex_TShadowObject_Update_i_TTCamera(bbt_cam);
		}
		glBindTexture((GLenum)3553,(GLuint)o->_openb3d_openb3dex_ttexture_texture [0U]);
		__glewGenerateMipmapEXT(3553);
		__glewBindFramebufferEXT(36160,0);
		__glewBindRenderbufferEXT(36161,0);
	}
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_TTexture_LoadTextureAlpha_TTTexture_Sii(BBSTRING bbt_file,BBINT bbt_flags,BBINT bbt_alphamask){
	struct brl_pixmap_TPixmap_obj* volatile bbt_map=brl_pixmap_LoadPixmap(bbt_file);
	if(bbt_map->_brl_pixmap_tpixmap_format !=6){
		bbt_map=(bbt_map)->clas->m_Convert_i(bbt_map,6);
	}
	if(bbt_alphamask!=0){
		{
			BBINT bbt_iy=0;
			BBINT bbt_=(brl_pixmap_PixmapWidth(bbt_map)-1);
			for(bbt_iy;(bbt_iy<=bbt_);bbt_iy=(bbt_iy+1)){
				{
					BBINT bbt_ix=0;
					BBINT bbt_2=(brl_pixmap_PixmapHeight(bbt_map)-1);
					for(bbt_ix;(bbt_ix<=bbt_2);bbt_ix=(bbt_ix+1)){
						BBINT bbt_rgba=brl_pixmap_ReadPixel(bbt_map,bbt_ix,bbt_iy);
						BBINT bbt_alp=((unsigned int)(bbt_rgba)&bbt_alphamask);
						if(((unsigned int)(bbt_alp)&-16777216)!=0){
							bbt_alp=((unsigned int)(bbt_alp)>>24);
						}else{
							if(((unsigned int)(bbt_alp)&16711680)!=0){
								bbt_alp=((unsigned int)(bbt_alp)>>16);
							}else{
								if(((unsigned int)(bbt_alp)&65280)!=0){
									bbt_alp=((unsigned int)(bbt_alp)>>8);
								}
							}
						}
						bbt_alp=((BBINT)(((BBFLOAT)bbt_alp)*(((BBFLOAT)bbt_alp)/255.0f)));
						brl_pixmap_WritePixel(bbt_map,bbt_ix,bbt_iy,((unsigned int)(((unsigned int)(bbt_rgba)&16777215))|(bbt_alp<<24)));
					}
				}
			}
		}
	}
	struct openb3d_openb3dex_TTexture_obj* volatile bbt_tex=openb3d_openb3dex_TTexture_CreateTexture_TTTexture_iiii(brl_pixmap_PixmapWidth(bbt_map),brl_pixmap_PixmapHeight(bbt_map),bbt_flags,1);
	(bbt_tex)->clas->m_BufferToTex_pbi(bbt_tex,brl_pixmap_PixmapPixelPtr(bbt_map,0,0),0);
	return bbt_tex;
}
BBINT _openb3d_openb3dex_TTexture_TextureFlags_i(struct openb3d_openb3dex_TTexture_obj* o,BBINT bbt_flags){
	TextureFlags(o->clas->f_GetInstance_pb_TTTexture(o),bbt_flags);
	return 0;
}
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TTexture_tex_list;
BBINT openb3d_openb3dex_TTexture_tex_list_id;
struct brl_map_TMap_obj* openb3d_openb3dex_TTexture_tex_map;
struct BBDebugScope_65 openb3d_openb3dex_TTexture_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TTexture",
	{
		{
			BBDEBUGDECL_FIELD,
			"texture",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_texture)
		},
		{
			BBDEBUGDECL_FIELD,
			"file",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_file)
		},
		{
			BBDEBUGDECL_FIELD,
			"frames",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_frames)
		},
		{
			BBDEBUGDECL_FIELD,
			"flags",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_flags)
		},
		{
			BBDEBUGDECL_FIELD,
			"blend",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_blend)
		},
		{
			BBDEBUGDECL_FIELD,
			"coords",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_coords)
		},
		{
			BBDEBUGDECL_FIELD,
			"u_scale",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_u_scale)
		},
		{
			BBDEBUGDECL_FIELD,
			"v_scale",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_v_scale)
		},
		{
			BBDEBUGDECL_FIELD,
			"u_pos",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_u_pos)
		},
		{
			BBDEBUGDECL_FIELD,
			"v_pos",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_v_pos)
		},
		{
			BBDEBUGDECL_FIELD,
			"angle",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_angle)
		},
		{
			BBDEBUGDECL_FIELD,
			"file_abs",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_file_abs)
		},
		{
			BBDEBUGDECL_FIELD,
			"width",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_width)
		},
		{
			BBDEBUGDECL_FIELD,
			"height",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_height)
		},
		{
			BBDEBUGDECL_FIELD,
			"no_frames",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_no_frames)
		},
		{
			BBDEBUGDECL_FIELD,
			"framebuffer",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_framebuffer)
		},
		{
			BBDEBUGDECL_FIELD,
			"cube_face",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_cube_face)
		},
		{
			BBDEBUGDECL_FIELD,
			"cube_mode",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_cube_mode)
		},
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_instance)
		},
		{
			BBDEBUGDECL_FIELD,
			"exists",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_exists)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"tex_list",
			":TList",
			&openb3d_openb3dex_TTexture_tex_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"tex_map",
			":TMap",
			&openb3d_openb3dex_TTexture_tex_map
		},
		{
			BBDEBUGDECL_GLOBAL,
			"tex_list_id",
			"i",
			&openb3d_openb3dex_TTexture_tex_list_id
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TTexture_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TTexture",
			&openb3d_openb3dex_TTexture_CreateObject_TTTexture_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TTexture_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TTexture",
			&openb3d_openb3dex_TTexture_GetObject_TTTexture_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TTexture)*b",
			&openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TTexture_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AddList_",
			"(:TList)i",
			&openb3d_openb3dex_TTexture_AddList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList_",
			"(:TList)i",
			&openb3d_openb3dex_TTexture_CopyList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"BufferToTex",
			"(*b,i)i",
			&_openb3d_openb3dex_TTexture_BufferToTex_pbi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TexToBuffer",
			"(*b,i)i",
			&_openb3d_openb3dex_TTexture_TexToBuffer_pbi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraToTex",
			"(:TCamera,i)i",
			&_openb3d_openb3dex_TTexture_CameraToTex_TTCamerai
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"DepthBufferToTex",
			"(:TCamera)i",
			&_openb3d_openb3dex_TTexture_DepthBufferToTex_TTCamera
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeTexture",
			"()i",
			&_openb3d_openb3dex_TTexture_FreeTexture
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateTexture",
			"(i,i,i,i):TTexture",
			&openb3d_openb3dex_TTexture_CreateTexture_TTTexture_iiii
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadTexture",
			"($,i):TTexture",
			&openb3d_openb3dex_TTexture_LoadTexture_TTTexture_Si
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadAnimTexture",
			"($,i,i,i,i,i):TTexture",
			&openb3d_openb3dex_TTexture_LoadAnimTexture_TTTexture_Siiiii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TextureBlend",
			"(i)i",
			&_openb3d_openb3dex_TTexture_TextureBlend_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TextureCoords",
			"(i)i",
			&_openb3d_openb3dex_TTexture_TextureCoords_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ScaleTexture",
			"(f,f)i",
			&_openb3d_openb3dex_TTexture_ScaleTexture_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"PositionTexture",
			"(f,f)i",
			&_openb3d_openb3dex_TTexture_PositionTexture_ff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RotateTexture",
			"(f)i",
			&_openb3d_openb3dex_TTexture_RotateTexture_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TextureWidth",
			"()i",
			&_openb3d_openb3dex_TTexture_TextureWidth
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TextureHeight",
			"()i",
			&_openb3d_openb3dex_TTexture_TextureHeight
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TextureName",
			"()$",
			&_openb3d_openb3dex_TTexture_TextureName
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetBrushTexture",
			"(:TBrush,i):TTexture",
			&openb3d_openb3dex_TTexture_GetBrushTexture_TTTexture_TTBrushi
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ClearTextureFilters",
			"()i",
			&openb3d_openb3dex_TTexture_ClearTextureFilters_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"TextureFilter",
			"($,i)i",
			&openb3d_openb3dex_TTexture_TextureFilter_i_Si
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetCubeFace",
			"(i)i",
			&_openb3d_openb3dex_TTexture_SetCubeFace_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetCubeMode",
			"(i)i",
			&_openb3d_openb3dex_TTexture_SetCubeMode_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"BackBufferToTex",
			"(i)i",
			&_openb3d_openb3dex_TTexture_BackBufferToTex_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Copy",
			"():TTexture",
			&_openb3d_openb3dex_TTexture_Copy
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TexInList",
			"():TTexture",
			&_openb3d_openb3dex_TTexture_TexInList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FilterFlags",
			"()i",
			&_openb3d_openb3dex_TTexture_FilterFlags
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FileFind",
			"($)i",
			&openb3d_openb3dex_TTexture_FileFind_i_vS
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FileAbs",
			"($)$",
			&openb3d_openb3dex_TTexture_FileAbs_S_S
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AdjustPixmap",
			"(:TPixmap):TPixmap",
			&openb3d_openb3dex_TTexture_AdjustPixmap_TTPixmap_TTPixmap
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Pow2Size",
			"(i)i",
			&openb3d_openb3dex_TTexture_Pow2Size_i_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ApplyAlpha",
			"(:TPixmap):TPixmap",
			&openb3d_openb3dex_TTexture_ApplyAlpha_TTPixmap_TTPixmap
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CameraToTexEXT",
			"(:TCamera,i)i",
			&_openb3d_openb3dex_TTexture_CameraToTexEXT_TTCamerai
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"DepthBufferToTexEXT",
			"(:TCamera,i)i",
			&_openb3d_openb3dex_TTexture_DepthBufferToTexEXT_TTCamerai
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadTextureAlpha",
			"($,i,i):TTexture",
			&openb3d_openb3dex_TTexture_LoadTextureAlpha_TTTexture_Sii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TextureFlags",
			"(i)i",
			&_openb3d_openb3dex_TTexture_TextureFlags_i
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TTexture openb3d_openb3dex_TTexture={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TTexture_scope,
	sizeof(struct openb3d_openb3dex_TTexture_obj),
	_openb3d_openb3dex_TTexture_New,
	_openb3d_openb3dex_TTexture_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TTexture_obj,_openb3d_openb3dex_ttexture_exists) - sizeof(void*) + sizeof(BBINT)
	,openb3d_openb3dex_TTexture_CreateObject_TTTexture_pb
	,openb3d_openb3dex_TTexture_FreeObject_i_pb
	,openb3d_openb3dex_TTexture_GetObject_TTTexture_pb
	,openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture
	,_openb3d_openb3dex_TTexture_InitFields
	,openb3d_openb3dex_TTexture_AddList__i_TTList
	,openb3d_openb3dex_TTexture_CopyList__i_TTList
	,_openb3d_openb3dex_TTexture_BufferToTex_pbi
	,_openb3d_openb3dex_TTexture_TexToBuffer_pbi
	,_openb3d_openb3dex_TTexture_CameraToTex_TTCamerai
	,_openb3d_openb3dex_TTexture_DepthBufferToTex_TTCamera
	,_openb3d_openb3dex_TTexture_FreeTexture
	,openb3d_openb3dex_TTexture_CreateTexture_TTTexture_iiii
	,openb3d_openb3dex_TTexture_LoadTexture_TTTexture_Si
	,openb3d_openb3dex_TTexture_LoadAnimTexture_TTTexture_Siiiii
	,_openb3d_openb3dex_TTexture_TextureBlend_i
	,_openb3d_openb3dex_TTexture_TextureCoords_i
	,_openb3d_openb3dex_TTexture_ScaleTexture_ff
	,_openb3d_openb3dex_TTexture_PositionTexture_ff
	,_openb3d_openb3dex_TTexture_RotateTexture_f
	,_openb3d_openb3dex_TTexture_TextureWidth
	,_openb3d_openb3dex_TTexture_TextureHeight
	,_openb3d_openb3dex_TTexture_TextureName
	,openb3d_openb3dex_TTexture_GetBrushTexture_TTTexture_TTBrushi
	,openb3d_openb3dex_TTexture_ClearTextureFilters_i
	,openb3d_openb3dex_TTexture_TextureFilter_i_Si
	,_openb3d_openb3dex_TTexture_SetCubeFace_i
	,_openb3d_openb3dex_TTexture_SetCubeMode_i
	,_openb3d_openb3dex_TTexture_BackBufferToTex_i
	,_openb3d_openb3dex_TTexture_Copy
	,_openb3d_openb3dex_TTexture_TexInList
	,_openb3d_openb3dex_TTexture_FilterFlags
	,openb3d_openb3dex_TTexture_FileFind_i_vS
	,openb3d_openb3dex_TTexture_FileAbs_S_S
	,openb3d_openb3dex_TTexture_AdjustPixmap_TTPixmap_TTPixmap
	,openb3d_openb3dex_TTexture_Pow2Size_i_i
	,openb3d_openb3dex_TTexture_ApplyAlpha_TTPixmap_TTPixmap
	,_openb3d_openb3dex_TTexture_CameraToTexEXT_TTCamerai
	,_openb3d_openb3dex_TTexture_DepthBufferToTexEXT_TTCamerai
	,openb3d_openb3dex_TTexture_LoadTextureAlpha_TTTexture_Sii
	,_openb3d_openb3dex_TTexture_TextureFlags_i
};

void _openb3d_openb3dex_TTextureFilter_New(struct openb3d_openb3dex_TTextureFilter_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TTextureFilter;
	o->_openb3d_openb3dex_ttexturefilter_text = &bbEmptyString;
	o->_openb3d_openb3dex_ttexturefilter_flags = 0;
}
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TTextureFilter_filter_list;
struct BBDebugScope_4 openb3d_openb3dex_TTextureFilter_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TTextureFilter",
	{
		{
			BBDEBUGDECL_FIELD,
			"Text",
			"$",
			.field_offset=offsetof(struct openb3d_openb3dex_TTextureFilter_obj,_openb3d_openb3dex_ttexturefilter_text)
		},
		{
			BBDEBUGDECL_FIELD,
			"flags",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TTextureFilter_obj,_openb3d_openb3dex_ttexturefilter_flags)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"filter_list",
			":TList",
			&openb3d_openb3dex_TTextureFilter_filter_list
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TTextureFilter_New
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TTextureFilter openb3d_openb3dex_TTextureFilter={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TTextureFilter_scope,
	sizeof(struct openb3d_openb3dex_TTextureFilter_obj),
	_openb3d_openb3dex_TTextureFilter_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TTextureFilter_obj,_openb3d_openb3dex_ttexturefilter_flags) - sizeof(void*) + sizeof(BBINT)
};

void _openb3d_openb3dex_TBrush_New(struct openb3d_openb3dex_TBrush_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TBrush;
	o->_openb3d_openb3dex_tbrush_no_texs = 0;
	o->_openb3d_openb3dex_tbrush_name = 0;
	o->_openb3d_openb3dex_tbrush_red = 0;
	o->_openb3d_openb3dex_tbrush_green = 0;
	o->_openb3d_openb3dex_tbrush_blue = 0;
	o->_openb3d_openb3dex_tbrush_alpha = 0;
	o->_openb3d_openb3dex_tbrush_shine = 0;
	o->_openb3d_openb3dex_tbrush_blend = 0;
	o->_openb3d_openb3dex_tbrush_fx = 0;
	o->_openb3d_openb3dex_tbrush_cache_frame = 0;
	o->_openb3d_openb3dex_tbrush_tex = bbArrayNew1D(":TTexture", 8);
	o->_openb3d_openb3dex_tbrush_instance = 0;
	o->_openb3d_openb3dex_tbrush_exists = 0;
}
void _openb3d_openb3dex_TBrush_Delete(struct openb3d_openb3dex_TBrush_obj* o) {
	bbObjectDtor(o);
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TBrush_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TBrush);
	(openb3d_openb3dex_TBrush_brush_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TBrush_brush_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tbrush_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TBrush_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TBrush_brush_map)->clas->m_Remove_TObject(openb3d_openb3dex_TBrush_brush_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_TBrush_GetObject_TTBrush_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TBrush_obj*)bbObjectDowncast((openb3d_openb3dex_TBrush_brush_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TBrush_brush_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TBrush));
}
BBBYTE* openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(struct openb3d_openb3dex_TBrush_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tbrush_instance ;
}
BBINT _openb3d_openb3dex_TBrush_InitFields(struct openb3d_openb3dex_TBrush_obj* o){
	o->_openb3d_openb3dex_tbrush_no_texs =BrushInt(o->clas->f_GetInstance_pb_TTBrush(o),1);
	o->_openb3d_openb3dex_tbrush_blend =BrushInt(o->clas->f_GetInstance_pb_TTBrush(o),8);
	o->_openb3d_openb3dex_tbrush_fx =BrushInt(o->clas->f_GetInstance_pb_TTBrush(o),9);
	o->_openb3d_openb3dex_tbrush_cache_frame =BrushUInt(o->clas->f_GetInstance_pb_TTBrush(o),10);
	o->_openb3d_openb3dex_tbrush_red =BrushFloat(o->clas->f_GetInstance_pb_TTBrush(o),3);
	o->_openb3d_openb3dex_tbrush_green =BrushFloat(o->clas->f_GetInstance_pb_TTBrush(o),4);
	o->_openb3d_openb3dex_tbrush_blue =BrushFloat(o->clas->f_GetInstance_pb_TTBrush(o),5);
	o->_openb3d_openb3dex_tbrush_alpha =BrushFloat(o->clas->f_GetInstance_pb_TTBrush(o),6);
	o->_openb3d_openb3dex_tbrush_shine =BrushFloat(o->clas->f_GetInstance_pb_TTBrush(o),7);
	o->_openb3d_openb3dex_tbrush_name =BrushString(o->clas->f_GetInstance_pb_TTBrush(o),2);
	{
		BBINT bbt_id=0;
		for(bbt_id;(bbt_id<=7);bbt_id=(bbt_id+1)){
			BBBYTE* bbt_inst=BrushTextureArray(o->clas->f_GetInstance_pb_TTBrush(o),11,bbt_id);
			((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((o->_openb3d_openb3dex_tbrush_tex ),(o->_openb3d_openb3dex_tbrush_tex )->dims))[((BBUINT)bbt_id)]=openb3d_openb3dex_TTexture_GetObject_TTTexture_pb(bbt_inst);
			if((((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((o->_openb3d_openb3dex_tbrush_tex ),(o->_openb3d_openb3dex_tbrush_tex )->dims))[((BBUINT)bbt_id)]==&bbNullObject) && (bbt_inst!=0)){
				((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((o->_openb3d_openb3dex_tbrush_tex ),(o->_openb3d_openb3dex_tbrush_tex )->dims))[((BBUINT)bbt_id)]=openb3d_openb3dex_TTexture_CreateObject_TTTexture_pb(bbt_inst);
			}
		}
	}
	o->_openb3d_openb3dex_tbrush_exists =1;
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* _openb3d_openb3dex_TBrush_GetBrushTexture_i(struct openb3d_openb3dex_TBrush_obj* o,BBINT bbt_index){
	BBBYTE* bbt_inst=GetBrushTexture(o->clas->f_GetInstance_pb_TTBrush(o),bbt_index);
	return openb3d_openb3dex_TTexture_GetObject_TTTexture_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TBrush_FreeBrush(struct openb3d_openb3dex_TBrush_obj* o){
	if(o->_openb3d_openb3dex_tbrush_exists !=0){
		{
			BBINT bbt_id=0;
			for(bbt_id;(bbt_id<=7);bbt_id=(bbt_id+1)){
				openb3d_openb3dex_TTexture_FreeObject_i_pb(openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((o->_openb3d_openb3dex_tbrush_tex ),(o->_openb3d_openb3dex_tbrush_tex )->dims))[((BBUINT)bbt_id)]));
				((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((o->_openb3d_openb3dex_tbrush_tex ),(o->_openb3d_openb3dex_tbrush_tex )->dims))[((BBUINT)bbt_id)]=&bbNullObject;
			}
		}
		FreeBrush(o->clas->f_GetInstance_pb_TTBrush(o));
		o->clas->f_FreeObject_i_pb(o->clas->f_GetInstance_pb_TTBrush(o));
		o->_openb3d_openb3dex_tbrush_exists =0;
	}
	return 0;
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_TBrush_CreateBrush_TTBrush_fff(BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	BBBYTE* bbt_inst=CreateBrush(bbt_r,bbt_g,bbt_b);
	return openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(bbt_inst);
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_TBrush_LoadBrush_TTBrush_Siff(BBSTRING bbt_file,BBINT bbt_flags,BBFLOAT bbt_u_scale,BBFLOAT bbt_v_scale){
	BBBYTE* bbt_cString=bbStringToCString(bbt_file);
	BBBYTE* bbt_inst=LoadBrush(bbt_cString,bbt_flags,bbt_u_scale,bbt_v_scale);
	struct openb3d_openb3dex_TBrush_obj* volatile bbt_brush=openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	return bbt_brush;
}
BBINT _openb3d_openb3dex_TBrush_BrushColor_fff(struct openb3d_openb3dex_TBrush_obj* o,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	BrushColor(o->clas->f_GetInstance_pb_TTBrush(o),bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT _openb3d_openb3dex_TBrush_BrushAlpha_f(struct openb3d_openb3dex_TBrush_obj* o,BBFLOAT bbt_a){
	BrushAlpha(o->clas->f_GetInstance_pb_TTBrush(o),bbt_a);
	return 0;
}
BBINT _openb3d_openb3dex_TBrush_BrushShininess_f(struct openb3d_openb3dex_TBrush_obj* o,BBFLOAT bbt_s){
	BrushShininess(o->clas->f_GetInstance_pb_TTBrush(o),bbt_s);
	return 0;
}
BBINT _openb3d_openb3dex_TBrush_BrushTexture_TTTextureii(struct openb3d_openb3dex_TBrush_obj* o,struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_frame,BBINT bbt_index){
	BrushTexture(o->clas->f_GetInstance_pb_TTBrush(o),openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex),bbt_frame,bbt_index);
	((struct openb3d_openb3dex_TBrush_obj*)o)->clas->m_InitFields(o);
	return 0;
}
BBINT _openb3d_openb3dex_TBrush_BrushBlend_i(struct openb3d_openb3dex_TBrush_obj* o,BBINT bbt_blend){
	BrushBlend(o->clas->f_GetInstance_pb_TTBrush(o),bbt_blend);
	return 0;
}
BBINT _openb3d_openb3dex_TBrush_BrushFX_i(struct openb3d_openb3dex_TBrush_obj* o,BBINT bbt_fx){
	BrushFX(o->clas->f_GetInstance_pb_TTBrush(o),bbt_fx);
	return 0;
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_TBrush_GetEntityBrush_TTBrush_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	BBBYTE* bbt_inst=GetEntityBrush(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent));
	struct openb3d_openb3dex_TBrush_obj* volatile bbt_brush=openb3d_openb3dex_TBrush_GetObject_TTBrush_pb(bbt_inst);
	if((bbt_brush==&bbNullObject) && (bbt_inst!=0)){
		bbt_brush=openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(bbt_inst);
	}
	return bbt_brush;
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_TBrush_GetSurfaceBrush_TTBrush_TTSurface(struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	BBBYTE* bbt_inst=GetSurfaceBrush(openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf));
	struct openb3d_openb3dex_TBrush_obj* volatile bbt_brush=openb3d_openb3dex_TBrush_GetObject_TTBrush_pb(bbt_inst);
	if((bbt_brush==&bbNullObject) && (bbt_inst!=0)){
		bbt_brush=openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb(bbt_inst);
	}
	return bbt_brush;
}
struct openb3d_openb3dex_TBrush_obj* _openb3d_openb3dex_TBrush_Copy(struct openb3d_openb3dex_TBrush_obj* o){
	BBBYTE* bbt_inst=BrushCopy(o->clas->f_GetInstance_pb_TTBrush(o));
	return o->clas->f_CreateObject_TTBrush_pb(bbt_inst);
}
BBINT openb3d_openb3dex_TBrush_CompareBrushes_i_TTBrushTTBrush(struct openb3d_openb3dex_TBrush_obj* bbt_brush1,struct openb3d_openb3dex_TBrush_obj* bbt_brush2){
	return CompareBrushes(openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_brush1),openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_brush2));
}
struct brl_map_TMap_obj* openb3d_openb3dex_TBrush_brush_map;
struct BBDebugScope_34 openb3d_openb3dex_TBrush_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TBrush",
	{
		{
			BBDEBUGDECL_FIELD,
			"no_texs",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_no_texs)
		},
		{
			BBDEBUGDECL_FIELD,
			"name",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_name)
		},
		{
			BBDEBUGDECL_FIELD,
			"red",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_red)
		},
		{
			BBDEBUGDECL_FIELD,
			"green",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_green)
		},
		{
			BBDEBUGDECL_FIELD,
			"blue",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_blue)
		},
		{
			BBDEBUGDECL_FIELD,
			"alpha",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_alpha)
		},
		{
			BBDEBUGDECL_FIELD,
			"shine",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_shine)
		},
		{
			BBDEBUGDECL_FIELD,
			"blend",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_blend)
		},
		{
			BBDEBUGDECL_FIELD,
			"fx",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_fx)
		},
		{
			BBDEBUGDECL_FIELD,
			"cache_frame",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_cache_frame)
		},
		{
			BBDEBUGDECL_FIELD,
			"tex",
			"[]:TTexture",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_tex)
		},
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_instance)
		},
		{
			BBDEBUGDECL_FIELD,
			"exists",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_exists)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"brush_map",
			":TMap",
			&openb3d_openb3dex_TBrush_brush_map
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TBrush_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TBrush",
			&openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TBrush_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TBrush",
			&openb3d_openb3dex_TBrush_GetObject_TTBrush_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TBrush)*b",
			&openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TBrush_InitFields
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetBrushTexture",
			"(i):TTexture",
			&_openb3d_openb3dex_TBrush_GetBrushTexture_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeBrush",
			"()i",
			&_openb3d_openb3dex_TBrush_FreeBrush
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateBrush",
			"(f,f,f):TBrush",
			&openb3d_openb3dex_TBrush_CreateBrush_TTBrush_fff
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadBrush",
			"($,i,f,f):TBrush",
			&openb3d_openb3dex_TBrush_LoadBrush_TTBrush_Siff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"BrushColor",
			"(f,f,f)i",
			&_openb3d_openb3dex_TBrush_BrushColor_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"BrushAlpha",
			"(f)i",
			&_openb3d_openb3dex_TBrush_BrushAlpha_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"BrushShininess",
			"(f)i",
			&_openb3d_openb3dex_TBrush_BrushShininess_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"BrushTexture",
			"(:TTexture,i,i)i",
			&_openb3d_openb3dex_TBrush_BrushTexture_TTTextureii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"BrushBlend",
			"(i)i",
			&_openb3d_openb3dex_TBrush_BrushBlend_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"BrushFX",
			"(i)i",
			&_openb3d_openb3dex_TBrush_BrushFX_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetEntityBrush",
			"(:TEntity):TBrush",
			&openb3d_openb3dex_TBrush_GetEntityBrush_TTBrush_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetSurfaceBrush",
			"(:TSurface):TBrush",
			&openb3d_openb3dex_TBrush_GetSurfaceBrush_TTBrush_TTSurface
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Copy",
			"():TBrush",
			&_openb3d_openb3dex_TBrush_Copy
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CompareBrushes",
			"(:TBrush,:TBrush)i",
			&openb3d_openb3dex_TBrush_CompareBrushes_i_TTBrushTTBrush
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TBrush openb3d_openb3dex_TBrush={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TBrush_scope,
	sizeof(struct openb3d_openb3dex_TBrush_obj),
	_openb3d_openb3dex_TBrush_New,
	_openb3d_openb3dex_TBrush_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TBrush_obj,_openb3d_openb3dex_tbrush_exists) - sizeof(void*) + sizeof(BBINT)
	,openb3d_openb3dex_TBrush_CreateObject_TTBrush_pb
	,openb3d_openb3dex_TBrush_FreeObject_i_pb
	,openb3d_openb3dex_TBrush_GetObject_TTBrush_pb
	,openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush
	,_openb3d_openb3dex_TBrush_InitFields
	,_openb3d_openb3dex_TBrush_GetBrushTexture_i
	,_openb3d_openb3dex_TBrush_FreeBrush
	,openb3d_openb3dex_TBrush_CreateBrush_TTBrush_fff
	,openb3d_openb3dex_TBrush_LoadBrush_TTBrush_Siff
	,_openb3d_openb3dex_TBrush_BrushColor_fff
	,_openb3d_openb3dex_TBrush_BrushAlpha_f
	,_openb3d_openb3dex_TBrush_BrushShininess_f
	,_openb3d_openb3dex_TBrush_BrushTexture_TTTextureii
	,_openb3d_openb3dex_TBrush_BrushBlend_i
	,_openb3d_openb3dex_TBrush_BrushFX_i
	,openb3d_openb3dex_TBrush_GetEntityBrush_TTBrush_TTEntity
	,openb3d_openb3dex_TBrush_GetSurfaceBrush_TTBrush_TTSurface
	,_openb3d_openb3dex_TBrush_Copy
	,openb3d_openb3dex_TBrush_CompareBrushes_i_TTBrushTTBrush
};

void _openb3d_openb3dex_TAnimation_New(struct openb3d_openb3dex_TAnimation_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TAnimation;
}
BBINT openb3d_openb3dex_TAnimation_AnimateMesh3_i_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent1){
	AnimateMesh3(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent1));
	return 0;
}
BBINT openb3d_openb3dex_TAnimation_AnimateMesh_i_TTEntityfii(struct openb3d_openb3dex_TEntity_obj* bbt_ent1,BBFLOAT bbt_framef,BBINT bbt_start_frame,BBINT bbt_end_frame){
	AnimateMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent1),bbt_framef,bbt_start_frame,bbt_end_frame);
	return 0;
}
BBINT openb3d_openb3dex_TAnimation_AnimateMesh2_i_TTEntityfii(struct openb3d_openb3dex_TEntity_obj* bbt_ent1,BBFLOAT bbt_framef,BBINT bbt_start_frame,BBINT bbt_end_frame){
	AnimateMesh2(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent1),bbt_framef,bbt_start_frame,bbt_end_frame);
	return 0;
}
BBINT openb3d_openb3dex_TAnimation_VertexDeform_i_TTMesh(struct openb3d_openb3dex_TMesh_obj* bbt_ent){
	VertexDeform(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TEntity)));
	return 0;
}
struct BBDebugScope_5 openb3d_openb3dex_TAnimation_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TAnimation",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TAnimation_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AnimateMesh3",
			"(:TEntity)i",
			&openb3d_openb3dex_TAnimation_AnimateMesh3_i_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AnimateMesh",
			"(:TEntity,f,i,i)i",
			&openb3d_openb3dex_TAnimation_AnimateMesh_i_TTEntityfii
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AnimateMesh2",
			"(:TEntity,f,i,i)i",
			&openb3d_openb3dex_TAnimation_AnimateMesh2_i_TTEntityfii
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"VertexDeform",
			"(:TMesh)i",
			&openb3d_openb3dex_TAnimation_VertexDeform_i_TTMesh
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TAnimation openb3d_openb3dex_TAnimation={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TAnimation_scope,
	sizeof(struct openb3d_openb3dex_TAnimation_obj),
	_openb3d_openb3dex_TAnimation_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,openb3d_openb3dex_TAnimation_AnimateMesh3_i_TTEntity
	,openb3d_openb3dex_TAnimation_AnimateMesh_i_TTEntityfii
	,openb3d_openb3dex_TAnimation_AnimateMesh2_i_TTEntityfii
	,openb3d_openb3dex_TAnimation_VertexDeform_i_TTMesh
};

void _openb3d_openb3dex_TAnimationKeys_New(struct openb3d_openb3dex_TAnimationKeys_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TAnimationKeys;
	o->_openb3d_openb3dex_tanimationkeys_frames = 0;
	o->_openb3d_openb3dex_tanimationkeys_flags = 0;
	o->_openb3d_openb3dex_tanimationkeys_px = 0;
	o->_openb3d_openb3dex_tanimationkeys_py = 0;
	o->_openb3d_openb3dex_tanimationkeys_pz = 0;
	o->_openb3d_openb3dex_tanimationkeys_sx = 0;
	o->_openb3d_openb3dex_tanimationkeys_sy = 0;
	o->_openb3d_openb3dex_tanimationkeys_sz = 0;
	o->_openb3d_openb3dex_tanimationkeys_qw = 0;
	o->_openb3d_openb3dex_tanimationkeys_qx = 0;
	o->_openb3d_openb3dex_tanimationkeys_qy = 0;
	o->_openb3d_openb3dex_tanimationkeys_qz = 0;
	o->_openb3d_openb3dex_tanimationkeys_instance = 0;
}
void _openb3d_openb3dex_TAnimationKeys_Delete(struct openb3d_openb3dex_TAnimationKeys_obj* o) {
	bbObjectDtor(o);
}
struct openb3d_openb3dex_TAnimationKeys_obj* openb3d_openb3dex_TAnimationKeys_CreateObject_TTAnimationKeys_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TAnimationKeys_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TAnimationKeys);
	(openb3d_openb3dex_TAnimationKeys_animkeys_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TAnimationKeys_animkeys_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tanimationkeys_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TAnimationKeys_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TAnimationKeys_animkeys_map)->clas->m_Remove_TObject(openb3d_openb3dex_TAnimationKeys_animkeys_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TAnimationKeys_obj* openb3d_openb3dex_TAnimationKeys_GetObject_TTAnimationKeys_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TAnimationKeys_obj*)bbObjectDowncast((openb3d_openb3dex_TAnimationKeys_animkeys_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TAnimationKeys_animkeys_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TAnimationKeys));
}
BBBYTE* openb3d_openb3dex_TAnimationKeys_GetInstance_pb_TTAnimationKeys(struct openb3d_openb3dex_TAnimationKeys_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tanimationkeys_instance ;
}
BBINT _openb3d_openb3dex_TAnimationKeys_InitFields(struct openb3d_openb3dex_TAnimationKeys_obj* o){
	o->_openb3d_openb3dex_tanimationkeys_frames =AnimationKeysInt(o->clas->f_GetInstance_pb_TTAnimationKeys(o),1);
	o->_openb3d_openb3dex_tanimationkeys_flags =AnimationKeysInt(o->clas->f_GetInstance_pb_TTAnimationKeys(o),2);
	o->_openb3d_openb3dex_tanimationkeys_px =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),3);
	o->_openb3d_openb3dex_tanimationkeys_py =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),4);
	o->_openb3d_openb3dex_tanimationkeys_pz =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),5);
	o->_openb3d_openb3dex_tanimationkeys_sx =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),6);
	o->_openb3d_openb3dex_tanimationkeys_sy =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),7);
	o->_openb3d_openb3dex_tanimationkeys_sz =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),8);
	o->_openb3d_openb3dex_tanimationkeys_qw =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),9);
	o->_openb3d_openb3dex_tanimationkeys_qx =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),10);
	o->_openb3d_openb3dex_tanimationkeys_qy =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),11);
	o->_openb3d_openb3dex_tanimationkeys_qz =AnimationKeysFloat(o->clas->f_GetInstance_pb_TTAnimationKeys(o),12);
	return 0;
}
struct openb3d_openb3dex_TAnimationKeys_obj* _openb3d_openb3dex_TAnimationKeys_Copy(struct openb3d_openb3dex_TAnimationKeys_obj* o){
	BBBYTE* bbt_inst=AnimationKeysCopy(o->clas->f_GetInstance_pb_TTAnimationKeys(o));
	return o->clas->f_CreateObject_TTAnimationKeys_pb(bbt_inst);
}
struct brl_map_TMap_obj* openb3d_openb3dex_TAnimationKeys_animkeys_map;
struct BBDebugScope_21 openb3d_openb3dex_TAnimationKeys_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TAnimationKeys",
	{
		{
			BBDEBUGDECL_FIELD,
			"frames",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_frames)
		},
		{
			BBDEBUGDECL_FIELD,
			"flags",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_flags)
		},
		{
			BBDEBUGDECL_FIELD,
			"px",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_px)
		},
		{
			BBDEBUGDECL_FIELD,
			"py",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_py)
		},
		{
			BBDEBUGDECL_FIELD,
			"pz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_pz)
		},
		{
			BBDEBUGDECL_FIELD,
			"sx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_sx)
		},
		{
			BBDEBUGDECL_FIELD,
			"sy",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_sy)
		},
		{
			BBDEBUGDECL_FIELD,
			"sz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_sz)
		},
		{
			BBDEBUGDECL_FIELD,
			"qw",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_qw)
		},
		{
			BBDEBUGDECL_FIELD,
			"qx",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_qx)
		},
		{
			BBDEBUGDECL_FIELD,
			"qy",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_qy)
		},
		{
			BBDEBUGDECL_FIELD,
			"qz",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_qz)
		},
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_instance)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"animkeys_map",
			":TMap",
			&openb3d_openb3dex_TAnimationKeys_animkeys_map
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TAnimationKeys_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TAnimationKeys",
			&openb3d_openb3dex_TAnimationKeys_CreateObject_TTAnimationKeys_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TAnimationKeys_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TAnimationKeys",
			&openb3d_openb3dex_TAnimationKeys_GetObject_TTAnimationKeys_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TAnimationKeys)*b",
			&openb3d_openb3dex_TAnimationKeys_GetInstance_pb_TTAnimationKeys
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TAnimationKeys_InitFields
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Copy",
			"():TAnimationKeys",
			&_openb3d_openb3dex_TAnimationKeys_Copy
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TAnimationKeys openb3d_openb3dex_TAnimationKeys={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TAnimationKeys_scope,
	sizeof(struct openb3d_openb3dex_TAnimationKeys_obj),
	_openb3d_openb3dex_TAnimationKeys_New,
	_openb3d_openb3dex_TAnimationKeys_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TAnimationKeys_obj,_openb3d_openb3dex_tanimationkeys_instance) - sizeof(void*) + sizeof(BBBYTE*)
	,openb3d_openb3dex_TAnimationKeys_CreateObject_TTAnimationKeys_pb
	,openb3d_openb3dex_TAnimationKeys_FreeObject_i_pb
	,openb3d_openb3dex_TAnimationKeys_GetObject_TTAnimationKeys_pb
	,openb3d_openb3dex_TAnimationKeys_GetInstance_pb_TTAnimationKeys
	,_openb3d_openb3dex_TAnimationKeys_InitFields
	,_openb3d_openb3dex_TAnimationKeys_Copy
};

void _openb3d_openb3dex_TPick_New(struct openb3d_openb3dex_TPick_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TPick;
}
BBINT openb3d_openb3dex_TPick_InitGlobals_i(){
	openb3d_openb3dex_TPick_picked_x=StaticFloat(35,2);
	openb3d_openb3dex_TPick_picked_y=StaticFloat(35,3);
	openb3d_openb3dex_TPick_picked_z=StaticFloat(35,4);
	openb3d_openb3dex_TPick_picked_nx=StaticFloat(35,5);
	openb3d_openb3dex_TPick_picked_ny=StaticFloat(35,6);
	openb3d_openb3dex_TPick_picked_nz=StaticFloat(35,7);
	openb3d_openb3dex_TPick_picked_time=StaticFloat(35,8);
	openb3d_openb3dex_TPick_picked_triangle=StaticInt(35,11);
	return 0;
}
BBINT openb3d_openb3dex_TPick_AddList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TPick_ent_list){
		if(StaticListSize(35,1)!=0){
			BBBYTE* bbt_inst=StaticIterListEntity(35,1,(&openb3d_openb3dex_TPick_ent_list_id));
			struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj=openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
			if((bbt_obj!= &bbNullObject) && (brl_linkedlist_ListContains(bbt_list,bbt_obj)==0)){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TPick_CopyList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	brl_linkedlist_ClearList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TPick_ent_list){
		openb3d_openb3dex_TPick_ent_list_id=0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(StaticListSize(35,1)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=StaticIterListEntity(35,1,(&openb3d_openb3dex_TPick_ent_list_id));
				struct openb3d_openb3dex_TEntity_obj* volatile bbt_obj=openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_TPick_CameraPick_TTEntity_TTCameraff(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBFLOAT bbt_x,BBFLOAT bbt_y){
	BBBYTE* bbt_inst=CameraPick(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_cam,&openb3d_openb3dex_TEntity)),bbt_x,(((BBFLOAT)brl_graphics_GraphicsHeight())-bbt_y));
	return openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_TPick_EntityPick_TTEntity_TTEntityf(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_Range){
	BBBYTE* bbt_inst=EntityPick(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_Range);
	return openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_TPick_LinePick_TTEntity_fffffff(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_dx,BBFLOAT bbt_dy,BBFLOAT bbt_dz,BBFLOAT bbt_radius){
	BBBYTE* bbt_inst=LinePick(bbt_x,bbt_y,bbt_z,bbt_dx,bbt_dy,bbt_dz,bbt_radius);
	return openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
}
BBINT openb3d_openb3dex_TPick_EntityVisible_i_TTEntityTTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	return EntityVisible(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_src_ent),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_dest_ent));
}
BBFLOAT openb3d_openb3dex_TPick_PickedX_f(){
	return PickedX();
}
BBFLOAT openb3d_openb3dex_TPick_PickedY_f(){
	return PickedY();
}
BBFLOAT openb3d_openb3dex_TPick_PickedZ_f(){
	return PickedZ();
}
BBFLOAT openb3d_openb3dex_TPick_PickedNX_f(){
	return PickedNX();
}
BBFLOAT openb3d_openb3dex_TPick_PickedNY_f(){
	return PickedNY();
}
BBFLOAT openb3d_openb3dex_TPick_PickedNZ_f(){
	return PickedNZ();
}
BBFLOAT openb3d_openb3dex_TPick_PickedTime_f(){
	return PickedTime();
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_TPick_PickedEntity_TTEntity(){
	BBBYTE* bbt_inst=PickedEntity();
	openb3d_openb3dex_TPick_picked_ent=openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(StaticEntity(35,9));
	return openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_TPick_PickedSurface_TTSurface(){
	BBBYTE* bbt_inst=PickedSurface();
	openb3d_openb3dex_TPick_picked_surface=openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(StaticSurface(35,10));
	return openb3d_openb3dex_TSurface_GetObject_TTSurface_pb(bbt_inst);
}
BBINT openb3d_openb3dex_TPick_PickedTriangle_i(){
	return PickedTriangle();
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_TPick_Pick_TTEntity_fffffff(BBFLOAT bbt_ax,BBFLOAT bbt_ay,BBFLOAT bbt_az,BBFLOAT bbt_bx,BBFLOAT bbt_by,BBFLOAT bbt_bz,BBFLOAT bbt_radius){
	BBBYTE* bbt_inst=PickMain(bbt_ax,bbt_ay,bbt_az,bbt_bx,bbt_by,bbt_bz,bbt_radius);
	return openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst);
}
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TPick_ent_list;
BBINT openb3d_openb3dex_TPick_ent_list_id;
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_TPick_picked_ent;
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_TPick_picked_surface;
BBFLOAT* openb3d_openb3dex_TPick_picked_x;
BBFLOAT* openb3d_openb3dex_TPick_picked_y;
BBFLOAT* openb3d_openb3dex_TPick_picked_z;
BBFLOAT* openb3d_openb3dex_TPick_picked_nx;
BBFLOAT* openb3d_openb3dex_TPick_picked_ny;
BBFLOAT* openb3d_openb3dex_TPick_picked_nz;
BBFLOAT* openb3d_openb3dex_TPick_picked_time;
BBINT* openb3d_openb3dex_TPick_picked_triangle;
struct BBDebugScope_32 openb3d_openb3dex_TPick_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TPick",
	{
		{
			BBDEBUGDECL_CONST,
			"EPSILON",
			"f",
			.const_value=&_s144
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ent_list",
			":TList",
			&openb3d_openb3dex_TPick_ent_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_x",
			"*f",
			&openb3d_openb3dex_TPick_picked_x
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_y",
			"*f",
			&openb3d_openb3dex_TPick_picked_y
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_z",
			"*f",
			&openb3d_openb3dex_TPick_picked_z
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_nx",
			"*f",
			&openb3d_openb3dex_TPick_picked_nx
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_ny",
			"*f",
			&openb3d_openb3dex_TPick_picked_ny
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_nz",
			"*f",
			&openb3d_openb3dex_TPick_picked_nz
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_time",
			"*f",
			&openb3d_openb3dex_TPick_picked_time
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_ent",
			":TEntity",
			&openb3d_openb3dex_TPick_picked_ent
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_surface",
			":TSurface",
			&openb3d_openb3dex_TPick_picked_surface
		},
		{
			BBDEBUGDECL_GLOBAL,
			"picked_triangle",
			"*i",
			&openb3d_openb3dex_TPick_picked_triangle
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ent_list_id",
			"i",
			&openb3d_openb3dex_TPick_ent_list_id
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TPick_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"InitGlobals",
			"()i",
			&openb3d_openb3dex_TPick_InitGlobals_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AddList_",
			"(:TList)i",
			&openb3d_openb3dex_TPick_AddList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList_",
			"(:TList)i",
			&openb3d_openb3dex_TPick_CopyList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CameraPick",
			"(:TCamera,f,f):TEntity",
			&openb3d_openb3dex_TPick_CameraPick_TTEntity_TTCameraff
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"EntityPick",
			"(:TEntity,f):TEntity",
			&openb3d_openb3dex_TPick_EntityPick_TTEntity_TTEntityf
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LinePick",
			"(f,f,f,f,f,f,f):TEntity",
			&openb3d_openb3dex_TPick_LinePick_TTEntity_fffffff
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"EntityVisible",
			"(:TEntity,:TEntity)i",
			&openb3d_openb3dex_TPick_EntityVisible_i_TTEntityTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedX",
			"()f",
			&openb3d_openb3dex_TPick_PickedX_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedY",
			"()f",
			&openb3d_openb3dex_TPick_PickedY_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedZ",
			"()f",
			&openb3d_openb3dex_TPick_PickedZ_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedNX",
			"()f",
			&openb3d_openb3dex_TPick_PickedNX_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedNY",
			"()f",
			&openb3d_openb3dex_TPick_PickedNY_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedNZ",
			"()f",
			&openb3d_openb3dex_TPick_PickedNZ_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedTime",
			"()f",
			&openb3d_openb3dex_TPick_PickedTime_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedEntity",
			"():TEntity",
			&openb3d_openb3dex_TPick_PickedEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedSurface",
			"():TSurface",
			&openb3d_openb3dex_TPick_PickedSurface_TTSurface
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"PickedTriangle",
			"()i",
			&openb3d_openb3dex_TPick_PickedTriangle_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Pick",
			"(f,f,f,f,f,f,f):TEntity",
			&openb3d_openb3dex_TPick_Pick_TTEntity_fffffff
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TPick openb3d_openb3dex_TPick={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TPick_scope,
	sizeof(struct openb3d_openb3dex_TPick_obj),
	_openb3d_openb3dex_TPick_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,openb3d_openb3dex_TPick_InitGlobals_i
	,openb3d_openb3dex_TPick_AddList__i_TTList
	,openb3d_openb3dex_TPick_CopyList__i_TTList
	,openb3d_openb3dex_TPick_CameraPick_TTEntity_TTCameraff
	,openb3d_openb3dex_TPick_EntityPick_TTEntity_TTEntityf
	,openb3d_openb3dex_TPick_LinePick_TTEntity_fffffff
	,openb3d_openb3dex_TPick_EntityVisible_i_TTEntityTTEntity
	,openb3d_openb3dex_TPick_PickedX_f
	,openb3d_openb3dex_TPick_PickedY_f
	,openb3d_openb3dex_TPick_PickedZ_f
	,openb3d_openb3dex_TPick_PickedNX_f
	,openb3d_openb3dex_TPick_PickedNY_f
	,openb3d_openb3dex_TPick_PickedNZ_f
	,openb3d_openb3dex_TPick_PickedTime_f
	,openb3d_openb3dex_TPick_PickedEntity_TTEntity
	,openb3d_openb3dex_TPick_PickedSurface_TTSurface
	,openb3d_openb3dex_TPick_PickedTriangle_i
	,openb3d_openb3dex_TPick_Pick_TTEntity_fffffff
};

void _openb3d_openb3dex_TVector_New(struct openb3d_openb3dex_TVector_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TVector;
	o->_openb3d_openb3dex_tvector_x = .0f;
	o->_openb3d_openb3dex_tvector_y = .0f;
	o->_openb3d_openb3dex_tvector_z = .0f;
}
void _openb3d_openb3dex_TVector_Delete(struct openb3d_openb3dex_TVector_obj* o) {
	bbObjectDtor(o);
}
struct openb3d_openb3dex_TVector_obj* openb3d_openb3dex_TVector_Create_TTVector_fff(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	struct openb3d_openb3dex_TVector_obj* volatile bbt_vec=bbObjectAtomicNew(&openb3d_openb3dex_TVector);
	bbt_vec->_openb3d_openb3dex_tvector_x =bbt_x;
	bbt_vec->_openb3d_openb3dex_tvector_y =bbt_y;
	bbt_vec->_openb3d_openb3dex_tvector_z =bbt_z;
	return bbt_vec;
}
struct openb3d_openb3dex_TVector_obj* _openb3d_openb3dex_TVector_Copy(struct openb3d_openb3dex_TVector_obj* o){
	struct openb3d_openb3dex_TVector_obj* volatile bbt_vec=bbObjectAtomicNew(&openb3d_openb3dex_TVector);
	bbt_vec->_openb3d_openb3dex_tvector_x =o->_openb3d_openb3dex_tvector_x ;
	bbt_vec->_openb3d_openb3dex_tvector_y =o->_openb3d_openb3dex_tvector_y ;
	bbt_vec->_openb3d_openb3dex_tvector_z =o->_openb3d_openb3dex_tvector_z ;
	return bbt_vec;
}
struct openb3d_openb3dex_TVector_obj* _openb3d_openb3dex_TVector_Add_TTVector(struct openb3d_openb3dex_TVector_obj* o,struct openb3d_openb3dex_TVector_obj* bbt_vec){
	struct openb3d_openb3dex_TVector_obj* volatile bbt_new_vec=bbObjectAtomicNew(&openb3d_openb3dex_TVector);
	bbt_new_vec->_openb3d_openb3dex_tvector_x =(o->_openb3d_openb3dex_tvector_x +bbt_vec->_openb3d_openb3dex_tvector_x );
	bbt_new_vec->_openb3d_openb3dex_tvector_y =(o->_openb3d_openb3dex_tvector_y +bbt_vec->_openb3d_openb3dex_tvector_y );
	bbt_new_vec->_openb3d_openb3dex_tvector_z =(o->_openb3d_openb3dex_tvector_z +bbt_vec->_openb3d_openb3dex_tvector_z );
	return bbt_new_vec;
}
struct openb3d_openb3dex_TVector_obj* _openb3d_openb3dex_TVector_Subtract_TTVector(struct openb3d_openb3dex_TVector_obj* o,struct openb3d_openb3dex_TVector_obj* bbt_vec){
	struct openb3d_openb3dex_TVector_obj* volatile bbt_new_vec=bbObjectAtomicNew(&openb3d_openb3dex_TVector);
	bbt_new_vec->_openb3d_openb3dex_tvector_x =(o->_openb3d_openb3dex_tvector_x -bbt_vec->_openb3d_openb3dex_tvector_x );
	bbt_new_vec->_openb3d_openb3dex_tvector_y =(o->_openb3d_openb3dex_tvector_y -bbt_vec->_openb3d_openb3dex_tvector_y );
	bbt_new_vec->_openb3d_openb3dex_tvector_z =(o->_openb3d_openb3dex_tvector_z -bbt_vec->_openb3d_openb3dex_tvector_z );
	return bbt_new_vec;
}
struct openb3d_openb3dex_TVector_obj* _openb3d_openb3dex_TVector_Multiply_f(struct openb3d_openb3dex_TVector_obj* o,BBFLOAT bbt_val){
	struct openb3d_openb3dex_TVector_obj* volatile bbt_new_vec=bbObjectAtomicNew(&openb3d_openb3dex_TVector);
	bbt_new_vec->_openb3d_openb3dex_tvector_x =(o->_openb3d_openb3dex_tvector_x *bbt_val);
	bbt_new_vec->_openb3d_openb3dex_tvector_y =(o->_openb3d_openb3dex_tvector_y *bbt_val);
	bbt_new_vec->_openb3d_openb3dex_tvector_z =(o->_openb3d_openb3dex_tvector_z *bbt_val);
	return bbt_new_vec;
}
struct openb3d_openb3dex_TVector_obj* _openb3d_openb3dex_TVector_Divide_f(struct openb3d_openb3dex_TVector_obj* o,BBFLOAT bbt_val){
	struct openb3d_openb3dex_TVector_obj* volatile bbt_new_vec=bbObjectAtomicNew(&openb3d_openb3dex_TVector);
	bbt_new_vec->_openb3d_openb3dex_tvector_x =(o->_openb3d_openb3dex_tvector_x /bbt_val);
	bbt_new_vec->_openb3d_openb3dex_tvector_y =(o->_openb3d_openb3dex_tvector_y /bbt_val);
	bbt_new_vec->_openb3d_openb3dex_tvector_z =(o->_openb3d_openb3dex_tvector_z /bbt_val);
	return bbt_new_vec;
}
BBFLOAT _openb3d_openb3dex_TVector_Dot_TTVector(struct openb3d_openb3dex_TVector_obj* o,struct openb3d_openb3dex_TVector_obj* bbt_vec){
	return (((o->_openb3d_openb3dex_tvector_x *bbt_vec->_openb3d_openb3dex_tvector_x )+(o->_openb3d_openb3dex_tvector_y *bbt_vec->_openb3d_openb3dex_tvector_y ))+(o->_openb3d_openb3dex_tvector_z *bbt_vec->_openb3d_openb3dex_tvector_z ));
}
struct openb3d_openb3dex_TVector_obj* _openb3d_openb3dex_TVector_Cross_TTVector(struct openb3d_openb3dex_TVector_obj* o,struct openb3d_openb3dex_TVector_obj* bbt_vec){
	struct openb3d_openb3dex_TVector_obj* volatile bbt_new_vec=bbObjectAtomicNew(&openb3d_openb3dex_TVector);
	bbt_new_vec->_openb3d_openb3dex_tvector_x =((o->_openb3d_openb3dex_tvector_y *bbt_vec->_openb3d_openb3dex_tvector_z )-(o->_openb3d_openb3dex_tvector_z *bbt_vec->_openb3d_openb3dex_tvector_y ));
	bbt_new_vec->_openb3d_openb3dex_tvector_y =((o->_openb3d_openb3dex_tvector_z *bbt_vec->_openb3d_openb3dex_tvector_x )-(o->_openb3d_openb3dex_tvector_x *bbt_vec->_openb3d_openb3dex_tvector_z ));
	bbt_new_vec->_openb3d_openb3dex_tvector_z =((o->_openb3d_openb3dex_tvector_x *bbt_vec->_openb3d_openb3dex_tvector_y )-(o->_openb3d_openb3dex_tvector_y *bbt_vec->_openb3d_openb3dex_tvector_x ));
	return bbt_new_vec;
}
BBINT _openb3d_openb3dex_TVector_Normalize(struct openb3d_openb3dex_TVector_obj* o){
	BBFLOAT bbt_d=((BBFLOAT)(1.0000000000000000/bbSqr((BBDOUBLE)(((o->_openb3d_openb3dex_tvector_x *o->_openb3d_openb3dex_tvector_x )+(o->_openb3d_openb3dex_tvector_y *o->_openb3d_openb3dex_tvector_y ))+(o->_openb3d_openb3dex_tvector_z *o->_openb3d_openb3dex_tvector_z )))));
	o->_openb3d_openb3dex_tvector_x *=bbt_d;
	o->_openb3d_openb3dex_tvector_y *=bbt_d;
	o->_openb3d_openb3dex_tvector_z *=bbt_d;
	return 0;
}
BBFLOAT _openb3d_openb3dex_TVector_Length(struct openb3d_openb3dex_TVector_obj* o){
	return ((BBFLOAT)bbSqr((BBDOUBLE)(((o->_openb3d_openb3dex_tvector_x *o->_openb3d_openb3dex_tvector_x )+(o->_openb3d_openb3dex_tvector_y *o->_openb3d_openb3dex_tvector_y ))+(o->_openb3d_openb3dex_tvector_z *o->_openb3d_openb3dex_tvector_z ))));
}
BBFLOAT _openb3d_openb3dex_TVector_SquaredLength(struct openb3d_openb3dex_TVector_obj* o){
	return (((o->_openb3d_openb3dex_tvector_x *o->_openb3d_openb3dex_tvector_x )+(o->_openb3d_openb3dex_tvector_y *o->_openb3d_openb3dex_tvector_y ))+(o->_openb3d_openb3dex_tvector_z *o->_openb3d_openb3dex_tvector_z ));
}
BBFLOAT _openb3d_openb3dex_TVector_SetLength_f(struct openb3d_openb3dex_TVector_obj* o,BBFLOAT bbt_val){
	((struct openb3d_openb3dex_TVector_obj*)o)->clas->m_Normalize(o);
	o->_openb3d_openb3dex_tvector_x =(o->_openb3d_openb3dex_tvector_x *bbt_val);
	o->_openb3d_openb3dex_tvector_y =(o->_openb3d_openb3dex_tvector_y *bbt_val);
	o->_openb3d_openb3dex_tvector_z =(o->_openb3d_openb3dex_tvector_z *bbt_val);
	return .0f;
}
BBINT _openb3d_openb3dex_TVector_Compare(struct openb3d_openb3dex_TVector_obj* o,BBOBJECT bbt_with){
	struct openb3d_openb3dex_TVector_obj* volatile bbt_q=((struct openb3d_openb3dex_TVector_obj*)bbObjectDowncast(bbt_with,&openb3d_openb3dex_TVector));
	if((o->_openb3d_openb3dex_tvector_x -bbt_q->_openb3d_openb3dex_tvector_x )>0.0001f){
		return 1;
	}
	if((bbt_q->_openb3d_openb3dex_tvector_x -o->_openb3d_openb3dex_tvector_x )>0.0001f){
		return -1;
	}
	if((o->_openb3d_openb3dex_tvector_y -bbt_q->_openb3d_openb3dex_tvector_y )>0.0001f){
		return 1;
	}
	if((bbt_q->_openb3d_openb3dex_tvector_y -o->_openb3d_openb3dex_tvector_y )>0.0001f){
		return -1;
	}
	if((o->_openb3d_openb3dex_tvector_z -bbt_q->_openb3d_openb3dex_tvector_z )>0.0001f){
		return 1;
	}
	if((bbt_q->_openb3d_openb3dex_tvector_z -o->_openb3d_openb3dex_tvector_z )>0.0001f){
		return -1;
	}
	return 0;
}
BBFLOAT openb3d_openb3dex_TVector_VectorYaw_f_fff(BBFLOAT bbt_vx,BBFLOAT bbt_vy,BBFLOAT bbt_vz){
	return ((BBFLOAT)bbATan2(((BBDOUBLE)-bbt_vx),((BBDOUBLE)bbt_vz)));
}
BBFLOAT openb3d_openb3dex_TVector_VectorPitch_f_fff(BBFLOAT bbt_vx,BBFLOAT bbt_vy,BBFLOAT bbt_vz){
	BBFLOAT bbt_ang=((BBFLOAT)(bbATan2(bbSqr((BBDOUBLE)((bbt_vx*bbt_vx)+(bbt_vz*bbt_vz))),((BBDOUBLE)bbt_vy))-90.000000000000000));
	if((bbt_ang<=0.0001f) && (bbt_ang>=-0.0001f)){
		bbt_ang=0.000000000f;
	}
	return bbt_ang;
}
struct BBDebugScope_20 openb3d_openb3dex_TVector_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TVector",
	{
		{
			BBDEBUGDECL_CONST,
			"EPSILON",
			"f",
			.const_value=&_s144
		},
		{
			BBDEBUGDECL_FIELD,
			"x",
			"f",
			.field_offset=offsetof(struct openb3d_openb3dex_TVector_obj,_openb3d_openb3dex_tvector_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"y",
			"f",
			.field_offset=offsetof(struct openb3d_openb3dex_TVector_obj,_openb3d_openb3dex_tvector_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"z",
			"f",
			.field_offset=offsetof(struct openb3d_openb3dex_TVector_obj,_openb3d_openb3dex_tvector_z)
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TVector_New
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Compare",
			"(:Object)i",
			&_openb3d_openb3dex_TVector_Compare
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Create",
			"(f,f,f):TVector",
			&openb3d_openb3dex_TVector_Create_TTVector_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Copy",
			"():TVector",
			&_openb3d_openb3dex_TVector_Copy
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Add",
			"(:TVector):TVector",
			&_openb3d_openb3dex_TVector_Add_TTVector
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Subtract",
			"(:TVector):TVector",
			&_openb3d_openb3dex_TVector_Subtract_TTVector
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Multiply",
			"(f):TVector",
			&_openb3d_openb3dex_TVector_Multiply_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Divide",
			"(f):TVector",
			&_openb3d_openb3dex_TVector_Divide_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Dot",
			"(:TVector)f",
			&_openb3d_openb3dex_TVector_Dot_TTVector
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Cross",
			"(:TVector):TVector",
			&_openb3d_openb3dex_TVector_Cross_TTVector
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Normalize",
			"()i",
			&_openb3d_openb3dex_TVector_Normalize
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Length",
			"()f",
			&_openb3d_openb3dex_TVector_Length
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SquaredLength",
			"()f",
			&_openb3d_openb3dex_TVector_SquaredLength
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetLength",
			"(f)f",
			&_openb3d_openb3dex_TVector_SetLength_f
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"VectorYaw",
			"(f,f,f)f",
			&openb3d_openb3dex_TVector_VectorYaw_f_fff
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"VectorPitch",
			"(f,f,f)f",
			&openb3d_openb3dex_TVector_VectorPitch_f_fff
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TVector openb3d_openb3dex_TVector={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TVector_scope,
	sizeof(struct openb3d_openb3dex_TVector_obj),
	_openb3d_openb3dex_TVector_New,
	_openb3d_openb3dex_TVector_Delete,
	bbObjectToString,
	_openb3d_openb3dex_TVector_Compare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TVector_obj,_openb3d_openb3dex_tvector_z) - sizeof(void*) + sizeof(BBFLOAT)
	,openb3d_openb3dex_TVector_Create_TTVector_fff
	,_openb3d_openb3dex_TVector_Copy
	,_openb3d_openb3dex_TVector_Add_TTVector
	,_openb3d_openb3dex_TVector_Subtract_TTVector
	,_openb3d_openb3dex_TVector_Multiply_f
	,_openb3d_openb3dex_TVector_Divide_f
	,_openb3d_openb3dex_TVector_Dot_TTVector
	,_openb3d_openb3dex_TVector_Cross_TTVector
	,_openb3d_openb3dex_TVector_Normalize
	,_openb3d_openb3dex_TVector_Length
	,_openb3d_openb3dex_TVector_SquaredLength
	,_openb3d_openb3dex_TVector_SetLength_f
	,openb3d_openb3dex_TVector_VectorYaw_f_fff
	,openb3d_openb3dex_TVector_VectorPitch_f_fff
};

void _openb3d_openb3dex_TMatrix_New(struct openb3d_openb3dex_TMatrix_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TMatrix;
	o->_openb3d_openb3dex_tmatrix_grid = 0;
	o->_openb3d_openb3dex_tmatrix_instance = 0;
}
void _openb3d_openb3dex_TMatrix_Delete(struct openb3d_openb3dex_TMatrix_obj* o) {
	bbObjectDtor(o);
}
struct openb3d_openb3dex_TMatrix_obj* openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TMatrix_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TMatrix);
	(openb3d_openb3dex_TMatrix_matrix_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TMatrix_matrix_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tmatrix_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TMatrix_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TMatrix_matrix_map)->clas->m_Remove_TObject(openb3d_openb3dex_TMatrix_matrix_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TMatrix_obj* openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TMatrix_obj*)bbObjectDowncast((openb3d_openb3dex_TMatrix_matrix_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TMatrix_matrix_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TMatrix));
}
BBBYTE* openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(struct openb3d_openb3dex_TMatrix_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tmatrix_instance ;
}
BBINT _openb3d_openb3dex_TMatrix_InitFields(struct openb3d_openb3dex_TMatrix_obj* o){
	o->_openb3d_openb3dex_tmatrix_grid =MatrixFloat(o->clas->f_GetInstance_pb_TTMatrix(o),1);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_LoadIdentity(struct openb3d_openb3dex_TMatrix_obj* o){
	MatrixLoadIdentity(o->clas->f_GetInstance_pb_TTMatrix(o));
	return 0;
}
struct openb3d_openb3dex_TMatrix_obj* _openb3d_openb3dex_TMatrix_Copy(struct openb3d_openb3dex_TMatrix_obj* o){
	BBBYTE* bbt_inst=MatrixCopy(o->clas->f_GetInstance_pb_TTMatrix(o));
	return o->clas->f_CreateObject_TTMatrix_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TMatrix_Overwrite_TTMatrix(struct openb3d_openb3dex_TMatrix_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_mat){
	MatrixOverwrite(o->clas->f_GetInstance_pb_TTMatrix(o),o->clas->f_GetInstance_pb_TTMatrix(bbt_mat));
	return 0;
}
struct openb3d_openb3dex_TMatrix_obj* _openb3d_openb3dex_TMatrix_GetInverse_TTMatrix(struct openb3d_openb3dex_TMatrix_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_mat){
	BBBYTE* bbt_inst=MatrixGetInverse(o->clas->f_GetInstance_pb_TTMatrix(o),o->clas->f_GetInstance_pb_TTMatrix(bbt_mat));
	return o->clas->f_GetObject_TTMatrix_pb(bbt_inst);
}
struct openb3d_openb3dex_TMatrix_obj* _openb3d_openb3dex_TMatrix_Inverse(struct openb3d_openb3dex_TMatrix_obj* o){
	struct openb3d_openb3dex_TMatrix_obj* volatile bbt_mat=bbObjectAtomicNew(&openb3d_openb3dex_TMatrix);
	BBFLOAT bbt_tx=0.000000000f;
	BBFLOAT bbt_ty=0.000000000f;
	BBFLOAT bbt_tz=0.000000000f;
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [0U]=o->_openb3d_openb3dex_tmatrix_grid [0U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [4U]=o->_openb3d_openb3dex_tmatrix_grid [1U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [8U]=o->_openb3d_openb3dex_tmatrix_grid [2U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [1U]=o->_openb3d_openb3dex_tmatrix_grid [4U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [5U]=o->_openb3d_openb3dex_tmatrix_grid [5U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [9U]=o->_openb3d_openb3dex_tmatrix_grid [6U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [2U]=o->_openb3d_openb3dex_tmatrix_grid [8U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [6U]=o->_openb3d_openb3dex_tmatrix_grid [9U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [10U]=o->_openb3d_openb3dex_tmatrix_grid [10U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [3U]=0.000000000f;
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [7U]=0.000000000f;
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [11U]=0.000000000f;
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [15U]=1.00000000f;
	bbt_tx=o->_openb3d_openb3dex_tmatrix_grid [12U];
	bbt_ty=o->_openb3d_openb3dex_tmatrix_grid [13U];
	bbt_tz=o->_openb3d_openb3dex_tmatrix_grid [14U];
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [12U]=-(((o->_openb3d_openb3dex_tmatrix_grid [0U]*bbt_tx)+(o->_openb3d_openb3dex_tmatrix_grid [1U]*bbt_ty))+(o->_openb3d_openb3dex_tmatrix_grid [2U]*bbt_tz));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [13U]=-(((o->_openb3d_openb3dex_tmatrix_grid [4U]*bbt_tx)+(o->_openb3d_openb3dex_tmatrix_grid [5U]*bbt_ty))+(o->_openb3d_openb3dex_tmatrix_grid [6U]*bbt_tz));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [14U]=-(((o->_openb3d_openb3dex_tmatrix_grid [8U]*bbt_tx)+(o->_openb3d_openb3dex_tmatrix_grid [9U]*bbt_ty))+(o->_openb3d_openb3dex_tmatrix_grid [10U]*bbt_tz));
	return bbt_mat;
}
BBINT _openb3d_openb3dex_TMatrix_Multiply_TTMatrix(struct openb3d_openb3dex_TMatrix_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_mat){
	MatrixMultiply(o->clas->f_GetInstance_pb_TTMatrix(o),o->clas->f_GetInstance_pb_TTMatrix(bbt_mat));
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_Translate_fff(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	MatrixTranslate(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_Scale_fff(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	MatrixScale(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_Rotate_fff(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_rx,BBFLOAT bbt_ry,BBFLOAT bbt_rz){
	MatrixRotate(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_rx,bbt_ry,bbt_rz);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_RotatePitch_f(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_ang){
	MatrixRotatePitch(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_ang);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_RotateYaw_f(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_ang){
	MatrixRotateYaw(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_ang);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_RotateRoll_f(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_ang){
	MatrixRotateRoll(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_ang);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_FromQuaternion_ffff(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_w){
	MatrixFromQuaternion(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_x,bbt_y,bbt_z,bbt_w);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_TransformVec_vfvfvfi(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT* bbt_rx,BBFLOAT* bbt_ry,BBFLOAT* bbt_rz,BBINT bbt_addTranslation){
	MatrixTransformVec(o->clas->f_GetInstance_pb_TTMatrix(o),&(*bbt_rx),&(*bbt_ry),&(*bbt_rz),bbt_addTranslation);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_Transpose(struct openb3d_openb3dex_TMatrix_obj* o){
	MatrixTranspose(o->clas->f_GetInstance_pb_TTMatrix(o));
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_SetTranslate_fff(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	MatrixSetTranslate(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_Multiply2_TTMatrix(struct openb3d_openb3dex_TMatrix_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_mat){
	MatrixMultiply2(o->clas->f_GetInstance_pb_TTMatrix(o),o->clas->f_GetInstance_pb_TTMatrix(bbt_mat));
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_GetInverse2_TTMatrix(struct openb3d_openb3dex_TMatrix_obj* o,struct openb3d_openb3dex_TMatrix_obj* bbt_mat){
	MatrixGetInverse2(o->clas->f_GetInstance_pb_TTMatrix(o),o->clas->f_GetInstance_pb_TTMatrix(bbt_mat));
	return 0;
}
BBFLOAT _openb3d_openb3dex_TMatrix_GetPitch(struct openb3d_openb3dex_TMatrix_obj* o){
	return MatrixGetPitch(o->clas->f_GetInstance_pb_TTMatrix(o));
}
BBFLOAT _openb3d_openb3dex_TMatrix_GetYaw(struct openb3d_openb3dex_TMatrix_obj* o){
	return MatrixGetYaw(o->clas->f_GetInstance_pb_TTMatrix(o));
}
BBFLOAT _openb3d_openb3dex_TMatrix_GetRoll(struct openb3d_openb3dex_TMatrix_obj* o){
	return MatrixGetRoll(o->clas->f_GetInstance_pb_TTMatrix(o));
}
BBINT _openb3d_openb3dex_TMatrix_FromToRotation_ffffff(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT bbt_ix,BBFLOAT bbt_iy,BBFLOAT bbt_iz,BBFLOAT bbt_jx,BBFLOAT bbt_jy,BBFLOAT bbt_jz){
	MatrixFromToRotation(o->clas->f_GetInstance_pb_TTMatrix(o),bbt_ix,bbt_iy,bbt_iz,bbt_jx,bbt_jy,bbt_jz);
	return 0;
}
BBINT _openb3d_openb3dex_TMatrix_ToQuat_vfvfvfvf(struct openb3d_openb3dex_TMatrix_obj* o,BBFLOAT* bbt_qx,BBFLOAT* bbt_qy,BBFLOAT* bbt_qz,BBFLOAT* bbt_qw){
	MatrixToQuat(o->clas->f_GetInstance_pb_TTMatrix(o),&(*bbt_qx),&(*bbt_qy),&(*bbt_qz),&(*bbt_qw));
	return 0;
}
struct brl_map_TMap_obj* openb3d_openb3dex_TMatrix_matrix_map;
struct BBDebugScope_32 openb3d_openb3dex_TMatrix_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TMatrix",
	{
		{
			BBDEBUGDECL_FIELD,
			"grid",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TMatrix_obj,_openb3d_openb3dex_tmatrix_grid)
		},
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TMatrix_obj,_openb3d_openb3dex_tmatrix_instance)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"matrix_map",
			":TMap",
			&openb3d_openb3dex_TMatrix_matrix_map
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TMatrix_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TMatrix",
			&openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TMatrix_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TMatrix",
			&openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TMatrix)*b",
			&openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TMatrix_InitFields
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"LoadIdentity",
			"()i",
			&_openb3d_openb3dex_TMatrix_LoadIdentity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Copy",
			"():TMatrix",
			&_openb3d_openb3dex_TMatrix_Copy
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Overwrite",
			"(:TMatrix)i",
			&_openb3d_openb3dex_TMatrix_Overwrite_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetInverse",
			"(:TMatrix):TMatrix",
			&_openb3d_openb3dex_TMatrix_GetInverse_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Inverse",
			"():TMatrix",
			&_openb3d_openb3dex_TMatrix_Inverse
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Multiply",
			"(:TMatrix)i",
			&_openb3d_openb3dex_TMatrix_Multiply_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Translate",
			"(f,f,f)i",
			&_openb3d_openb3dex_TMatrix_Translate_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Scale",
			"(f,f,f)i",
			&_openb3d_openb3dex_TMatrix_Scale_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Rotate",
			"(f,f,f)i",
			&_openb3d_openb3dex_TMatrix_Rotate_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RotatePitch",
			"(f)i",
			&_openb3d_openb3dex_TMatrix_RotatePitch_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RotateYaw",
			"(f)i",
			&_openb3d_openb3dex_TMatrix_RotateYaw_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RotateRoll",
			"(f)i",
			&_openb3d_openb3dex_TMatrix_RotateRoll_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FromQuaternion",
			"(f,f,f,f)i",
			&_openb3d_openb3dex_TMatrix_FromQuaternion_ffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TransformVec",
			"(f,f,f,i)i",
			&_openb3d_openb3dex_TMatrix_TransformVec_vfvfvfi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Transpose",
			"()i",
			&_openb3d_openb3dex_TMatrix_Transpose
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetTranslate",
			"(f,f,f)i",
			&_openb3d_openb3dex_TMatrix_SetTranslate_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Multiply2",
			"(:TMatrix)i",
			&_openb3d_openb3dex_TMatrix_Multiply2_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetInverse2",
			"(:TMatrix)i",
			&_openb3d_openb3dex_TMatrix_GetInverse2_TTMatrix
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetPitch",
			"()f",
			&_openb3d_openb3dex_TMatrix_GetPitch
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetYaw",
			"()f",
			&_openb3d_openb3dex_TMatrix_GetYaw
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetRoll",
			"()f",
			&_openb3d_openb3dex_TMatrix_GetRoll
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FromToRotation",
			"(f,f,f,f,f,f)i",
			&_openb3d_openb3dex_TMatrix_FromToRotation_ffffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ToQuat",
			"(f,f,f,f)i",
			&_openb3d_openb3dex_TMatrix_ToQuat_vfvfvfvf
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TMatrix openb3d_openb3dex_TMatrix={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TMatrix_scope,
	sizeof(struct openb3d_openb3dex_TMatrix_obj),
	_openb3d_openb3dex_TMatrix_New,
	_openb3d_openb3dex_TMatrix_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TMatrix_obj,_openb3d_openb3dex_tmatrix_instance) - sizeof(void*) + sizeof(BBBYTE*)
	,openb3d_openb3dex_TMatrix_CreateObject_TTMatrix_pb
	,openb3d_openb3dex_TMatrix_FreeObject_i_pb
	,openb3d_openb3dex_TMatrix_GetObject_TTMatrix_pb
	,openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix
	,_openb3d_openb3dex_TMatrix_InitFields
	,_openb3d_openb3dex_TMatrix_LoadIdentity
	,_openb3d_openb3dex_TMatrix_Copy
	,_openb3d_openb3dex_TMatrix_Overwrite_TTMatrix
	,_openb3d_openb3dex_TMatrix_GetInverse_TTMatrix
	,_openb3d_openb3dex_TMatrix_Inverse
	,_openb3d_openb3dex_TMatrix_Multiply_TTMatrix
	,_openb3d_openb3dex_TMatrix_Translate_fff
	,_openb3d_openb3dex_TMatrix_Scale_fff
	,_openb3d_openb3dex_TMatrix_Rotate_fff
	,_openb3d_openb3dex_TMatrix_RotatePitch_f
	,_openb3d_openb3dex_TMatrix_RotateYaw_f
	,_openb3d_openb3dex_TMatrix_RotateRoll_f
	,_openb3d_openb3dex_TMatrix_FromQuaternion_ffff
	,_openb3d_openb3dex_TMatrix_TransformVec_vfvfvfi
	,_openb3d_openb3dex_TMatrix_Transpose
	,_openb3d_openb3dex_TMatrix_SetTranslate_fff
	,_openb3d_openb3dex_TMatrix_Multiply2_TTMatrix
	,_openb3d_openb3dex_TMatrix_GetInverse2_TTMatrix
	,_openb3d_openb3dex_TMatrix_GetPitch
	,_openb3d_openb3dex_TMatrix_GetYaw
	,_openb3d_openb3dex_TMatrix_GetRoll
	,_openb3d_openb3dex_TMatrix_FromToRotation_ffffff
	,_openb3d_openb3dex_TMatrix_ToQuat_vfvfvfvf
};

void _openb3d_openb3dex_TQuaternion_New(struct openb3d_openb3dex_TQuaternion_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TQuaternion;
	o->_openb3d_openb3dex_tquaternion_w = .0f;
	o->_openb3d_openb3dex_tquaternion_x = .0f;
	o->_openb3d_openb3dex_tquaternion_y = .0f;
	o->_openb3d_openb3dex_tquaternion_z = .0f;
}
void _openb3d_openb3dex_TQuaternion_Delete(struct openb3d_openb3dex_TQuaternion_obj* o) {
	bbObjectDtor(o);
}
BBINT openb3d_openb3dex_TQuaternion_QuatToMat_i_ffffvTTMatrix(BBFLOAT bbt_w,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,struct openb3d_openb3dex_TMatrix_obj** bbt_mat){
	BBARRAY bbt_q=bbArrayNew1D("f", 4);
	((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[0U]=bbt_w;
	((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]=bbt_x;
	((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]=bbt_y;
	((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]=bbt_z;
	BBFLOAT bbt_xx=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]);
	BBFLOAT bbt_yy=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]);
	BBFLOAT bbt_zz=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]);
	BBFLOAT bbt_xy=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]);
	BBFLOAT bbt_xz=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]);
	BBFLOAT bbt_yz=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]);
	BBFLOAT bbt_wx=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[0U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]);
	BBFLOAT bbt_wy=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[0U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]);
	BBFLOAT bbt_wz=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[0U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]);
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [0U]=(1.00000000f-(2.00000000f*(bbt_yy+bbt_zz)));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [1U]=(2.00000000f*(bbt_xy-bbt_wz));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [2U]=(2.00000000f*(bbt_xz+bbt_wy));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [4U]=(2.00000000f*(bbt_xy+bbt_wz));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [5U]=(1.00000000f-(2.00000000f*(bbt_xx+bbt_zz)));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [6U]=(2.00000000f*(bbt_yz-bbt_wx));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [8U]=(2.00000000f*(bbt_xz-bbt_wy));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [9U]=(2.00000000f*(bbt_yz+bbt_wx));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [10U]=(1.00000000f-(2.00000000f*(bbt_xx+bbt_yy)));
	(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [15U]=1.00000000f;
	{
		BBINT bbt_iy=0;
		for(bbt_iy;(bbt_iy<=3);bbt_iy=(bbt_iy+1)){
			{
				BBINT bbt_ix=0;
				for(bbt_ix;(bbt_ix<=3);bbt_ix=(bbt_ix+1)){
					bbt_xx=(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [((BBUINT)((4*bbt_ix)+bbt_iy))];
					if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
						bbt_xx=0.000000000f;
					}
					(*bbt_mat)->_openb3d_openb3dex_tmatrix_grid [((BBUINT)((4*bbt_ix)+bbt_iy))]=bbt_xx;
				}
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TQuaternion_QuatToEuler_i_ffffvfvfvf(BBFLOAT bbt_w,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT* bbt_pitch,BBFLOAT* bbt_yaw,BBFLOAT* bbt_roll){
	BBARRAY bbt_q=bbArrayNew1D("f", 4);
	((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[0U]=bbt_w;
	((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]=bbt_x;
	((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]=bbt_y;
	((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]=bbt_z;
	BBFLOAT bbt_xx=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]);
	BBFLOAT bbt_yy=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]);
	BBFLOAT bbt_zz=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]);
	BBFLOAT bbt_xy=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]);
	BBFLOAT bbt_xz=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]);
	BBFLOAT bbt_yz=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]);
	BBFLOAT bbt_wx=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[0U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[1U]);
	BBFLOAT bbt_wy=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[0U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[2U]);
	BBFLOAT bbt_wz=(((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[0U]*((BBFLOAT*)BBARRAYDATA((bbt_q),(bbt_q)->dims))[3U]);
	struct openb3d_openb3dex_TMatrix_obj* volatile bbt_mat=bbObjectAtomicNew(&openb3d_openb3dex_TMatrix);
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [0U]=(1.00000000f-(2.00000000f*(bbt_yy+bbt_zz)));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [1U]=(2.00000000f*(bbt_xy-bbt_wz));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [2U]=(2.00000000f*(bbt_xz+bbt_wy));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [4U]=(2.00000000f*(bbt_xy+bbt_wz));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [5U]=(1.00000000f-(2.00000000f*(bbt_xx+bbt_zz)));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [6U]=(2.00000000f*(bbt_yz-bbt_wx));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [8U]=(2.00000000f*(bbt_xz-bbt_wy));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [9U]=(2.00000000f*(bbt_yz+bbt_wx));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [10U]=(1.00000000f-(2.00000000f*(bbt_xx+bbt_yy)));
	bbt_mat->_openb3d_openb3dex_tmatrix_grid [15U]=1.00000000f;
	{
		BBINT bbt_iy=0;
		for(bbt_iy;(bbt_iy<=3);bbt_iy=(bbt_iy+1)){
			{
				BBINT bbt_ix=0;
				for(bbt_ix;(bbt_ix<=3);bbt_ix=(bbt_ix+1)){
					bbt_xx=bbt_mat->_openb3d_openb3dex_tmatrix_grid [((BBUINT)((4*bbt_ix)+bbt_iy))];
					if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
						bbt_xx=0.000000000f;
					}
					bbt_mat->_openb3d_openb3dex_tmatrix_grid [((BBUINT)((4*bbt_ix)+bbt_iy))]=bbt_xx;
				}
			}
		}
	}
	*bbt_pitch=((BBFLOAT)bbATan2(((BBDOUBLE)bbt_mat->_openb3d_openb3dex_tmatrix_grid [9U]),bbSqr((BBDOUBLE)((bbt_mat->_openb3d_openb3dex_tmatrix_grid [8U]*bbt_mat->_openb3d_openb3dex_tmatrix_grid [8U])+(bbt_mat->_openb3d_openb3dex_tmatrix_grid [10U]*bbt_mat->_openb3d_openb3dex_tmatrix_grid [10U])))));
	*bbt_yaw=((BBFLOAT)bbATan2(((BBDOUBLE)bbt_mat->_openb3d_openb3dex_tmatrix_grid [8U]),((BBDOUBLE)bbt_mat->_openb3d_openb3dex_tmatrix_grid [10U])));
	*bbt_roll=((BBFLOAT)bbATan2(((BBDOUBLE)bbt_mat->_openb3d_openb3dex_tmatrix_grid [1U]),((BBDOUBLE)bbt_mat->_openb3d_openb3dex_tmatrix_grid [5U])));
	return 0;
}
BBINT openb3d_openb3dex_TQuaternion_Slerp_i_ffffffffvfvfvfvff(BBFLOAT bbt_Ax,BBFLOAT bbt_Ay,BBFLOAT bbt_Az,BBFLOAT bbt_Aw,BBFLOAT bbt_Bx,BBFLOAT bbt_By,BBFLOAT bbt_Bz,BBFLOAT bbt_Bw,BBFLOAT* bbt_Cx,BBFLOAT* bbt_Cy,BBFLOAT* bbt_Cz,BBFLOAT* bbt_Cw,BBFLOAT bbt_t){
	if((((bbFloatAbs(bbt_Ax-bbt_Bx)<0.001f) && (bbFloatAbs(bbt_Ay-bbt_By)<0.001f)) && (bbFloatAbs(bbt_Az-bbt_Bz)<0.001f)) && (bbFloatAbs(bbt_Aw-bbt_Bw)<0.001f)){
		*bbt_Cx=bbt_Ax;
		*bbt_Cy=bbt_Ay;
		*bbt_Cz=bbt_Az;
		*bbt_Cw=bbt_Aw;
		return 1;
	}
	BBFLOAT bbt_cosineom=((((bbt_Ax*bbt_Bx)+(bbt_Ay*bbt_By))+(bbt_Az*bbt_Bz))+(bbt_Aw*bbt_Bw));
	BBFLOAT bbt_scaler_w=.0f;
	BBFLOAT bbt_scaler_x=.0f;
	BBFLOAT bbt_scaler_y=.0f;
	BBFLOAT bbt_scaler_z=.0f;
	if(bbt_cosineom<=0.0f){
		bbt_cosineom=-bbt_cosineom;
		bbt_scaler_w=-bbt_Bw;
		bbt_scaler_x=-bbt_Bx;
		bbt_scaler_y=-bbt_By;
		bbt_scaler_z=-bbt_Bz;
	}else{
		bbt_scaler_w=bbt_Bw;
		bbt_scaler_x=bbt_Bx;
		bbt_scaler_y=bbt_By;
		bbt_scaler_z=bbt_Bz;
	}
	BBFLOAT bbt_scale0=.0f;
	BBFLOAT bbt_scale1=.0f;
	if((1.0f-bbt_cosineom)>0.0001f){
		BBFLOAT bbt_omega=((BBFLOAT)bbACos((BBDOUBLE)bbt_cosineom));
		BBFLOAT bbt_sineom=((BBFLOAT)bbSin((BBDOUBLE)bbt_omega));
		bbt_scale0=((BBFLOAT)(bbSin((BBDOUBLE)((1.0f-bbt_t)*bbt_omega))/((BBDOUBLE)bbt_sineom)));
		bbt_scale1=((BBFLOAT)(bbSin((BBDOUBLE)(bbt_t*bbt_omega))/((BBDOUBLE)bbt_sineom)));
	}else{
		bbt_scale0=(1.0f-bbt_t);
		bbt_scale1=bbt_t;
	}
	*bbt_Cw=((bbt_scale0*bbt_Aw)+(bbt_scale1*bbt_scaler_w));
	*bbt_Cx=((bbt_scale0*bbt_Ax)+(bbt_scale1*bbt_scaler_x));
	*bbt_Cy=((bbt_scale0*bbt_Ay)+(bbt_scale1*bbt_scaler_y));
	*bbt_Cz=((bbt_scale0*bbt_Az)+(bbt_scale1*bbt_scaler_z));
	return 0;
}
struct BBDebugScope_8 openb3d_openb3dex_TQuaternion_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TQuaternion",
	{
		{
			BBDEBUGDECL_FIELD,
			"w",
			"f",
			.field_offset=offsetof(struct openb3d_openb3dex_TQuaternion_obj,_openb3d_openb3dex_tquaternion_w)
		},
		{
			BBDEBUGDECL_FIELD,
			"x",
			"f",
			.field_offset=offsetof(struct openb3d_openb3dex_TQuaternion_obj,_openb3d_openb3dex_tquaternion_x)
		},
		{
			BBDEBUGDECL_FIELD,
			"y",
			"f",
			.field_offset=offsetof(struct openb3d_openb3dex_TQuaternion_obj,_openb3d_openb3dex_tquaternion_y)
		},
		{
			BBDEBUGDECL_FIELD,
			"z",
			"f",
			.field_offset=offsetof(struct openb3d_openb3dex_TQuaternion_obj,_openb3d_openb3dex_tquaternion_z)
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TQuaternion_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"QuatToMat",
			"(f,f,f,f,:TMatrix)i",
			&openb3d_openb3dex_TQuaternion_QuatToMat_i_ffffvTTMatrix
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"QuatToEuler",
			"(f,f,f,f,f,f,f)i",
			&openb3d_openb3dex_TQuaternion_QuatToEuler_i_ffffvfvfvf
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Slerp",
			"(f,f,f,f,f,f,f,f,f,f,f,f,f)i",
			&openb3d_openb3dex_TQuaternion_Slerp_i_ffffffffvfvfvfvff
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TQuaternion openb3d_openb3dex_TQuaternion={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TQuaternion_scope,
	sizeof(struct openb3d_openb3dex_TQuaternion_obj),
	_openb3d_openb3dex_TQuaternion_New,
	_openb3d_openb3dex_TQuaternion_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TQuaternion_obj,_openb3d_openb3dex_tquaternion_z) - sizeof(void*) + sizeof(BBFLOAT)
	,openb3d_openb3dex_TQuaternion_QuatToMat_i_ffffvTTMatrix
	,openb3d_openb3dex_TQuaternion_QuatToEuler_i_ffffvfvfvf
	,openb3d_openb3dex_TQuaternion_Slerp_i_ffffffffvfvfvfvff
};

void _openb3d_openb3dex_TBlitz2D_New(struct openb3d_openb3dex_TBlitz2D_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TBlitz2D;
}
BBINT openb3d_openb3dex_TBlitz2D_Text_i_iiS(BBINT bbt_x,BBINT bbt_y,BBSTRING bbt_Text){
	if(openb3d_openb3dex_THardwareInfo_VBOSupport!=0){
		__glewActiveTextureARB(33984);
		__glewClientActiveTextureARB(33984);
	}
	glTexEnvf((GLenum)8960,(GLenum)8704,(GLfloat)7681.00000f);
	glDisable((GLenum)2896);
	glColor3f((GLfloat)1.0f,(GLfloat)1.0f,(GLfloat)1.0f);
	glEnable((GLenum)3042);
	brl_glgraphics_source_GLDrawText(bbt_Text,bbt_x,bbt_y);
	glDisable((GLenum)3042);
	glEnable((GLenum)2896);
	glDisable((GLenum)3553);
	return 0;
}
BBINT openb3d_openb3dex_TBlitz2D_BeginMax2D_i(){
	glPopClientAttrib();
	glPopAttrib();
	glMatrixMode((GLenum)5888);
	glPopMatrix();
	glMatrixMode((GLenum)5889);
	glPopMatrix();
	glMatrixMode((GLenum)5890);
	glPopMatrix();
	glMatrixMode((GLenum)6144);
	glPopMatrix();
	return 0;
}
BBINT openb3d_openb3dex_TBlitz2D_EndMax2D_i(){
	glPushAttrib((GLbitfield)1048575);
	glPushClientAttrib((GLbitfield)-1);
	glMatrixMode((GLenum)5888);
	glPushMatrix();
	glMatrixMode((GLenum)5889);
	glPushMatrix();
	glMatrixMode((GLenum)5890);
	glPushMatrix();
	glMatrixMode((GLenum)6144);
	glPushMatrix();
	openb3d_openb3dex_TGlobal_EnableStates_i();
	glDisable((GLenum)3553);
	openb3d_openb3dex_TGlobal_alpha_enable[0U]=0;
	openb3d_openb3dex_TGlobal_blend_mode[0U]=1;
	openb3d_openb3dex_TGlobal_fx1[0U]=0;
	openb3d_openb3dex_TGlobal_fx2[0U]=1;
	glLightModeli((GLenum)33272,(GLint)33274);
	glLightModeli((GLenum)2897,(GLint)1);
	glClearDepth((GLclampd)1.0000000000000000);
	glDepthFunc((GLenum)515);
	glHint((GLenum)3152,(GLenum)4354);
	glAlphaFunc((GLenum)518,(GLclampf)0.5f);
	struct brl_linkedlist_TListEnum_obj* volatile bbt_=(openb3d_openb3dex_TCamera_cam_list)->clas->m_ObjectEnumerator(openb3d_openb3dex_TCamera_cam_list);
	while((bbt_)->clas->m_HasNext(bbt_)!=0){
		struct openb3d_openb3dex_TCamera_obj* volatile bbt_cam=((struct openb3d_openb3dex_TCamera_obj*)bbObjectDowncast((bbt_)->clas->m_NextObject(bbt_),&openb3d_openb3dex_TCamera));
		if(bbt_cam==&bbNullObject){
			continue;
		}
		if(bbt_cam==openb3d_openb3dex_TGlobal_camera_in_use){
			(bbt_cam)->clas->m_UpdateFog(bbt_cam);
			break;
		}
	}
	return 0;
}
struct BBDebugScope_4 openb3d_openb3dex_TBlitz2D_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TBlitz2D",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TBlitz2D_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Text",
			"(i,i,$)i",
			&openb3d_openb3dex_TBlitz2D_Text_i_iiS
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"BeginMax2D",
			"()i",
			&openb3d_openb3dex_TBlitz2D_BeginMax2D_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"EndMax2D",
			"()i",
			&openb3d_openb3dex_TBlitz2D_EndMax2D_i
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TBlitz2D openb3d_openb3dex_TBlitz2D={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TBlitz2D_scope,
	sizeof(struct openb3d_openb3dex_TBlitz2D_obj),
	_openb3d_openb3dex_TBlitz2D_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,openb3d_openb3dex_TBlitz2D_Text_i_iiS
	,openb3d_openb3dex_TBlitz2D_BeginMax2D_i
	,openb3d_openb3dex_TBlitz2D_EndMax2D_i
};

void _openb3d_openb3dex_TUtility_New(struct openb3d_openb3dex_TUtility_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TUtility;
}
BBFLOAT openb3d_openb3dex_TUtility_UpdateValue_f_fff(BBFLOAT bbt_Current,BBFLOAT bbt_destination,BBFLOAT bbt_rate){
	bbt_Current=(bbt_Current+((bbt_destination-bbt_Current)*bbt_rate));
	return bbt_Current;
}
struct BBDebugScope_2 openb3d_openb3dex_TUtility_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TUtility",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TUtility_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UpdateValue",
			"(f,f,f)f",
			&openb3d_openb3dex_TUtility_UpdateValue_f_fff
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TUtility openb3d_openb3dex_TUtility={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TUtility_scope,
	sizeof(struct openb3d_openb3dex_TUtility_obj),
	_openb3d_openb3dex_TUtility_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,openb3d_openb3dex_TUtility_UpdateValue_f_fff
};

void _openb3d_openb3dex_TDebug_New(struct openb3d_openb3dex_TDebug_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TDebug;
}
BBINT openb3d_openb3dex_TDebug_DebugWorld_i(){
	BBINT bbt_no_ents=0;
	BBINT bbt_no_cams=0;
	BBINT bbt_no_lights=0;
	BBINT bbt_no_pivs=0;
	BBINT bbt_no_meshes=0;
	BBINT bbt_no_sprites=0;
	BBINT bbt_no_bones=0;
	struct brl_linkedlist_TListEnum_obj* volatile bbt_=(openb3d_openb3dex_TEntity_entity_list)->clas->m_ObjectEnumerator(openb3d_openb3dex_TEntity_entity_list);
	while((bbt_)->clas->m_HasNext(bbt_)!=0){
		struct openb3d_openb3dex_TEntity_obj* volatile bbt_ent=((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast((bbt_)->clas->m_NextObject(bbt_),&openb3d_openb3dex_TEntity));
		if(bbt_ent==&bbNullObject){
			continue;
		}
		bbt_no_ents+=1;
		if(((struct openb3d_openb3dex_TCamera_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TCamera))!=&bbNullObject){
			bbt_no_cams+=1;
		}
		if(((struct openb3d_openb3dex_TLight_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TLight))!=&bbNullObject){
			bbt_no_lights+=1;
		}
		if(((struct openb3d_openb3dex_TPivot_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TPivot))!=&bbNullObject){
			bbt_no_pivs+=1;
		}
		if(((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))!=&bbNullObject){
			bbt_no_meshes+=1;
		}
		if(((struct openb3d_openb3dex_TSprite_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TSprite))!=&bbNullObject){
			bbt_no_sprites+=1;
		}
		if(((struct openb3d_openb3dex_TBone_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TBone))!=&bbNullObject){
			bbt_no_bones+=1;
		}
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,120,bbStringConcat(&_s34,bbStringFromInt(bbt_no_ents)));
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,140,bbStringConcat(&_s35,bbStringFromInt(bbt_no_cams)));
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,160,bbStringConcat(&_s36,bbStringFromInt(bbt_no_lights)));
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,180,bbStringConcat(&_s37,bbStringFromInt(bbt_no_pivs)));
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,200,bbStringConcat(&_s38,bbStringFromInt(bbt_no_meshes)));
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,220,bbStringConcat(&_s39,bbStringFromInt(bbt_no_sprites)));
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,240,bbStringConcat(&_s40,bbStringFromInt(bbt_no_bones)));
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_TDebug_DebugEntity_TTEntity_TTEntityTTCamera(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TCamera_obj* bbt_cam){
	if(bbt_ent==&bbNullObject){
		return &bbNullObject;
	}
	BBINT bbt_no_children=0;
	struct openb3d_openb3dex_TEntity_obj* volatile bbt_old_cent=(bbt_ent)->clas->m_GetChildFromAll_iviTTEntity(bbt_ent,openb3d_openb3dex_TDebug_cno,(&bbt_no_children),&bbNullObject);
	if(bbt_old_cent!=&bbNullObject){
		(bbt_old_cent)->clas->m_EntityColor_fff(bbt_old_cent,255.000000f,255.000000f,255.000000f);
	}
	if(brl_polledinput_KeyHit(107)!=0){
		openb3d_openb3dex_TDebug_cno=(openb3d_openb3dex_TDebug_cno+1);
	}
	if(brl_polledinput_KeyHit(109)!=0){
		openb3d_openb3dex_TDebug_cno=(openb3d_openb3dex_TDebug_cno-1);
	}
	BBINT bbt_no_childs=openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi(bbt_ent,0);
	if(openb3d_openb3dex_TDebug_cno<0){
		openb3d_openb3dex_TDebug_cno=0;
	}
	if(openb3d_openb3dex_TDebug_cno>bbt_no_childs){
		openb3d_openb3dex_TDebug_cno=bbt_no_childs;
	}
	bbt_no_children=0;
	struct openb3d_openb3dex_TEntity_obj* volatile bbt_cent=(bbt_ent)->clas->m_GetChildFromAll_iviTTEntity(bbt_ent,openb3d_openb3dex_TDebug_cno,(&bbt_no_children),&bbNullObject);
	if(bbt_cent==&bbNullObject){
		bbt_cent=bbt_ent;
	}
	if(bbt_cent!=&bbNullObject){
		struct openb3d_openb3dex_TSurface_obj* volatile bbt_surf=&bbNullObject;
		if(((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_cent,&openb3d_openb3dex_TMesh))!=&bbNullObject){
			if(brl_polledinput_KeyHit(111)!=0){
				openb3d_openb3dex_TDebug_surf_no-=1;
			}
			if(brl_polledinput_KeyHit(106)!=0){
				openb3d_openb3dex_TDebug_surf_no+=1;
			}
			if(openb3d_openb3dex_TDebug_surf_no<1){
				openb3d_openb3dex_TDebug_surf_no=1;
			}
			if(openb3d_openb3dex_TDebug_surf_no>(((struct openb3d_openb3dex_TMesh_obj*)((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_cent,&openb3d_openb3dex_TMesh)))->clas)->m_CountSurfaces((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_cent,&openb3d_openb3dex_TMesh))){
				openb3d_openb3dex_TDebug_surf_no=(((struct openb3d_openb3dex_TMesh_obj*)((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_cent,&openb3d_openb3dex_TMesh)))->clas)->m_CountSurfaces((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_cent,&openb3d_openb3dex_TMesh));
			}
			bbt_surf=openb3d_openb3dex_GetSurface(((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_cent,&openb3d_openb3dex_TMesh)),openb3d_openb3dex_TDebug_surf_no);
		}else{
			openb3d_openb3dex_TDebug_surf_no=0;
			bbt_surf=&bbNullObject;
		}
		if(brl_polledinput_KeyHit(96)!=0){
			openb3d_openb3dex_TDebug_show_ents=(1-openb3d_openb3dex_TDebug_show_ents);
		}
		openb3d_openb3dex_TDebug_UpdateBoundingSphere_i_TTEntity(bbt_cent);
		openb3d_openb3dex_TDebug_UpdateSurface_i_TTEntityTTSurface(bbt_cent,bbt_surf);
		openb3d_openb3dex_TDebug_UpdateMarker_i_TTEntityTTCamera(bbt_cent,bbt_cam);
		if(brl_polledinput_KeyHit(97)!=0){
			openb3d_openb3dex_TDebug_info=1;
		}
		if(brl_polledinput_KeyHit(98)!=0){
			openb3d_openb3dex_TDebug_info=2;
		}
		if(brl_polledinput_KeyHit(99)!=0){
			openb3d_openb3dex_TDebug_info=3;
		}
		if(brl_polledinput_KeyHit(100)!=0){
			openb3d_openb3dex_TDebug_info=4;
		}
		if(brl_polledinput_KeyHit(101)!=0){
			openb3d_openb3dex_TDebug_info=5;
		}
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,0,bbStringConcat(bbStringConcat(bbStringConcat(bbStringConcat(bbStringConcat(bbStringConcat(bbStringConcat(&_s41,bbStringFromInt(openb3d_openb3dex_TDebug_cno)),&_s21),bbStringFromInt(bbt_no_childs)),&_s42),(bbt_cent)->clas->m_EntityName(bbt_cent)),&_s43),(bbt_cent)->clas->m_EntityClass(bbt_cent)));
		if(openb3d_openb3dex_TDebug_info==1){
			openb3d_openb3dex_TDebug_EntityInfo1_i_TTEntity(bbt_cent);
		}
		if(openb3d_openb3dex_TDebug_info==2){
			openb3d_openb3dex_TDebug_EntityInfo2_i_TTEntityTTSurface(bbt_cent,bbt_surf);
		}
		if(openb3d_openb3dex_TDebug_info==3){
			openb3d_openb3dex_TDebug_EntityInfo3_i_TTEntityTTSurface(bbt_cent,bbt_surf);
		}
		if(openb3d_openb3dex_TDebug_info==4){
			openb3d_openb3dex_TDebug_EntityInfo4_i_TTEntityTTCamera(bbt_cent,bbt_cam);
		}
		if(openb3d_openb3dex_TDebug_info==5){
			openb3d_openb3dex_TDebug_EntityInfo4_i_TTEntityTTCamera(bbt_cent,bbt_cam);
		}
	}
	return bbt_cent;
}
BBINT openb3d_openb3dex_TDebug_UpdateBoundingSphere_i_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	if(openb3d_openb3dex_TDebug_bounding_sphere==&bbNullObject){
		openb3d_openb3dex_TDebug_bounding_sphere=openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity(16,&bbNullObject);
		(openb3d_openb3dex_TDebug_bounding_sphere)->clas->m_EntityAlpha_f(openb3d_openb3dex_TDebug_bounding_sphere,0.25f);
		(openb3d_openb3dex_TDebug_bounding_sphere)->clas->m_EntityColor_fff(openb3d_openb3dex_TDebug_bounding_sphere,255.000000f,0.000000000f,0.000000000f);
	}
	if((openb3d_openb3dex_TDebug_show_ents==0) || (((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))==&bbNullObject)){
		(openb3d_openb3dex_TDebug_bounding_sphere)->clas->m_HideEntity(openb3d_openb3dex_TDebug_bounding_sphere);
		return 0;
	}
	(openb3d_openb3dex_TDebug_bounding_sphere)->clas->m_ShowEntity(openb3d_openb3dex_TDebug_bounding_sphere);
	BBFLOAT bbt_radius=bbFloatAbs(bbt_ent->_openb3d_openb3dex_tentity_cull_radius [0U]);
	BBFLOAT bbt_x=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_x [0U];
	BBFLOAT bbt_y=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_y [0U];
	BBFLOAT bbt_z=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_z [0U];
	bbt_x=(bbt_x+((((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_max_x [0U]-((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_x [0U])/2.0f));
	bbt_y=(bbt_y+((((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_max_y [0U]-((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_y [0U])/2.0f));
	bbt_z=(bbt_z+((((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_max_z [0U]-((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_z [0U])/2.0f));
	openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity(bbt_x,bbt_y,bbt_z,bbt_ent,&bbNullObject);
	bbt_x=openb3d_openb3dex_TEntity_TFormedX_f();
	bbt_y=openb3d_openb3dex_TEntity_TFormedY_f();
	bbt_z=openb3d_openb3dex_TEntity_TFormedZ_f();
	BBFLOAT bbt_rx=(bbt_radius*(bbt_ent)->clas->m_EntityScaleX_i(bbt_ent,1));
	BBFLOAT bbt_ry=(bbt_radius*(bbt_ent)->clas->m_EntityScaleY_i(bbt_ent,1));
	BBFLOAT bbt_rz=(bbt_radius*(bbt_ent)->clas->m_EntityScaleZ_i(bbt_ent,1));
	if((bbt_rx>=bbt_ry) && (bbt_rx>=bbt_rz)){
		bbt_radius=bbFloatAbs(bbt_rx);
	}else{
		if((bbt_ry>=bbt_rx) && (bbt_ry>=bbt_rz)){
			bbt_radius=bbFloatAbs(bbt_ry);
		}else{
			bbt_radius=bbFloatAbs(bbt_rz);
		}
	}
	(openb3d_openb3dex_TDebug_bounding_sphere)->clas->m_PositionEntity_fffi(openb3d_openb3dex_TDebug_bounding_sphere,bbt_x,bbt_y,bbt_z,1);
	(openb3d_openb3dex_TDebug_bounding_sphere)->clas->m_ScaleEntity_fffi(openb3d_openb3dex_TDebug_bounding_sphere,bbt_radius,bbt_radius,bbt_radius,0);
	return 0;
}
BBINT openb3d_openb3dex_TDebug_UpdateSurface_i_TTEntityTTSurface(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	if(openb3d_openb3dex_TDebug_debug_mesh==&bbNullObject){
		openb3d_openb3dex_TDebug_debug_mesh=openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity(&bbNullObject);
		openb3d_openb3dex_TDebug_debug_surf=(openb3d_openb3dex_TDebug_debug_mesh)->clas->m_CreateSurface_TTBrush(openb3d_openb3dex_TDebug_debug_mesh,&bbNullObject);
		(openb3d_openb3dex_TDebug_debug_mesh)->clas->m_EntityColor_fff(openb3d_openb3dex_TDebug_debug_mesh,255.000000f,0.000000000f,0.000000000f);
		(openb3d_openb3dex_TDebug_debug_mesh)->clas->m_EntityAlpha_f(openb3d_openb3dex_TDebug_debug_mesh,0.5f);
		(openb3d_openb3dex_TDebug_debug_mesh)->clas->m_EntityOrder_i(openb3d_openb3dex_TDebug_debug_mesh,-99);
	}else{
		(openb3d_openb3dex_TDebug_debug_surf)->clas->m_ClearSurface_ii(openb3d_openb3dex_TDebug_debug_surf,1,1);
	}
	if((openb3d_openb3dex_TDebug_show_ents==0) || (bbt_surf==&bbNullObject)){
		(openb3d_openb3dex_TDebug_debug_mesh)->clas->m_HideEntity(openb3d_openb3dex_TDebug_debug_mesh);
		return 0;
	}
	(openb3d_openb3dex_TDebug_debug_mesh)->clas->m_ShowEntity(openb3d_openb3dex_TDebug_debug_mesh);
	{
		BBINT bbt_tri=0;
		BBINT bbt_=(bbt_surf)->clas->m_CountTriangles(bbt_surf);
		for(bbt_tri;(bbt_tri<bbt_);bbt_tri=(bbt_tri+1)){
			BBARRAY bbt_v=bbArrayNew1D("i", 3);
			((BBINT*)BBARRAYDATA((bbt_v),(bbt_v)->dims))[0U]=(bbt_surf)->clas->m_TriangleVertex_ii(bbt_surf,bbt_tri,0);
			((BBINT*)BBARRAYDATA((bbt_v),(bbt_v)->dims))[1U]=(bbt_surf)->clas->m_TriangleVertex_ii(bbt_surf,bbt_tri,1);
			((BBINT*)BBARRAYDATA((bbt_v),(bbt_v)->dims))[2U]=(bbt_surf)->clas->m_TriangleVertex_ii(bbt_surf,bbt_tri,2);
			BBARRAY bbt_nv=bbArrayNew1D("i", 3);
			{
				BBINT bbt_i=0;
				for(bbt_i;(bbt_i<=2);bbt_i=(bbt_i+1)){
					BBFLOAT bbt_vx=(bbt_surf)->clas->m_VertexX_i(bbt_surf,((BBINT*)BBARRAYDATA((bbt_v),(bbt_v)->dims))[((BBUINT)bbt_i)]);
					BBFLOAT bbt_vy=(bbt_surf)->clas->m_VertexY_i(bbt_surf,((BBINT*)BBARRAYDATA((bbt_v),(bbt_v)->dims))[((BBUINT)bbt_i)]);
					BBFLOAT bbt_vz=(bbt_surf)->clas->m_VertexZ_i(bbt_surf,((BBINT*)BBARRAYDATA((bbt_v),(bbt_v)->dims))[((BBUINT)bbt_i)]);
					openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity(bbt_vx,bbt_vy,bbt_vz,bbt_ent,&bbNullObject);
					bbt_vx=openb3d_openb3dex_TEntity_TFormedX_f();
					bbt_vy=openb3d_openb3dex_TEntity_TFormedY_f();
					bbt_vz=openb3d_openb3dex_TEntity_TFormedZ_f();
					((BBINT*)BBARRAYDATA((bbt_nv),(bbt_nv)->dims))[((BBUINT)bbt_i)]=(openb3d_openb3dex_TDebug_debug_surf)->clas->m_AddVertex_ffffff(openb3d_openb3dex_TDebug_debug_surf,bbt_vx,bbt_vy,bbt_vz,0.000000000f,0.000000000f,0.000000000f);
				}
			}
			(openb3d_openb3dex_TDebug_debug_surf)->clas->m_AddTriangle_iii(openb3d_openb3dex_TDebug_debug_surf,((BBINT*)BBARRAYDATA((bbt_nv),(bbt_nv)->dims))[0U],((BBINT*)BBARRAYDATA((bbt_nv),(bbt_nv)->dims))[1U],((BBINT*)BBARRAYDATA((bbt_nv),(bbt_nv)->dims))[2U]);
		}
	}
	(openb3d_openb3dex_TDebug_debug_mesh)->clas->m_PositionMesh_fff(openb3d_openb3dex_TDebug_debug_mesh,0.000000000f,0.000000000f,0.000000000f);
	return 0;
}
BBINT openb3d_openb3dex_TDebug_UpdateMarker_i_TTEntityTTCamera(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TCamera_obj* bbt_cam){
	if(bbt_cam==&bbNullObject){
		return 0;
	}
	BBFLOAT bbt_x=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_x [0U];
	BBFLOAT bbt_y=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_y [0U];
	BBFLOAT bbt_z=((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_z [0U];
	bbt_x=(bbt_x+((((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_max_x [0U]-((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_x [0U])/2.0f));
	bbt_y=(bbt_y+((((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_max_y [0U]-((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_y [0U])/2.0f));
	bbt_z=(bbt_z+((((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_max_z [0U]-((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))->_openb3d_openb3dex_tmesh_min_z [0U])/2.0f));
	openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity(bbt_x,bbt_y,bbt_z,bbt_ent,&bbNullObject);
	bbt_x=openb3d_openb3dex_TEntity_TFormedX_f();
	bbt_y=openb3d_openb3dex_TEntity_TFormedY_f();
	bbt_z=openb3d_openb3dex_TEntity_TFormedZ_f();
	(bbt_cam)->clas->m_CameraProject_fff(bbt_cam,bbt_x,bbt_y,bbt_z);
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(((BBINT)openb3d_openb3dex_ProjectedX()),((BBINT)openb3d_openb3dex_ProjectedY()),&_s44);
	openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity(((BBFLOAT)((BBINT)(bbt_ent)->clas->m_EntityX_i(bbt_ent,1))),((BBFLOAT)((BBINT)(bbt_ent)->clas->m_EntityY_i(bbt_ent,1))),((BBFLOAT)((BBINT)(bbt_ent)->clas->m_EntityZ_i(bbt_ent,1))),bbt_ent,&bbNullObject);
	bbt_x=openb3d_openb3dex_TEntity_TFormedX_f();
	bbt_y=openb3d_openb3dex_TEntity_TFormedY_f();
	bbt_z=openb3d_openb3dex_TEntity_TFormedZ_f();
	(bbt_cam)->clas->m_CameraProject_fff(bbt_cam,bbt_x,bbt_y,bbt_z);
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(((BBINT)openb3d_openb3dex_ProjectedX()),((BBINT)openb3d_openb3dex_ProjectedY()),&_s45);
	return 0;
}
BBINT openb3d_openb3dex_TDebug_EntityInfo1_i_TTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,40,&_s46);
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,80,&_s47);
	BBFLOAT bbt_xx=0.000000000f;
	bbt_xx=(bbt_ent)->clas->m_EntityX_i(bbt_ent,1);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,100,bbStringConcat(&_s48,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityY_i(bbt_ent,1);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,120,bbStringConcat(&_s49,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityZ_i(bbt_ent,1);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,140,bbStringConcat(&_s50,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityPitch_i(bbt_ent,1);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,160,bbStringConcat(&_s51,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityYaw_i(bbt_ent,1);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,180,bbStringConcat(&_s52,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityRoll_i(bbt_ent,1);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,200,bbStringConcat(&_s53,bbStringFromFloat(bbt_xx)));
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,240,&_s54);
	bbt_xx=(bbt_ent)->clas->m_EntityX_i(bbt_ent,0);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,260,bbStringConcat(&_s48,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityY_i(bbt_ent,0);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,280,bbStringConcat(&_s49,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityZ_i(bbt_ent,0);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,300,bbStringConcat(&_s50,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityPitch_i(bbt_ent,0);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,320,bbStringConcat(&_s51,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityYaw_i(bbt_ent,0);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,340,bbStringConcat(&_s52,bbStringFromFloat(bbt_xx)));
	bbt_xx=(bbt_ent)->clas->m_EntityRoll_i(bbt_ent,0);
	if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
		bbt_xx=0.000000000f;
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,360,bbStringConcat(&_s53,bbStringFromFloat(bbt_xx)));
	BBINT bbt_tx=0;
	BBINT bbt_ty=380;
	{
		BBINT bbt_iy=0;
		for(bbt_iy;(bbt_iy<=3);bbt_iy=(bbt_iy+1)){
			bbt_tx=0;
			bbt_ty=(bbt_ty+20);
			{
				BBINT bbt_ix=0;
				for(bbt_ix;(bbt_ix<=3);bbt_ix=(bbt_ix+1)){
					bbt_xx=bbt_ent->_openb3d_openb3dex_tentity_mat ->_openb3d_openb3dex_tmatrix_grid [((BBUINT)((4*bbt_ix)+bbt_iy))];
					if((bbt_xx<0.0001f) && (bbt_xx>-0.0001f)){
						bbt_xx=0.000000000f;
					}
					openb3d_openb3dex_TBlitz2D_Text_i_iiS(bbt_tx,bbt_ty,bbStringFromFloat(bbt_xx));
					bbt_tx=(bbt_tx+100);
				}
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TDebug_EntityInfo2_i_TTEntityTTSurface(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	if(((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh))!=&bbNullObject){
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,40,&_s55);
		if(bbt_surf!=&bbNullObject){
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,80,bbStringConcat(bbStringConcat(bbStringConcat(&_s56,bbStringFromInt(openb3d_openb3dex_TDebug_surf_no)),&_s21),bbStringFromInt((((struct openb3d_openb3dex_TMesh_obj*)((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh)))->clas)->m_CountSurfaces((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh)))));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,100,bbStringConcat(bbStringConcat(bbStringConcat(&_s57,bbStringFromInt((bbt_surf)->clas->m_CountVertices(bbt_surf))),&_s21),bbStringFromInt((((struct openb3d_openb3dex_TMesh_obj*)((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh)))->clas)->m_CountVertices((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh)))));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,120,bbStringConcat(bbStringConcat(bbStringConcat(&_s58,bbStringFromInt((bbt_surf)->clas->m_CountTriangles(bbt_surf))),&_s21),bbStringFromInt((((struct openb3d_openb3dex_TMesh_obj*)((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh)))->clas)->m_CountTriangles((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh)))));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,160,bbStringConcat(&_s59,bbStringFromInt(bbt_surf->_openb3d_openb3dex_tsurface_alpha_enable [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,200,bbStringConcat(&_s60,bbStringFromInt(bbt_surf->_openb3d_openb3dex_tsurface_vmin [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,220,bbStringConcat(&_s61,bbStringFromInt(bbt_surf->_openb3d_openb3dex_tsurface_vmax [0U])));
		}else{
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,80,&_s62);
		}
	}else{
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,80,&_s63);
	}
	return 0;
}
BBINT openb3d_openb3dex_TDebug_EntityInfo3_i_TTEntityTTSurface(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,40,&_s64);
	if(bbt_surf!=&bbNullObject){
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,80,bbStringConcat(bbStringConcat(bbStringConcat(bbStringConcat(&_s56,bbStringFromInt(openb3d_openb3dex_TDebug_surf_no)),&_s21),bbStringFromInt((((struct openb3d_openb3dex_TMesh_obj*)((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh)))->clas)->m_CountSurfaces((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(bbt_ent,&openb3d_openb3dex_TMesh)))),&_s65));
		if(bbt_surf->_openb3d_openb3dex_tsurface_brush !=&bbNullObject){
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,100,bbStringConcat(&_s66,bbStringFromCString(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_name )));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,120,bbStringConcat(&_s67,bbStringFromFloat(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_red [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,140,bbStringConcat(&_s68,bbStringFromFloat(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_green [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,160,bbStringConcat(&_s69,bbStringFromFloat(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_blue [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,180,bbStringConcat(&_s70,bbStringFromFloat(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_alpha [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,200,bbStringConcat(&_s71,bbStringFromInt(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_blend [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,220,bbStringConcat(&_s72,bbStringFromInt(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_fx [0U])));
			if(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[0U]!=&bbNullObject){
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,240,bbStringConcat(&_s73,bbStringFromCString(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[0U]->_openb3d_openb3dex_ttexture_file )));
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,260,bbStringConcat(&_s74,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[0U]->_openb3d_openb3dex_ttexture_flags [0U])));
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,280,bbStringConcat(&_s75,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[0U]->_openb3d_openb3dex_ttexture_blend [0U])));
			}
			if(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[1U]!=&bbNullObject){
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,300,bbStringConcat(&_s76,bbStringFromCString(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[1U]->_openb3d_openb3dex_ttexture_file )));
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,320,bbStringConcat(&_s77,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[1U]->_openb3d_openb3dex_ttexture_flags [0U])));
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,340,bbStringConcat(&_s78,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[1U]->_openb3d_openb3dex_ttexture_blend [0U])));
			}
			if(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[2U]!=&bbNullObject){
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,360,bbStringConcat(&_s79,bbStringFromCString(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[2U]->_openb3d_openb3dex_ttexture_file )));
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,380,bbStringConcat(&_s80,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[2U]->_openb3d_openb3dex_ttexture_flags [0U])));
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,400,bbStringConcat(&_s81,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[2U]->_openb3d_openb3dex_ttexture_blend [0U])));
			}
			if(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[3U]!=&bbNullObject){
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,420,bbStringConcat(&_s82,bbStringFromCString(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[3U]->_openb3d_openb3dex_ttexture_file )));
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,440,bbStringConcat(&_s83,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[3U]->_openb3d_openb3dex_ttexture_flags [0U])));
				openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,460,bbStringConcat(&_s84,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_surf->_openb3d_openb3dex_tsurface_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[3U]->_openb3d_openb3dex_ttexture_blend [0U])));
			}
		}else{
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,100,&_s85);
		}
	}else{
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,100,&_s62);
	}
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,80,&_s86);
	if(bbt_ent->_openb3d_openb3dex_tentity_brush !=&bbNullObject){
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,100,bbStringConcat(&_s66,bbStringFromCString(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_name )));
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,120,bbStringConcat(&_s67,bbStringFromFloat(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_red [0U])));
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,140,bbStringConcat(&_s68,bbStringFromFloat(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_green [0U])));
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,160,bbStringConcat(&_s69,bbStringFromFloat(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_blue [0U])));
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,180,bbStringConcat(&_s70,bbStringFromFloat(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_alpha [0U])));
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,200,bbStringConcat(&_s71,bbStringFromInt(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_blend [0U])));
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,220,bbStringConcat(&_s72,bbStringFromInt(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_fx [0U])));
		if(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[0U]!=&bbNullObject){
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,240,bbStringConcat(&_s73,bbStringFromCString(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[0U]->_openb3d_openb3dex_ttexture_file )));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,160,bbStringConcat(&_s74,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[0U]->_openb3d_openb3dex_ttexture_flags [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,280,bbStringConcat(&_s75,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[0U]->_openb3d_openb3dex_ttexture_blend [0U])));
		}
		if(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[1U]!=&bbNullObject){
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,300,bbStringConcat(&_s76,bbStringFromCString(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[1U]->_openb3d_openb3dex_ttexture_file )));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,320,bbStringConcat(&_s77,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[1U]->_openb3d_openb3dex_ttexture_flags [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,340,bbStringConcat(&_s78,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[1U]->_openb3d_openb3dex_ttexture_blend [0U])));
		}
		if(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[2U]!=&bbNullObject){
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,360,bbStringConcat(&_s79,bbStringFromCString(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[2U]->_openb3d_openb3dex_ttexture_file )));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,380,bbStringConcat(&_s80,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[2U]->_openb3d_openb3dex_ttexture_flags [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,400,bbStringConcat(&_s81,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[2U]->_openb3d_openb3dex_ttexture_blend [0U])));
		}
		if(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[3U]!=&bbNullObject){
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,420,bbStringConcat(&_s82,bbStringFromCString(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[3U]->_openb3d_openb3dex_ttexture_file )));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,440,bbStringConcat(&_s83,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[3U]->_openb3d_openb3dex_ttexture_flags [0U])));
			openb3d_openb3dex_TBlitz2D_Text_i_iiS(200,460,bbStringConcat(&_s84,bbStringFromInt(((struct openb3d_openb3dex_TTexture_obj**)BBARRAYDATA((bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex ),(bbt_ent->_openb3d_openb3dex_tentity_brush ->_openb3d_openb3dex_tbrush_tex )->dims))[3U]->_openb3d_openb3dex_ttexture_blend [0U])));
		}
	}else{
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,100,&_s85);
	}
	return 0;
}
BBINT openb3d_openb3dex_TDebug_EntityInfo4_i_TTEntityTTCamera(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TCamera_obj* bbt_cam){
	openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,40,&_s87);
	if(bbt_cam!=&bbNullObject){
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,80,bbStringConcat(&_s88,bbStringFromInt((bbt_cam)->clas->m_EntityInView_TTEntity(bbt_cam,bbt_ent))));
	}else{
		openb3d_openb3dex_TBlitz2D_Text_i_iiS(0,80,&_s89);
	}
	return 0;
}
BBINT openb3d_openb3dex_TDebug_cno;
BBINT openb3d_openb3dex_TDebug_surf_no;
BBINT openb3d_openb3dex_TDebug_info;
BBINT openb3d_openb3dex_TDebug_show_ents;
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TDebug_bounding_sphere;
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TDebug_debug_mesh;
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_TDebug_debug_surf;
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_TDebug_marker;
struct BBDebugScope_18 openb3d_openb3dex_TDebug_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TDebug",
	{
		{
			BBDEBUGDECL_GLOBAL,
			"cno",
			"i",
			&openb3d_openb3dex_TDebug_cno
		},
		{
			BBDEBUGDECL_GLOBAL,
			"surf_no",
			"i",
			&openb3d_openb3dex_TDebug_surf_no
		},
		{
			BBDEBUGDECL_GLOBAL,
			"info",
			"i",
			&openb3d_openb3dex_TDebug_info
		},
		{
			BBDEBUGDECL_GLOBAL,
			"show_ents",
			"i",
			&openb3d_openb3dex_TDebug_show_ents
		},
		{
			BBDEBUGDECL_GLOBAL,
			"bounding_sphere",
			":TMesh",
			&openb3d_openb3dex_TDebug_bounding_sphere
		},
		{
			BBDEBUGDECL_GLOBAL,
			"debug_mesh",
			":TMesh",
			&openb3d_openb3dex_TDebug_debug_mesh
		},
		{
			BBDEBUGDECL_GLOBAL,
			"debug_surf",
			":TSurface",
			&openb3d_openb3dex_TDebug_debug_surf
		},
		{
			BBDEBUGDECL_GLOBAL,
			"marker",
			":TMesh",
			&openb3d_openb3dex_TDebug_marker
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TDebug_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"DebugWorld",
			"()i",
			&openb3d_openb3dex_TDebug_DebugWorld_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"DebugEntity",
			"(:TEntity,:TCamera):TEntity",
			&openb3d_openb3dex_TDebug_DebugEntity_TTEntity_TTEntityTTCamera
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UpdateBoundingSphere",
			"(:TEntity)i",
			&openb3d_openb3dex_TDebug_UpdateBoundingSphere_i_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UpdateSurface",
			"(:TEntity,:TSurface)i",
			&openb3d_openb3dex_TDebug_UpdateSurface_i_TTEntityTTSurface
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UpdateMarker",
			"(:TEntity,:TCamera)i",
			&openb3d_openb3dex_TDebug_UpdateMarker_i_TTEntityTTCamera
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"EntityInfo1",
			"(:TEntity)i",
			&openb3d_openb3dex_TDebug_EntityInfo1_i_TTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"EntityInfo2",
			"(:TEntity,:TSurface)i",
			&openb3d_openb3dex_TDebug_EntityInfo2_i_TTEntityTTSurface
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"EntityInfo3",
			"(:TEntity,:TSurface)i",
			&openb3d_openb3dex_TDebug_EntityInfo3_i_TTEntityTTSurface
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"EntityInfo4",
			"(:TEntity,:TCamera)i",
			&openb3d_openb3dex_TDebug_EntityInfo4_i_TTEntityTTCamera
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TDebug openb3d_openb3dex_TDebug={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TDebug_scope,
	sizeof(struct openb3d_openb3dex_TDebug_obj),
	_openb3d_openb3dex_TDebug_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,openb3d_openb3dex_TDebug_DebugWorld_i
	,openb3d_openb3dex_TDebug_DebugEntity_TTEntity_TTEntityTTCamera
	,openb3d_openb3dex_TDebug_UpdateBoundingSphere_i_TTEntity
	,openb3d_openb3dex_TDebug_UpdateSurface_i_TTEntityTTSurface
	,openb3d_openb3dex_TDebug_UpdateMarker_i_TTEntityTTCamera
	,openb3d_openb3dex_TDebug_EntityInfo1_i_TTEntity
	,openb3d_openb3dex_TDebug_EntityInfo2_i_TTEntityTTSurface
	,openb3d_openb3dex_TDebug_EntityInfo3_i_TTEntityTTSurface
	,openb3d_openb3dex_TDebug_EntityInfo4_i_TTEntityTTCamera
};

void _openb3d_openb3dex_TTerrain_New(struct openb3d_openb3dex_TTerrain_obj* o) {
	_openb3d_openb3dex_TEntity_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TTerrain;
	o->_openb3d_openb3dex_tterrain_size = 0;
	o->_openb3d_openb3dex_tterrain_vsize = 0;
	o->_openb3d_openb3dex_tterrain_level2dzsize = 0;
	o->_openb3d_openb3dex_tterrain_height = 0;
	o->_openb3d_openb3dex_tterrain_eyepoint = &bbNullObject;
	o->_openb3d_openb3dex_tterrain_shadermat = &bbNullObject;
}
void _openb3d_openb3dex_TTerrain_Delete(struct openb3d_openb3dex_TTerrain_obj* o) {
	_openb3d_openb3dex_TEntity_Delete(o);
}
struct openb3d_openb3dex_TTerrain_obj* openb3d_openb3dex_TTerrain_CreateObject_TTTerrain_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TTerrain_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TTerrain);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TTerrain_InitGlobals_i(){
	openb3d_openb3dex_TTerrain_triangleindex=StaticInt(51,2);
	return 0;
}
BBINT _openb3d_openb3dex_TTerrain_InitFields(struct openb3d_openb3dex_TTerrain_obj* o){
	(&openb3d_openb3dex_TTerrain)->super->m_InitFields(o);
	o->_openb3d_openb3dex_tterrain_size =TerrainFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),4);
	o->_openb3d_openb3dex_tterrain_vsize =TerrainFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),5);
	o->_openb3d_openb3dex_tterrain_level2dzsize =TerrainFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),6);
	o->_openb3d_openb3dex_tterrain_height =TerrainFloat(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),7);
	BBBYTE* bbt_inst=TerrainCamera(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),9);
	o->_openb3d_openb3dex_tterrain_eyepoint =((struct openb3d_openb3dex_TCamera_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TCamera));
	bbt_inst=TerrainShader(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),10);
	o->_openb3d_openb3dex_tterrain_shadermat =openb3d_openb3dex_TShader_GetObject_TTShader_pb(bbt_inst);
	o->clas->f_AddList__i_TTList(openb3d_openb3dex_TTerrain_terrain_list);
	return 0;
}
BBINT openb3d_openb3dex_TTerrain_AddList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	openb3d_openb3dex_TEntity_AddList__i_TTList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TTerrain_terrain_list){
		if(StaticListSize(51,1)!=0){
			BBBYTE* bbt_inst=StaticIterListTerrain(51,1,(&openb3d_openb3dex_TTerrain_terrain_list_id));
			struct openb3d_openb3dex_TTerrain_obj* volatile bbt_obj=((struct openb3d_openb3dex_TTerrain_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TTerrain));
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TTerrain_CopyList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	openb3d_openb3dex_TEntity_CopyList__i_TTList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TTerrain_terrain_list){
		openb3d_openb3dex_TTerrain_terrain_list_id=0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(StaticListSize(51,1)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=StaticIterListTerrain(51,1,(&openb3d_openb3dex_TTerrain_terrain_list_id));
				struct openb3d_openb3dex_TTerrain_obj* volatile bbt_obj=((struct openb3d_openb3dex_TTerrain_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TTerrain));
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TTerrain_FreeEntity(struct openb3d_openb3dex_TTerrain_obj* o){
	if(o->_openb3d_openb3dex_tentity_exists !=0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TTerrain_terrain_list,o);
		openb3d_openb3dex_TTerrain_terrain_list_id-=1;
		(&openb3d_openb3dex_TTerrain)->super->m_FreeEntity(o);
	}
	return 0;
}
struct openb3d_openb3dex_TTerrain_obj* openb3d_openb3dex_TTerrain_CreateTerrain_TTTerrain_iTTEntity(BBINT bbt_size,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateTerrain(bbt_size,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TTerrain_CreateObject_TTTerrain_pb(bbt_inst);
}
struct openb3d_openb3dex_TTerrain_obj* openb3d_openb3dex_TTerrain_LoadTerrain_TTTerrain_STTEntity(BBSTRING bbt_file,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_cString=bbStringToCString(bbt_file);
	BBBYTE* bbt_inst=LoadTerrain(bbt_cString,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TTerrain_obj* volatile bbt_terr=openb3d_openb3dex_TTerrain_CreateObject_TTTerrain_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	return bbt_terr;
}
BBINT _openb3d_openb3dex_TTerrain_ModifyTerrain_iif(struct openb3d_openb3dex_TTerrain_obj* o,BBINT bbt_x,BBINT bbt_z,BBFLOAT bbt_new_height){
	ModifyTerrain(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_z,bbt_new_height);
	return 0;
}
BBFLOAT _openb3d_openb3dex_TTerrain_TerrainHeight_ii(struct openb3d_openb3dex_TTerrain_obj* o,BBINT bbt_x,BBINT bbt_z){
	return TerrainHeight(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_z);
}
BBFLOAT _openb3d_openb3dex_TTerrain_TerrainX_fff(struct openb3d_openb3dex_TTerrain_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	return TerrainX(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_y,bbt_z);
}
BBFLOAT _openb3d_openb3dex_TTerrain_TerrainY_fff(struct openb3d_openb3dex_TTerrain_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	return TerrainY(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_y,bbt_z);
}
BBFLOAT _openb3d_openb3dex_TTerrain_TerrainZ_fff(struct openb3d_openb3dex_TTerrain_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	return TerrainZ(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_y,bbt_z);
}
struct openb3d_openb3dex_TTerrain_obj* _openb3d_openb3dex_TTerrain_CopyEntity_TTEntity(struct openb3d_openb3dex_TTerrain_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TTerrain_obj* volatile bbt_terr=o->clas->f_CreateObject_TTTerrain_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_terr;
}
BBINT _openb3d_openb3dex_TTerrain_Update(struct openb3d_openb3dex_TTerrain_obj* o){
	return 0;
}
BBINT _openb3d_openb3dex_TTerrain_UpdateTerrain(struct openb3d_openb3dex_TTerrain_obj* o){
	UpdateTerrain(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TTerrain_RecreateROAM(struct openb3d_openb3dex_TTerrain_obj* o){
	RecreateROAM(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TTerrain_drawsub_iafafaf(struct openb3d_openb3dex_TTerrain_obj* o,BBINT bbt_l,BBARRAY bbt_v0,BBARRAY bbt_v1,BBARRAY bbt_v2){
	drawsub(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_l,((BBFLOAT*)BBARRAYDATA(bbt_v0,bbt_v0->dims)),((BBFLOAT*)BBARRAYDATA(bbt_v1,bbt_v1->dims)),((BBFLOAT*)BBARRAYDATA(bbt_v2,bbt_v2->dims)));
	return 0;
}
BBINT _openb3d_openb3dex_TTerrain_UpdateNormals(struct openb3d_openb3dex_TTerrain_obj* o){
	TerrainUpdateNormals(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT _openb3d_openb3dex_TTerrain_col_tree_sub_iafafaf(struct openb3d_openb3dex_TTerrain_obj* o,BBINT bbt_l,BBARRAY bbt_v0,BBARRAY bbt_v1,BBARRAY bbt_v2){
	col_tree_sub(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_l,((BBFLOAT*)BBARRAYDATA(bbt_v0,bbt_v0->dims)),((BBFLOAT*)BBARRAYDATA(bbt_v1,bbt_v1->dims)),((BBFLOAT*)BBARRAYDATA(bbt_v2,bbt_v2->dims)));
	return 0;
}
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TTerrain_terrain_list;
BBINT openb3d_openb3dex_TTerrain_terrain_list_id;
BBINT* openb3d_openb3dex_TTerrain_triangleindex;
struct BBDebugScope_30 openb3d_openb3dex_TTerrain_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TTerrain",
	{
		{
			BBDEBUGDECL_FIELD,
			"size",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTerrain_obj,_openb3d_openb3dex_tterrain_size)
		},
		{
			BBDEBUGDECL_FIELD,
			"vsize",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTerrain_obj,_openb3d_openb3dex_tterrain_vsize)
		},
		{
			BBDEBUGDECL_FIELD,
			"level2dzsize",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTerrain_obj,_openb3d_openb3dex_tterrain_level2dzsize)
		},
		{
			BBDEBUGDECL_FIELD,
			"height",
			"*f",
			.field_offset=offsetof(struct openb3d_openb3dex_TTerrain_obj,_openb3d_openb3dex_tterrain_height)
		},
		{
			BBDEBUGDECL_FIELD,
			"eyepoint",
			":TCamera",
			.field_offset=offsetof(struct openb3d_openb3dex_TTerrain_obj,_openb3d_openb3dex_tterrain_eyepoint)
		},
		{
			BBDEBUGDECL_FIELD,
			"ShaderMat",
			":TShader",
			.field_offset=offsetof(struct openb3d_openb3dex_TTerrain_obj,_openb3d_openb3dex_tterrain_shadermat)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"terrain_list",
			":TList",
			&openb3d_openb3dex_TTerrain_terrain_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"triangleindex",
			"*i",
			&openb3d_openb3dex_TTerrain_triangleindex
		},
		{
			BBDEBUGDECL_GLOBAL,
			"terrain_list_id",
			"i",
			&openb3d_openb3dex_TTerrain_terrain_list_id
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TTerrain_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TTerrain",
			&openb3d_openb3dex_TTerrain_CreateObject_TTTerrain_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"InitGlobals",
			"()i",
			&openb3d_openb3dex_TTerrain_InitGlobals_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TTerrain_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AddList_",
			"(:TList)i",
			&openb3d_openb3dex_TTerrain_AddList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList_",
			"(:TList)i",
			&openb3d_openb3dex_TTerrain_CopyList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeEntity",
			"()i",
			&_openb3d_openb3dex_TTerrain_FreeEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateTerrain",
			"(i,:TEntity):TTerrain",
			&openb3d_openb3dex_TTerrain_CreateTerrain_TTTerrain_iTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadTerrain",
			"($,:TEntity):TTerrain",
			&openb3d_openb3dex_TTerrain_LoadTerrain_TTTerrain_STTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ModifyTerrain",
			"(i,i,f)i",
			&_openb3d_openb3dex_TTerrain_ModifyTerrain_iif
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TerrainHeight",
			"(i,i)f",
			&_openb3d_openb3dex_TTerrain_TerrainHeight_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TerrainX",
			"(f,f,f)f",
			&_openb3d_openb3dex_TTerrain_TerrainX_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TerrainY",
			"(f,f,f)f",
			&_openb3d_openb3dex_TTerrain_TerrainY_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"TerrainZ",
			"(f,f,f)f",
			&_openb3d_openb3dex_TTerrain_TerrainZ_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TTerrain",
			&_openb3d_openb3dex_TTerrain_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Update",
			"()i",
			&_openb3d_openb3dex_TTerrain_Update
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateTerrain",
			"()i",
			&_openb3d_openb3dex_TTerrain_UpdateTerrain
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RecreateROAM",
			"()i",
			&_openb3d_openb3dex_TTerrain_RecreateROAM
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"drawsub",
			"(i,[]f,[]f,[]f)i",
			&_openb3d_openb3dex_TTerrain_drawsub_iafafaf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateNormals",
			"()i",
			&_openb3d_openb3dex_TTerrain_UpdateNormals
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"col_tree_sub",
			"(i,[]f,[]f,[]f)i",
			&_openb3d_openb3dex_TTerrain_col_tree_sub_iafafaf
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TTerrain openb3d_openb3dex_TTerrain={
	&openb3d_openb3dex_TEntity,
	bbObjectFree,
	&openb3d_openb3dex_TTerrain_scope,
	sizeof(struct openb3d_openb3dex_TTerrain_obj),
	_openb3d_openb3dex_TTerrain_New,
	_openb3d_openb3dex_TTerrain_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TTerrain_obj,_openb3d_openb3dex_tterrain_shadermat) - sizeof(void*) + sizeof(struct openb3d_openb3dex_TShader_obj*)
	,_openb3d_openb3dex_TTerrain_CopyEntity_TTEntity
	,_openb3d_openb3dex_TTerrain_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TTerrain_InitGlobals_i
	,_openb3d_openb3dex_TTerrain_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TTerrain_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TTerrain_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TTerrain_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TTerrain_CreateObject_TTTerrain_pb
	,openb3d_openb3dex_TTerrain_CreateTerrain_TTTerrain_iTTEntity
	,openb3d_openb3dex_TTerrain_LoadTerrain_TTTerrain_STTEntity
	,_openb3d_openb3dex_TTerrain_ModifyTerrain_iif
	,_openb3d_openb3dex_TTerrain_TerrainHeight_ii
	,_openb3d_openb3dex_TTerrain_TerrainX_fff
	,_openb3d_openb3dex_TTerrain_TerrainY_fff
	,_openb3d_openb3dex_TTerrain_TerrainZ_fff
	,_openb3d_openb3dex_TTerrain_UpdateTerrain
	,_openb3d_openb3dex_TTerrain_RecreateROAM
	,_openb3d_openb3dex_TTerrain_drawsub_iafafaf
	,_openb3d_openb3dex_TTerrain_UpdateNormals
	,_openb3d_openb3dex_TTerrain_col_tree_sub_iafafaf
};

void _openb3d_openb3dex_TMaterial_New(struct openb3d_openb3dex_TMaterial_obj* o) {
	_openb3d_openb3dex_TTexture_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TMaterial;
}
void _openb3d_openb3dex_TMaterial_Delete(struct openb3d_openb3dex_TMaterial_obj* o) {
	_openb3d_openb3dex_TTexture_Delete(o);
}
struct openb3d_openb3dex_TMaterial_obj* openb3d_openb3dex_TMaterial_CreateObject_TTMaterial_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TMaterial_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TMaterial);
	(openb3d_openb3dex_TTexture_tex_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TTexture_tex_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_ttexture_instance =bbt_inst;
	return bbt_obj;
}
struct openb3d_openb3dex_TMaterial_obj* openb3d_openb3dex_TMaterial_LoadMaterial_TTMaterial_Siiiii(BBSTRING bbt_filename,BBINT bbt_flags,BBINT bbt_frame_width,BBINT bbt_frame_height,BBINT bbt_first_frame,BBINT bbt_frame_count){
	BBBYTE* bbt_cString=bbStringToCString(bbt_filename);
	BBBYTE* bbt_inst=LoadMaterial(bbt_cString,bbt_flags,bbt_frame_width,bbt_frame_height,bbt_first_frame,bbt_frame_count);
	struct openb3d_openb3dex_TMaterial_obj* volatile bbt_mat=openb3d_openb3dex_TMaterial_CreateObject_TTMaterial_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	return bbt_mat;
}
struct BBDebugScope_3 openb3d_openb3dex_TMaterial_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TMaterial",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TMaterial_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TMaterial",
			&openb3d_openb3dex_TMaterial_CreateObject_TTMaterial_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadMaterial",
			"($,i,i,i,i,i):TMaterial",
			&openb3d_openb3dex_TMaterial_LoadMaterial_TTMaterial_Siiiii
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TMaterial openb3d_openb3dex_TMaterial={
	&openb3d_openb3dex_TTexture,
	bbObjectFree,
	&openb3d_openb3dex_TMaterial_scope,
	sizeof(struct openb3d_openb3dex_TMaterial_obj),
	_openb3d_openb3dex_TMaterial_New,
	_openb3d_openb3dex_TMaterial_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,openb3d_openb3dex_TMaterial_CreateObject_TTMaterial_pb
	,openb3d_openb3dex_TTexture_FreeObject_i_pb
	,openb3d_openb3dex_TTexture_GetObject_TTTexture_pb
	,openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture
	,_openb3d_openb3dex_TTexture_InitFields
	,openb3d_openb3dex_TTexture_AddList__i_TTList
	,openb3d_openb3dex_TTexture_CopyList__i_TTList
	,_openb3d_openb3dex_TTexture_BufferToTex_pbi
	,_openb3d_openb3dex_TTexture_TexToBuffer_pbi
	,_openb3d_openb3dex_TTexture_CameraToTex_TTCamerai
	,_openb3d_openb3dex_TTexture_DepthBufferToTex_TTCamera
	,_openb3d_openb3dex_TTexture_FreeTexture
	,openb3d_openb3dex_TTexture_CreateTexture_TTTexture_iiii
	,openb3d_openb3dex_TTexture_LoadTexture_TTTexture_Si
	,openb3d_openb3dex_TTexture_LoadAnimTexture_TTTexture_Siiiii
	,_openb3d_openb3dex_TTexture_TextureBlend_i
	,_openb3d_openb3dex_TTexture_TextureCoords_i
	,_openb3d_openb3dex_TTexture_ScaleTexture_ff
	,_openb3d_openb3dex_TTexture_PositionTexture_ff
	,_openb3d_openb3dex_TTexture_RotateTexture_f
	,_openb3d_openb3dex_TTexture_TextureWidth
	,_openb3d_openb3dex_TTexture_TextureHeight
	,_openb3d_openb3dex_TTexture_TextureName
	,openb3d_openb3dex_TTexture_GetBrushTexture_TTTexture_TTBrushi
	,openb3d_openb3dex_TTexture_ClearTextureFilters_i
	,openb3d_openb3dex_TTexture_TextureFilter_i_Si
	,_openb3d_openb3dex_TTexture_SetCubeFace_i
	,_openb3d_openb3dex_TTexture_SetCubeMode_i
	,_openb3d_openb3dex_TTexture_BackBufferToTex_i
	,_openb3d_openb3dex_TTexture_Copy
	,_openb3d_openb3dex_TTexture_TexInList
	,_openb3d_openb3dex_TTexture_FilterFlags
	,openb3d_openb3dex_TTexture_FileFind_i_vS
	,openb3d_openb3dex_TTexture_FileAbs_S_S
	,openb3d_openb3dex_TTexture_AdjustPixmap_TTPixmap_TTPixmap
	,openb3d_openb3dex_TTexture_Pow2Size_i_i
	,openb3d_openb3dex_TTexture_ApplyAlpha_TTPixmap_TTPixmap
	,_openb3d_openb3dex_TTexture_CameraToTexEXT_TTCamerai
	,_openb3d_openb3dex_TTexture_DepthBufferToTexEXT_TTCamerai
	,openb3d_openb3dex_TTexture_LoadTextureAlpha_TTTexture_Sii
	,_openb3d_openb3dex_TTexture_TextureFlags_i
	,openb3d_openb3dex_TMaterial_LoadMaterial_TTMaterial_Siiiii
};

void _openb3d_openb3dex_TShader_New(struct openb3d_openb3dex_TShader_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TShader;
	o->_openb3d_openb3dex_tshader_instance = 0;
}
struct openb3d_openb3dex_TShader_obj* openb3d_openb3dex_TShader_CreateObject_TTShader_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TShader_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TShader);
	(openb3d_openb3dex_TShader_shader_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TShader_shader_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tshader_instance =bbt_inst;
	return bbt_obj;
}
BBINT openb3d_openb3dex_TShader_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TShader_shader_map)->clas->m_Remove_TObject(openb3d_openb3dex_TShader_shader_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TShader_obj* openb3d_openb3dex_TShader_GetObject_TTShader_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TShader_obj*)bbObjectDowncast((openb3d_openb3dex_TShader_shader_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TShader_shader_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TShader));
}
BBBYTE* openb3d_openb3dex_TShader_GetInstance_pb_TTShader(struct openb3d_openb3dex_TShader_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tshader_instance ;
}
struct openb3d_openb3dex_TShader_obj* openb3d_openb3dex_TShader_LoadShader_TTShader_SSS(BBSTRING bbt_ShaderName,BBSTRING bbt_VshaderFileName,BBSTRING bbt_FshaderFileName){
	BBBYTE* bbt_cString=bbStringToCString(bbt_ShaderName);
	BBBYTE* bbt_vcString=bbStringToCString(bbt_VshaderFileName);
	BBBYTE* bbt_fcString=bbStringToCString(bbt_FshaderFileName);
	BBBYTE* bbt_inst=LoadShader(bbt_cString,bbt_vcString,bbt_fcString);
	struct openb3d_openb3dex_TShader_obj* volatile bbt_material=openb3d_openb3dex_TShader_CreateObject_TTShader_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	bbMemFree((void*)bbt_vcString);
	bbMemFree((void*)bbt_fcString);
	return bbt_material;
}
struct openb3d_openb3dex_TShader_obj* openb3d_openb3dex_TShader_CreateShader_TTShader_SSS(BBSTRING bbt_ShaderName,BBSTRING bbt_VshaderString,BBSTRING bbt_FshaderString){
	BBBYTE* bbt_cString=bbStringToCString(bbt_ShaderName);
	BBBYTE* bbt_vcString=bbStringToCString(bbt_VshaderString);
	BBBYTE* bbt_fcString=bbStringToCString(bbt_FshaderString);
	BBBYTE* bbt_inst=CreateShader(bbt_cString,bbt_vcString,bbt_fcString);
	struct openb3d_openb3dex_TShader_obj* volatile bbt_material=openb3d_openb3dex_TShader_CreateObject_TTShader_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	bbMemFree((void*)bbt_vcString);
	bbMemFree((void*)bbt_fcString);
	return bbt_material;
}
BBINT _openb3d_openb3dex_TShader_ShadeSurface_TTSurface(struct openb3d_openb3dex_TShader_obj* o,struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	ShadeSurface(openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf),o->clas->f_GetInstance_pb_TTShader(o));
	return 0;
}
BBINT _openb3d_openb3dex_TShader_ShadeMesh_TTMesh(struct openb3d_openb3dex_TShader_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	ShadeMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)),o->clas->f_GetInstance_pb_TTShader(o));
	return 0;
}
BBINT _openb3d_openb3dex_TShader_ShadeEntity_TTEntity(struct openb3d_openb3dex_TShader_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	ShadeEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),o->clas->f_GetInstance_pb_TTShader(o));
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* _openb3d_openb3dex_TShader_ShaderTexture_TTTextureSi(struct openb3d_openb3dex_TShader_obj* o,struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBSTRING bbt_name,BBINT bbt_index){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	BBBYTE* bbt_inst=ShaderTexture(o->clas->f_GetInstance_pb_TTShader(o),openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex),bbt_cString,bbt_index);
	bbMemFree((void*)bbt_cString);
	struct openb3d_openb3dex_TTexture_obj* volatile bbt_tex2=openb3d_openb3dex_TTexture_GetObject_TTTexture_pb(bbt_inst);
	if((bbt_tex2==&bbNullObject) && (bbt_inst!=0)){
		bbt_tex2=openb3d_openb3dex_TTexture_CreateObject_TTTexture_pb(bbt_inst);
	}
	return bbt_tex2;
}
BBINT _openb3d_openb3dex_TShader_SetFloat_Sf(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBFLOAT bbt_v1){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	SetFloat(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_v1);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_SetFloat2_Sff(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBFLOAT bbt_v1,BBFLOAT bbt_v2){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	SetFloat2(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_v1,bbt_v2);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_SetFloat3_Sfff(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBFLOAT bbt_v1,BBFLOAT bbt_v2,BBFLOAT bbt_v3){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	SetFloat3(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_v1,bbt_v2,bbt_v3);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_SetFloat4_Sffff(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBFLOAT bbt_v1,BBFLOAT bbt_v2,BBFLOAT bbt_v3,BBFLOAT bbt_v4){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	SetFloat4(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_v1,bbt_v2,bbt_v3,bbt_v4);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseFloat_Svf(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBFLOAT* bbt_v1){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseFloat(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,&(*bbt_v1));
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseFloat2_Svfvf(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBFLOAT* bbt_v1,BBFLOAT* bbt_v2){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseFloat2(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,&(*bbt_v1),&(*bbt_v2));
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseFloat3_Svfvfvf(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBFLOAT* bbt_v1,BBFLOAT* bbt_v2,BBFLOAT* bbt_v3){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseFloat3(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,&(*bbt_v1),&(*bbt_v2),&(*bbt_v3));
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseFloat4_Svfvfvfvf(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBFLOAT* bbt_v1,BBFLOAT* bbt_v2,BBFLOAT* bbt_v3,BBFLOAT* bbt_v4){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseFloat4(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,&(*bbt_v1),&(*bbt_v2),&(*bbt_v3),&(*bbt_v4));
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_SetInteger_Si(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT bbt_v1){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	SetInteger(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_v1);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_SetInteger2_Sii(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT bbt_v1,BBINT bbt_v2){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	SetInteger2(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_v1,bbt_v2);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_SetInteger3_Siii(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT bbt_v1,BBINT bbt_v2,BBINT bbt_v3){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	SetInteger3(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_v1,bbt_v2,bbt_v3);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_SetInteger4_Siiii(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT bbt_v1,BBINT bbt_v2,BBINT bbt_v3,BBINT bbt_v4){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	SetInteger4(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_v1,bbt_v2,bbt_v3,bbt_v4);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseInteger_Svi(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT* bbt_v1){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseInteger(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,&(*bbt_v1));
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseInteger2_Svivi(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT* bbt_v1,BBINT* bbt_v2){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseInteger2(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,&(*bbt_v1),&(*bbt_v2));
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseInteger3_Svivivi(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT* bbt_v1,BBINT* bbt_v2,BBINT* bbt_v3){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseInteger3(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,&(*bbt_v1),&(*bbt_v2),&(*bbt_v3));
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseInteger4_Svivivivi(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT* bbt_v1,BBINT* bbt_v2,BBINT* bbt_v3,BBINT* bbt_v4){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseInteger4(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,&(*bbt_v1),&(*bbt_v2),&(*bbt_v3),&(*bbt_v4));
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseSurface_STTSurfacei(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vbo){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseSurface(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf),bbt_vbo);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_UseMatrix_Si(struct openb3d_openb3dex_TShader_obj* o,BBSTRING bbt_name,BBINT bbt_Mode){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	UseMatrix(o->clas->f_GetInstance_pb_TTShader(o),bbt_cString,bbt_Mode);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_ShaderMaterial_TTMaterialSi(struct openb3d_openb3dex_TShader_obj* o,struct openb3d_openb3dex_TMaterial_obj* bbt_tex,BBSTRING bbt_name,BBINT bbt_index){
	BBBYTE* bbt_cString=bbStringToCString(bbt_name);
	ShaderMaterial(o->clas->f_GetInstance_pb_TTShader(o),openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture((struct openb3d_openb3dex_TTexture_obj*)bbObjectDowncast(bbt_tex,&openb3d_openb3dex_TTexture)),bbt_cString,bbt_index);
	bbMemFree((void*)bbt_cString);
	return 0;
}
BBINT _openb3d_openb3dex_TShader_AmbientShader(struct openb3d_openb3dex_TShader_obj* o){
	AmbientShader(o->clas->f_GetInstance_pb_TTShader(o));
	return 0;
}
BBINT _openb3d_openb3dex_TShader_FreeShader(struct openb3d_openb3dex_TShader_obj* o){
	FreeShader(o->clas->f_GetInstance_pb_TTShader(o));
	o->clas->f_FreeObject_i_pb(o->clas->f_GetInstance_pb_TTShader(o));
	return 0;
}
struct brl_map_TMap_obj* openb3d_openb3dex_TShader_shader_map;
struct BBDebugScope_34 openb3d_openb3dex_TShader_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TShader",
	{
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TShader_obj,_openb3d_openb3dex_tshader_instance)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"shader_map",
			":TMap",
			&openb3d_openb3dex_TShader_shader_map
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TShader_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TShader",
			&openb3d_openb3dex_TShader_CreateObject_TTShader_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TShader_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TShader",
			&openb3d_openb3dex_TShader_GetObject_TTShader_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TShader)*b",
			&openb3d_openb3dex_TShader_GetInstance_pb_TTShader
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadShader",
			"($,$,$):TShader",
			&openb3d_openb3dex_TShader_LoadShader_TTShader_SSS
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateShader",
			"($,$,$):TShader",
			&openb3d_openb3dex_TShader_CreateShader_TTShader_SSS
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ShadeSurface",
			"(:TSurface)i",
			&_openb3d_openb3dex_TShader_ShadeSurface_TTSurface
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ShadeMesh",
			"(:TMesh)i",
			&_openb3d_openb3dex_TShader_ShadeMesh_TTMesh
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ShadeEntity",
			"(:TEntity)i",
			&_openb3d_openb3dex_TShader_ShadeEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ShaderTexture",
			"(:TTexture,$,i):TTexture",
			&_openb3d_openb3dex_TShader_ShaderTexture_TTTextureSi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetFloat",
			"($,f)i",
			&_openb3d_openb3dex_TShader_SetFloat_Sf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetFloat2",
			"($,f,f)i",
			&_openb3d_openb3dex_TShader_SetFloat2_Sff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetFloat3",
			"($,f,f,f)i",
			&_openb3d_openb3dex_TShader_SetFloat3_Sfff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetFloat4",
			"($,f,f,f,f)i",
			&_openb3d_openb3dex_TShader_SetFloat4_Sffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseFloat",
			"($,f)i",
			&_openb3d_openb3dex_TShader_UseFloat_Svf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseFloat2",
			"($,f,f)i",
			&_openb3d_openb3dex_TShader_UseFloat2_Svfvf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseFloat3",
			"($,f,f,f)i",
			&_openb3d_openb3dex_TShader_UseFloat3_Svfvfvf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseFloat4",
			"($,f,f,f,f)i",
			&_openb3d_openb3dex_TShader_UseFloat4_Svfvfvfvf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetInteger",
			"($,i)i",
			&_openb3d_openb3dex_TShader_SetInteger_Si
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetInteger2",
			"($,i,i)i",
			&_openb3d_openb3dex_TShader_SetInteger2_Sii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetInteger3",
			"($,i,i,i)i",
			&_openb3d_openb3dex_TShader_SetInteger3_Siii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"SetInteger4",
			"($,i,i,i,i)i",
			&_openb3d_openb3dex_TShader_SetInteger4_Siiii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseInteger",
			"($,i)i",
			&_openb3d_openb3dex_TShader_UseInteger_Svi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseInteger2",
			"($,i,i)i",
			&_openb3d_openb3dex_TShader_UseInteger2_Svivi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseInteger3",
			"($,i,i,i)i",
			&_openb3d_openb3dex_TShader_UseInteger3_Svivivi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseInteger4",
			"($,i,i,i,i)i",
			&_openb3d_openb3dex_TShader_UseInteger4_Svivivivi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseSurface",
			"($,:TSurface,i)i",
			&_openb3d_openb3dex_TShader_UseSurface_STTSurfacei
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UseMatrix",
			"($,i)i",
			&_openb3d_openb3dex_TShader_UseMatrix_Si
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ShaderMaterial",
			"(:TMaterial,$,i)i",
			&_openb3d_openb3dex_TShader_ShaderMaterial_TTMaterialSi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AmbientShader",
			"()i",
			&_openb3d_openb3dex_TShader_AmbientShader
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeShader",
			"()i",
			&_openb3d_openb3dex_TShader_FreeShader
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TShader openb3d_openb3dex_TShader={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TShader_scope,
	sizeof(struct openb3d_openb3dex_TShader_obj),
	_openb3d_openb3dex_TShader_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TShader_obj,_openb3d_openb3dex_tshader_instance) - sizeof(void*) + sizeof(BBBYTE*)
	,openb3d_openb3dex_TShader_CreateObject_TTShader_pb
	,openb3d_openb3dex_TShader_FreeObject_i_pb
	,openb3d_openb3dex_TShader_GetObject_TTShader_pb
	,openb3d_openb3dex_TShader_GetInstance_pb_TTShader
	,openb3d_openb3dex_TShader_LoadShader_TTShader_SSS
	,openb3d_openb3dex_TShader_CreateShader_TTShader_SSS
	,_openb3d_openb3dex_TShader_ShadeSurface_TTSurface
	,_openb3d_openb3dex_TShader_ShadeMesh_TTMesh
	,_openb3d_openb3dex_TShader_ShadeEntity_TTEntity
	,_openb3d_openb3dex_TShader_ShaderTexture_TTTextureSi
	,_openb3d_openb3dex_TShader_SetFloat_Sf
	,_openb3d_openb3dex_TShader_SetFloat2_Sff
	,_openb3d_openb3dex_TShader_SetFloat3_Sfff
	,_openb3d_openb3dex_TShader_SetFloat4_Sffff
	,_openb3d_openb3dex_TShader_UseFloat_Svf
	,_openb3d_openb3dex_TShader_UseFloat2_Svfvf
	,_openb3d_openb3dex_TShader_UseFloat3_Svfvfvf
	,_openb3d_openb3dex_TShader_UseFloat4_Svfvfvfvf
	,_openb3d_openb3dex_TShader_SetInteger_Si
	,_openb3d_openb3dex_TShader_SetInteger2_Sii
	,_openb3d_openb3dex_TShader_SetInteger3_Siii
	,_openb3d_openb3dex_TShader_SetInteger4_Siiii
	,_openb3d_openb3dex_TShader_UseInteger_Svi
	,_openb3d_openb3dex_TShader_UseInteger2_Svivi
	,_openb3d_openb3dex_TShader_UseInteger3_Svivivi
	,_openb3d_openb3dex_TShader_UseInteger4_Svivivivi
	,_openb3d_openb3dex_TShader_UseSurface_STTSurfacei
	,_openb3d_openb3dex_TShader_UseMatrix_Si
	,_openb3d_openb3dex_TShader_ShaderMaterial_TTMaterialSi
	,_openb3d_openb3dex_TShader_AmbientShader
	,_openb3d_openb3dex_TShader_FreeShader
};

void _openb3d_openb3dex_TShadowObject_New(struct openb3d_openb3dex_TShadowObject_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TShadowObject;
	o->_openb3d_openb3dex_tshadowobject_parent = &bbNullObject;
	o->_openb3d_openb3dex_tshadowobject_cnt_tris = 0;
	o->_openb3d_openb3dex_tshadowobject_shadowmesh = &bbNullObject;
	o->_openb3d_openb3dex_tshadowobject_shadowvolume = &bbNullObject;
	o->_openb3d_openb3dex_tshadowobject_render = 0;
	o->_openb3d_openb3dex_tshadowobject_static = 0;
	o->_openb3d_openb3dex_tshadowobject_vcreated = 0;
	o->_openb3d_openb3dex_tshadowobject_instance = 0;
	o->_openb3d_openb3dex_tshadowobject_exists = 0;
}
struct openb3d_openb3dex_TShadowObject_obj* openb3d_openb3dex_TShadowObject_CreateObject_TTShadowObject_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TShadowObject_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TShadowObject);
	(openb3d_openb3dex_TShadowObject_shad_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TShadowObject_shad_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tshadowobject_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TShadowObject_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TShadowObject_shad_map)->clas->m_Remove_TObject(openb3d_openb3dex_TShadowObject_shad_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TShadowObject_obj* openb3d_openb3dex_TShadowObject_GetObject_TTShadowObject_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TShadowObject_obj*)bbObjectDowncast((openb3d_openb3dex_TShadowObject_shad_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TShadowObject_shad_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TShadowObject));
}
BBBYTE* openb3d_openb3dex_TShadowObject_GetInstance_pb_TTShadowObject(struct openb3d_openb3dex_TShadowObject_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tshadowobject_instance ;
}
BBINT openb3d_openb3dex_TShadowObject_InitGlobals_i(){
	openb3d_openb3dex_TShadowObject_VolumeLength=StaticFloat(46,9);
	openb3d_openb3dex_TShadowObject_top_caps=StaticChar(46,10);
	openb3d_openb3dex_TShadowObject_parallel=StaticInt(46,11);
	openb3d_openb3dex_TShadowObject_light_x=StaticFloat(46,12);
	openb3d_openb3dex_TShadowObject_light_y=StaticFloat(46,13);
	openb3d_openb3dex_TShadowObject_light_z=StaticFloat(46,14);
	openb3d_openb3dex_TShadowObject_midStencilVal=StaticInt(46,15);
	openb3d_openb3dex_TShadowObject_ShadowRed=StaticFloat(46,16);
	openb3d_openb3dex_TShadowObject_ShadowGreen=StaticFloat(46,17);
	openb3d_openb3dex_TShadowObject_ShadowBlue=StaticFloat(46,18);
	openb3d_openb3dex_TShadowObject_ShadowAlpha=StaticFloat(46,19);
	return 0;
}
BBINT _openb3d_openb3dex_TShadowObject_InitFields(struct openb3d_openb3dex_TShadowObject_obj* o){
	o->_openb3d_openb3dex_tshadowobject_render =ShadowObjectChar(o->clas->f_GetInstance_pb_TTShadowObject(o),6);
	o->_openb3d_openb3dex_tshadowobject_static =ShadowObjectChar(o->clas->f_GetInstance_pb_TTShadowObject(o),7);
	o->_openb3d_openb3dex_tshadowobject_vcreated =ShadowObjectChar(o->clas->f_GetInstance_pb_TTShadowObject(o),8);
	o->_openb3d_openb3dex_tshadowobject_cnt_tris =ShadowObjectInt(o->clas->f_GetInstance_pb_TTShadowObject(o),3);
	BBBYTE* bbt_inst=ShadowObjectMesh(o->clas->f_GetInstance_pb_TTShadowObject(o),2);
	o->_openb3d_openb3dex_tshadowobject_parent =((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TMesh));
	bbt_inst=ShadowObjectMesh(o->clas->f_GetInstance_pb_TTShadowObject(o),4);
	o->_openb3d_openb3dex_tshadowobject_shadowmesh =((struct openb3d_openb3dex_TMesh_obj*)bbObjectDowncast(openb3d_openb3dex_TEntity_GetObject_TTEntity_pb(bbt_inst),&openb3d_openb3dex_TMesh));
	if((o->_openb3d_openb3dex_tshadowobject_shadowmesh ==&bbNullObject) && (bbt_inst!=0)){
		o->_openb3d_openb3dex_tshadowobject_shadowmesh =openb3d_openb3dex_TMesh_CreateObject_TTMesh_pb(bbt_inst);
	}
	o->clas->f_AddList__i_TTList(openb3d_openb3dex_TShadowObject_shadow_list);
	o->_openb3d_openb3dex_tshadowobject_exists =1;
	return 0;
}
BBINT openb3d_openb3dex_TShadowObject_AddList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TShadowObject_shadow_list){
		if(StaticListSize(46,1)!=0){
			BBBYTE* bbt_inst=StaticIterListShadowObject(46,1,(&openb3d_openb3dex_TShadowObject_shadow_list_id));
			struct openb3d_openb3dex_TShadowObject_obj* volatile bbt_obj=openb3d_openb3dex_TShadowObject_GetObject_TTShadowObject_pb(bbt_inst);
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TShadowObject_CopyList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	brl_linkedlist_ClearList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TShadowObject_shadow_list){
		openb3d_openb3dex_TShadowObject_shadow_list_id=0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(StaticListSize(46,1)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=StaticIterListShadowObject(46,1,(&openb3d_openb3dex_TShadowObject_shadow_list_id));
				struct openb3d_openb3dex_TShadowObject_obj* volatile bbt_obj=openb3d_openb3dex_TShadowObject_GetObject_TTShadowObject_pb(bbt_inst);
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}
	return 0;
}
struct openb3d_openb3dex_TShadowObject_obj* openb3d_openb3dex_TShadowObject_CreateShadow_TTShadowObject_TTMeshi(struct openb3d_openb3dex_TMesh_obj* bbt_parent,BBINT bbt_Static){
	BBBYTE* bbt_inst=CreateShadow(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_parent,&openb3d_openb3dex_TEntity)),bbt_Static);
	return openb3d_openb3dex_TShadowObject_CreateObject_TTShadowObject_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TShadowObject_FreeShadow(struct openb3d_openb3dex_TShadowObject_obj* o){
	if(o->_openb3d_openb3dex_tshadowobject_exists !=0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TShadowObject_shadow_list,o);
		openb3d_openb3dex_TShadowObject_shadow_list_id-=1;
		brl_linkedlist_ListRemove(openb3d_openb3dex_TEntity_entity_list,o->_openb3d_openb3dex_tshadowobject_shadowmesh );
		openb3d_openb3dex_TEntity_entity_list_id-=1;
		openb3d_openb3dex_TEntity_FreeObject_i_pb(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o->_openb3d_openb3dex_tshadowobject_shadowmesh ,&openb3d_openb3dex_TEntity)));
		o->_openb3d_openb3dex_tshadowobject_shadowmesh =&bbNullObject;
		FreeShadow(o->clas->f_GetInstance_pb_TTShadowObject(o));
		o->clas->f_FreeObject_i_pb(o->clas->f_GetInstance_pb_TTShadowObject(o));
		o->_openb3d_openb3dex_tshadowobject_exists =0;
	}
	return 0;
}
BBINT openb3d_openb3dex_TShadowObject_ShadowInit_i(){
	ShadowInit();
	return 0;
}
BBINT _openb3d_openb3dex_TShadowObject_RemoveShadowfromMesh_TTMesh(struct openb3d_openb3dex_TShadowObject_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_M){
	RemoveShadowfromMesh(o->clas->f_GetInstance_pb_TTShadowObject(o),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_M,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT openb3d_openb3dex_TShadowObject_Update_i_TTCamera(struct openb3d_openb3dex_TCamera_obj* bbt_Cam){
	ShadowObjectUpdate(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_Cam,&openb3d_openb3dex_TEntity)));
	return 0;
}
BBINT openb3d_openb3dex_TShadowObject_RenderVolume_i(){
	RenderVolume();
	return 0;
}
BBINT _openb3d_openb3dex_TShadowObject_UpdateAnim(struct openb3d_openb3dex_TShadowObject_obj* o){
	UpdateAnim(o->clas->f_GetInstance_pb_TTShadowObject(o));
	return 0;
}
BBINT _openb3d_openb3dex_TShadowObject_Init(struct openb3d_openb3dex_TShadowObject_obj* o){
	ShadowObjectInit(o->clas->f_GetInstance_pb_TTShadowObject(o));
	return 0;
}
BBINT _openb3d_openb3dex_TShadowObject_InitShadow(struct openb3d_openb3dex_TShadowObject_obj* o){
	InitShadow(o->clas->f_GetInstance_pb_TTShadowObject(o));
	return 0;
}
BBINT _openb3d_openb3dex_TShadowObject_UpdateCaster(struct openb3d_openb3dex_TShadowObject_obj* o){
	UpdateCaster(o->clas->f_GetInstance_pb_TTShadowObject(o));
	return 0;
}
BBINT openb3d_openb3dex_TShadowObject_ShadowRenderWorldZFail_i(){
	ShadowRenderWorldZFail();
	return 0;
}
BBINT _openb3d_openb3dex_TShadowObject_ResetShadow(struct openb3d_openb3dex_TShadowObject_obj* o){
	o->_openb3d_openb3dex_tshadowobject_vcreated [0U]=0;
	return 0;
}
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TShadowObject_shadow_list;
BBINT openb3d_openb3dex_TShadowObject_shadow_list_id;
struct brl_map_TMap_obj* openb3d_openb3dex_TShadowObject_shad_map;
BBFLOAT* openb3d_openb3dex_TShadowObject_VolumeLength;
BBBYTE* openb3d_openb3dex_TShadowObject_top_caps;
BBINT* openb3d_openb3dex_TShadowObject_parallel;
BBFLOAT* openb3d_openb3dex_TShadowObject_light_x;
BBFLOAT* openb3d_openb3dex_TShadowObject_light_y;
BBFLOAT* openb3d_openb3dex_TShadowObject_light_z;
BBINT* openb3d_openb3dex_TShadowObject_midStencilVal;
BBFLOAT* openb3d_openb3dex_TShadowObject_ShadowRed;
BBFLOAT* openb3d_openb3dex_TShadowObject_ShadowGreen;
BBFLOAT* openb3d_openb3dex_TShadowObject_ShadowBlue;
BBFLOAT* openb3d_openb3dex_TShadowObject_ShadowAlpha;
struct BBDebugScope_44 openb3d_openb3dex_TShadowObject_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TShadowObject",
	{
		{
			BBDEBUGDECL_FIELD,
			"Parent",
			":TMesh",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_parent)
		},
		{
			BBDEBUGDECL_FIELD,
			"cnt_tris",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_cnt_tris)
		},
		{
			BBDEBUGDECL_FIELD,
			"ShadowMesh",
			":TMesh",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_shadowmesh)
		},
		{
			BBDEBUGDECL_FIELD,
			"ShadowVolume",
			":TSurface",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_shadowvolume)
		},
		{
			BBDEBUGDECL_FIELD,
			"Render",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_render)
		},
		{
			BBDEBUGDECL_FIELD,
			"Static",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_static)
		},
		{
			BBDEBUGDECL_FIELD,
			"VCreated",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_vcreated)
		},
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_instance)
		},
		{
			BBDEBUGDECL_FIELD,
			"exists",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_exists)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"shadow_list",
			":TList",
			&openb3d_openb3dex_TShadowObject_shadow_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"VolumeLength",
			"*f",
			&openb3d_openb3dex_TShadowObject_VolumeLength
		},
		{
			BBDEBUGDECL_GLOBAL,
			"top_caps",
			"*b",
			&openb3d_openb3dex_TShadowObject_top_caps
		},
		{
			BBDEBUGDECL_GLOBAL,
			"parallel",
			"*i",
			&openb3d_openb3dex_TShadowObject_parallel
		},
		{
			BBDEBUGDECL_GLOBAL,
			"light_x",
			"*f",
			&openb3d_openb3dex_TShadowObject_light_x
		},
		{
			BBDEBUGDECL_GLOBAL,
			"light_y",
			"*f",
			&openb3d_openb3dex_TShadowObject_light_y
		},
		{
			BBDEBUGDECL_GLOBAL,
			"light_z",
			"*f",
			&openb3d_openb3dex_TShadowObject_light_z
		},
		{
			BBDEBUGDECL_GLOBAL,
			"midStencilVal",
			"*i",
			&openb3d_openb3dex_TShadowObject_midStencilVal
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ShadowRed",
			"*f",
			&openb3d_openb3dex_TShadowObject_ShadowRed
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ShadowGreen",
			"*f",
			&openb3d_openb3dex_TShadowObject_ShadowGreen
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ShadowBlue",
			"*f",
			&openb3d_openb3dex_TShadowObject_ShadowBlue
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ShadowAlpha",
			"*f",
			&openb3d_openb3dex_TShadowObject_ShadowAlpha
		},
		{
			BBDEBUGDECL_GLOBAL,
			"shad_map",
			":TMap",
			&openb3d_openb3dex_TShadowObject_shad_map
		},
		{
			BBDEBUGDECL_GLOBAL,
			"shadow_list_id",
			"i",
			&openb3d_openb3dex_TShadowObject_shadow_list_id
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TShadowObject_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TShadowObject",
			&openb3d_openb3dex_TShadowObject_CreateObject_TTShadowObject_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TShadowObject_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TShadowObject",
			&openb3d_openb3dex_TShadowObject_GetObject_TTShadowObject_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TShadowObject)*b",
			&openb3d_openb3dex_TShadowObject_GetInstance_pb_TTShadowObject
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"InitGlobals",
			"()i",
			&openb3d_openb3dex_TShadowObject_InitGlobals_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TShadowObject_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AddList_",
			"(:TList)i",
			&openb3d_openb3dex_TShadowObject_AddList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList_",
			"(:TList)i",
			&openb3d_openb3dex_TShadowObject_CopyList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateShadow",
			"(:TMesh,i):TShadowObject",
			&openb3d_openb3dex_TShadowObject_CreateShadow_TTShadowObject_TTMeshi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeShadow",
			"()i",
			&_openb3d_openb3dex_TShadowObject_FreeShadow
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ShadowInit",
			"()i",
			&openb3d_openb3dex_TShadowObject_ShadowInit_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"RemoveShadowfromMesh",
			"(:TMesh)i",
			&_openb3d_openb3dex_TShadowObject_RemoveShadowfromMesh_TTMesh
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"Update",
			"(:TCamera)i",
			&openb3d_openb3dex_TShadowObject_Update_i_TTCamera
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"RenderVolume",
			"()i",
			&openb3d_openb3dex_TShadowObject_RenderVolume_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateAnim",
			"()i",
			&_openb3d_openb3dex_TShadowObject_UpdateAnim
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Init",
			"()i",
			&_openb3d_openb3dex_TShadowObject_Init
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitShadow",
			"()i",
			&_openb3d_openb3dex_TShadowObject_InitShadow
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"UpdateCaster",
			"()i",
			&_openb3d_openb3dex_TShadowObject_UpdateCaster
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"ShadowRenderWorldZFail",
			"()i",
			&openb3d_openb3dex_TShadowObject_ShadowRenderWorldZFail_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ResetShadow",
			"()i",
			&_openb3d_openb3dex_TShadowObject_ResetShadow
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TShadowObject openb3d_openb3dex_TShadowObject={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TShadowObject_scope,
	sizeof(struct openb3d_openb3dex_TShadowObject_obj),
	_openb3d_openb3dex_TShadowObject_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TShadowObject_obj,_openb3d_openb3dex_tshadowobject_exists) - sizeof(void*) + sizeof(BBINT)
	,openb3d_openb3dex_TShadowObject_CreateObject_TTShadowObject_pb
	,openb3d_openb3dex_TShadowObject_FreeObject_i_pb
	,openb3d_openb3dex_TShadowObject_GetObject_TTShadowObject_pb
	,openb3d_openb3dex_TShadowObject_GetInstance_pb_TTShadowObject
	,openb3d_openb3dex_TShadowObject_InitGlobals_i
	,_openb3d_openb3dex_TShadowObject_InitFields
	,openb3d_openb3dex_TShadowObject_AddList__i_TTList
	,openb3d_openb3dex_TShadowObject_CopyList__i_TTList
	,openb3d_openb3dex_TShadowObject_CreateShadow_TTShadowObject_TTMeshi
	,_openb3d_openb3dex_TShadowObject_FreeShadow
	,openb3d_openb3dex_TShadowObject_ShadowInit_i
	,_openb3d_openb3dex_TShadowObject_RemoveShadowfromMesh_TTMesh
	,openb3d_openb3dex_TShadowObject_Update_i_TTCamera
	,openb3d_openb3dex_TShadowObject_RenderVolume_i
	,_openb3d_openb3dex_TShadowObject_UpdateAnim
	,_openb3d_openb3dex_TShadowObject_Init
	,_openb3d_openb3dex_TShadowObject_InitShadow
	,_openb3d_openb3dex_TShadowObject_UpdateCaster
	,openb3d_openb3dex_TShadowObject_ShadowRenderWorldZFail_i
	,_openb3d_openb3dex_TShadowObject_ResetShadow
};

void _openb3d_openb3dex_THardwareInfo_New(struct openb3d_openb3dex_THardwareInfo_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_THardwareInfo;
}
BBINT openb3d_openb3dex_THardwareInfo_GetInfo_i(){
	BBSTRING bbt_Extensions=&bbEmptyString;
	openb3d_openb3dex_THardwareInfo_Vendor=bbStringFromCString(glGetString((GLenum)7936));
	openb3d_openb3dex_THardwareInfo_Renderer=bbStringFromCString(glGetString((GLenum)7937));
	openb3d_openb3dex_THardwareInfo_OGLVersion=bbStringFromCString(glGetString((GLenum)7938));
	bbt_Extensions=bbStringFromCString(glGetString((GLenum)7939));
	openb3d_openb3dex_THardwareInfo_Extensions=bbt_Extensions;
	openb3d_openb3dex_THardwareInfo_GLTCSupport=(bbStringFind(bbt_Extensions,&_s90,0)>-1);
	openb3d_openb3dex_THardwareInfo_S3TCSupport=(bbStringFind(bbt_Extensions,&_s91,0)>-1);
	openb3d_openb3dex_THardwareInfo_AnIsoSupport=(bbStringFind(bbt_Extensions,&_s92,0)>-1);
	openb3d_openb3dex_THardwareInfo_MultiTexSupport=(bbStringFind(bbt_Extensions,&_s93,0)>-1);
	openb3d_openb3dex_THardwareInfo_TexBlendSupport=(bbStringFind(bbt_Extensions,&_s94,0)>-1);
	openb3d_openb3dex_THardwareInfo_CubemapSupport=(bbStringFind(bbt_Extensions,&_s95,0)>-1);
	openb3d_openb3dex_THardwareInfo_DepthmapSupport=(bbStringFind(bbt_Extensions,&_s96,0)>-1);
	openb3d_openb3dex_THardwareInfo_VBOSupport=(bbStringFind(bbt_Extensions,&_s97,0)>-1);
	openb3d_openb3dex_THardwareInfo_VPSupport=(bbStringFind(bbt_Extensions,&_s98,0)>-1);
	openb3d_openb3dex_THardwareInfo_FPSupport=(bbStringFind(bbt_Extensions,&_s99,0)>-1);
	openb3d_openb3dex_THardwareInfo_ShaderSupport=(bbStringFind(bbt_Extensions,&_s100,0)>-1);
	openb3d_openb3dex_THardwareInfo_VSSupport=(bbStringFind(bbt_Extensions,&_s101,0)>-1);
	openb3d_openb3dex_THardwareInfo_FSSupport=(bbStringFind(bbt_Extensions,&_s102,0)>-1);
	openb3d_openb3dex_THardwareInfo_SLSupport=(bbStringFind(bbt_Extensions,&_s103,0)>-1);
	openb3d_openb3dex_THardwareInfo_FBOSupport=(bbStringFind(bbt_Extensions,&_s104,0)>-1);
	openb3d_openb3dex_THardwareInfo_DepthStencil=(bbStringFind(bbt_Extensions,&_s105,0)>-1);
	if((openb3d_openb3dex_THardwareInfo_VSSupport==0) || (openb3d_openb3dex_THardwareInfo_FSSupport==0)){
		openb3d_openb3dex_THardwareInfo_ShaderSupport=0;
	}
	if(!(openb3d_openb3dex_THardwareInfo_TexBlendSupport!=0)){
		openb3d_openb3dex_THardwareInfo_TexBlendSupport=(bbStringFind(bbt_Extensions,&_s106,0)>-1);
	}
	glGetIntegerv((GLenum)34018,(GLint*)(&openb3d_openb3dex_THardwareInfo_MaxTextures));
	glGetIntegerv((GLenum)3379,(GLint*)(&openb3d_openb3dex_THardwareInfo_MaxTexSize));
	glGetIntegerv((GLenum)3377,(GLint*)(&openb3d_openb3dex_THardwareInfo_MaxLights));
	return 0;
}
BBINT openb3d_openb3dex_THardwareInfo_DisplayInfo_i_i(BBINT bbt_LogFile){
	BBINT bbt_position=0;
	BBINT bbt_Space=0;
	struct brl_stream_TStream_obj* volatile bbt_stream=&bbNullObject;
	if(bbt_LogFile!=0){
		bbt_stream=brl_stream_WriteStream(&_s107);
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,&_s108);
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,&bbEmptyString);
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s109,bbStringFromInt(openb3d_openb3dex_THardwareInfo_ScreenWidth)));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s110,bbStringFromInt(openb3d_openb3dex_THardwareInfo_ScreenHeight)));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s111,bbStringFromInt(openb3d_openb3dex_THardwareInfo_ScreenDepth)));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s112,bbStringFromInt(openb3d_openb3dex_THardwareInfo_ScreenHertz)));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,&bbEmptyString);
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s113,openb3d_openb3dex_THardwareInfo_Vendor));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s114,openb3d_openb3dex_THardwareInfo_Renderer));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s115,openb3d_openb3dex_THardwareInfo_OGLVersion));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,&bbEmptyString);
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s116,bbStringFromInt(openb3d_openb3dex_THardwareInfo_MaxTextures)));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s117,bbStringFromInt(openb3d_openb3dex_THardwareInfo_MaxTexSize)));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringConcat(&_s118,bbStringFromInt(openb3d_openb3dex_THardwareInfo_MaxLights)));
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,&bbEmptyString);
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,&_s119);
		while(bbt_position<(openb3d_openb3dex_THardwareInfo_Extensions->length)){
			bbt_Space=bbStringFind(openb3d_openb3dex_THardwareInfo_Extensions,&_s120,bbt_position);
			if(bbt_Space==-1){
				break;
			}
			(bbt_stream)->clas->m_WriteLine_S(bbt_stream,bbStringSlice(openb3d_openb3dex_THardwareInfo_Extensions,bbt_position,bbt_Space));
			bbt_position=(bbt_Space+1);
		}
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,&bbEmptyString);
		(bbt_stream)->clas->m_WriteLine_S(bbt_stream,&_s121);
		(bbt_stream)->clas->m_Close(bbt_stream);
	}else{
		brl_standardio_Print(&_s108);
		brl_standardio_Print(&bbEmptyString);
		brl_standardio_Print(bbStringConcat(&_s109,bbStringFromInt(openb3d_openb3dex_THardwareInfo_ScreenWidth)));
		brl_standardio_Print(bbStringConcat(&_s110,bbStringFromInt(openb3d_openb3dex_THardwareInfo_ScreenHeight)));
		brl_standardio_Print(bbStringConcat(&_s111,bbStringFromInt(openb3d_openb3dex_THardwareInfo_ScreenDepth)));
		brl_standardio_Print(bbStringConcat(&_s112,bbStringFromInt(openb3d_openb3dex_THardwareInfo_ScreenHertz)));
		brl_standardio_Print(&bbEmptyString);
		brl_standardio_Print(bbStringConcat(&_s113,openb3d_openb3dex_THardwareInfo_Vendor));
		brl_standardio_Print(bbStringConcat(&_s114,openb3d_openb3dex_THardwareInfo_Renderer));
		brl_standardio_Print(bbStringConcat(&_s115,openb3d_openb3dex_THardwareInfo_OGLVersion));
		brl_standardio_Print(&bbEmptyString);
		brl_standardio_Print(bbStringConcat(&_s116,bbStringFromInt(openb3d_openb3dex_THardwareInfo_MaxTextures)));
		brl_standardio_Print(bbStringConcat(&_s117,bbStringFromInt(openb3d_openb3dex_THardwareInfo_MaxTexSize)));
		brl_standardio_Print(bbStringConcat(&_s118,bbStringFromInt(openb3d_openb3dex_THardwareInfo_MaxLights)));
		brl_standardio_Print(&bbEmptyString);
		brl_standardio_Print(&_s119);
		while(bbt_position<(openb3d_openb3dex_THardwareInfo_Extensions->length)){
			bbt_Space=bbStringFind(openb3d_openb3dex_THardwareInfo_Extensions,&_s120,bbt_position);
			if(bbt_Space==-1){
				break;
			}
			brl_standardio_Print(bbStringSlice(openb3d_openb3dex_THardwareInfo_Extensions,bbt_position,bbt_Space));
			bbt_position=(bbt_Space+1);
		}
		brl_standardio_Print(&bbEmptyString);
		brl_standardio_Print(&_s121);
	}
	return 0;
}
BBINT openb3d_openb3dex_THardwareInfo_DepthStencil;
BBSTRING openb3d_openb3dex_THardwareInfo_Vendor;
BBSTRING openb3d_openb3dex_THardwareInfo_Renderer;
BBSTRING openb3d_openb3dex_THardwareInfo_OGLVersion;
BBSTRING openb3d_openb3dex_THardwareInfo_Extensions;
BBINT openb3d_openb3dex_THardwareInfo_GLTCSupport;
BBINT openb3d_openb3dex_THardwareInfo_S3TCSupport;
BBINT openb3d_openb3dex_THardwareInfo_AnIsoSupport;
BBINT openb3d_openb3dex_THardwareInfo_MultiTexSupport;
BBINT openb3d_openb3dex_THardwareInfo_TexBlendSupport;
BBINT openb3d_openb3dex_THardwareInfo_CubemapSupport;
BBINT openb3d_openb3dex_THardwareInfo_DepthmapSupport;
BBINT openb3d_openb3dex_THardwareInfo_VBOSupport;
BBINT openb3d_openb3dex_THardwareInfo_VPSupport;
BBINT openb3d_openb3dex_THardwareInfo_FPSupport;
BBINT openb3d_openb3dex_THardwareInfo_ShaderSupport;
BBINT openb3d_openb3dex_THardwareInfo_VSSupport;
BBINT openb3d_openb3dex_THardwareInfo_FSSupport;
BBINT openb3d_openb3dex_THardwareInfo_SLSupport;
BBINT openb3d_openb3dex_THardwareInfo_FBOSupport;
BBINT openb3d_openb3dex_THardwareInfo_MaxTextures;
BBINT openb3d_openb3dex_THardwareInfo_MaxTexSize;
BBINT openb3d_openb3dex_THardwareInfo_MaxLights;
BBINT openb3d_openb3dex_THardwareInfo_ScreenWidth;
BBINT openb3d_openb3dex_THardwareInfo_ScreenHeight;
BBINT openb3d_openb3dex_THardwareInfo_ScreenDepth;
BBINT openb3d_openb3dex_THardwareInfo_ScreenHertz;
struct BBDebugScope_30 openb3d_openb3dex_THardwareInfo_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"THardwareInfo",
	{
		{
			BBDEBUGDECL_GLOBAL,
			"ScreenWidth",
			"i",
			&openb3d_openb3dex_THardwareInfo_ScreenWidth
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ScreenHeight",
			"i",
			&openb3d_openb3dex_THardwareInfo_ScreenHeight
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ScreenDepth",
			"i",
			&openb3d_openb3dex_THardwareInfo_ScreenDepth
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ScreenHertz",
			"i",
			&openb3d_openb3dex_THardwareInfo_ScreenHertz
		},
		{
			BBDEBUGDECL_GLOBAL,
			"Vendor",
			"$",
			&openb3d_openb3dex_THardwareInfo_Vendor
		},
		{
			BBDEBUGDECL_GLOBAL,
			"Renderer",
			"$",
			&openb3d_openb3dex_THardwareInfo_Renderer
		},
		{
			BBDEBUGDECL_GLOBAL,
			"OGLVersion",
			"$",
			&openb3d_openb3dex_THardwareInfo_OGLVersion
		},
		{
			BBDEBUGDECL_GLOBAL,
			"Extensions",
			"$",
			&openb3d_openb3dex_THardwareInfo_Extensions
		},
		{
			BBDEBUGDECL_GLOBAL,
			"GLTCSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_GLTCSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"S3TCSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_S3TCSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"AnIsoSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_AnIsoSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"MultiTexSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_MultiTexSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"TexBlendSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_TexBlendSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"CubemapSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_CubemapSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"DepthmapSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_DepthmapSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"VBOSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_VBOSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"VPSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_VPSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"FPSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_FPSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"ShaderSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_ShaderSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"VSSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_VSSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"FSSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_FSSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"SLSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_SLSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"FBOSupport",
			"i",
			&openb3d_openb3dex_THardwareInfo_FBOSupport
		},
		{
			BBDEBUGDECL_GLOBAL,
			"DepthStencil",
			"i",
			&openb3d_openb3dex_THardwareInfo_DepthStencil
		},
		{
			BBDEBUGDECL_GLOBAL,
			"MaxTextures",
			"i",
			&openb3d_openb3dex_THardwareInfo_MaxTextures
		},
		{
			BBDEBUGDECL_GLOBAL,
			"MaxTexSize",
			"i",
			&openb3d_openb3dex_THardwareInfo_MaxTexSize
		},
		{
			BBDEBUGDECL_GLOBAL,
			"MaxLights",
			"i",
			&openb3d_openb3dex_THardwareInfo_MaxLights
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_THardwareInfo_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInfo",
			"()i",
			&openb3d_openb3dex_THardwareInfo_GetInfo_i
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"DisplayInfo",
			"(i)i",
			&openb3d_openb3dex_THardwareInfo_DisplayInfo_i_i
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_THardwareInfo openb3d_openb3dex_THardwareInfo={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_THardwareInfo_scope,
	sizeof(struct openb3d_openb3dex_THardwareInfo_obj),
	_openb3d_openb3dex_THardwareInfo_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,openb3d_openb3dex_THardwareInfo_GetInfo_i
	,openb3d_openb3dex_THardwareInfo_DisplayInfo_i_i
};

void _openb3d_openb3dex_TGLShader_New(struct openb3d_openb3dex_TGLShader_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TGLShader;
	o->_openb3d_openb3dex_tglshader_programobject = 0;
	o->_openb3d_openb3dex_tglshader_error = 0;
	o->_openb3d_openb3dex_tglshader_errorshader = 0;
	o->_openb3d_openb3dex_tglshader_errorline = 0;
	o->_openb3d_openb3dex_tglshader_errormessage = &bbEmptyString;
}
void _openb3d_openb3dex_TGLShader_Delete(struct openb3d_openb3dex_TGLShader_obj* o) {
	__glewDeleteObjectARB(o->_openb3d_openb3dex_tglshader_programobject );
	BBRELEASE(o->_openb3d_openb3dex_tglshader_errormessage )
	bbObjectDtor(o);
}
struct openb3d_openb3dex_TGLShader_obj* _openb3d_openb3dex_TGLShader_Load_SS(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_VertexPath,BBSTRING bbt_FragmentPath){
	o->_openb3d_openb3dex_tglshader_programobject =-1;
	o->_openb3d_openb3dex_tglshader_error =0;
	o->_openb3d_openb3dex_tglshader_errorshader =-1;
	o->_openb3d_openb3dex_tglshader_errorline =-1;
	o->_openb3d_openb3dex_tglshader_errormessage =&bbEmptyString;
	BBSTRING bbt_VertexCode=&bbEmptyString;
	BBSTRING bbt_FragmentCode=&bbEmptyString;
	do {
		jmp_buf * buf = bbExEnter();
		switch(setjmp(*buf)) {
			case 0: {
				brl_standardio_Print(bbStringConcat(&_s122,bbt_VertexPath));
				bbt_VertexCode=brl_textstream_LoadText(bbt_VertexPath);
				brl_standardio_Print(bbStringConcat(&_s123,bbt_FragmentPath));
				bbt_FragmentCode=brl_textstream_LoadText(bbt_FragmentPath);
				bbExLeave();
			}
			break;
			case 1:
			{
				BBOBJECT ex = bbExObject();
				if (bbObjectDowncast(ex,&bbObjectClass) != &bbNullObject) {
					BBOBJECT bbt_Dummy=(BBOBJECT)ex;
					return &bbNullObject;
				} else  {
					bbExThrow(ex);
				}
			}
			break;
		}
	} while(0);
	((struct openb3d_openb3dex_TGLShader_obj*)o)->clas->m_Compile_SS(o,bbt_VertexCode,bbt_FragmentCode);
	return o;
}
struct openb3d_openb3dex_TGLShader_obj* _openb3d_openb3dex_TGLShader_Compile_SS(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_VertexCode,BBSTRING bbt_FragmentCode){
	if(!(o->_openb3d_openb3dex_tglshader_programobject !=0) || (o->_openb3d_openb3dex_tglshader_programobject <0)){
		brl_standardio_Print(&_s124);
		glewInit();
		o->_openb3d_openb3dex_tglshader_programobject =__glewCreateProgramObjectARB();
	}
	BBINT bbt_VertexShader=__glewCreateShaderObjectARB(35633);
	BBINT bbt_FragmentShader=__glewCreateShaderObjectARB(35632);
	brl_standardio_Print(&_s125);
	o->clas->f__LoadShader_i_Si(bbt_VertexCode,bbt_VertexShader);
	brl_standardio_Print(&_s126);
	__glewCompileShaderARB(bbt_VertexShader);
	if(((struct openb3d_openb3dex_TGLShader_obj*)o)->clas->m__CheckForErrors_ivSi(o,bbt_VertexShader,&o->_openb3d_openb3dex_tglshader_errormessage ,1)!=0){
		__glewDeleteObjectARB(bbt_VertexShader);
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =0;
		return &bbNullObject;
	}
	brl_standardio_Print(&_s127);
	o->clas->f__LoadShader_i_Si(bbt_FragmentCode,bbt_FragmentShader);
	brl_standardio_Print(&_s128);
	__glewCompileShaderARB(bbt_FragmentShader);
	if(((struct openb3d_openb3dex_TGLShader_obj*)o)->clas->m__CheckForErrors_ivSi(o,bbt_FragmentShader,&o->_openb3d_openb3dex_tglshader_errormessage ,1)!=0){
		__glewDeleteObjectARB(bbt_VertexShader);
		__glewDeleteObjectARB(bbt_FragmentShader);
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =1;
		return &bbNullObject;
	}
	__glewAttachObjectARB(o->_openb3d_openb3dex_tglshader_programobject ,bbt_VertexShader);
	__glewAttachObjectARB(o->_openb3d_openb3dex_tglshader_programobject ,bbt_FragmentShader);
	__glewDeleteObjectARB(bbt_VertexShader);
	__glewDeleteObjectARB(bbt_FragmentShader);
	o->_openb3d_openb3dex_tglshader_error =0;
	brl_standardio_Print(&_s129);
	return o;
}
struct openb3d_openb3dex_TGLShader_obj* _openb3d_openb3dex_TGLShader_link(struct openb3d_openb3dex_TGLShader_obj* o){
	if(!(o->_openb3d_openb3dex_tglshader_programobject !=0) || (o->_openb3d_openb3dex_tglshader_programobject <0)){
		brl_standardio_Print(&_s130);
		glewInit();
		o->_openb3d_openb3dex_tglshader_programobject =__glewCreateProgramObjectARB();
	}
	brl_standardio_Print(bbStringConcat(&_s131,bbStringFromInt(o->_openb3d_openb3dex_tglshader_programobject )));
	__glewLinkProgramARB(o->_openb3d_openb3dex_tglshader_programobject );
	brl_standardio_Print(&_s132);
	if(((struct openb3d_openb3dex_TGLShader_obj*)o)->clas->m__CheckForLinkErrors_ivSi(o,o->_openb3d_openb3dex_tglshader_programobject ,&o->_openb3d_openb3dex_tglshader_errormessage ,0)!=0){
		brl_standardio_Print(&_s133);
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =2;
		return &bbNullObject;
	}
	o->_openb3d_openb3dex_tglshader_error =0;
	brl_standardio_Print(&_s134);
	return o;
}
BBINT _openb3d_openb3dex_TGLShader_ErrorReport(struct openb3d_openb3dex_TGLShader_obj* o){
	BBINT bbt_=o->_openb3d_openb3dex_tglshader_errorshader ;
	if(bbt_==0){
		brl_standardio_Print(bbStringConcat(&_s135,bbStringFromInt(o->_openb3d_openb3dex_tglshader_errorline )));
	}else{
		if(bbt_==1){
			brl_standardio_Print(bbStringConcat(&_s136,bbStringFromInt(o->_openb3d_openb3dex_tglshader_errorline )));
		}else{
			if(bbt_==2){
				brl_standardio_Print(bbStringConcat(&_s137,bbStringFromInt(o->_openb3d_openb3dex_tglshader_errorline )));
			}
		}
	}
	brl_standardio_Print(bbStringConcat(&_s138,o->_openb3d_openb3dex_tglshader_errormessage ));
	return 0;
}
BBINT _openb3d_openb3dex_TGLShader_Enable(struct openb3d_openb3dex_TGLShader_obj* o){
	__glewUseProgramObjectARB(o->_openb3d_openb3dex_tglshader_programobject );
	return 0;
}
BBINT _openb3d_openb3dex_TGLShader_Disable(struct openb3d_openb3dex_TGLShader_obj* o){
	__glewUseProgramObjectARB(0);
	return 0;
}
BBINT _openb3d_openb3dex_TGLShader_GetUniformLocation_S(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_Name){
	BBBYTE* bbt_ = bbStringToCString(bbt_Name);
	BBINT rt_ = __glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbt_);
	bbMemFree(bbt_);
	return rt_;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformFloatArray1_Sipf(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBINT bbt_count,BBFLOAT* bbt_val){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s139,bbt_name),&_s140);
		return 0;
	}
	__glewUniform1fv(bbt_loc,bbt_count,bbt_val);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformMatrix4_Siipf(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBINT bbt_count,BBINT bbt_transpose,BBFLOAT* bbt_mat){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s139,bbt_name),&_s140);
		return 0;
	}
	__glewUniformMatrix4fv(bbt_loc,bbt_count,((BBBYTE)bbt_transpose),bbt_mat);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformFloat1_Sf(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBFLOAT bbt_val){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s141,bbt_name),&_s140);
		return 0;
	}
	__glewUniform1fARB(bbt_loc,bbt_val);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformFloat2_Sff(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBFLOAT bbt_val1,BBFLOAT bbt_val2){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s141,bbt_name),&_s140);
		return 0;
	}
	__glewUniform2fARB(bbt_loc,bbt_val1,bbt_val2);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformFloat3_Sfff(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBFLOAT bbt_val1,BBFLOAT bbt_val2,BBFLOAT bbt_val3){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s141,bbt_name),&_s140);
		return 0;
	}
	__glewUniform3fARB(bbt_loc,bbt_val1,bbt_val2,bbt_val3);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformFloat4_Sffff(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBFLOAT bbt_val1,BBFLOAT bbt_val2,BBFLOAT bbt_val3,BBFLOAT bbt_val4){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s141,bbt_name),&_s140);
		return 0;
	}
	__glewUniform4fARB(bbt_loc,bbt_val1,bbt_val2,bbt_val3,bbt_val4);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformInt1_Si(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBINT bbt_val){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s142,bbt_name),&_s140);
		return 0;
	}
	__glewUniform1iARB(bbt_loc,bbt_val);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformInt2_Sii(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBINT bbt_val1,BBINT bbt_val2){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s142,bbt_name),&_s140);
		return 0;
	}
	__glewUniform2iARB(bbt_loc,bbt_val1,bbt_val2);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformInt3_Siii(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBINT bbt_val1,BBINT bbt_val2,BBINT bbt_val3){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s142,bbt_name),&_s140);
		return 0;
	}
	__glewUniform3iARB(bbt_loc,bbt_val1,bbt_val2,bbt_val3);
	return 1;
}
BBINT _openb3d_openb3dex_TGLShader_setUniformInt4_Siiii(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_name,BBINT bbt_val1,BBINT bbt_val2,BBINT bbt_val3,BBINT bbt_val4){
	BBINT bbt_loc=__glewGetUniformLocationARB(o->_openb3d_openb3dex_tglshader_programobject ,bbStringToCString(bbt_name));
	if(bbt_loc<0){
		o->_openb3d_openb3dex_tglshader_error =1;
		o->_openb3d_openb3dex_tglshader_errorshader =3;
		o->_openb3d_openb3dex_tglshader_errormessage =bbStringConcat(bbStringConcat(&_s142,bbt_name),&_s140);
		return 0;
	}
	__glewUniform4iARB(bbt_loc,bbt_val1,bbt_val2,bbt_val3,bbt_val4);
	return 1;
}
BBINT openb3d_openb3dex_TGLShader__LoadShader_i_Si(BBSTRING bbt_ShaderCode,BBINT bbt_ShaderObject){
	BBBYTE* bbt_ShaderCodeC=bbStringToCString(bbt_ShaderCode);
	BBINT bbt_ShaderCodeLen=(bbt_ShaderCode->length);
	__glewShaderSourceARB(bbt_ShaderObject,1,((BBBYTE**)(&bbt_ShaderCodeC)),(&bbt_ShaderCodeLen));
	bbMemFree((void*)bbt_ShaderCodeC);
	return 0;
}
BBINT _openb3d_openb3dex_TGLShader__CheckForErrors_ivSi(struct openb3d_openb3dex_TGLShader_obj* o,BBINT bbt_ShaderObject,BBSTRING* bbt_ErrorString,BBINT bbt_Compiled){
	BBINT bbt_Successful=0;
	if(bbt_Compiled!=0){
		__glewGetShaderiv(bbt_ShaderObject,35713,(&bbt_Successful));
	}else{
		__glewGetProgramiv(bbt_ShaderObject,35714,(&bbt_Successful));
	}
	if(!(bbt_Successful!=0)){
		BBINT bbt_ErrorLength=0;
		__glewGetObjectParameterivARB(bbt_ShaderObject,35716,(&bbt_ErrorLength));
		BBBYTE* bbt_Message=bbMemAlloc((size_t)((BBLONG)bbt_ErrorLength));
		BBINT bbt_Dummy=0;
		__glewGetInfoLogARB(bbt_ShaderObject,bbt_ErrorLength,(&bbt_Dummy),bbt_Message);
		*bbt_ErrorString=bbStringFromCString(bbt_Message);
		bbMemFree((void*)bbt_Message);
		*bbt_ErrorString=brl_retro_Right(*bbt_ErrorString,(((*bbt_ErrorString)->length)-9));
		BBINT bbt_pos=brl_retro_Instr(*bbt_ErrorString,&_s23,1);
		BBSTRING bbt_Line=brl_retro_Left(*bbt_ErrorString,(bbt_pos-1));
		o->_openb3d_openb3dex_tglshader_errorline =bbStringToInt(bbt_Line);
		*bbt_ErrorString=brl_retro_Right(*bbt_ErrorString,((((*bbt_ErrorString)->length)-bbt_pos)-1));
		return -1;
	}
	return 0;
}
BBINT _openb3d_openb3dex_TGLShader__CheckForLinkErrors_ivSi(struct openb3d_openb3dex_TGLShader_obj* o,BBINT bbt_ShaderObject,BBSTRING* bbt_ErrorString,BBINT bbt_Compiled){
	BBINT bbt_Successful=0;
	if(bbt_Compiled!=0){
		__glewGetShaderiv(bbt_ShaderObject,35713,(&bbt_Successful));
	}else{
		__glewGetProgramiv(bbt_ShaderObject,35714,(&bbt_Successful));
	}
	if(!(bbt_Successful!=0)){
		BBINT bbt_ErrorLength=0;
		__glewGetObjectParameterivARB(bbt_ShaderObject,35716,(&bbt_ErrorLength));
		BBBYTE* bbt_Message=bbMemAlloc((size_t)((BBLONG)bbt_ErrorLength));
		BBINT bbt_Dummy=0;
		__glewGetProgramInfoLog(bbt_ShaderObject,bbt_ErrorLength,(&bbt_Dummy),bbt_Message);
		*bbt_ErrorString=bbStringFromCString(bbt_Message);
		bbMemFree((void*)bbt_Message);
		*bbt_ErrorString=brl_retro_Right(*bbt_ErrorString,(((*bbt_ErrorString)->length)-9));
		BBINT bbt_pos=brl_retro_Instr(*bbt_ErrorString,&_s23,1);
		BBSTRING bbt_Line=brl_retro_Left(*bbt_ErrorString,(bbt_pos-1));
		o->_openb3d_openb3dex_tglshader_errorline =bbStringToInt(bbt_Line);
		*bbt_ErrorString=brl_retro_Right(*bbt_ErrorString,((((*bbt_ErrorString)->length)-bbt_pos)-1));
		return -1;
	}
	return 0;
}
BBINT openb3d_openb3dex_TGLShader_CheckCompability_i(){
	BBSTRING bbt_Extensions=bbStringFromCString(glGetString((GLenum)7939));
	BBSTRING bbt_GLVersion=bbStringFromCString(glGetString((GLenum)7938));
	BBINT bbt_GLVersionInt=bbStringToInt(bbStringReplace(bbStringSlice(bbt_GLVersion,0,3),&_s143,&bbEmptyString));
	if((((bbStringFind(bbt_Extensions,&_s100,0)>=0) && (bbStringFind(bbt_Extensions,&_s101,0)>=0)) && (bbStringFind(bbt_Extensions,&_s102,0)>=0)) || (bbt_GLVersionInt>=20)){
		return 1;
	}
	return 0;
}
BBINT _openb3d_openb3dex_TGLShader_InitShaders_SS(struct openb3d_openb3dex_TGLShader_obj* o,BBSTRING bbt_vertShader,BBSTRING bbt_fragShader){
	BBINT bbt_ok=1;
	((struct openb3d_openb3dex_TGLShader_obj*)o)->clas->m_Load_SS(o,bbt_vertShader,bbt_fragShader);
	if(o->_openb3d_openb3dex_tglshader_error !=0){
		((struct openb3d_openb3dex_TGLShader_obj*)o)->clas->m_ErrorReport(o);
		bbt_ok=0;
	}
	((struct openb3d_openb3dex_TGLShader_obj*)o)->clas->m_link(o);
	if(o->_openb3d_openb3dex_tglshader_error !=0){
		((struct openb3d_openb3dex_TGLShader_obj*)o)->clas->m_ErrorReport(o);
		bbt_ok=0;
	}
	return bbt_ok;
}
struct BBDebugScope_33 openb3d_openb3dex_TGLShader_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TGLShader",
	{
		{
			BBDEBUGDECL_CONST,
			"SHERROR_NONE",
			"i",
			.const_value=&_s145
		},
		{
			BBDEBUGDECL_CONST,
			"SHERROR_VERTEX",
			"i",
			.const_value=&_s146
		},
		{
			BBDEBUGDECL_CONST,
			"SHERROR_FRAGMENT",
			"i",
			.const_value=&_s147
		},
		{
			BBDEBUGDECL_CONST,
			"SHERROR_LINK",
			"i",
			.const_value=&_s148
		},
		{
			BBDEBUGDECL_CONST,
			"SHERROR_VARIABLE",
			"i",
			.const_value=&_s149
		},
		{
			BBDEBUGDECL_FIELD,
			"ProgramObject",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TGLShader_obj,_openb3d_openb3dex_tglshader_programobject)
		},
		{
			BBDEBUGDECL_FIELD,
			"Error",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TGLShader_obj,_openb3d_openb3dex_tglshader_error)
		},
		{
			BBDEBUGDECL_FIELD,
			"ErrorShader",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TGLShader_obj,_openb3d_openb3dex_tglshader_errorshader)
		},
		{
			BBDEBUGDECL_FIELD,
			"ErrorLine",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TGLShader_obj,_openb3d_openb3dex_tglshader_errorline)
		},
		{
			BBDEBUGDECL_FIELD,
			"ErrorMessage",
			"$",
			.field_offset=offsetof(struct openb3d_openb3dex_TGLShader_obj,_openb3d_openb3dex_tglshader_errormessage)
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TGLShader_New
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Load",
			"($,$):TGLShader",
			&_openb3d_openb3dex_TGLShader_Load_SS
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Compile",
			"($,$):TGLShader",
			&_openb3d_openb3dex_TGLShader_Compile_SS
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"link",
			"():TGLShader",
			&_openb3d_openb3dex_TGLShader_link
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ErrorReport",
			"()i",
			&_openb3d_openb3dex_TGLShader_ErrorReport
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Enable",
			"()i",
			&_openb3d_openb3dex_TGLShader_Enable
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Disable",
			"()i",
			&_openb3d_openb3dex_TGLShader_Disable
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GetUniformLocation",
			"($)i",
			&_openb3d_openb3dex_TGLShader_GetUniformLocation_S
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformFloatArray1",
			"($,i,*f)i",
			&_openb3d_openb3dex_TGLShader_setUniformFloatArray1_Sipf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformMatrix4",
			"($,i,i,*f)i",
			&_openb3d_openb3dex_TGLShader_setUniformMatrix4_Siipf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformFloat1",
			"($,f)i",
			&_openb3d_openb3dex_TGLShader_setUniformFloat1_Sf
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformFloat2",
			"($,f,f)i",
			&_openb3d_openb3dex_TGLShader_setUniformFloat2_Sff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformFloat3",
			"($,f,f,f)i",
			&_openb3d_openb3dex_TGLShader_setUniformFloat3_Sfff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformFloat4",
			"($,f,f,f,f)i",
			&_openb3d_openb3dex_TGLShader_setUniformFloat4_Sffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformInt1",
			"($,i)i",
			&_openb3d_openb3dex_TGLShader_setUniformInt1_Si
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformInt2",
			"($,i,i)i",
			&_openb3d_openb3dex_TGLShader_setUniformInt2_Sii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformInt3",
			"($,i,i,i)i",
			&_openb3d_openb3dex_TGLShader_setUniformInt3_Siii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"setUniformInt4",
			"($,i,i,i,i)i",
			&_openb3d_openb3dex_TGLShader_setUniformInt4_Siiii
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"_LoadShader",
			"($,i)i",
			&openb3d_openb3dex_TGLShader__LoadShader_i_Si
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"_CheckForErrors",
			"(i,$,i)i",
			&_openb3d_openb3dex_TGLShader__CheckForErrors_ivSi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"_CheckForLinkErrors",
			"(i,$,i)i",
			&_openb3d_openb3dex_TGLShader__CheckForLinkErrors_ivSi
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CheckCompability",
			"()i",
			&openb3d_openb3dex_TGLShader_CheckCompability_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitShaders",
			"($,$)i",
			&_openb3d_openb3dex_TGLShader_InitShaders_SS
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TGLShader openb3d_openb3dex_TGLShader={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TGLShader_scope,
	sizeof(struct openb3d_openb3dex_TGLShader_obj),
	_openb3d_openb3dex_TGLShader_New,
	_openb3d_openb3dex_TGLShader_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TGLShader_obj,_openb3d_openb3dex_tglshader_errormessage) - sizeof(void*) + sizeof(BBSTRING)
	,_openb3d_openb3dex_TGLShader_Load_SS
	,_openb3d_openb3dex_TGLShader_Compile_SS
	,_openb3d_openb3dex_TGLShader_link
	,_openb3d_openb3dex_TGLShader_ErrorReport
	,_openb3d_openb3dex_TGLShader_Enable
	,_openb3d_openb3dex_TGLShader_Disable
	,_openb3d_openb3dex_TGLShader_GetUniformLocation_S
	,_openb3d_openb3dex_TGLShader_setUniformFloatArray1_Sipf
	,_openb3d_openb3dex_TGLShader_setUniformMatrix4_Siipf
	,_openb3d_openb3dex_TGLShader_setUniformFloat1_Sf
	,_openb3d_openb3dex_TGLShader_setUniformFloat2_Sff
	,_openb3d_openb3dex_TGLShader_setUniformFloat3_Sfff
	,_openb3d_openb3dex_TGLShader_setUniformFloat4_Sffff
	,_openb3d_openb3dex_TGLShader_setUniformInt1_Si
	,_openb3d_openb3dex_TGLShader_setUniformInt2_Sii
	,_openb3d_openb3dex_TGLShader_setUniformInt3_Siii
	,_openb3d_openb3dex_TGLShader_setUniformInt4_Siiii
	,openb3d_openb3dex_TGLShader__LoadShader_i_Si
	,_openb3d_openb3dex_TGLShader__CheckForErrors_ivSi
	,_openb3d_openb3dex_TGLShader__CheckForLinkErrors_ivSi
	,openb3d_openb3dex_TGLShader_CheckCompability_i
	,_openb3d_openb3dex_TGLShader_InitShaders_SS
};

void _openb3d_openb3dex_TStencil_New(struct openb3d_openb3dex_TStencil_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TStencil;
	o->_openb3d_openb3dex_tstencil_instance = 0;
}
struct openb3d_openb3dex_TStencil_obj* openb3d_openb3dex_TStencil_CreateObject_TTStencil_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TStencil_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TStencil);
	(openb3d_openb3dex_TStencil_stencil_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TStencil_stencil_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tstencil_instance =bbt_inst;
	return bbt_obj;
}
BBINT openb3d_openb3dex_TStencil_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TStencil_stencil_map)->clas->m_Remove_TObject(openb3d_openb3dex_TStencil_stencil_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TStencil_obj* openb3d_openb3dex_TStencil_GetObject_TTStencil_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TStencil_obj*)bbObjectDowncast((openb3d_openb3dex_TStencil_stencil_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TStencil_stencil_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TStencil));
}
BBBYTE* openb3d_openb3dex_TStencil_GetInstance_pb_TTStencil(struct openb3d_openb3dex_TStencil_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tstencil_instance ;
}
struct openb3d_openb3dex_TStencil_obj* openb3d_openb3dex_TStencil_CreateStencil_TTStencil(){
	BBBYTE* bbt_inst=CreateStencil();
	return openb3d_openb3dex_TStencil_CreateObject_TTStencil_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TStencil_StencilAlpha_f(struct openb3d_openb3dex_TStencil_obj* o,BBFLOAT bbt_a){
	StencilAlpha(o->clas->f_GetInstance_pb_TTStencil(o),bbt_a);
	return 0;
}
BBINT _openb3d_openb3dex_TStencil_StencilClsColor_fff(struct openb3d_openb3dex_TStencil_obj* o,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	StencilClsColor(o->clas->f_GetInstance_pb_TTStencil(o),bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT _openb3d_openb3dex_TStencil_StencilClsMode_ii(struct openb3d_openb3dex_TStencil_obj* o,BBINT bbt_cls_color,BBINT bbt_cls_zbuffer){
	StencilClsMode(o->clas->f_GetInstance_pb_TTStencil(o),bbt_cls_color,bbt_cls_zbuffer);
	return 0;
}
BBINT _openb3d_openb3dex_TStencil_StencilMesh_TTMeshi(struct openb3d_openb3dex_TStencil_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBINT bbt_Mode){
	StencilMesh(o->clas->f_GetInstance_pb_TTStencil(o),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)),bbt_Mode);
	return 0;
}
BBINT _openb3d_openb3dex_TStencil_StencilMode_ii(struct openb3d_openb3dex_TStencil_obj* o,BBINT bbt_m,BBINT bbt_o){
	StencilMode(o->clas->f_GetInstance_pb_TTStencil(o),bbt_m,bbt_o);
	return 0;
}
BBINT openb3d_openb3dex_TStencil_UseStencil_i_TTStencil(struct openb3d_openb3dex_TStencil_obj* bbt_sten){
	UseStencil(openb3d_openb3dex_TStencil_GetInstance_pb_TTStencil(bbt_sten));
	return 0;
}
BBINT _openb3d_openb3dex_TStencil_FreeStencil(struct openb3d_openb3dex_TStencil_obj* o){
	FreeStencil(o->clas->f_GetInstance_pb_TTStencil(o));
	o->clas->f_FreeObject_i_pb(o->clas->f_GetInstance_pb_TTStencil(o));
	return 0;
}
struct brl_map_TMap_obj* openb3d_openb3dex_TStencil_stencil_map;
struct BBDebugScope_15 openb3d_openb3dex_TStencil_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TStencil",
	{
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TStencil_obj,_openb3d_openb3dex_tstencil_instance)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"stencil_map",
			":TMap",
			&openb3d_openb3dex_TStencil_stencil_map
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TStencil_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TStencil",
			&openb3d_openb3dex_TStencil_CreateObject_TTStencil_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TStencil_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TStencil",
			&openb3d_openb3dex_TStencil_GetObject_TTStencil_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TStencil)*b",
			&openb3d_openb3dex_TStencil_GetInstance_pb_TTStencil
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateStencil",
			"():TStencil",
			&openb3d_openb3dex_TStencil_CreateStencil_TTStencil
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"StencilAlpha",
			"(f)i",
			&_openb3d_openb3dex_TStencil_StencilAlpha_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"StencilClsColor",
			"(f,f,f)i",
			&_openb3d_openb3dex_TStencil_StencilClsColor_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"StencilClsMode",
			"(i,i)i",
			&_openb3d_openb3dex_TStencil_StencilClsMode_ii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"StencilMesh",
			"(:TMesh,i)i",
			&_openb3d_openb3dex_TStencil_StencilMesh_TTMeshi
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"StencilMode",
			"(i,i)i",
			&_openb3d_openb3dex_TStencil_StencilMode_ii
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"UseStencil",
			"(:TStencil)i",
			&openb3d_openb3dex_TStencil_UseStencil_i_TTStencil
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeStencil",
			"()i",
			&_openb3d_openb3dex_TStencil_FreeStencil
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TStencil openb3d_openb3dex_TStencil={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TStencil_scope,
	sizeof(struct openb3d_openb3dex_TStencil_obj),
	_openb3d_openb3dex_TStencil_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TStencil_obj,_openb3d_openb3dex_tstencil_instance) - sizeof(void*) + sizeof(BBBYTE*)
	,openb3d_openb3dex_TStencil_CreateObject_TTStencil_pb
	,openb3d_openb3dex_TStencil_FreeObject_i_pb
	,openb3d_openb3dex_TStencil_GetObject_TTStencil_pb
	,openb3d_openb3dex_TStencil_GetInstance_pb_TTStencil
	,openb3d_openb3dex_TStencil_CreateStencil_TTStencil
	,_openb3d_openb3dex_TStencil_StencilAlpha_f
	,_openb3d_openb3dex_TStencil_StencilClsColor_fff
	,_openb3d_openb3dex_TStencil_StencilClsMode_ii
	,_openb3d_openb3dex_TStencil_StencilMesh_TTMeshi
	,_openb3d_openb3dex_TStencil_StencilMode_ii
	,openb3d_openb3dex_TStencil_UseStencil_i_TTStencil
	,_openb3d_openb3dex_TStencil_FreeStencil
};

void _openb3d_openb3dex_TFluid_New(struct openb3d_openb3dex_TFluid_obj* o) {
	_openb3d_openb3dex_TMesh_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TFluid;
}
void _openb3d_openb3dex_TFluid_Delete(struct openb3d_openb3dex_TFluid_obj* o) {
	_openb3d_openb3dex_TMesh_Delete(o);
}
struct openb3d_openb3dex_TFluid_obj* openb3d_openb3dex_TFluid_CreateObject_TTFluid_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TFluid_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TFluid);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TFluid_InitFields(struct openb3d_openb3dex_TFluid_obj* o){
	(&openb3d_openb3dex_TFluid)->super->m_InitFields(o);
	return 0;
}
struct openb3d_openb3dex_TFluid_obj* openb3d_openb3dex_TFluid_CreateFluid_TTFluid(){
	BBBYTE* bbt_inst=CreateFluid();
	return openb3d_openb3dex_TFluid_CreateObject_TTFluid_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TFluid_FluidArray_vfiii(struct openb3d_openb3dex_TFluid_obj* o,BBFLOAT* bbt_Array,BBINT bbt_w,BBINT bbt_h,BBINT bbt_d){
	FluidArray(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),&(*bbt_Array),bbt_w,bbt_h,bbt_d);
	return 0;
}
BBINT _openb3d_openb3dex_TFluid_FluidFunction_F_fff_f_(struct openb3d_openb3dex_TFluid_obj* o,BBFLOAT(* bbt_FieldFunction)(BBFLOAT,BBFLOAT,BBFLOAT)){
	FluidFunction(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_FieldFunction);
	return 0;
}
BBINT _openb3d_openb3dex_TFluid_FluidThreshold_f(struct openb3d_openb3dex_TFluid_obj* o,BBFLOAT bbt_threshold){
	FluidThreshold(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_threshold);
	return 0;
}
struct BBDebugScope_7 openb3d_openb3dex_TFluid_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TFluid",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TFluid_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TFluid",
			&openb3d_openb3dex_TFluid_CreateObject_TTFluid_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TFluid_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateFluid",
			"():TFluid",
			&openb3d_openb3dex_TFluid_CreateFluid_TTFluid
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FluidArray",
			"(f,i,i,i)i",
			&_openb3d_openb3dex_TFluid_FluidArray_vfiii
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FluidFunction",
			"((f,f,f)f)i",
			&_openb3d_openb3dex_TFluid_FluidFunction_F_fff_f_
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FluidThreshold",
			"(f)i",
			&_openb3d_openb3dex_TFluid_FluidThreshold_f
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TFluid openb3d_openb3dex_TFluid={
	&openb3d_openb3dex_TMesh,
	bbObjectFree,
	&openb3d_openb3dex_TFluid_scope,
	sizeof(struct openb3d_openb3dex_TFluid_obj),
	_openb3d_openb3dex_TFluid_New,
	_openb3d_openb3dex_TFluid_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,_openb3d_openb3dex_TMesh_CopyEntity_TTEntity
	,_openb3d_openb3dex_TMesh_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TFluid_InitFields
	,_openb3d_openb3dex_TMesh_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TMesh_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TMesh_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TMesh_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TFluid_CreateObject_TTFluid_pb
	,_openb3d_openb3dex_TMesh_CreateBone_TTEntity
	,openb3d_openb3dex_TMesh_CreatePlane_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateQuad_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_MeshCSG_TTMesh_TTMeshTTMeshi
	,_openb3d_openb3dex_TMesh_MeshesIntersect_TTMesh
	,_openb3d_openb3dex_TMesh_RepeatMesh_TTEntity
	,_openb3d_openb3dex_TMesh_SkinMesh_iiifififif
	,openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_LoadMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_LoadAnimMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_CreateCube_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateCylinder_TTMesh_iiTTEntity
	,openb3d_openb3dex_TMesh_CreateCone_TTMesh_iiTTEntity
	,_openb3d_openb3dex_TMesh_CopyMesh_TTEntity
	,_openb3d_openb3dex_TMesh_AddMesh_TTMesh
	,_openb3d_openb3dex_TMesh_FlipMesh
	,_openb3d_openb3dex_TMesh_PaintMesh_TTBrush
	,_openb3d_openb3dex_TMesh_FitMesh_ffffffi
	,_openb3d_openb3dex_TMesh_ScaleMesh_fff
	,_openb3d_openb3dex_TMesh_RotateMesh_fff
	,_openb3d_openb3dex_TMesh_PositionMesh_fff
	,_openb3d_openb3dex_TMesh_UpdateNormals
	,_openb3d_openb3dex_TMesh_CreateSurface_TTBrush
	,_openb3d_openb3dex_TMesh_MeshWidth
	,_openb3d_openb3dex_TMesh_MeshHeight
	,_openb3d_openb3dex_TMesh_MeshDepth
	,_openb3d_openb3dex_TMesh_CountSurfaces
	,_openb3d_openb3dex_TMesh_GetSurface_i
	,_openb3d_openb3dex_TMesh_FindSurface_TTBrush
	,_openb3d_openb3dex_TMesh_CountVertices
	,_openb3d_openb3dex_TMesh_CountTriangles
	,openb3d_openb3dex_TMesh_CopyBonesList_i_TTEntity
	,_openb3d_openb3dex_TMesh_CollapseAnimMesh_TTMesh
	,_openb3d_openb3dex_TMesh_CollapseChildren_TTEntityTTMesh
	,_openb3d_openb3dex_TMesh_TransformMesh_TTMatrix
	,_openb3d_openb3dex_TMesh_GetBounds
	,_openb3d_openb3dex_TMesh_Alpha
	,_openb3d_openb3dex_TMesh_MeshColor_ffff
	,_openb3d_openb3dex_TMesh_MeshRed_f
	,_openb3d_openb3dex_TMesh_MeshGreen_f
	,_openb3d_openb3dex_TMesh_MeshBlue_f
	,_openb3d_openb3dex_TMesh_MeshAlpha_f
	,_openb3d_openb3dex_TMesh_TreeCheck
	,_openb3d_openb3dex_TMesh_Render
	,_openb3d_openb3dex_TMesh_UpdateShadow
	,openb3d_openb3dex_TFluid_CreateFluid_TTFluid
	,_openb3d_openb3dex_TFluid_FluidArray_vfiii
	,_openb3d_openb3dex_TFluid_FluidFunction_F_fff_f_
	,_openb3d_openb3dex_TFluid_FluidThreshold_f
};

void _openb3d_openb3dex_TBlob_New(struct openb3d_openb3dex_TBlob_obj* o) {
	_openb3d_openb3dex_TEntity_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TBlob;
}
void _openb3d_openb3dex_TBlob_Delete(struct openb3d_openb3dex_TBlob_obj* o) {
	_openb3d_openb3dex_TEntity_Delete(o);
}
struct openb3d_openb3dex_TBlob_obj* openb3d_openb3dex_TBlob_CreateObject_TTBlob_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TBlob_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TBlob);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TBlob_InitFields(struct openb3d_openb3dex_TBlob_obj* o){
	(&openb3d_openb3dex_TBlob)->super->m_InitFields(o);
	return 0;
}
struct openb3d_openb3dex_TBlob_obj* openb3d_openb3dex_TBlob_CreateBlob_TTBlob_TTFluidfTTEntity(struct openb3d_openb3dex_TFluid_obj* bbt_fluid,BBFLOAT bbt_radius,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	BBBYTE* bbt_inst=CreateBlob(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_fluid,&openb3d_openb3dex_TEntity)),bbt_radius,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent_ent));
	return openb3d_openb3dex_TBlob_CreateObject_TTBlob_pb(bbt_inst);
}
struct openb3d_openb3dex_TBlob_obj* _openb3d_openb3dex_TBlob_CopyEntity_TTEntity(struct openb3d_openb3dex_TBlob_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TBlob_obj* volatile bbt_blob=o->clas->f_CreateObject_TTBlob_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_blob;
}
BBINT _openb3d_openb3dex_TBlob_Update(struct openb3d_openb3dex_TBlob_obj* o){
	return 0;
}
struct BBDebugScope_6 openb3d_openb3dex_TBlob_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TBlob",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TBlob_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TBlob",
			&openb3d_openb3dex_TBlob_CreateObject_TTBlob_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TBlob_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateBlob",
			"(:TFluid,f,:TEntity):TBlob",
			&openb3d_openb3dex_TBlob_CreateBlob_TTBlob_TTFluidfTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TBlob",
			&_openb3d_openb3dex_TBlob_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Update",
			"()i",
			&_openb3d_openb3dex_TBlob_Update
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TBlob openb3d_openb3dex_TBlob={
	&openb3d_openb3dex_TEntity,
	bbObjectFree,
	&openb3d_openb3dex_TBlob_scope,
	sizeof(struct openb3d_openb3dex_TBlob_obj),
	_openb3d_openb3dex_TBlob_New,
	_openb3d_openb3dex_TBlob_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,_openb3d_openb3dex_TBlob_CopyEntity_TTEntity
	,_openb3d_openb3dex_TBlob_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TBlob_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TEntity_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TBlob_CreateObject_TTBlob_pb
	,openb3d_openb3dex_TBlob_CreateBlob_TTBlob_TTFluidfTTEntity
};

void _openb3d_openb3dex_TGeosphere_New(struct openb3d_openb3dex_TGeosphere_obj* o) {
	_openb3d_openb3dex_TTerrain_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TGeosphere;
}
void _openb3d_openb3dex_TGeosphere_Delete(struct openb3d_openb3dex_TGeosphere_obj* o) {
	_openb3d_openb3dex_TTerrain_Delete(o);
}
struct openb3d_openb3dex_TGeosphere_obj* openb3d_openb3dex_TGeosphere_CreateObject_TTGeosphere_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TGeosphere_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TGeosphere);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TGeosphere_InitFields(struct openb3d_openb3dex_TGeosphere_obj* o){
	(&openb3d_openb3dex_TGeosphere)->super->m_InitFields(o);
	return 0;
}
struct openb3d_openb3dex_TGeosphere_obj* openb3d_openb3dex_TGeosphere_CreateGeosphere_TTGeosphere_iTTEntity(BBINT bbt_size,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateGeosphere(bbt_size,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TGeosphere_CreateObject_TTGeosphere_pb(bbt_inst);
}
struct openb3d_openb3dex_TGeosphere_obj* openb3d_openb3dex_TGeosphere_LoadGeosphere_TTGeosphere_STTEntity(BBSTRING bbt_file,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_cString=bbStringToCString(bbt_file);
	BBBYTE* bbt_inst=LoadGeosphere(bbt_cString,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TGeosphere_obj* volatile bbt_geo=openb3d_openb3dex_TGeosphere_CreateObject_TTGeosphere_pb(bbt_inst);
	bbMemFree((void*)bbt_cString);
	return bbt_geo;
}
BBINT _openb3d_openb3dex_TGeosphere_ModifyGeosphere_iif(struct openb3d_openb3dex_TGeosphere_obj* o,BBINT bbt_x,BBINT bbt_z,BBFLOAT bbt_new_height){
	ModifyGeosphere(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_z,bbt_new_height);
	return 0;
}
BBINT _openb3d_openb3dex_TGeosphere_GeosphereHeight_f(struct openb3d_openb3dex_TGeosphere_obj* o,BBFLOAT bbt_h){
	GeosphereHeight(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_h);
	return 0;
}
struct BBDebugScope_7 openb3d_openb3dex_TGeosphere_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TGeosphere",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TGeosphere_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TGeosphere",
			&openb3d_openb3dex_TGeosphere_CreateObject_TTGeosphere_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TGeosphere_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateGeosphere",
			"(i,:TEntity):TGeosphere",
			&openb3d_openb3dex_TGeosphere_CreateGeosphere_TTGeosphere_iTTEntity
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"LoadGeosphere",
			"($,:TEntity):TGeosphere",
			&openb3d_openb3dex_TGeosphere_LoadGeosphere_TTGeosphere_STTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"ModifyGeosphere",
			"(i,i,f)i",
			&_openb3d_openb3dex_TGeosphere_ModifyGeosphere_iif
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"GeosphereHeight",
			"(f)i",
			&_openb3d_openb3dex_TGeosphere_GeosphereHeight_f
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TGeosphere openb3d_openb3dex_TGeosphere={
	&openb3d_openb3dex_TTerrain,
	bbObjectFree,
	&openb3d_openb3dex_TGeosphere_scope,
	sizeof(struct openb3d_openb3dex_TGeosphere_obj),
	_openb3d_openb3dex_TGeosphere_New,
	_openb3d_openb3dex_TGeosphere_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,_openb3d_openb3dex_TTerrain_CopyEntity_TTEntity
	,_openb3d_openb3dex_TTerrain_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TTerrain_InitGlobals_i
	,_openb3d_openb3dex_TGeosphere_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TTerrain_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TTerrain_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TTerrain_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TGeosphere_CreateObject_TTGeosphere_pb
	,openb3d_openb3dex_TTerrain_CreateTerrain_TTTerrain_iTTEntity
	,openb3d_openb3dex_TTerrain_LoadTerrain_TTTerrain_STTEntity
	,_openb3d_openb3dex_TTerrain_ModifyTerrain_iif
	,_openb3d_openb3dex_TTerrain_TerrainHeight_ii
	,_openb3d_openb3dex_TTerrain_TerrainX_fff
	,_openb3d_openb3dex_TTerrain_TerrainY_fff
	,_openb3d_openb3dex_TTerrain_TerrainZ_fff
	,_openb3d_openb3dex_TTerrain_UpdateTerrain
	,_openb3d_openb3dex_TTerrain_RecreateROAM
	,_openb3d_openb3dex_TTerrain_drawsub_iafafaf
	,_openb3d_openb3dex_TTerrain_UpdateNormals
	,_openb3d_openb3dex_TTerrain_col_tree_sub_iafafaf
	,openb3d_openb3dex_TGeosphere_CreateGeosphere_TTGeosphere_iTTEntity
	,openb3d_openb3dex_TGeosphere_LoadGeosphere_TTGeosphere_STTEntity
	,_openb3d_openb3dex_TGeosphere_ModifyGeosphere_iif
	,_openb3d_openb3dex_TGeosphere_GeosphereHeight_f
};

void _openb3d_openb3dex_TOcTree_New(struct openb3d_openb3dex_TOcTree_obj* o) {
	_openb3d_openb3dex_TTerrain_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TOcTree;
}
void _openb3d_openb3dex_TOcTree_Delete(struct openb3d_openb3dex_TOcTree_obj* o) {
	_openb3d_openb3dex_TTerrain_Delete(o);
}
struct openb3d_openb3dex_TOcTree_obj* openb3d_openb3dex_TOcTree_CreateObject_TTOcTree_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TOcTree_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TOcTree);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TOcTree_InitFields(struct openb3d_openb3dex_TOcTree_obj* o){
	(&openb3d_openb3dex_TOcTree)->super->m_InitFields(o);
	return 0;
}
struct openb3d_openb3dex_TOcTree_obj* openb3d_openb3dex_TOcTree_CreateOcTree_TTOcTree_fffTTEntity(BBFLOAT bbt_w,BBFLOAT bbt_h,BBFLOAT bbt_d,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	BBBYTE* bbt_inst=CreateOcTree(bbt_w,bbt_h,bbt_d,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent_ent));
	return openb3d_openb3dex_TOcTree_CreateObject_TTOcTree_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TOcTree_OctreeBlock_TTMeshifffff(struct openb3d_openb3dex_TOcTree_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBINT bbt_level,BBFLOAT bbt_X,BBFLOAT bbt_Y,BBFLOAT bbt_Z,BBFLOAT bbt_Near,BBFLOAT bbt_Far){
	OctreeBlock(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)),bbt_level,bbt_X,bbt_Y,bbt_Z,bbt_Near,bbt_Far);
	return 0;
}
BBINT _openb3d_openb3dex_TOcTree_OctreeMesh_TTMeshifffff(struct openb3d_openb3dex_TOcTree_obj* o,struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBINT bbt_level,BBFLOAT bbt_X,BBFLOAT bbt_Y,BBFLOAT bbt_Z,BBFLOAT bbt_Near,BBFLOAT bbt_Far){
	OctreeMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)),bbt_level,bbt_X,bbt_Y,bbt_Z,bbt_Near,bbt_Far);
	return 0;
}
struct BBDebugScope_6 openb3d_openb3dex_TOcTree_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TOcTree",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TOcTree_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TOcTree",
			&openb3d_openb3dex_TOcTree_CreateObject_TTOcTree_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TOcTree_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateOcTree",
			"(f,f,f,:TEntity):TOcTree",
			&openb3d_openb3dex_TOcTree_CreateOcTree_TTOcTree_fffTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"OctreeBlock",
			"(:TMesh,i,f,f,f,f,f)i",
			&_openb3d_openb3dex_TOcTree_OctreeBlock_TTMeshifffff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"OctreeMesh",
			"(:TMesh,i,f,f,f,f,f)i",
			&_openb3d_openb3dex_TOcTree_OctreeMesh_TTMeshifffff
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TOcTree openb3d_openb3dex_TOcTree={
	&openb3d_openb3dex_TTerrain,
	bbObjectFree,
	&openb3d_openb3dex_TOcTree_scope,
	sizeof(struct openb3d_openb3dex_TOcTree_obj),
	_openb3d_openb3dex_TOcTree_New,
	_openb3d_openb3dex_TOcTree_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,_openb3d_openb3dex_TTerrain_CopyEntity_TTEntity
	,_openb3d_openb3dex_TTerrain_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TTerrain_InitGlobals_i
	,_openb3d_openb3dex_TOcTree_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TTerrain_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TTerrain_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TTerrain_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TOcTree_CreateObject_TTOcTree_pb
	,openb3d_openb3dex_TTerrain_CreateTerrain_TTTerrain_iTTEntity
	,openb3d_openb3dex_TTerrain_LoadTerrain_TTTerrain_STTEntity
	,_openb3d_openb3dex_TTerrain_ModifyTerrain_iif
	,_openb3d_openb3dex_TTerrain_TerrainHeight_ii
	,_openb3d_openb3dex_TTerrain_TerrainX_fff
	,_openb3d_openb3dex_TTerrain_TerrainY_fff
	,_openb3d_openb3dex_TTerrain_TerrainZ_fff
	,_openb3d_openb3dex_TTerrain_UpdateTerrain
	,_openb3d_openb3dex_TTerrain_RecreateROAM
	,_openb3d_openb3dex_TTerrain_drawsub_iafafaf
	,_openb3d_openb3dex_TTerrain_UpdateNormals
	,_openb3d_openb3dex_TTerrain_col_tree_sub_iafafaf
	,openb3d_openb3dex_TOcTree_CreateOcTree_TTOcTree_fffTTEntity
	,_openb3d_openb3dex_TOcTree_OctreeBlock_TTMeshifffff
	,_openb3d_openb3dex_TOcTree_OctreeMesh_TTMeshifffff
};

void _openb3d_openb3dex_TVoxelSprite_New(struct openb3d_openb3dex_TVoxelSprite_obj* o) {
	_openb3d_openb3dex_TMesh_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TVoxelSprite;
}
void _openb3d_openb3dex_TVoxelSprite_Delete(struct openb3d_openb3dex_TVoxelSprite_obj* o) {
	_openb3d_openb3dex_TMesh_Delete(o);
}
struct openb3d_openb3dex_TVoxelSprite_obj* openb3d_openb3dex_TVoxelSprite_CreateObject_TTVoxelSprite_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TVoxelSprite_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TVoxelSprite);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TVoxelSprite_InitFields(struct openb3d_openb3dex_TVoxelSprite_obj* o){
	(&openb3d_openb3dex_TVoxelSprite)->super->m_InitFields(o);
	return 0;
}
struct openb3d_openb3dex_TVoxelSprite_obj* openb3d_openb3dex_TVoxelSprite_CreateVoxelSprite_TTVoxelSprite_iTTEntity(BBINT bbt_slices,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CreateVoxelSprite(bbt_slices,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	return openb3d_openb3dex_TVoxelSprite_CreateObject_TTVoxelSprite_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TVoxelSprite_VoxelSpriteMaterial_TTMaterial(struct openb3d_openb3dex_TVoxelSprite_obj* o,struct openb3d_openb3dex_TMaterial_obj* bbt_mat){
	VoxelSpriteMaterial(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture((struct openb3d_openb3dex_TTexture_obj*)bbObjectDowncast(bbt_mat,&openb3d_openb3dex_TTexture)));
	return 0;
}
struct BBDebugScope_5 openb3d_openb3dex_TVoxelSprite_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TVoxelSprite",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TVoxelSprite_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TVoxelSprite",
			&openb3d_openb3dex_TVoxelSprite_CreateObject_TTVoxelSprite_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TVoxelSprite_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateVoxelSprite",
			"(i,:TEntity):TVoxelSprite",
			&openb3d_openb3dex_TVoxelSprite_CreateVoxelSprite_TTVoxelSprite_iTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"VoxelSpriteMaterial",
			"(:TMaterial)i",
			&_openb3d_openb3dex_TVoxelSprite_VoxelSpriteMaterial_TTMaterial
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TVoxelSprite openb3d_openb3dex_TVoxelSprite={
	&openb3d_openb3dex_TMesh,
	bbObjectFree,
	&openb3d_openb3dex_TVoxelSprite_scope,
	sizeof(struct openb3d_openb3dex_TVoxelSprite_obj),
	_openb3d_openb3dex_TVoxelSprite_New,
	_openb3d_openb3dex_TVoxelSprite_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,_openb3d_openb3dex_TMesh_CopyEntity_TTEntity
	,_openb3d_openb3dex_TMesh_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TVoxelSprite_InitFields
	,_openb3d_openb3dex_TMesh_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TMesh_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TMesh_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TMesh_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TVoxelSprite_CreateObject_TTVoxelSprite_pb
	,_openb3d_openb3dex_TMesh_CreateBone_TTEntity
	,openb3d_openb3dex_TMesh_CreatePlane_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateQuad_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_MeshCSG_TTMesh_TTMeshTTMeshi
	,_openb3d_openb3dex_TMesh_MeshesIntersect_TTMesh
	,_openb3d_openb3dex_TMesh_RepeatMesh_TTEntity
	,_openb3d_openb3dex_TMesh_SkinMesh_iiifififif
	,openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_LoadMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_LoadAnimMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_CreateCube_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateCylinder_TTMesh_iiTTEntity
	,openb3d_openb3dex_TMesh_CreateCone_TTMesh_iiTTEntity
	,_openb3d_openb3dex_TMesh_CopyMesh_TTEntity
	,_openb3d_openb3dex_TMesh_AddMesh_TTMesh
	,_openb3d_openb3dex_TMesh_FlipMesh
	,_openb3d_openb3dex_TMesh_PaintMesh_TTBrush
	,_openb3d_openb3dex_TMesh_FitMesh_ffffffi
	,_openb3d_openb3dex_TMesh_ScaleMesh_fff
	,_openb3d_openb3dex_TMesh_RotateMesh_fff
	,_openb3d_openb3dex_TMesh_PositionMesh_fff
	,_openb3d_openb3dex_TMesh_UpdateNormals
	,_openb3d_openb3dex_TMesh_CreateSurface_TTBrush
	,_openb3d_openb3dex_TMesh_MeshWidth
	,_openb3d_openb3dex_TMesh_MeshHeight
	,_openb3d_openb3dex_TMesh_MeshDepth
	,_openb3d_openb3dex_TMesh_CountSurfaces
	,_openb3d_openb3dex_TMesh_GetSurface_i
	,_openb3d_openb3dex_TMesh_FindSurface_TTBrush
	,_openb3d_openb3dex_TMesh_CountVertices
	,_openb3d_openb3dex_TMesh_CountTriangles
	,openb3d_openb3dex_TMesh_CopyBonesList_i_TTEntity
	,_openb3d_openb3dex_TMesh_CollapseAnimMesh_TTMesh
	,_openb3d_openb3dex_TMesh_CollapseChildren_TTEntityTTMesh
	,_openb3d_openb3dex_TMesh_TransformMesh_TTMatrix
	,_openb3d_openb3dex_TMesh_GetBounds
	,_openb3d_openb3dex_TMesh_Alpha
	,_openb3d_openb3dex_TMesh_MeshColor_ffff
	,_openb3d_openb3dex_TMesh_MeshRed_f
	,_openb3d_openb3dex_TMesh_MeshGreen_f
	,_openb3d_openb3dex_TMesh_MeshBlue_f
	,_openb3d_openb3dex_TMesh_MeshAlpha_f
	,_openb3d_openb3dex_TMesh_TreeCheck
	,_openb3d_openb3dex_TMesh_Render
	,_openb3d_openb3dex_TMesh_UpdateShadow
	,openb3d_openb3dex_TVoxelSprite_CreateVoxelSprite_TTVoxelSprite_iTTEntity
	,_openb3d_openb3dex_TVoxelSprite_VoxelSpriteMaterial_TTMaterial
};

void _openb3d_openb3dex_TAction_New(struct openb3d_openb3dex_TAction_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TAction;
	o->_openb3d_openb3dex_taction_act = 0;
	o->_openb3d_openb3dex_taction_instance = 0;
	o->_openb3d_openb3dex_taction_exists = 0;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_TAction_CreateObject_TTAction_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TAction_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TAction);
	(openb3d_openb3dex_TAction_action_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TAction_action_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_taction_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT openb3d_openb3dex_TAction_FreeObject_i_pb(BBBYTE* bbt_inst){
	(openb3d_openb3dex_TAction_action_map)->clas->m_Remove_TObject(openb3d_openb3dex_TAction_action_map,bbStringFromLong((BBLONG)bbt_inst));
	return 0;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_TAction_GetObject_TTAction_pb(BBBYTE* bbt_inst){
	return ((struct openb3d_openb3dex_TAction_obj*)bbObjectDowncast((openb3d_openb3dex_TAction_action_map)->clas->m_ValueForKey_TObject(openb3d_openb3dex_TAction_action_map,bbStringFromLong((BBLONG)bbt_inst)),&openb3d_openb3dex_TAction));
}
BBBYTE* openb3d_openb3dex_TAction_GetInstance_pb_TTAction(struct openb3d_openb3dex_TAction_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_taction_instance ;
}
BBINT _openb3d_openb3dex_TAction_InitFields(struct openb3d_openb3dex_TAction_obj* o){
	o->_openb3d_openb3dex_taction_act =ActionInt(o->clas->f_GetInstance_pb_TTAction(o),2);
	o->clas->f_AddList__i_TTList(openb3d_openb3dex_TAction_action_list);
	o->_openb3d_openb3dex_taction_exists =1;
	return 0;
}
BBINT openb3d_openb3dex_TAction_AddList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TAction_action_list){
		if(StaticListSize(1,1)!=0){
			BBBYTE* bbt_inst=StaticIterListAction(1,1,(&openb3d_openb3dex_TAction_action_list_id));
			struct openb3d_openb3dex_TAction_obj* volatile bbt_obj=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
			if(bbt_obj!= &bbNullObject){
				brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
			}
		}
	}
	return 0;
}
BBINT openb3d_openb3dex_TAction_CopyList__i_TTList(struct brl_linkedlist_TList_obj* bbt_list){
	brl_linkedlist_ClearList(bbt_list);
	struct brl_linkedlist_TList_obj* volatile bbt_=bbt_list;
	if(bbt_==openb3d_openb3dex_TAction_action_list){
		openb3d_openb3dex_TAction_action_list_id=0;
		{
			BBINT bbt_id=0;
			BBINT bbt_2=(StaticListSize(1,1)-1);
			for(bbt_id;(bbt_id<=bbt_2);bbt_id=(bbt_id+1)){
				BBBYTE* bbt_inst=StaticIterListAction(1,1,(&openb3d_openb3dex_TAction_action_list_id));
				struct openb3d_openb3dex_TAction_obj* volatile bbt_obj=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
				if(bbt_obj!= &bbNullObject){
					brl_linkedlist_ListAddLast(bbt_list,bbt_obj);
				}
			}
		}
	}
	return 0;
}
BBINT _openb3d_openb3dex_TAction_AppendAction_TTAction(struct openb3d_openb3dex_TAction_obj* o,struct openb3d_openb3dex_TAction_obj* bbt_act2){
	AppendAction(o->clas->f_GetInstance_pb_TTAction(o),o->clas->f_GetInstance_pb_TTAction(bbt_act2));
	return 0;
}
BBINT _openb3d_openb3dex_TAction_FreeAction(struct openb3d_openb3dex_TAction_obj* o){
	if(o->_openb3d_openb3dex_taction_exists !=0){
		brl_linkedlist_ListRemove(openb3d_openb3dex_TAction_action_list,o);
		openb3d_openb3dex_TAction_action_list_id-=1;
		o->clas->f_FreeObject_i_pb(o->clas->f_GetInstance_pb_TTAction(o));
		FreeAction(o->clas->f_GetInstance_pb_TTAction(o));
		o->_openb3d_openb3dex_taction_exists =0;
	}
	return 0;
}
struct brl_map_TMap_obj* openb3d_openb3dex_TAction_action_map;
struct brl_linkedlist_TList_obj* openb3d_openb3dex_TAction_action_list;
BBINT openb3d_openb3dex_TAction_action_list_id;
struct BBDebugScope_16 openb3d_openb3dex_TAction_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TAction",
	{
		{
			BBDEBUGDECL_FIELD,
			"act",
			"*i",
			.field_offset=offsetof(struct openb3d_openb3dex_TAction_obj,_openb3d_openb3dex_taction_act)
		},
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TAction_obj,_openb3d_openb3dex_taction_instance)
		},
		{
			BBDEBUGDECL_FIELD,
			"exists",
			"i",
			.field_offset=offsetof(struct openb3d_openb3dex_TAction_obj,_openb3d_openb3dex_taction_exists)
		},
		{
			BBDEBUGDECL_GLOBAL,
			"action_list",
			":TList",
			&openb3d_openb3dex_TAction_action_list
		},
		{
			BBDEBUGDECL_GLOBAL,
			"action_map",
			":TMap",
			&openb3d_openb3dex_TAction_action_map
		},
		{
			BBDEBUGDECL_GLOBAL,
			"action_list_id",
			"i",
			&openb3d_openb3dex_TAction_action_list_id
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TAction_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TAction",
			&openb3d_openb3dex_TAction_CreateObject_TTAction_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"FreeObject",
			"(*b)i",
			&openb3d_openb3dex_TAction_FreeObject_i_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetObject",
			"(*b):TAction",
			&openb3d_openb3dex_TAction_GetObject_TTAction_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TAction)*b",
			&openb3d_openb3dex_TAction_GetInstance_pb_TTAction
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TAction_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"AddList_",
			"(:TList)i",
			&openb3d_openb3dex_TAction_AddList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CopyList_",
			"(:TList)i",
			&openb3d_openb3dex_TAction_CopyList__i_TTList
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"AppendAction",
			"(:TAction)i",
			&_openb3d_openb3dex_TAction_AppendAction_TTAction
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"FreeAction",
			"()i",
			&_openb3d_openb3dex_TAction_FreeAction
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TAction openb3d_openb3dex_TAction={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TAction_scope,
	sizeof(struct openb3d_openb3dex_TAction_obj),
	_openb3d_openb3dex_TAction_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TAction_obj,_openb3d_openb3dex_taction_exists) - sizeof(void*) + sizeof(BBINT)
	,openb3d_openb3dex_TAction_CreateObject_TTAction_pb
	,openb3d_openb3dex_TAction_FreeObject_i_pb
	,openb3d_openb3dex_TAction_GetObject_TTAction_pb
	,openb3d_openb3dex_TAction_GetInstance_pb_TTAction
	,_openb3d_openb3dex_TAction_InitFields
	,openb3d_openb3dex_TAction_AddList__i_TTList
	,openb3d_openb3dex_TAction_CopyList__i_TTList
	,_openb3d_openb3dex_TAction_AppendAction_TTAction
	,_openb3d_openb3dex_TAction_FreeAction
};

void _openb3d_openb3dex_TConstraint_New(struct openb3d_openb3dex_TConstraint_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TConstraint;
	o->_openb3d_openb3dex_tconstraint_instance = 0;
}
struct openb3d_openb3dex_TConstraint_obj* openb3d_openb3dex_TConstraint_CreateObject_TTConstraint_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TConstraint_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TConstraint);
	bbt_obj->_openb3d_openb3dex_tconstraint_instance =bbt_inst;
	return bbt_obj;
}
BBBYTE* openb3d_openb3dex_TConstraint_GetInstance_pb_TTConstraint(struct openb3d_openb3dex_TConstraint_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_tconstraint_instance ;
}
struct openb3d_openb3dex_TConstraint_obj* openb3d_openb3dex_TConstraint_CreateConstraint_TTConstraint_TTEntityTTEntityf(struct openb3d_openb3dex_TEntity_obj* bbt_p1,struct openb3d_openb3dex_TEntity_obj* bbt_p2,BBFLOAT bbt_l){
	BBBYTE* bbt_inst=CreateConstraint(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_p1),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_p2),bbt_l);
	return openb3d_openb3dex_TConstraint_CreateObject_TTConstraint_pb(bbt_inst);
}
struct BBDebugScope_5 openb3d_openb3dex_TConstraint_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TConstraint",
	{
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TConstraint_obj,_openb3d_openb3dex_tconstraint_instance)
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TConstraint_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TConstraint",
			&openb3d_openb3dex_TConstraint_CreateObject_TTConstraint_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TConstraint)*b",
			&openb3d_openb3dex_TConstraint_GetInstance_pb_TTConstraint
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateConstraint",
			"(:TEntity,:TEntity,f):TConstraint",
			&openb3d_openb3dex_TConstraint_CreateConstraint_TTConstraint_TTEntityTTEntityf
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TConstraint openb3d_openb3dex_TConstraint={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TConstraint_scope,
	sizeof(struct openb3d_openb3dex_TConstraint_obj),
	_openb3d_openb3dex_TConstraint_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TConstraint_obj,_openb3d_openb3dex_tconstraint_instance) - sizeof(void*) + sizeof(BBBYTE*)
	,openb3d_openb3dex_TConstraint_CreateObject_TTConstraint_pb
	,openb3d_openb3dex_TConstraint_GetInstance_pb_TTConstraint
	,openb3d_openb3dex_TConstraint_CreateConstraint_TTConstraint_TTEntityTTEntityf
};

void _openb3d_openb3dex_TRigidBody_New(struct openb3d_openb3dex_TRigidBody_obj* o) {
	bbObjectCtor(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TRigidBody;
	o->_openb3d_openb3dex_trigidbody_instance = 0;
}
struct openb3d_openb3dex_TRigidBody_obj* openb3d_openb3dex_TRigidBody_CreateObject_TTRigidBody_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TRigidBody_obj* volatile bbt_obj=bbObjectAtomicNew(&openb3d_openb3dex_TRigidBody);
	bbt_obj->_openb3d_openb3dex_trigidbody_instance =bbt_inst;
	return bbt_obj;
}
BBBYTE* openb3d_openb3dex_TRigidBody_GetInstance_pb_TTRigidBody(struct openb3d_openb3dex_TRigidBody_obj* bbt_obj){
	if(bbt_obj==&bbNullObject){
		return 0;
	}
	return bbt_obj->_openb3d_openb3dex_trigidbody_instance ;
}
struct openb3d_openb3dex_TRigidBody_obj* openb3d_openb3dex_TRigidBody_CreateRigidBody_TTRigidBody_TTEntityTTEntityTTEntityTTEntityTTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_body,struct openb3d_openb3dex_TEntity_obj* bbt_p1,struct openb3d_openb3dex_TEntity_obj* bbt_p2,struct openb3d_openb3dex_TEntity_obj* bbt_p3,struct openb3d_openb3dex_TEntity_obj* bbt_p4){
	BBBYTE* bbt_inst=CreateRigidBody(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_body),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_p1),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_p2),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_p3),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_p4));
	return openb3d_openb3dex_TRigidBody_CreateObject_TTRigidBody_pb(bbt_inst);
}
struct BBDebugScope_5 openb3d_openb3dex_TRigidBody_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TRigidBody",
	{
		{
			BBDEBUGDECL_FIELD,
			"instance",
			"*b",
			.field_offset=offsetof(struct openb3d_openb3dex_TRigidBody_obj,_openb3d_openb3dex_trigidbody_instance)
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TRigidBody_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TRigidBody",
			&openb3d_openb3dex_TRigidBody_CreateObject_TTRigidBody_pb
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"GetInstance",
			"(:TRigidBody)*b",
			&openb3d_openb3dex_TRigidBody_GetInstance_pb_TTRigidBody
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateRigidBody",
			"(:TEntity,:TEntity,:TEntity,:TEntity,:TEntity):TRigidBody",
			&openb3d_openb3dex_TRigidBody_CreateRigidBody_TTRigidBody_TTEntityTTEntityTTEntityTTEntityTTEntity
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TRigidBody openb3d_openb3dex_TRigidBody={
	&bbObjectClass,
	bbObjectFree,
	&openb3d_openb3dex_TRigidBody_scope,
	sizeof(struct openb3d_openb3dex_TRigidBody_obj),
	_openb3d_openb3dex_TRigidBody_New,
	bbObjectDtor,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	offsetof(struct openb3d_openb3dex_TRigidBody_obj,_openb3d_openb3dex_trigidbody_instance) - sizeof(void*) + sizeof(BBBYTE*)
	,openb3d_openb3dex_TRigidBody_CreateObject_TTRigidBody_pb
	,openb3d_openb3dex_TRigidBody_GetInstance_pb_TTRigidBody
	,openb3d_openb3dex_TRigidBody_CreateRigidBody_TTRigidBody_TTEntityTTEntityTTEntityTTEntityTTEntity
};

void _openb3d_openb3dex_TParticleBatch_New(struct openb3d_openb3dex_TParticleBatch_obj* o) {
	_openb3d_openb3dex_TMesh_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TParticleBatch;
}
void _openb3d_openb3dex_TParticleBatch_Delete(struct openb3d_openb3dex_TParticleBatch_obj* o) {
	_openb3d_openb3dex_TMesh_Delete(o);
}
struct openb3d_openb3dex_TParticleBatch_obj* openb3d_openb3dex_TParticleBatch_CreateObject_TTParticleBatch_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TParticleBatch_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TParticleBatch);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TParticleBatch_InitFields(struct openb3d_openb3dex_TParticleBatch_obj* o){
	(&openb3d_openb3dex_TParticleBatch)->super->m_InitFields(o);
	return 0;
}
struct BBDebugScope_3 openb3d_openb3dex_TParticleBatch_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TParticleBatch",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TParticleBatch_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TParticleBatch",
			&openb3d_openb3dex_TParticleBatch_CreateObject_TTParticleBatch_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TParticleBatch_InitFields
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TParticleBatch openb3d_openb3dex_TParticleBatch={
	&openb3d_openb3dex_TMesh,
	bbObjectFree,
	&openb3d_openb3dex_TParticleBatch_scope,
	sizeof(struct openb3d_openb3dex_TParticleBatch_obj),
	_openb3d_openb3dex_TParticleBatch_New,
	_openb3d_openb3dex_TParticleBatch_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,_openb3d_openb3dex_TMesh_CopyEntity_TTEntity
	,_openb3d_openb3dex_TMesh_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TParticleBatch_InitFields
	,_openb3d_openb3dex_TMesh_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TMesh_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TMesh_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TMesh_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TParticleBatch_CreateObject_TTParticleBatch_pb
	,_openb3d_openb3dex_TMesh_CreateBone_TTEntity
	,openb3d_openb3dex_TMesh_CreatePlane_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateQuad_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_MeshCSG_TTMesh_TTMeshTTMeshi
	,_openb3d_openb3dex_TMesh_MeshesIntersect_TTMesh
	,_openb3d_openb3dex_TMesh_RepeatMesh_TTEntity
	,_openb3d_openb3dex_TMesh_SkinMesh_iiifififif
	,openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_LoadMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_LoadAnimMesh_TTMesh_STTEntity
	,openb3d_openb3dex_TMesh_CreateCube_TTMesh_TTEntity
	,openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity
	,openb3d_openb3dex_TMesh_CreateCylinder_TTMesh_iiTTEntity
	,openb3d_openb3dex_TMesh_CreateCone_TTMesh_iiTTEntity
	,_openb3d_openb3dex_TMesh_CopyMesh_TTEntity
	,_openb3d_openb3dex_TMesh_AddMesh_TTMesh
	,_openb3d_openb3dex_TMesh_FlipMesh
	,_openb3d_openb3dex_TMesh_PaintMesh_TTBrush
	,_openb3d_openb3dex_TMesh_FitMesh_ffffffi
	,_openb3d_openb3dex_TMesh_ScaleMesh_fff
	,_openb3d_openb3dex_TMesh_RotateMesh_fff
	,_openb3d_openb3dex_TMesh_PositionMesh_fff
	,_openb3d_openb3dex_TMesh_UpdateNormals
	,_openb3d_openb3dex_TMesh_CreateSurface_TTBrush
	,_openb3d_openb3dex_TMesh_MeshWidth
	,_openb3d_openb3dex_TMesh_MeshHeight
	,_openb3d_openb3dex_TMesh_MeshDepth
	,_openb3d_openb3dex_TMesh_CountSurfaces
	,_openb3d_openb3dex_TMesh_GetSurface_i
	,_openb3d_openb3dex_TMesh_FindSurface_TTBrush
	,_openb3d_openb3dex_TMesh_CountVertices
	,_openb3d_openb3dex_TMesh_CountTriangles
	,openb3d_openb3dex_TMesh_CopyBonesList_i_TTEntity
	,_openb3d_openb3dex_TMesh_CollapseAnimMesh_TTMesh
	,_openb3d_openb3dex_TMesh_CollapseChildren_TTEntityTTMesh
	,_openb3d_openb3dex_TMesh_TransformMesh_TTMatrix
	,_openb3d_openb3dex_TMesh_GetBounds
	,_openb3d_openb3dex_TMesh_Alpha
	,_openb3d_openb3dex_TMesh_MeshColor_ffff
	,_openb3d_openb3dex_TMesh_MeshRed_f
	,_openb3d_openb3dex_TMesh_MeshGreen_f
	,_openb3d_openb3dex_TMesh_MeshBlue_f
	,_openb3d_openb3dex_TMesh_MeshAlpha_f
	,_openb3d_openb3dex_TMesh_TreeCheck
	,_openb3d_openb3dex_TMesh_Render
	,_openb3d_openb3dex_TMesh_UpdateShadow
};

void _openb3d_openb3dex_TParticleEmitter_New(struct openb3d_openb3dex_TParticleEmitter_obj* o) {
	_openb3d_openb3dex_TEntity_New(o);
	o->clas = (BBClass*)&openb3d_openb3dex_TParticleEmitter;
}
void _openb3d_openb3dex_TParticleEmitter_Delete(struct openb3d_openb3dex_TParticleEmitter_obj* o) {
	_openb3d_openb3dex_TEntity_Delete(o);
}
struct openb3d_openb3dex_TParticleEmitter_obj* openb3d_openb3dex_TParticleEmitter_CreateObject_TTParticleEmitter_pb(BBBYTE* bbt_inst){
	if(bbt_inst==0){
		return &bbNullObject;
	}
	struct openb3d_openb3dex_TParticleEmitter_obj* volatile bbt_obj=bbObjectNew(&openb3d_openb3dex_TParticleEmitter);
	(openb3d_openb3dex_TEntity_ent_map)->clas->m_Insert_TObjectTObject(openb3d_openb3dex_TEntity_ent_map,bbStringFromLong((BBLONG)bbt_inst),bbt_obj);
	bbt_obj->_openb3d_openb3dex_tentity_instance =bbt_inst;
	(bbt_obj)->clas->m_InitFields(bbt_obj);
	return bbt_obj;
}
BBINT _openb3d_openb3dex_TParticleEmitter_InitFields(struct openb3d_openb3dex_TParticleEmitter_obj* o){
	(&openb3d_openb3dex_TParticleEmitter)->super->m_InitFields(o);
	return 0;
}
struct openb3d_openb3dex_TParticleEmitter_obj* openb3d_openb3dex_TParticleEmitter_CreateParticleEmitter_TTParticleEmitter_TTEntityTTEntity(struct openb3d_openb3dex_TEntity_obj* bbt_particle,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	BBBYTE* bbt_inst=CreateParticleEmitter(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_particle),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent_ent));
	return openb3d_openb3dex_TParticleEmitter_CreateObject_TTParticleEmitter_pb(bbt_inst);
}
BBINT _openb3d_openb3dex_TParticleEmitter_EmitterVector_fff(struct openb3d_openb3dex_TParticleEmitter_obj* o,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	EmitterVector(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT _openb3d_openb3dex_TParticleEmitter_EmitterRate_f(struct openb3d_openb3dex_TParticleEmitter_obj* o,BBFLOAT bbt_r){
	EmitterRate(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_r);
	return 0;
}
BBINT _openb3d_openb3dex_TParticleEmitter_EmitterParticleLife_i(struct openb3d_openb3dex_TParticleEmitter_obj* o,BBINT bbt_l){
	EmitterParticleLife(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_l);
	return 0;
}
BBINT _openb3d_openb3dex_TParticleEmitter_EmitterParticleFunction_F_pbi_i_(struct openb3d_openb3dex_TParticleEmitter_obj* o,BBINT(* bbt_EmitterFunction)(BBBYTE*,BBINT)){
	EmitterParticleFunction(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_EmitterFunction);
	return 0;
}
BBINT _openb3d_openb3dex_TParticleEmitter_EmitterParticleSpeed_f(struct openb3d_openb3dex_TParticleEmitter_obj* o,BBFLOAT bbt_s){
	EmitterParticleSpeed(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_s);
	return 0;
}
BBINT _openb3d_openb3dex_TParticleEmitter_EmitterVariance_f(struct openb3d_openb3dex_TParticleEmitter_obj* o,BBFLOAT bbt_v){
	EmitterVariance(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),bbt_v);
	return 0;
}
struct openb3d_openb3dex_TParticleEmitter_obj* _openb3d_openb3dex_TParticleEmitter_CopyEntity_TTEntity(struct openb3d_openb3dex_TParticleEmitter_obj* o,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	BBBYTE* bbt_inst=CopyEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(o,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_parent));
	struct openb3d_openb3dex_TParticleEmitter_obj* volatile bbt_particle=o->clas->f_CreateObject_TTParticleEmitter_pb(bbt_inst);
	if(o->_openb3d_openb3dex_tentity_pick_mode [0U]!=0){
		openb3d_openb3dex_TPick_AddList__i_TTList(openb3d_openb3dex_TPick_ent_list);
	}
	return bbt_particle;
}
BBINT _openb3d_openb3dex_TParticleEmitter_Update(struct openb3d_openb3dex_TParticleEmitter_obj* o){
	return 0;
}
struct BBDebugScope_12 openb3d_openb3dex_TParticleEmitter_scope ={
	BBDEBUGSCOPE_USERTYPE,
	"TParticleEmitter",
	{
		{
			BBDEBUGDECL_TYPEMETHOD,
			"New",
			"()i",
			&_openb3d_openb3dex_TParticleEmitter_New
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateObject",
			"(*b):TParticleEmitter",
			&openb3d_openb3dex_TParticleEmitter_CreateObject_TTParticleEmitter_pb
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"InitFields",
			"()i",
			&_openb3d_openb3dex_TParticleEmitter_InitFields
		},
		{
			BBDEBUGDECL_TYPEFUNCTION,
			"CreateParticleEmitter",
			"(:TEntity,:TEntity):TParticleEmitter",
			&openb3d_openb3dex_TParticleEmitter_CreateParticleEmitter_TTParticleEmitter_TTEntityTTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EmitterVector",
			"(f,f,f)i",
			&_openb3d_openb3dex_TParticleEmitter_EmitterVector_fff
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EmitterRate",
			"(f)i",
			&_openb3d_openb3dex_TParticleEmitter_EmitterRate_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EmitterParticleLife",
			"(i)i",
			&_openb3d_openb3dex_TParticleEmitter_EmitterParticleLife_i
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EmitterParticleFunction",
			"((*b,i)i)i",
			&_openb3d_openb3dex_TParticleEmitter_EmitterParticleFunction_F_pbi_i_
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EmitterParticleSpeed",
			"(f)i",
			&_openb3d_openb3dex_TParticleEmitter_EmitterParticleSpeed_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"EmitterVariance",
			"(f)i",
			&_openb3d_openb3dex_TParticleEmitter_EmitterVariance_f
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"CopyEntity",
			"(:TEntity):TParticleEmitter",
			&_openb3d_openb3dex_TParticleEmitter_CopyEntity_TTEntity
		},
		{
			BBDEBUGDECL_TYPEMETHOD,
			"Update",
			"()i",
			&_openb3d_openb3dex_TParticleEmitter_Update
		},
		BBDEBUGDECL_END
	}
};
struct BBClass_openb3d_openb3dex_TParticleEmitter openb3d_openb3dex_TParticleEmitter={
	&openb3d_openb3dex_TEntity,
	bbObjectFree,
	&openb3d_openb3dex_TParticleEmitter_scope,
	sizeof(struct openb3d_openb3dex_TParticleEmitter_obj),
	_openb3d_openb3dex_TParticleEmitter_New,
	_openb3d_openb3dex_TParticleEmitter_Delete,
	bbObjectToString,
	bbObjectCompare,
	bbObjectSendMessage,
	0,
	0,
	0
	,_openb3d_openb3dex_TParticleEmitter_CopyEntity_TTEntity
	,_openb3d_openb3dex_TParticleEmitter_Update
	,openb3d_openb3dex_TEntity_FreeObject_i_pb
	,openb3d_openb3dex_TEntity_GetObject_TTEntity_pb
	,openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity
	,openb3d_openb3dex_TEntity_InitGlobals_i
	,_openb3d_openb3dex_TParticleEmitter_InitFields
	,_openb3d_openb3dex_TEntity_AddList_TTList
	,openb3d_openb3dex_TEntity_AddList__i_TTList
	,_openb3d_openb3dex_TEntity_CopyList_TTList
	,openb3d_openb3dex_TEntity_CopyList__i_TTList
	,_openb3d_openb3dex_TEntity_ListPushBack_TTListTObject
	,_openb3d_openb3dex_TEntity_AddAnimSeq_i
	,_openb3d_openb3dex_TEntity_SetAnimKey_fiii
	,_openb3d_openb3dex_TEntity_AlignToVector_fffif
	,_openb3d_openb3dex_TEntity_FreeEntity
	,_openb3d_openb3dex_TEntity_FreeEntityList
	,_openb3d_openb3dex_TEntity_PositionEntity_fffi
	,_openb3d_openb3dex_TEntity_MoveEntity_fff
	,_openb3d_openb3dex_TEntity_TranslateEntity_fffi
	,_openb3d_openb3dex_TEntity_ScaleEntity_fffi
	,_openb3d_openb3dex_TEntity_RotateEntity_fffi
	,_openb3d_openb3dex_TEntity_TurnEntity_fffi
	,_openb3d_openb3dex_TEntity_PointEntity_TTEntityf
	,_openb3d_openb3dex_TEntity_LoadAnimSeq_S
	,_openb3d_openb3dex_TEntity_ExtractAnimSeq_iii
	,_openb3d_openb3dex_TEntity_Animate_ifii
	,_openb3d_openb3dex_TEntity_SetAnimTime_fi
	,_openb3d_openb3dex_TEntity_AnimSeq
	,_openb3d_openb3dex_TEntity_AnimLength
	,_openb3d_openb3dex_TEntity_AnimTime
	,_openb3d_openb3dex_TEntity_Animating
	,_openb3d_openb3dex_TEntity_EntityColor_fff
	,_openb3d_openb3dex_TEntity_EntityAlpha_f
	,_openb3d_openb3dex_TEntity_EntityShininess_f
	,_openb3d_openb3dex_TEntity_EntityTexture_TTTextureii
	,_openb3d_openb3dex_TEntity_EntityBlend_i
	,_openb3d_openb3dex_TEntity_EntityFX_i
	,_openb3d_openb3dex_TEntity_PaintEntity_TTBrush
	,_openb3d_openb3dex_TEntity_GetEntityBrush
	,_openb3d_openb3dex_TEntity_EntityOrder_i
	,_openb3d_openb3dex_TEntity_ShowEntity
	,_openb3d_openb3dex_TEntity_HideEntity
	,_openb3d_openb3dex_TEntity_NameEntity_S
	,_openb3d_openb3dex_TEntity_EntityParent_TTEntityi
	,_openb3d_openb3dex_TEntity_GetParent
	,_openb3d_openb3dex_TEntity_EntityX_i
	,_openb3d_openb3dex_TEntity_EntityY_i
	,_openb3d_openb3dex_TEntity_EntityZ_i
	,_openb3d_openb3dex_TEntity_EntityPitch_i
	,_openb3d_openb3dex_TEntity_EntityYaw_i
	,_openb3d_openb3dex_TEntity_EntityRoll_i
	,_openb3d_openb3dex_TEntity_EntityClass
	,_openb3d_openb3dex_TEntity_EntityName
	,_openb3d_openb3dex_TEntity_CountChildren
	,_openb3d_openb3dex_TEntity_GetChild_i
	,_openb3d_openb3dex_TEntity_FindChild_S
	,_openb3d_openb3dex_TEntity_EntityPick_f
	,_openb3d_openb3dex_TEntity_LinePick_fffffff
	,_openb3d_openb3dex_TEntity_EntityVisible_TTEntityTTEntity
	,_openb3d_openb3dex_TEntity_EntityDistance_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaYaw_TTEntity
	,_openb3d_openb3dex_TEntity_DeltaPitch_TTEntity
	,openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity
	,openb3d_openb3dex_TEntity_TFormedX_f
	,openb3d_openb3dex_TEntity_TFormedY_f
	,openb3d_openb3dex_TEntity_TFormedZ_f
	,_openb3d_openb3dex_TEntity_GetMatElement_ii
	,_openb3d_openb3dex_TEntity_ResetEntity
	,_openb3d_openb3dex_TEntity_EntityRadius_ff
	,_openb3d_openb3dex_TEntity_EntityBox_ffffff
	,_openb3d_openb3dex_TEntity_EntityType_ii
	,_openb3d_openb3dex_TEntity_EntityPickMode_ii
	,_openb3d_openb3dex_TEntity_EntityCollided_i
	,_openb3d_openb3dex_TEntity_CountCollisions
	,_openb3d_openb3dex_TEntity_CollisionX_i
	,_openb3d_openb3dex_TEntity_CollisionY_i
	,_openb3d_openb3dex_TEntity_CollisionZ_i
	,_openb3d_openb3dex_TEntity_CollisionNX_i
	,_openb3d_openb3dex_TEntity_CollisionNY_i
	,_openb3d_openb3dex_TEntity_CollisionNZ_i
	,_openb3d_openb3dex_TEntity_CollisionTime_i
	,_openb3d_openb3dex_TEntity_CollisionEntity_i
	,_openb3d_openb3dex_TEntity_CollisionSurface_i
	,_openb3d_openb3dex_TEntity_CollisionTriangle_i
	,_openb3d_openb3dex_TEntity_GetEntityType
	,_openb3d_openb3dex_TEntity_MeshCullRadius_f
	,_openb3d_openb3dex_TEntity_EntityScaleX_i
	,_openb3d_openb3dex_TEntity_EntityScaleY_i
	,_openb3d_openb3dex_TEntity_EntityScaleZ_i
	,_openb3d_openb3dex_TEntity_Hidden
	,openb3d_openb3dex_TEntity_CountAllChildren_i_TTEntityi
	,_openb3d_openb3dex_TEntity_GetChildFromAll_iviTTEntity
	,_openb3d_openb3dex_TEntity_ListParents_TTList
	,_openb3d_openb3dex_TEntity_UpdateMat_b
	,_openb3d_openb3dex_TEntity_AddParent_TTEntity
	,openb3d_openb3dex_TEntity_UpdateChildren_i_TTEntity
	,_openb3d_openb3dex_TEntity_EntityDistanceSquared_TTEntity
	,_openb3d_openb3dex_TEntity_MQ_Update
	,_openb3d_openb3dex_TEntity_MQ_GetInvMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_ApplyNewtonTransform_pf
	,_openb3d_openb3dex_TEntity_MQ_SetMatrix_TTMatrix
	,_openb3d_openb3dex_TEntity_MQ_GetScaleXYZ_vfvfvf
	,_openb3d_openb3dex_TEntity_MQ_Turn_ffffi
	,openb3d_openb3dex_TParticleEmitter_CreateObject_TTParticleEmitter_pb
	,openb3d_openb3dex_TParticleEmitter_CreateParticleEmitter_TTParticleEmitter_TTEntityTTEntity
	,_openb3d_openb3dex_TParticleEmitter_EmitterVector_fff
	,_openb3d_openb3dex_TParticleEmitter_EmitterRate_f
	,_openb3d_openb3dex_TParticleEmitter_EmitterParticleLife_i
	,_openb3d_openb3dex_TParticleEmitter_EmitterParticleFunction_F_pbi_i_
	,_openb3d_openb3dex_TParticleEmitter_EmitterParticleSpeed_f
	,_openb3d_openb3dex_TParticleEmitter_EmitterVariance_f
};

BBINT openb3d_openb3dex_BeginMax2D(){
	openb3d_openb3dex_TBlitz2D_BeginMax2D_i();
	return 0;
}
BBINT openb3d_openb3dex_EndMax2D(){
	openb3d_openb3dex_TBlitz2D_EndMax2D_i();
	return 0;
}
BBINT openb3d_openb3dex_CopyList(struct brl_linkedlist_TList_obj* bbt_list){
	openb3d_openb3dex_TGlobal_CopyList_i_TTList(bbt_list);
	return 0;
}
BBINT openb3d_openb3dex_ListPushBack(struct brl_linkedlist_TList_obj* bbt_list,BBOBJECT bbt_value,struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	openb3d_openb3dex_TGlobal_ListPushBack_i_TTListTObjectTTEntity(bbt_list,bbt_value,bbt_ent);
	return 0;
}
BBINT openb3d_openb3dex_AddSurface(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_anim_surf){
	if(bbt_anim_surf==0){
		(bbt_mesh)->clas->m_ListPushBack_TTListTObject(bbt_mesh,bbt_mesh->_openb3d_openb3dex_tmesh_surf_list ,bbt_surf);
	}else{
		(bbt_mesh)->clas->m_ListPushBack_TTListTObject(bbt_mesh,bbt_mesh->_openb3d_openb3dex_tmesh_anim_surf_list ,bbt_surf);
	}
	return 0;
}
BBINT openb3d_openb3dex_Quaternion_FromAngleAxis(BBFLOAT bbt_angle,BBFLOAT bbt_ax,BBFLOAT bbt_ay,BBFLOAT bbt_az,BBFLOAT* bbt_rx,BBFLOAT* bbt_ry,BBFLOAT* bbt_rz,BBFLOAT* bbt_rw){
	MatrixQuaternion_FromAngleAxis(bbt_angle,bbt_ax,bbt_ay,bbt_az,&(*bbt_rx),&(*bbt_ry),&(*bbt_rz),&(*bbt_rw));
	return 0;
}
BBINT openb3d_openb3dex_Quaternion_MultiplyQuat(BBFLOAT bbt_x1,BBFLOAT bbt_y1,BBFLOAT bbt_z1,BBFLOAT bbt_w1,BBFLOAT bbt_x2,BBFLOAT bbt_y2,BBFLOAT bbt_z2,BBFLOAT bbt_w2,BBFLOAT* bbt_rx,BBFLOAT* bbt_ry,BBFLOAT* bbt_rz,BBFLOAT* bbt_rw){
	MatrixQuaternion_MultiplyQuat(bbt_x1,bbt_y1,bbt_z1,bbt_w1,bbt_x2,bbt_y2,bbt_z2,bbt_w2,&(*bbt_rx),&(*bbt_ry),&(*bbt_rz),&(*bbt_rw));
	return 0;
}
BBINT openb3d_openb3dex_InterpolateMatrix(struct openb3d_openb3dex_TMatrix_obj* bbt_m,struct openb3d_openb3dex_TMatrix_obj* bbt_a,BBFLOAT bbt_alpha){
	MatrixInterpolateMatrix(openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(bbt_m),openb3d_openb3dex_TMatrix_GetInstance_pb_TTMatrix(bbt_a),bbt_alpha);
	return 0;
}
BBINT openb3d_openb3dex_BoxFromPoints(BBFLOAT bbt_px1,BBFLOAT bbt_py1,BBFLOAT bbt_pz1,BBFLOAT bbt_px2,BBFLOAT bbt_py2,BBFLOAT bbt_pz2,BBFLOAT* bbt_bx1,BBFLOAT* bbt_by1,BBFLOAT* bbt_bz1,BBFLOAT* bbt_bx2,BBFLOAT* bbt_by2,BBFLOAT* bbt_bz2){
	if(bbt_px1<bbt_px2){
		*bbt_bx1=bbt_px1;
		*bbt_bx2=bbt_px2;
	}else{
		*bbt_bx1=bbt_px2;
		*bbt_bx2=bbt_px1;
	}
	if(bbt_py1<bbt_py2){
		*bbt_by1=bbt_py1;
		*bbt_by2=bbt_py2;
	}else{
		*bbt_by1=bbt_py2;
		*bbt_by2=bbt_py1;
	}
	if(bbt_pz1<bbt_pz2){
		*bbt_bz1=bbt_pz1;
		*bbt_bz2=bbt_pz2;
	}else{
		*bbt_bz1=bbt_pz2;
		*bbt_bz2=bbt_pz1;
	}
	return 0;
}
BBINT openb3d_openb3dex_BoxFromTri(BBFLOAT bbt_tx1,BBFLOAT bbt_ty1,BBFLOAT bbt_tz1,BBFLOAT bbt_tx2,BBFLOAT bbt_ty2,BBFLOAT bbt_tz2,BBFLOAT bbt_tx3,BBFLOAT bbt_ty3,BBFLOAT bbt_tz3,BBFLOAT* bbt_bx1,BBFLOAT* bbt_by1,BBFLOAT* bbt_bz1,BBFLOAT* bbt_bx2,BBFLOAT* bbt_by2,BBFLOAT* bbt_bz2){
	*bbt_bx1=1000000.00f;
	*bbt_by1=1000000.00f;
	*bbt_bz1=1000000.00f;
	*bbt_bx2=-1000000.00f;
	*bbt_by2=-1000000.00f;
	*bbt_bz2=-1000000.00f;
	if(bbt_tx1<*bbt_bx1){
		*bbt_bx1=bbt_tx1;
	}
	if(bbt_ty1<*bbt_by1){
		*bbt_by1=bbt_ty1;
	}
	if(bbt_tz1<*bbt_bz1){
		*bbt_bz1=bbt_tz1;
	}
	if(bbt_tx2<*bbt_bx1){
		*bbt_bx1=bbt_tx2;
	}
	if(bbt_ty2<*bbt_by1){
		*bbt_by1=bbt_ty2;
	}
	if(bbt_tz2<*bbt_bz1){
		*bbt_bz1=bbt_tz2;
	}
	if(bbt_tx3<*bbt_bx1){
		*bbt_bx1=bbt_tx3;
	}
	if(bbt_ty3<*bbt_by1){
		*bbt_by1=bbt_ty3;
	}
	if(bbt_tz3<*bbt_bz1){
		*bbt_bz1=bbt_tz3;
	}
	if(bbt_tx1>*bbt_bx2){
		*bbt_bx2=bbt_tx1;
	}
	if(bbt_ty1>*bbt_by2){
		*bbt_by2=bbt_ty1;
	}
	if(bbt_tz1>*bbt_bz2){
		*bbt_bz2=bbt_tz1;
	}
	if(bbt_tx2>*bbt_bx2){
		*bbt_bx2=bbt_tx2;
	}
	if(bbt_ty2>*bbt_by2){
		*bbt_by2=bbt_ty2;
	}
	if(bbt_tz2>*bbt_bz2){
		*bbt_bz2=bbt_tz2;
	}
	if(bbt_tx3>*bbt_bx2){
		*bbt_bx2=bbt_tx3;
	}
	if(bbt_ty3>*bbt_by2){
		*bbt_by2=bbt_ty3;
	}
	if(bbt_tz3>*bbt_bz2){
		*bbt_bz2=bbt_tz3;
	}
	return 0;
}
BBINT openb3d_openb3dex_BoxBoxIntersection(BBFLOAT bbt_ax1,BBFLOAT bbt_ay1,BBFLOAT bbt_az1,BBFLOAT bbt_ax2,BBFLOAT bbt_ay2,BBFLOAT bbt_az2,BBFLOAT bbt_bx1,BBFLOAT bbt_by1,BBFLOAT bbt_bz1,BBFLOAT bbt_bx2,BBFLOAT bbt_by2,BBFLOAT bbt_bz2){
	if((bbt_ax2<bbt_bx1) || (bbt_ax1>bbt_bx2)){
		return 0;
	}
	if((bbt_ay2<bbt_by1) || (bbt_ay1>bbt_by2)){
		return 0;
	}
	if((bbt_az2<bbt_bz1) || (bbt_az1>bbt_bz2)){
		return 0;
	}
	return 1;
}
BBINT openb3d_openb3dex_BoxSphereIntersection(BBFLOAT bbt_x1,BBFLOAT bbt_y1,BBFLOAT bbt_z1,BBFLOAT bbt_x2,BBFLOAT bbt_y2,BBFLOAT bbt_z2,BBFLOAT bbt_sx,BBFLOAT bbt_sy,BBFLOAT bbt_sz,BBFLOAT bbt_sr){
	BBFLOAT bbt_dmin=0.000000000f;
	BBFLOAT bbt_sr2=(bbt_sr*bbt_sr);
	if(bbt_sx<bbt_x1){
		bbt_dmin=(bbt_dmin+((bbt_sx-bbt_x1)*(bbt_sx-bbt_x1)));
	}else{
		if(bbt_sx>bbt_x2){
			bbt_dmin=(bbt_dmin+((bbt_sx-bbt_x2)*(bbt_sx-bbt_x2)));
		}
	}
	if(bbt_sy<bbt_y1){
		bbt_dmin=(bbt_dmin+((bbt_sy-bbt_y1)*(bbt_sy-bbt_y1)));
	}else{
		if(bbt_sy>bbt_y2){
			bbt_dmin=(bbt_dmin+((bbt_sy-bbt_y2)*(bbt_sy-bbt_y2)));
		}
	}
	if(bbt_sz<bbt_z1){
		bbt_dmin=(bbt_dmin+((bbt_sz-bbt_z1)*(bbt_sz-bbt_z2)));
	}else{
		if(bbt_sz>bbt_x2){
			bbt_dmin=(bbt_dmin+((bbt_sz-bbt_z2)*(bbt_sz-bbt_z2)));
		}
	}
	if(bbt_dmin<=bbt_sr2){
		return 1;
	}else{
		return 0;
	}
}
BBINT openb3d_openb3dex_FreeShader(struct openb3d_openb3dex_TShader_obj* bbt_shader){
	(bbt_shader)->clas->m_FreeShader(bbt_shader);
	return 0;
}
BBINT openb3d_openb3dex_FreeStencil(struct openb3d_openb3dex_TStencil_obj* bbt_stencil){
	(bbt_stencil)->clas->m_FreeStencil(bbt_stencil);
	return 0;
}
BBINT openb3d_openb3dex_BrushGLColor(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b,BBFLOAT bbt_a){
	BrushGLColor(openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_brush),bbt_r,bbt_g,bbt_b,bbt_a);
	return 0;
}
BBINT openb3d_openb3dex_BrushGLBlendFunc(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBINT bbt_sfactor,BBINT bbt_dfactor){
	BrushGLBlendFunc(openb3d_openb3dex_TBrush_GetInstance_pb_TTBrush(bbt_brush),bbt_sfactor,bbt_dfactor);
	return 0;
}
BBINT openb3d_openb3dex_TextureGLTexEnv(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_target,BBINT bbt_pname,BBINT bbt_param){
	TextureGLTexEnv(openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex),bbt_target,bbt_pname,bbt_param);
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_CreateTexture(BBINT bbt_width,BBINT bbt_height,BBINT bbt_flags,BBINT bbt_frames){
	return openb3d_openb3dex_TTexture_CreateTexture_TTTexture_iiii(bbt_width,bbt_height,bbt_flags,bbt_frames);
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_LoadTextureAlpha(BBSTRING bbt_file,BBINT bbt_flags,BBINT bbt_alphamask){
	return openb3d_openb3dex_TTexture_LoadTextureAlpha_TTTexture_Sii(bbt_file,bbt_flags,bbt_alphamask);
}
BBINT openb3d_openb3dex_TextureFlags(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_flags){
	(bbt_tex)->clas->m_TextureFlags_i(bbt_tex,bbt_flags);
	return 0;
}
BBINT openb3d_openb3dex_FreeSurface(struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	return (bbt_surf)->clas->m_FreeSurface(bbt_surf);
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_CopyBrush(struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	return (bbt_brush)->clas->m_Copy(bbt_brush);
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_CopySurface(struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	return (bbt_surf)->clas->m_Copy(bbt_surf);
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_CopyTexture(struct openb3d_openb3dex_TTexture_obj* bbt_tex){
	return (bbt_tex)->clas->m_Copy(bbt_tex);
}
BBINT openb3d_openb3dex_BackBufferToTex(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_frame){
	(bbt_tex)->clas->m_BackBufferToTex_i(bbt_tex,bbt_frame);
	return 0;
}
BBINT openb3d_openb3dex_MeshCullRadius(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_radius){
	MeshCullRadius(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_radius);
	return 0;
}
BBFLOAT openb3d_openb3dex_EntityScaleX(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityScaleX_i(bbt_ent,bbt_glob);
}
BBFLOAT openb3d_openb3dex_EntityScaleY(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityScaleY_i(bbt_ent,bbt_glob);
}
BBFLOAT openb3d_openb3dex_EntityScaleZ(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityScaleZ_i(bbt_ent,bbt_glob);
}
BBINT openb3d_openb3dex_BufferToTex(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBBYTE* bbt_buffer,BBINT bbt_frame){
	(bbt_tex)->clas->m_BufferToTex_pbi(bbt_tex,bbt_buffer,bbt_frame);
	return 0;
}
BBINT openb3d_openb3dex_CameraToTex(struct openb3d_openb3dex_TTexture_obj* bbt_tex,struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBINT bbt_frame){
	(bbt_tex)->clas->m_CameraToTex_TTCamerai(bbt_tex,bbt_cam,bbt_frame);
	return 0;
}
struct openb3d_openb3dex_TBone_obj* openb3d_openb3dex_CreateBone(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	return openb3d_openb3dex_TBone_CreateBone_TTBone_TTMeshTTEntity(bbt_mesh,bbt_parent_ent);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_CreateQuad(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_CreateQuad_TTMesh_TTEntity(bbt_parent);
}
BBINT openb3d_openb3dex_DepthBufferToTex(struct openb3d_openb3dex_TTexture_obj* bbt_tex,struct openb3d_openb3dex_TCamera_obj* bbt_cam){
	(bbt_tex)->clas->m_DepthBufferToTex_TTCamera(bbt_tex,bbt_cam);
	return 0;
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_MeshCSG(struct openb3d_openb3dex_TMesh_obj* bbt_m1,struct openb3d_openb3dex_TMesh_obj* bbt_m2,BBINT bbt_method_no){
	return openb3d_openb3dex_TMesh_MeshCSG_TTMesh_TTMeshTTMeshi(bbt_m1,bbt_m2,bbt_method_no);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_RepeatMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return (bbt_mesh)->clas->m_RepeatMesh_TTEntity(bbt_mesh,bbt_parent);
}
BBINT openb3d_openb3dex_SkinMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBINT bbt_surf_no_get,BBINT bbt_vid,BBINT bbt_bone1,BBFLOAT bbt_weight1,BBINT bbt_bone2,BBFLOAT bbt_weight2,BBINT bbt_bone3,BBFLOAT bbt_weight3,BBINT bbt_bone4,BBFLOAT bbt_weight4){
	(bbt_mesh)->clas->m_SkinMesh_iiifififif(bbt_mesh,bbt_surf_no_get,bbt_vid,bbt_bone1,bbt_weight1,bbt_bone2,bbt_weight2,bbt_bone3,bbt_weight3,bbt_bone4,bbt_weight4);
	return 0;
}
BBINT openb3d_openb3dex_SpriteRenderMode(struct openb3d_openb3dex_TSprite_obj* bbt_sprite,BBINT bbt_Mode){
	(bbt_sprite)->clas->m_SpriteRenderMode_i(bbt_sprite,bbt_Mode);
	return 0;
}
BBINT openb3d_openb3dex_TexToBuffer(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBBYTE* bbt_buffer,BBINT bbt_frame){
	(bbt_tex)->clas->m_TexToBuffer_pbi(bbt_tex,bbt_buffer,bbt_frame);
	return 0;
}
BBINT openb3d_openb3dex_UpdateTexCoords(struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	(bbt_surf)->clas->m_UpdateTexCoords(bbt_surf);
	return 0;
}
BBINT openb3d_openb3dex_AddMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh1,struct openb3d_openb3dex_TMesh_obj* bbt_mesh2){
	(bbt_mesh1)->clas->m_AddMesh_TTMesh(bbt_mesh1,bbt_mesh2);
	return 0;
}
BBINT openb3d_openb3dex_AddTriangle(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_v0,BBINT bbt_v1,BBINT bbt_v2){
	return (bbt_surf)->clas->m_AddTriangle_iii(bbt_surf,bbt_v0,bbt_v1,bbt_v2);
}
BBINT openb3d_openb3dex_AddVertex(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_u,BBFLOAT bbt_v,BBFLOAT bbt_w){
	return (bbt_surf)->clas->m_AddVertex_ffffff(bbt_surf,bbt_x,bbt_y,bbt_z,bbt_u,bbt_v,bbt_w);
}
BBINT openb3d_openb3dex_AmbientLight(BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	openb3d_openb3dex_TGlobal_AmbientLight_i_fff(bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT openb3d_openb3dex_Animate(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_Mode,BBFLOAT bbt_speed,BBINT bbt_seq,BBINT bbt_trans){
	(bbt_ent)->clas->m_Animate_ifii(bbt_ent,bbt_Mode,bbt_speed,bbt_seq,bbt_trans);
	return 0;
}
BBINT openb3d_openb3dex_Animating(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return Animating(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent));
}
BBINT openb3d_openb3dex_AnimLength(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_AnimLength(bbt_ent);
}
BBINT openb3d_openb3dex_AnimSeq(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return AnimSeq(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent));
}
BBFLOAT openb3d_openb3dex_AnimTime(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_AnimTime(bbt_ent);
}
BBINT openb3d_openb3dex_BrushAlpha(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBFLOAT bbt_a){
	(bbt_brush)->clas->m_BrushAlpha_f(bbt_brush,bbt_a);
	return 0;
}
BBINT openb3d_openb3dex_BrushBlend(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBINT bbt_blend){
	(bbt_brush)->clas->m_BrushBlend_i(bbt_brush,bbt_blend);
	return 0;
}
BBINT openb3d_openb3dex_BrushColor(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	(bbt_brush)->clas->m_BrushColor_fff(bbt_brush,bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT openb3d_openb3dex_BrushFX(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBINT bbt_fx){
	(bbt_brush)->clas->m_BrushFX_i(bbt_brush,bbt_fx);
	return 0;
}
BBINT openb3d_openb3dex_BrushShininess(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBFLOAT bbt_s){
	(bbt_brush)->clas->m_BrushShininess_f(bbt_brush,bbt_s);
	return 0;
}
BBINT openb3d_openb3dex_BrushTexture(struct openb3d_openb3dex_TBrush_obj* bbt_brush,struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_frame,BBINT bbt_index){
	(bbt_brush)->clas->m_BrushTexture_TTTextureii(bbt_brush,bbt_tex,bbt_frame,bbt_index);
	return 0;
}
BBINT openb3d_openb3dex_CameraClsColor(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	(bbt_cam)->clas->m_CameraClsColor_fff(bbt_cam,bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT openb3d_openb3dex_CameraClsMode(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBINT bbt_cls_depth,BBINT bbt_cls_zbuffer){
	(bbt_cam)->clas->m_CameraClsMode_ii(bbt_cam,bbt_cls_depth,bbt_cls_zbuffer);
	return 0;
}
BBINT openb3d_openb3dex_CameraFogColor(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	(bbt_cam)->clas->m_CameraFogColor_fff(bbt_cam,bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT openb3d_openb3dex_CameraFogMode(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBINT bbt_Mode){
	(bbt_cam)->clas->m_CameraFogMode_i(bbt_cam,bbt_Mode);
	return 0;
}
BBINT openb3d_openb3dex_CameraFogRange(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBFLOAT bbt_nnear,BBFLOAT bbt_nfar){
	(bbt_cam)->clas->m_CameraFogRange_ff(bbt_cam,bbt_nnear,bbt_nfar);
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_CameraPick(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBFLOAT bbt_x,BBFLOAT bbt_y){
	return (bbt_cam)->clas->m_CameraPick_ff(bbt_cam,bbt_x,bbt_y);
}
BBINT openb3d_openb3dex_CameraProject(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	(bbt_cam)->clas->m_CameraProject_fff(bbt_cam,bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT openb3d_openb3dex_CameraProjMode(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBINT bbt_Mode){
	(bbt_cam)->clas->m_CameraProjMode_i(bbt_cam,bbt_Mode);
	return 0;
}
BBINT openb3d_openb3dex_CameraRange(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBFLOAT bbt_nnear,BBFLOAT bbt_nfar){
	(bbt_cam)->clas->m_CameraRange_ff(bbt_cam,bbt_nnear,bbt_nfar);
	return 0;
}
BBINT openb3d_openb3dex_CameraViewport(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBINT bbt_x,BBINT bbt_y,BBINT bbt_width,BBINT bbt_height){
	(bbt_cam)->clas->m_CameraViewport_iiii(bbt_cam,bbt_x,bbt_y,bbt_width,bbt_height);
	return 0;
}
BBINT openb3d_openb3dex_CameraZoom(struct openb3d_openb3dex_TCamera_obj* bbt_cam,BBFLOAT bbt_zoom){
	(bbt_cam)->clas->m_CameraZoom_f(bbt_cam,bbt_zoom);
	return 0;
}
BBINT openb3d_openb3dex_ClearCollisions(){
	openb3d_openb3dex_TGlobal_ClearCollisions_i();
	return 0;
}
BBINT openb3d_openb3dex_ClearSurface(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_clear_verts,BBINT bbt_clear_tris){
	(bbt_surf)->clas->m_ClearSurface_ii(bbt_surf,bbt_clear_verts,bbt_clear_tris);
	return 0;
}
BBINT openb3d_openb3dex_ClearTextureFilters(){
	openb3d_openb3dex_TTexture_ClearTextureFilters_i();
	return 0;
}
BBINT openb3d_openb3dex_ClearWorld(BBINT bbt_entities,BBINT bbt_brushes,BBINT bbt_textures){
	openb3d_openb3dex_TGlobal_ClearWorld_i_iii(bbt_entities,bbt_brushes,bbt_textures);
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_CollisionEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionEntity_i(bbt_ent,bbt_index);
}
BBFLOAT openb3d_openb3dex_CollisionNX(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionNX_i(bbt_ent,bbt_index);
}
BBFLOAT openb3d_openb3dex_CollisionNY(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionNY_i(bbt_ent,bbt_index);
}
BBFLOAT openb3d_openb3dex_CollisionNZ(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionNZ_i(bbt_ent,bbt_index);
}
BBINT openb3d_openb3dex_Collisions(BBINT bbt_src_no,BBINT bbt_dest_no,BBINT bbt_method_no,BBINT bbt_response_no){
	openb3d_openb3dex_TGlobal_Collisions_i_iiii(bbt_src_no,bbt_dest_no,bbt_method_no,bbt_response_no);
	return 0;
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_CollisionSurface(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionSurface_i(bbt_ent,bbt_index);
}
BBFLOAT openb3d_openb3dex_CollisionTime(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionTime_i(bbt_ent,bbt_index);
}
BBINT openb3d_openb3dex_CollisionTriangle(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionTriangle_i(bbt_ent,bbt_index);
}
BBFLOAT openb3d_openb3dex_CollisionX(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionX_i(bbt_ent,bbt_index);
}
BBFLOAT openb3d_openb3dex_CollisionY(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionY_i(bbt_ent,bbt_index);
}
BBFLOAT openb3d_openb3dex_CollisionZ(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_index){
	return (bbt_ent)->clas->m_CollisionZ_i(bbt_ent,bbt_index);
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_CopyEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return (bbt_ent)->clas->m_CopyEntity_TTEntity(bbt_ent,bbt_parent);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_CopyMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return (bbt_mesh)->clas->m_CopyMesh_TTEntity(bbt_mesh,bbt_parent);
}
BBINT openb3d_openb3dex_CountChildren(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_CountChildren(bbt_ent);
}
BBINT openb3d_openb3dex_CountCollisions(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_CountCollisions(bbt_ent);
}
BBINT openb3d_openb3dex_CountSurfaces(struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	return (bbt_mesh)->clas->m_CountSurfaces(bbt_mesh);
}
BBINT openb3d_openb3dex_CountTriangles(struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	return (bbt_surf)->clas->m_CountTriangles(bbt_surf);
}
BBINT openb3d_openb3dex_CountVertices(struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	return (bbt_surf)->clas->m_CountVertices(bbt_surf);
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_CreateBrush(BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	return openb3d_openb3dex_TBrush_CreateBrush_TTBrush_fff(bbt_r,bbt_g,bbt_b);
}
struct openb3d_openb3dex_TCamera_obj* openb3d_openb3dex_CreateCamera(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TCamera_CreateCamera_TTCamera_TTEntity(bbt_parent);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_CreateCone(BBINT bbt_segments,BBINT bbt_solid,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_CreateCone_TTMesh_iiTTEntity(bbt_segments,bbt_solid,bbt_parent);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_CreateCylinder(BBINT bbt_segments,BBINT bbt_solid,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_CreateCylinder_TTMesh_iiTTEntity(bbt_segments,bbt_solid,bbt_parent);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_CreateCube(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_CreateCube_TTMesh_TTEntity(bbt_parent);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_CreateMesh(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_CreateMesh_TTMesh_TTEntity(bbt_parent);
}
struct openb3d_openb3dex_TLight_obj* openb3d_openb3dex_CreateLight(BBINT bbt_light_type,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TLight_CreateLight_TTLight_iTTEntity(bbt_light_type,bbt_parent);
}
struct openb3d_openb3dex_TPivot_obj* openb3d_openb3dex_CreatePivot(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TPivot_CreatePivot_TTPivot_TTEntity(bbt_parent);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_CreateSphere(BBINT bbt_segments,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_CreateSphere_TTMesh_iTTEntity(bbt_segments,bbt_parent);
}
struct openb3d_openb3dex_TSprite_obj* openb3d_openb3dex_CreateSprite(struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TSprite_CreateSprite_TTSprite_TTEntity(bbt_parent);
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_CreateSurface(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	return openb3d_openb3dex_TSurface_CreateSurface_TTSurface_TTMeshTTBrush(bbt_mesh,bbt_brush);
}
BBFLOAT openb3d_openb3dex_DeltaPitch(struct openb3d_openb3dex_TEntity_obj* bbt_ent1,struct openb3d_openb3dex_TEntity_obj* bbt_ent2){
	return (bbt_ent1)->clas->m_DeltaPitch_TTEntity(bbt_ent1,bbt_ent2);
}
BBFLOAT openb3d_openb3dex_DeltaYaw(struct openb3d_openb3dex_TEntity_obj* bbt_ent1,struct openb3d_openb3dex_TEntity_obj* bbt_ent2){
	return (bbt_ent1)->clas->m_DeltaYaw_TTEntity(bbt_ent1,bbt_ent2);
}
BBINT openb3d_openb3dex_EntityAlpha(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_alpha){
	(bbt_ent)->clas->m_EntityAlpha_f(bbt_ent,bbt_alpha);
	return 0;
}
BBINT openb3d_openb3dex_EntityBlend(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_blend){
	(bbt_ent)->clas->m_EntityBlend_i(bbt_ent,bbt_blend);
	return 0;
}
BBINT openb3d_openb3dex_EntityBox(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_w,BBFLOAT bbt_h,BBFLOAT bbt_d){
	(bbt_ent)->clas->m_EntityBox_ffffff(bbt_ent,bbt_x,bbt_y,bbt_z,bbt_w,bbt_h,bbt_d);
	return 0;
}
BBSTRING openb3d_openb3dex_EntityClass(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_EntityClass(bbt_ent);
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_EntityCollided(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_type_no){
	return (bbt_ent)->clas->m_EntityCollided_i(bbt_ent,bbt_type_no);
}
BBINT openb3d_openb3dex_EntityColor(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_red,BBFLOAT bbt_green,BBFLOAT bbt_blue){
	(bbt_ent)->clas->m_EntityColor_fff(bbt_ent,bbt_red,bbt_green,bbt_blue);
	return 0;
}
BBFLOAT openb3d_openb3dex_EntityDistance(struct openb3d_openb3dex_TEntity_obj* bbt_ent1,struct openb3d_openb3dex_TEntity_obj* bbt_ent2){
	return (bbt_ent1)->clas->m_EntityDistance_TTEntity(bbt_ent1,bbt_ent2);
}
BBINT openb3d_openb3dex_EntityFX(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_fx){
	(bbt_ent)->clas->m_EntityFX_i(bbt_ent,bbt_fx);
	return 0;
}
BBINT openb3d_openb3dex_EntityInView(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TCamera_obj* bbt_cam){
	return (bbt_cam)->clas->m_EntityInView_TTEntity(bbt_cam,bbt_ent);
}
BBSTRING openb3d_openb3dex_EntityName(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_EntityName(bbt_ent);
}
BBINT openb3d_openb3dex_EntityOrder(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_order){
	(bbt_ent)->clas->m_EntityOrder_i(bbt_ent,bbt_order);
	return 0;
}
BBINT openb3d_openb3dex_EntityParent(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent,BBINT bbt_glob){
	(bbt_ent)->clas->m_EntityParent_TTEntityi(bbt_ent,bbt_parent_ent,bbt_glob);
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_EntityPick(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_Range){
	return (bbt_ent)->clas->m_EntityPick_f(bbt_ent,bbt_Range);
}
BBINT openb3d_openb3dex_EntityPickMode(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_pick_mode,BBINT bbt_obscurer){
	(bbt_ent)->clas->m_EntityPickMode_ii(bbt_ent,bbt_pick_mode,bbt_obscurer);
	return 0;
}
BBFLOAT openb3d_openb3dex_EntityPitch(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityPitch_i(bbt_ent,bbt_glob);
}
BBINT openb3d_openb3dex_EntityRadius(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_radius_x,BBFLOAT bbt_radius_y){
	(bbt_ent)->clas->m_EntityRadius_ff(bbt_ent,bbt_radius_x,bbt_radius_y);
	return 0;
}
BBFLOAT openb3d_openb3dex_EntityRoll(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityRoll_i(bbt_ent,bbt_glob);
}
BBINT openb3d_openb3dex_EntityShininess(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_shine){
	(bbt_ent)->clas->m_EntityShininess_f(bbt_ent,bbt_shine);
	return 0;
}
BBINT openb3d_openb3dex_EntityTexture(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_frame,BBINT bbt_index){
	(bbt_ent)->clas->m_EntityTexture_TTTextureii(bbt_ent,bbt_tex,bbt_frame,bbt_index);
	return 0;
}
BBINT openb3d_openb3dex_EntityType(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_type_no,BBINT bbt_recursive){
	(bbt_ent)->clas->m_EntityType_ii(bbt_ent,bbt_type_no,bbt_recursive);
	return 0;
}
BBINT openb3d_openb3dex_EntityVisible(struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	return openb3d_openb3dex_TPick_EntityVisible_i_TTEntityTTEntity(bbt_src_ent,bbt_dest_ent);
}
BBFLOAT openb3d_openb3dex_EntityX(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityX_i(bbt_ent,bbt_glob);
}
BBFLOAT openb3d_openb3dex_EntityY(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityY_i(bbt_ent,bbt_glob);
}
BBFLOAT openb3d_openb3dex_EntityYaw(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityYaw_i(bbt_ent,bbt_glob);
}
BBFLOAT openb3d_openb3dex_EntityZ(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_glob){
	return (bbt_ent)->clas->m_EntityZ_i(bbt_ent,bbt_glob);
}
BBINT openb3d_openb3dex_ExtractAnimSeq(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_first_frame,BBINT bbt_last_frame,BBINT bbt_seq){
	return (bbt_ent)->clas->m_ExtractAnimSeq_iii(bbt_ent,bbt_first_frame,bbt_last_frame,bbt_seq);
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_FindChild(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBSTRING bbt_child_name){
	return (bbt_ent)->clas->m_FindChild_S(bbt_ent,bbt_child_name);
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_FindSurface(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	return (bbt_mesh)->clas->m_FindSurface_TTBrush(bbt_mesh,bbt_brush);
}
BBINT openb3d_openb3dex_FitMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_width,BBFLOAT bbt_height,BBFLOAT bbt_depth,BBINT bbt_uniform){
	(bbt_mesh)->clas->m_FitMesh_ffffffi(bbt_mesh,bbt_x,bbt_y,bbt_z,bbt_width,bbt_height,bbt_depth,bbt_uniform);
	return 0;
}
BBINT openb3d_openb3dex_FlipMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	(bbt_mesh)->clas->m_FlipMesh(bbt_mesh);
	return 0;
}
BBINT openb3d_openb3dex_FreeBrush(struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	(bbt_brush)->clas->m_FreeBrush(bbt_brush);
	return 0;
}
BBINT openb3d_openb3dex_FreeEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	(bbt_ent)->clas->m_FreeEntity(bbt_ent);
	return 0;
}
BBINT openb3d_openb3dex_FreeTexture(struct openb3d_openb3dex_TTexture_obj* bbt_tex){
	(bbt_tex)->clas->m_FreeTexture(bbt_tex);
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_GetBrushTexture(struct openb3d_openb3dex_TBrush_obj* bbt_brush,BBINT bbt_index){
	return (bbt_brush)->clas->m_GetBrushTexture_i(bbt_brush,bbt_index);
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_GetChild(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_child_no){
	return (bbt_ent)->clas->m_GetChild_i(bbt_ent,bbt_child_no);
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_GetEntityBrush(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_GetEntityBrush(bbt_ent);
}
BBINT openb3d_openb3dex_GetEntityType(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_GetEntityType(bbt_ent);
}
BBFLOAT openb3d_openb3dex_GetMatElement(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_row,BBINT bbt_col){
	(bbt_ent)->clas->m_GetMatElement_ii(bbt_ent,bbt_row,bbt_col);
	return .0f;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_GetParent(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	return (bbt_ent)->clas->m_GetParent(bbt_ent);
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_GetSurface(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBINT bbt_surf_no){
	return (bbt_mesh)->clas->m_GetSurface_i(bbt_mesh,bbt_surf_no);
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_GetSurfaceBrush(struct openb3d_openb3dex_TSurface_obj* bbt_surf){
	return (bbt_surf)->clas->m_GetSurfaceBrush(bbt_surf);
}
BBINT openb3d_openb3dex_HandleSprite(struct openb3d_openb3dex_TSprite_obj* bbt_sprite,BBFLOAT bbt_h_x,BBFLOAT bbt_h_y){
	(bbt_sprite)->clas->m_HandleSprite_ff(bbt_sprite,bbt_h_x,bbt_h_y);
	return 0;
}
BBINT openb3d_openb3dex_HideEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	(bbt_ent)->clas->m_HideEntity(bbt_ent);
	return 0;
}
BBINT openb3d_openb3dex_LightColor(struct openb3d_openb3dex_TLight_obj* bbt_light,BBFLOAT bbt_red,BBFLOAT bbt_green,BBFLOAT bbt_blue){
	(bbt_light)->clas->m_LightColor_fff(bbt_light,bbt_red,bbt_green,bbt_blue);
	return 0;
}
BBINT openb3d_openb3dex_LightConeAngles(struct openb3d_openb3dex_TLight_obj* bbt_light,BBFLOAT bbt_inner_ang,BBFLOAT bbt_outer_ang){
	(bbt_light)->clas->m_LightConeAngles_ff(bbt_light,bbt_inner_ang,bbt_outer_ang);
	return 0;
}
BBINT openb3d_openb3dex_LightRange(struct openb3d_openb3dex_TLight_obj* bbt_light,BBFLOAT bbt_Range){
	(bbt_light)->clas->m_LightRange_f(bbt_light,bbt_Range);
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_LinePick(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBFLOAT bbt_dx,BBFLOAT bbt_dy,BBFLOAT bbt_dz,BBFLOAT bbt_radius){
	return openb3d_openb3dex_TPick_LinePick_TTEntity_fffffff(bbt_x,bbt_y,bbt_z,bbt_dx,bbt_dy,bbt_dz,bbt_radius);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_LoadAnimMesh(BBSTRING bbt_file,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_LoadAnimMesh_TTMesh_STTEntity(bbt_file,bbt_parent);
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_LoadAnimTexture(BBSTRING bbt_file,BBINT bbt_flags,BBINT bbt_frame_width,BBINT bbt_frame_height,BBINT bbt_first_frame,BBINT bbt_frame_count){
	return openb3d_openb3dex_TTexture_LoadAnimTexture_TTTexture_Siiiii(bbt_file,bbt_flags,bbt_frame_width,bbt_frame_height,bbt_first_frame,bbt_frame_count);
}
struct openb3d_openb3dex_TBrush_obj* openb3d_openb3dex_LoadBrush(BBSTRING bbt_file,BBINT bbt_flags,BBFLOAT bbt_u_scale,BBFLOAT bbt_v_scale){
	return openb3d_openb3dex_TBrush_LoadBrush_TTBrush_Siff(bbt_file,bbt_flags,bbt_u_scale,bbt_v_scale);
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_LoadMesh(BBSTRING bbt_file,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_LoadMesh_TTMesh_STTEntity(bbt_file,bbt_parent);
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_LoadTexture(BBSTRING bbt_file,BBINT bbt_flags){
	return openb3d_openb3dex_TTexture_LoadTexture_TTTexture_Si(bbt_file,bbt_flags);
}
struct openb3d_openb3dex_TSprite_obj* openb3d_openb3dex_LoadSprite(BBSTRING bbt_tex_file,BBINT bbt_tex_flag,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TSprite_LoadSprite_TTSprite_SiTTEntity(bbt_tex_file,bbt_tex_flag,bbt_parent);
}
BBFLOAT openb3d_openb3dex_MeshDepth(struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	return (bbt_mesh)->clas->m_MeshDepth(bbt_mesh);
}
BBFLOAT openb3d_openb3dex_MeshHeight(struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	return (bbt_mesh)->clas->m_MeshHeight(bbt_mesh);
}
BBFLOAT openb3d_openb3dex_MeshWidth(struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	return (bbt_mesh)->clas->m_MeshWidth(bbt_mesh);
}
BBINT openb3d_openb3dex_MoveEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	(bbt_ent)->clas->m_MoveEntity_fff(bbt_ent,bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT openb3d_openb3dex_NameEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBSTRING bbt_name){
	(bbt_ent)->clas->m_NameEntity_S(bbt_ent,bbt_name);
	return 0;
}
BBINT openb3d_openb3dex_PaintEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	(bbt_ent)->clas->m_PaintEntity_TTBrush(bbt_ent,bbt_brush);
	return 0;
}
BBINT openb3d_openb3dex_PaintMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	(bbt_mesh)->clas->m_PaintMesh_TTBrush(bbt_mesh,bbt_brush);
	return 0;
}
BBINT openb3d_openb3dex_PaintSurface(struct openb3d_openb3dex_TSurface_obj* bbt_surf,struct openb3d_openb3dex_TBrush_obj* bbt_brush){
	(bbt_surf)->clas->m_PaintSurface_TTBrush(bbt_surf,bbt_brush);
	return 0;
}
struct openb3d_openb3dex_TEntity_obj* openb3d_openb3dex_PickedEntity(){
	return openb3d_openb3dex_TPick_PickedEntity_TTEntity();
}
BBFLOAT openb3d_openb3dex_PickedNX(){
	return openb3d_openb3dex_TPick_PickedNX_f();
}
BBFLOAT openb3d_openb3dex_PickedNY(){
	return openb3d_openb3dex_TPick_PickedNY_f();
}
BBFLOAT openb3d_openb3dex_PickedNZ(){
	return openb3d_openb3dex_TPick_PickedNZ_f();
}
struct openb3d_openb3dex_TSurface_obj* openb3d_openb3dex_PickedSurface(){
	return openb3d_openb3dex_TPick_PickedSurface_TTSurface();
}
BBFLOAT openb3d_openb3dex_PickedTime(){
	return openb3d_openb3dex_TPick_PickedTime_f();
}
BBINT openb3d_openb3dex_PickedTriangle(){
	return openb3d_openb3dex_TPick_PickedTriangle_i();
}
BBFLOAT openb3d_openb3dex_PickedX(){
	return openb3d_openb3dex_TPick_PickedX_f();
}
BBFLOAT openb3d_openb3dex_PickedY(){
	return openb3d_openb3dex_TPick_PickedY_f();
}
BBFLOAT openb3d_openb3dex_PickedZ(){
	return openb3d_openb3dex_TPick_PickedZ_f();
}
BBINT openb3d_openb3dex_PointEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TEntity_obj* bbt_target_ent,BBFLOAT bbt_roll){
	(bbt_ent)->clas->m_PointEntity_TTEntityf(bbt_ent,bbt_target_ent,bbt_roll);
	return 0;
}
BBINT openb3d_openb3dex_PositionEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	(bbt_ent)->clas->m_PositionEntity_fffi(bbt_ent,bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT openb3d_openb3dex_PositionMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBFLOAT bbt_px,BBFLOAT bbt_py,BBFLOAT bbt_pz){
	(bbt_mesh)->clas->m_PositionMesh_fff(bbt_mesh,bbt_px,bbt_py,bbt_pz);
	return 0;
}
BBINT openb3d_openb3dex_PositionTexture(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBFLOAT bbt_u_pos,BBFLOAT bbt_v_pos){
	(bbt_tex)->clas->m_PositionTexture_ff(bbt_tex,bbt_u_pos,bbt_v_pos);
	return 0;
}
BBFLOAT openb3d_openb3dex_ProjectedX(){
	return ProjectedX();
}
BBFLOAT openb3d_openb3dex_ProjectedY(){
	return ProjectedY();
}
BBFLOAT openb3d_openb3dex_ProjectedZ(){
	return ProjectedZ();
}
BBINT openb3d_openb3dex_RenderWorld(){
	openb3d_openb3dex_TGlobal_RenderWorld_i();
	return 0;
}
BBINT openb3d_openb3dex_ResetEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	(bbt_ent)->clas->m_ResetEntity(bbt_ent);
	return 0;
}
BBINT openb3d_openb3dex_RotateEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	(bbt_ent)->clas->m_RotateEntity_fffi(bbt_ent,bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT openb3d_openb3dex_RotateMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBFLOAT bbt_pitch,BBFLOAT bbt_yaw,BBFLOAT bbt_roll){
	(bbt_mesh)->clas->m_RotateMesh_fff(bbt_mesh,bbt_pitch,bbt_yaw,bbt_roll);
	return 0;
}
BBINT openb3d_openb3dex_RotateSprite(struct openb3d_openb3dex_TSprite_obj* bbt_sprite,BBFLOAT bbt_ang){
	(bbt_sprite)->clas->m_RotateSprite_f(bbt_sprite,bbt_ang);
	return 0;
}
BBINT openb3d_openb3dex_RotateTexture(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBFLOAT bbt_ang){
	(bbt_tex)->clas->m_RotateTexture_f(bbt_tex,bbt_ang);
	return 0;
}
BBINT openb3d_openb3dex_ScaleEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	(bbt_ent)->clas->m_ScaleEntity_fffi(bbt_ent,bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT openb3d_openb3dex_ScaleMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBFLOAT bbt_sx,BBFLOAT bbt_sy,BBFLOAT bbt_sz){
	(bbt_mesh)->clas->m_ScaleMesh_fff(bbt_mesh,bbt_sx,bbt_sy,bbt_sz);
	return 0;
}
BBINT openb3d_openb3dex_ScaleSprite(struct openb3d_openb3dex_TSprite_obj* bbt_sprite,BBFLOAT bbt_s_x,BBFLOAT bbt_s_y){
	(bbt_sprite)->clas->m_ScaleSprite_ff(bbt_sprite,bbt_s_x,bbt_s_y);
	return 0;
}
BBINT openb3d_openb3dex_ScaleTexture(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBFLOAT bbt_u_scale,BBFLOAT bbt_v_scale){
	(bbt_tex)->clas->m_ScaleTexture_ff(bbt_tex,bbt_u_scale,bbt_v_scale);
	return 0;
}
BBINT openb3d_openb3dex_SetAnimTime(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_time,BBINT bbt_seq){
	(bbt_ent)->clas->m_SetAnimTime_fi(bbt_ent,bbt_time,bbt_seq);
	return 0;
}
BBINT openb3d_openb3dex_SetCubeFace(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_face){
	SetCubeFace(openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex),bbt_face);
	return 0;
}
BBINT openb3d_openb3dex_SetCubeMode(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_Mode){
	SetCubeMode(openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex),bbt_Mode);
	return 0;
}
BBINT openb3d_openb3dex_ShowEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent){
	(bbt_ent)->clas->m_ShowEntity(bbt_ent);
	return 0;
}
BBINT openb3d_openb3dex_SpriteViewMode(struct openb3d_openb3dex_TSprite_obj* bbt_sprite,BBINT bbt_Mode){
	(bbt_sprite)->clas->m_SpriteViewMode_i(bbt_sprite,bbt_Mode);
	return 0;
}
BBINT openb3d_openb3dex_TextureBlend(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_blend){
	(bbt_tex)->clas->m_TextureBlend_i(bbt_tex,bbt_blend);
	return 0;
}
BBINT openb3d_openb3dex_TextureCoords(struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBINT bbt_coords){
	(bbt_tex)->clas->m_TextureCoords_i(bbt_tex,bbt_coords);
	return 0;
}
BBINT openb3d_openb3dex_TextureHeight(struct openb3d_openb3dex_TTexture_obj* bbt_tex){
	return TextureHeight(openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex));
}
BBINT openb3d_openb3dex_TextureFilter(BBSTRING bbt_match_text,BBINT bbt_flags){
	openb3d_openb3dex_TTexture_TextureFilter_i_Si(bbt_match_text,bbt_flags);
	return 0;
}
BBSTRING openb3d_openb3dex_TextureName(struct openb3d_openb3dex_TTexture_obj* bbt_tex){
	return (bbt_tex)->clas->m_TextureName(bbt_tex);
}
BBINT openb3d_openb3dex_TextureWidth(struct openb3d_openb3dex_TTexture_obj* bbt_tex){
	return TextureWidth(openb3d_openb3dex_TTexture_GetInstance_pb_TTTexture(bbt_tex));
}
BBFLOAT openb3d_openb3dex_TFormedX(){
	return openb3d_openb3dex_TEntity_TFormedX_f();
}
BBFLOAT openb3d_openb3dex_TFormedY(){
	return openb3d_openb3dex_TEntity_TFormedY_f();
}
BBFLOAT openb3d_openb3dex_TFormedZ(){
	return openb3d_openb3dex_TEntity_TFormedZ_f();
}
BBINT openb3d_openb3dex_TFormNormal(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	openb3d_openb3dex_TEntity_TFormNormal_i_fffTTEntityTTEntity(bbt_x,bbt_y,bbt_z,bbt_src_ent,bbt_dest_ent);
	return 0;
}
BBINT openb3d_openb3dex_TFormPoint(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	openb3d_openb3dex_TEntity_TFormPoint_i_fffTTEntityTTEntity(bbt_x,bbt_y,bbt_z,bbt_src_ent,bbt_dest_ent);
	return 0;
}
BBINT openb3d_openb3dex_TFormVector(BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,struct openb3d_openb3dex_TEntity_obj* bbt_src_ent,struct openb3d_openb3dex_TEntity_obj* bbt_dest_ent){
	openb3d_openb3dex_TEntity_TFormVector_i_fffTTEntityTTEntity(bbt_x,bbt_y,bbt_z,bbt_src_ent,bbt_dest_ent);
	return 0;
}
BBINT openb3d_openb3dex_TranslateEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	(bbt_ent)->clas->m_TranslateEntity_fffi(bbt_ent,bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT openb3d_openb3dex_TriangleVertex(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_tri_no,BBINT bbt_corner){
	return (bbt_surf)->clas->m_TriangleVertex_ii(bbt_surf,bbt_tri_no,bbt_corner);
}
BBINT openb3d_openb3dex_TurnEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_glob){
	(bbt_ent)->clas->m_TurnEntity_fffi(bbt_ent,bbt_x,bbt_y,bbt_z,bbt_glob);
	return 0;
}
BBINT openb3d_openb3dex_UpdateNormals(struct openb3d_openb3dex_TMesh_obj* bbt_mesh){
	(bbt_mesh)->clas->m_UpdateNormals(bbt_mesh);
	return 0;
}
BBINT openb3d_openb3dex_UpdateWorld(BBFLOAT bbt_anim_speed){
	openb3d_openb3dex_TGlobal_UpdateWorld_i_f(bbt_anim_speed);
	return 0;
}
BBFLOAT openb3d_openb3dex_VectorPitch(BBFLOAT bbt_vx,BBFLOAT bbt_vy,BBFLOAT bbt_vz){
	return openb3d_openb3dex_TVector_VectorPitch_f_fff(bbt_vx,bbt_vy,bbt_vz);
}
BBFLOAT openb3d_openb3dex_VectorYaw(BBFLOAT bbt_vx,BBFLOAT bbt_vy,BBFLOAT bbt_vz){
	return openb3d_openb3dex_TVector_VectorYaw_f_fff(bbt_vx,bbt_vy,bbt_vz);
}
BBFLOAT openb3d_openb3dex_VertexAlpha(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexAlpha_i(bbt_surf,bbt_vid);
}
BBFLOAT openb3d_openb3dex_VertexBlue(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexBlue_i(bbt_surf,bbt_vid);
}
BBINT openb3d_openb3dex_VertexColor(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b,BBFLOAT bbt_a){
	(bbt_surf)->clas->m_VertexColor_iffff(bbt_surf,bbt_vid,bbt_r,bbt_g,bbt_b,bbt_a);
	return 0;
}
BBINT openb3d_openb3dex_VertexCoords(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	(bbt_surf)->clas->m_VertexCoords_ifff(bbt_surf,bbt_vid,bbt_x,bbt_y,bbt_z);
	return 0;
}
BBFLOAT openb3d_openb3dex_VertexGreen(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexGreen_i(bbt_surf,bbt_vid);
}
BBINT openb3d_openb3dex_VertexNormal(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid,BBFLOAT bbt_nx,BBFLOAT bbt_ny,BBFLOAT bbt_nz){
	(bbt_surf)->clas->m_VertexNormal_ifff(bbt_surf,bbt_vid,bbt_nx,bbt_ny,bbt_nz);
	return 0;
}
BBFLOAT openb3d_openb3dex_VertexNX(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexNX_i(bbt_surf,bbt_vid);
}
BBFLOAT openb3d_openb3dex_VertexNY(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexNY_i(bbt_surf,bbt_vid);
}
BBFLOAT openb3d_openb3dex_VertexNZ(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexNZ_i(bbt_surf,bbt_vid);
}
BBFLOAT openb3d_openb3dex_VertexRed(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexRed_i(bbt_surf,bbt_vid);
}
BBINT openb3d_openb3dex_VertexTexCoords(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid,BBFLOAT bbt_u,BBFLOAT bbt_v,BBFLOAT bbt_w,BBINT bbt_coord_set){
	(bbt_surf)->clas->m_VertexTexCoords_ifffi(bbt_surf,bbt_vid,bbt_u,bbt_v,bbt_w,bbt_coord_set);
	return 0;
}
BBFLOAT openb3d_openb3dex_VertexU(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid,BBINT bbt_coord_set){
	return (bbt_surf)->clas->m_VertexU_ii(bbt_surf,bbt_vid,bbt_coord_set);
}
BBFLOAT openb3d_openb3dex_VertexV(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid,BBINT bbt_coord_set){
	return (bbt_surf)->clas->m_VertexV_ii(bbt_surf,bbt_vid,bbt_coord_set);
}
BBFLOAT openb3d_openb3dex_VertexW(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid,BBINT bbt_coord_set){
	return (bbt_surf)->clas->m_VertexW_ii(bbt_surf,bbt_vid,bbt_coord_set);
}
BBFLOAT openb3d_openb3dex_VertexX(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexX_i(bbt_surf,bbt_vid);
}
BBFLOAT openb3d_openb3dex_VertexY(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexY_i(bbt_surf,bbt_vid);
}
BBFLOAT openb3d_openb3dex_VertexZ(struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vid){
	return (bbt_surf)->clas->m_VertexZ_i(bbt_surf,bbt_vid);
}
BBINT openb3d_openb3dex_Wireframe(BBINT bbt_enable){
	Wireframe(bbt_enable);
	return 0;
}
BBINT openb3d_openb3dex_AddAnimSeq(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBINT bbt_length){
	return (bbt_ent)->clas->m_AddAnimSeq_i(bbt_ent,bbt_length);
}
BBINT openb3d_openb3dex_AlignToVector(struct openb3d_openb3dex_TEntity_obj* bbt_entity,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z,BBINT bbt_axis,BBINT bbt_rate){
	(bbt_entity)->clas->m_AlignToVector_fffif(bbt_entity,bbt_x,bbt_y,bbt_z,bbt_axis,((BBFLOAT)bbt_rate));
	return 0;
}
struct openb3d_openb3dex_TMesh_obj* openb3d_openb3dex_CreatePlane(BBINT bbt_divisions,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TMesh_CreatePlane_TTMesh_iTTEntity(bbt_divisions,bbt_parent);
}
struct openb3d_openb3dex_TTerrain_obj* openb3d_openb3dex_CreateTerrain(BBINT bbt_size,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TTerrain_CreateTerrain_TTTerrain_iTTEntity(bbt_size,bbt_parent);
}
BBINT openb3d_openb3dex_LoadAnimSeq(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBSTRING bbt_file){
	return (bbt_ent)->clas->m_LoadAnimSeq_S(bbt_ent,bbt_file);
}
struct openb3d_openb3dex_TTerrain_obj* openb3d_openb3dex_LoadTerrain(BBSTRING bbt_file,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TTerrain_LoadTerrain_TTTerrain_STTEntity(bbt_file,bbt_parent);
}
BBINT openb3d_openb3dex_MeshesIntersect(struct openb3d_openb3dex_TMesh_obj* bbt_mesh1,struct openb3d_openb3dex_TMesh_obj* bbt_mesh2){
	return (bbt_mesh1)->clas->m_MeshesIntersect_TTMesh(bbt_mesh1,bbt_mesh2);
}
BBINT openb3d_openb3dex_ModifyTerrain(struct openb3d_openb3dex_TTerrain_obj* bbt_terr,BBINT bbt_x,BBINT bbt_z,BBFLOAT bbt_new_height){
	(bbt_terr)->clas->m_ModifyTerrain_iif(bbt_terr,bbt_x,bbt_z,bbt_new_height);
	return 0;
}
BBINT openb3d_openb3dex_SetAnimKey(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_frame,BBINT bbt_pos_key,BBINT bbt_rot_key,BBINT bbt_scale_key){
	(bbt_ent)->clas->m_SetAnimKey_fiii(bbt_ent,bbt_frame,bbt_pos_key,bbt_rot_key,bbt_scale_key);
	return 0;
}
BBFLOAT openb3d_openb3dex_TerrainHeight(struct openb3d_openb3dex_TTerrain_obj* bbt_terr,BBINT bbt_x,BBINT bbt_z){
	return (bbt_terr)->clas->m_TerrainHeight_ii(bbt_terr,bbt_x,bbt_z);
}
BBFLOAT openb3d_openb3dex_TerrainX(struct openb3d_openb3dex_TTerrain_obj* bbt_terr,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	return (bbt_terr)->clas->m_TerrainX_fff(bbt_terr,bbt_x,bbt_y,bbt_z);
}
BBFLOAT openb3d_openb3dex_TerrainY(struct openb3d_openb3dex_TTerrain_obj* bbt_terr,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	return (bbt_terr)->clas->m_TerrainY_fff(bbt_terr,bbt_x,bbt_y,bbt_z);
}
BBFLOAT openb3d_openb3dex_TerrainZ(struct openb3d_openb3dex_TTerrain_obj* bbt_terr,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	return (bbt_terr)->clas->m_TerrainZ_fff(bbt_terr,bbt_x,bbt_y,bbt_z);
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActMoveBy(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_a,BBFLOAT bbt_b,BBFLOAT bbt_c,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActMoveBy(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_a,bbt_b,bbt_c,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActTurnBy(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_a,BBFLOAT bbt_b,BBFLOAT bbt_c,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActTurnBy(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_a,bbt_b,bbt_c,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActVector(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_a,BBFLOAT bbt_b,BBFLOAT bbt_c){
	BBBYTE* bbt_inst=ActVector(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_a,bbt_b,bbt_c);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActMoveTo(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_a,BBFLOAT bbt_b,BBFLOAT bbt_c,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActMoveTo(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_a,bbt_b,bbt_c,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActTurnTo(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_a,BBFLOAT bbt_b,BBFLOAT bbt_c,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActTurnTo(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_a,bbt_b,bbt_c,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActScaleTo(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_a,BBFLOAT bbt_b,BBFLOAT bbt_c,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActScaleTo(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_a,bbt_b,bbt_c,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActFadeTo(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_a,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActFadeTo(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_a,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActTintTo(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_a,BBFLOAT bbt_b,BBFLOAT bbt_c,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActTintTo(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_a,bbt_b,bbt_c,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActTrackByPoint(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TEntity_obj* bbt_target,BBFLOAT bbt_a,BBFLOAT bbt_b,BBFLOAT bbt_c,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActTrackByPoint(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_target),bbt_a,bbt_b,bbt_c,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActTrackByDistance(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TEntity_obj* bbt_target,BBFLOAT bbt_a,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActTrackByDistance(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_target),bbt_a,bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
struct openb3d_openb3dex_TAction_obj* openb3d_openb3dex_ActNewtonian(struct openb3d_openb3dex_TEntity_obj* bbt_ent,BBFLOAT bbt_rate){
	BBBYTE* bbt_inst=ActNewtonian(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),bbt_rate);
	struct openb3d_openb3dex_TAction_obj* volatile bbt_act=openb3d_openb3dex_TAction_GetObject_TTAction_pb(bbt_inst);
	if((bbt_act==&bbNullObject) && (bbt_inst!=0)){
		bbt_act=openb3d_openb3dex_TAction_CreateObject_TTAction_pb(bbt_inst);
	}
	return bbt_act;
}
BBINT openb3d_openb3dex_AppendAction(struct openb3d_openb3dex_TAction_obj* bbt_act1,struct openb3d_openb3dex_TAction_obj* bbt_act2){
	(bbt_act1)->clas->m_AppendAction_TTAction(bbt_act1,bbt_act2);
	return 0;
}
BBINT openb3d_openb3dex_FreeAction(struct openb3d_openb3dex_TAction_obj* bbt_act){
	(bbt_act)->clas->m_FreeAction(bbt_act);
	return 0;
}
struct openb3d_openb3dex_TConstraint_obj* openb3d_openb3dex_CreateConstraint(struct openb3d_openb3dex_TEntity_obj* bbt_p1,struct openb3d_openb3dex_TEntity_obj* bbt_p2,BBFLOAT bbt_l){
	return openb3d_openb3dex_TConstraint_CreateConstraint_TTConstraint_TTEntityTTEntityf(bbt_p1,bbt_p2,bbt_l);
}
struct openb3d_openb3dex_TRigidBody_obj* openb3d_openb3dex_CreateRigidBody(struct openb3d_openb3dex_TEntity_obj* bbt_body,struct openb3d_openb3dex_TEntity_obj* bbt_p1,struct openb3d_openb3dex_TEntity_obj* bbt_p2,struct openb3d_openb3dex_TEntity_obj* bbt_p3,struct openb3d_openb3dex_TEntity_obj* bbt_p4){
	return openb3d_openb3dex_TRigidBody_CreateRigidBody_TTRigidBody_TTEntityTTEntityTTEntityTTEntityTTEntity(bbt_body,bbt_p1,bbt_p2,bbt_p3,bbt_p4);
}
struct openb3d_openb3dex_TBlob_obj* openb3d_openb3dex_CreateBlob(struct openb3d_openb3dex_TFluid_obj* bbt_fluid,BBFLOAT bbt_radius,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	return openb3d_openb3dex_TBlob_CreateBlob_TTBlob_TTFluidfTTEntity(bbt_fluid,bbt_radius,bbt_parent_ent);
}
struct openb3d_openb3dex_TFluid_obj* openb3d_openb3dex_CreateFluid(){
	return openb3d_openb3dex_TFluid_CreateFluid_TTFluid();
}
BBINT openb3d_openb3dex_FluidArray(struct openb3d_openb3dex_TFluid_obj* bbt_fluid,BBFLOAT* bbt_Array,BBINT bbt_w,BBINT bbt_h,BBINT bbt_d){
	(bbt_fluid)->clas->m_FluidArray_vfiii(bbt_fluid,bbt_Array,bbt_w,bbt_h,bbt_d);
	return 0;
}
BBINT openb3d_openb3dex_FluidFunction(struct openb3d_openb3dex_TFluid_obj* bbt_fluid,BBFLOAT(* bbt_FieldFunction)(BBFLOAT,BBFLOAT,BBFLOAT)){
	(bbt_fluid)->clas->m_FluidFunction_F_fff_f_(bbt_fluid,bbt_FieldFunction);
	return 0;
}
BBINT openb3d_openb3dex_FluidThreshold(struct openb3d_openb3dex_TFluid_obj* bbt_fluid,BBFLOAT bbt_threshold){
	FluidThreshold(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_fluid,&openb3d_openb3dex_TEntity)),bbt_threshold);
	return 0;
}
struct openb3d_openb3dex_TGeosphere_obj* openb3d_openb3dex_CreateGeosphere(BBINT bbt_size,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TGeosphere_CreateGeosphere_TTGeosphere_iTTEntity(bbt_size,bbt_parent);
}
BBINT openb3d_openb3dex_GeosphereHeight(struct openb3d_openb3dex_TGeosphere_obj* bbt_geo,BBFLOAT bbt_h){
	GeosphereHeight(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_geo,&openb3d_openb3dex_TEntity)),bbt_h);
	return 0;
}
struct openb3d_openb3dex_TGeosphere_obj* openb3d_openb3dex_LoadGeosphere(BBSTRING bbt_file,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TGeosphere_LoadGeosphere_TTGeosphere_STTEntity(bbt_file,bbt_parent);
}
BBINT openb3d_openb3dex_ModifyGeosphere(struct openb3d_openb3dex_TGeosphere_obj* bbt_geo,BBINT bbt_x,BBINT bbt_z,BBFLOAT bbt_new_height){
	(bbt_geo)->clas->m_ModifyGeosphere_iif(bbt_geo,bbt_x,bbt_z,bbt_new_height);
	return 0;
}
struct openb3d_openb3dex_TOcTree_obj* openb3d_openb3dex_CreateOcTree(BBFLOAT bbt_w,BBFLOAT bbt_h,BBFLOAT bbt_d,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	return openb3d_openb3dex_TOcTree_CreateOcTree_TTOcTree_fffTTEntity(bbt_w,bbt_h,bbt_d,bbt_parent_ent);
}
BBINT openb3d_openb3dex_OctreeBlock(struct openb3d_openb3dex_TOcTree_obj* bbt_octree,struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBINT bbt_level,BBFLOAT bbt_X,BBFLOAT bbt_Y,BBFLOAT bbt_Z,BBFLOAT bbt_Near,BBFLOAT bbt_Far){
	(bbt_octree)->clas->m_OctreeBlock_TTMeshifffff(bbt_octree,bbt_mesh,bbt_level,bbt_X,bbt_Y,bbt_Z,bbt_Near,bbt_Far);
	return 0;
}
BBINT openb3d_openb3dex_OctreeMesh(struct openb3d_openb3dex_TOcTree_obj* bbt_octree,struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBINT bbt_level,BBFLOAT bbt_X,BBFLOAT bbt_Y,BBFLOAT bbt_Z,BBFLOAT bbt_Near,BBFLOAT bbt_Far){
	(bbt_octree)->clas->m_OctreeMesh_TTMeshifffff(bbt_octree,bbt_mesh,bbt_level,bbt_X,bbt_Y,bbt_Z,bbt_Near,bbt_Far);
	return 0;
}
struct openb3d_openb3dex_TParticleEmitter_obj* openb3d_openb3dex_CreateParticleEmitter(struct openb3d_openb3dex_TEntity_obj* bbt_particle,struct openb3d_openb3dex_TEntity_obj* bbt_parent_ent){
	return openb3d_openb3dex_TParticleEmitter_CreateParticleEmitter_TTParticleEmitter_TTEntityTTEntity(bbt_particle,bbt_parent_ent);
}
BBINT openb3d_openb3dex_EmitterVector(struct openb3d_openb3dex_TParticleEmitter_obj* bbt_emit,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	(bbt_emit)->clas->m_EmitterVector_fff(bbt_emit,bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT openb3d_openb3dex_EmitterRate(struct openb3d_openb3dex_TParticleEmitter_obj* bbt_emit,BBFLOAT bbt_r){
	(bbt_emit)->clas->m_EmitterRate_f(bbt_emit,bbt_r);
	return 0;
}
BBINT openb3d_openb3dex_EmitterParticleLife(struct openb3d_openb3dex_TParticleEmitter_obj* bbt_emit,BBINT bbt_l){
	(bbt_emit)->clas->m_EmitterParticleLife_i(bbt_emit,bbt_l);
	return 0;
}
BBINT openb3d_openb3dex_EmitterParticleFunction(struct openb3d_openb3dex_TParticleEmitter_obj* bbt_emit,BBINT(* bbt_EmitterFunction)(BBBYTE*,BBINT)){
	(bbt_emit)->clas->m_EmitterParticleFunction_F_pbi_i_(bbt_emit,bbt_EmitterFunction);
	return 0;
}
BBINT openb3d_openb3dex_EmitterParticleSpeed(struct openb3d_openb3dex_TParticleEmitter_obj* bbt_emit,BBFLOAT bbt_s){
	(bbt_emit)->clas->m_EmitterParticleSpeed_f(bbt_emit,bbt_s);
	return 0;
}
BBINT openb3d_openb3dex_EmitterVariance(struct openb3d_openb3dex_TParticleEmitter_obj* bbt_emit,BBFLOAT bbt_v){
	(bbt_emit)->clas->m_EmitterVariance_f(bbt_emit,bbt_v);
	return 0;
}
BBINT openb3d_openb3dex_ParticleColor(struct openb3d_openb3dex_TSprite_obj* bbt_sprite,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b,BBFLOAT bbt_a){
	ParticleColor(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_sprite,&openb3d_openb3dex_TEntity)),bbt_r,bbt_g,bbt_b,bbt_a);
	return 0;
}
BBINT openb3d_openb3dex_ParticleVector(struct openb3d_openb3dex_TSprite_obj* bbt_sprite,BBFLOAT bbt_x,BBFLOAT bbt_y,BBFLOAT bbt_z){
	ParticleVector(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_sprite,&openb3d_openb3dex_TEntity)),bbt_x,bbt_y,bbt_z);
	return 0;
}
BBINT openb3d_openb3dex_ParticleTrail(struct openb3d_openb3dex_TSprite_obj* bbt_sprite,BBINT bbt_length){
	ParticleTrail(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_sprite,&openb3d_openb3dex_TEntity)),bbt_length);
	return 0;
}
struct openb3d_openb3dex_TShader_obj* openb3d_openb3dex_LoadShader(BBSTRING bbt_ShaderName,BBSTRING bbt_VshaderFileName,BBSTRING bbt_FshaderFileName){
	return openb3d_openb3dex_TShader_LoadShader_TTShader_SSS(bbt_ShaderName,bbt_VshaderFileName,bbt_FshaderFileName);
}
struct openb3d_openb3dex_TShader_obj* openb3d_openb3dex_CreateShader(BBSTRING bbt_ShaderName,BBSTRING bbt_VshaderString,BBSTRING bbt_FshaderString){
	return openb3d_openb3dex_TShader_CreateShader_TTShader_SSS(bbt_ShaderName,bbt_VshaderString,bbt_FshaderString);
}
BBINT openb3d_openb3dex_ShadeSurface(struct openb3d_openb3dex_TSurface_obj* bbt_surf,struct openb3d_openb3dex_TShader_obj* bbt_material){
	ShadeSurface(openb3d_openb3dex_TSurface_GetInstance_pb_TTSurface(bbt_surf),openb3d_openb3dex_TShader_GetInstance_pb_TTShader(bbt_material));
	return 0;
}
BBINT openb3d_openb3dex_ShadeMesh(struct openb3d_openb3dex_TMesh_obj* bbt_mesh,struct openb3d_openb3dex_TShader_obj* bbt_material){
	ShadeMesh(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity((struct openb3d_openb3dex_TEntity_obj*)bbObjectDowncast(bbt_mesh,&openb3d_openb3dex_TEntity)),openb3d_openb3dex_TShader_GetInstance_pb_TTShader(bbt_material));
	return 0;
}
BBINT openb3d_openb3dex_ShadeEntity(struct openb3d_openb3dex_TEntity_obj* bbt_ent,struct openb3d_openb3dex_TShader_obj* bbt_material){
	ShadeEntity(openb3d_openb3dex_TEntity_GetInstance_pb_TTEntity(bbt_ent),openb3d_openb3dex_TShader_GetInstance_pb_TTShader(bbt_material));
	return 0;
}
struct openb3d_openb3dex_TTexture_obj* openb3d_openb3dex_ShaderTexture(struct openb3d_openb3dex_TShader_obj* bbt_material,struct openb3d_openb3dex_TTexture_obj* bbt_tex,BBSTRING bbt_name,BBINT bbt_index){
	return (bbt_material)->clas->m_ShaderTexture_TTTextureSi(bbt_material,bbt_tex,bbt_name,bbt_index);
}
BBINT openb3d_openb3dex_SetFloat(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBFLOAT bbt_v1){
	(bbt_material)->clas->m_SetFloat_Sf(bbt_material,bbt_name,bbt_v1);
	return 0;
}
BBINT openb3d_openb3dex_SetFloat2(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBFLOAT bbt_v1,BBFLOAT bbt_v2){
	(bbt_material)->clas->m_SetFloat2_Sff(bbt_material,bbt_name,bbt_v1,bbt_v2);
	return 0;
}
BBINT openb3d_openb3dex_SetFloat3(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBFLOAT bbt_v1,BBFLOAT bbt_v2,BBFLOAT bbt_v3){
	(bbt_material)->clas->m_SetFloat3_Sfff(bbt_material,bbt_name,bbt_v1,bbt_v2,bbt_v3);
	return 0;
}
BBINT openb3d_openb3dex_SetFloat4(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBFLOAT bbt_v1,BBFLOAT bbt_v2,BBFLOAT bbt_v3,BBFLOAT bbt_v4){
	(bbt_material)->clas->m_SetFloat4_Sffff(bbt_material,bbt_name,bbt_v1,bbt_v2,bbt_v3,bbt_v4);
	return 0;
}
BBINT openb3d_openb3dex_UseFloat(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBFLOAT* bbt_v1){
	(bbt_material)->clas->m_UseFloat_Svf(bbt_material,bbt_name,bbt_v1);
	return 0;
}
BBINT openb3d_openb3dex_UseFloat2(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBFLOAT* bbt_v1,BBFLOAT* bbt_v2){
	(bbt_material)->clas->m_UseFloat2_Svfvf(bbt_material,bbt_name,bbt_v1,bbt_v2);
	return 0;
}
BBINT openb3d_openb3dex_UseFloat3(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBFLOAT* bbt_v1,BBFLOAT* bbt_v2,BBFLOAT* bbt_v3){
	(bbt_material)->clas->m_UseFloat3_Svfvfvf(bbt_material,bbt_name,bbt_v1,bbt_v2,bbt_v3);
	return 0;
}
BBINT openb3d_openb3dex_UseFloat4(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBFLOAT* bbt_v1,BBFLOAT* bbt_v2,BBFLOAT* bbt_v3,BBFLOAT* bbt_v4){
	(bbt_material)->clas->m_UseFloat4_Svfvfvfvf(bbt_material,bbt_name,bbt_v1,bbt_v2,bbt_v3,bbt_v4);
	return 0;
}
BBINT openb3d_openb3dex_SetInteger(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT bbt_v1){
	(bbt_material)->clas->m_SetInteger_Si(bbt_material,bbt_name,bbt_v1);
	return 0;
}
BBINT openb3d_openb3dex_SetInteger2(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT bbt_v1,BBINT bbt_v2){
	(bbt_material)->clas->m_SetInteger2_Sii(bbt_material,bbt_name,bbt_v1,bbt_v2);
	return 0;
}
BBINT openb3d_openb3dex_SetInteger3(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT bbt_v1,BBINT bbt_v2,BBINT bbt_v3){
	(bbt_material)->clas->m_SetInteger3_Siii(bbt_material,bbt_name,bbt_v1,bbt_v2,bbt_v3);
	return 0;
}
BBINT openb3d_openb3dex_SetInteger4(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT bbt_v1,BBINT bbt_v2,BBINT bbt_v3,BBINT bbt_v4){
	(bbt_material)->clas->m_SetInteger4_Siiii(bbt_material,bbt_name,bbt_v1,bbt_v2,bbt_v3,bbt_v4);
	return 0;
}
BBINT openb3d_openb3dex_UseInteger(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT* bbt_v1){
	(bbt_material)->clas->m_UseInteger_Svi(bbt_material,bbt_name,bbt_v1);
	return 0;
}
BBINT openb3d_openb3dex_UseInteger2(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT* bbt_v1,BBINT* bbt_v2){
	(bbt_material)->clas->m_UseInteger2_Svivi(bbt_material,bbt_name,bbt_v1,bbt_v2);
	return 0;
}
BBINT openb3d_openb3dex_UseInteger3(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT* bbt_v1,BBINT* bbt_v2,BBINT* bbt_v3){
	(bbt_material)->clas->m_UseInteger3_Svivivi(bbt_material,bbt_name,bbt_v1,bbt_v2,bbt_v3);
	return 0;
}
BBINT openb3d_openb3dex_UseInteger4(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT* bbt_v1,BBINT* bbt_v2,BBINT* bbt_v3,BBINT* bbt_v4){
	(bbt_material)->clas->m_UseInteger4_Svivivivi(bbt_material,bbt_name,bbt_v1,bbt_v2,bbt_v3,bbt_v4);
	return 0;
}
BBINT openb3d_openb3dex_UseSurface(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,struct openb3d_openb3dex_TSurface_obj* bbt_surf,BBINT bbt_vbo){
	(bbt_material)->clas->m_UseSurface_STTSurfacei(bbt_material,bbt_name,bbt_surf,bbt_vbo);
	return 0;
}
BBINT openb3d_openb3dex_UseMatrix(struct openb3d_openb3dex_TShader_obj* bbt_material,BBSTRING bbt_name,BBINT bbt_Mode){
	(bbt_material)->clas->m_UseMatrix_Si(bbt_material,bbt_name,bbt_Mode);
	return 0;
}
struct openb3d_openb3dex_TMaterial_obj* openb3d_openb3dex_LoadMaterial(BBSTRING bbt_filename,BBINT bbt_flags,BBINT bbt_frame_width,BBINT bbt_frame_height,BBINT bbt_first_frame,BBINT bbt_frame_count){
	return openb3d_openb3dex_TMaterial_LoadMaterial_TTMaterial_Siiiii(bbt_filename,bbt_flags,bbt_frame_width,bbt_frame_height,bbt_first_frame,bbt_frame_count);
}
BBINT openb3d_openb3dex_ShaderMaterial(struct openb3d_openb3dex_TShader_obj* bbt_material,struct openb3d_openb3dex_TMaterial_obj* bbt_tex,BBSTRING bbt_name,BBINT bbt_index){
	(bbt_material)->clas->m_ShaderMaterial_TTMaterialSi(bbt_material,bbt_tex,bbt_name,bbt_index);
	return 0;
}
BBINT openb3d_openb3dex_AmbientShader(struct openb3d_openb3dex_TShader_obj* bbt_material){
	openb3d_openb3dex_TGlobal_ambient_shader=bbt_material;
	AmbientShader(openb3d_openb3dex_TShader_GetInstance_pb_TTShader(bbt_material));
	return 0;
}
struct openb3d_openb3dex_TShadowObject_obj* openb3d_openb3dex_CreateShadow(struct openb3d_openb3dex_TMesh_obj* bbt_parent,BBINT bbt_Static){
	return openb3d_openb3dex_TShadowObject_CreateShadow_TTShadowObject_TTMeshi(bbt_parent,bbt_Static);
}
BBINT openb3d_openb3dex_FreeShadow(struct openb3d_openb3dex_TShadowObject_obj* bbt_shad){
	(bbt_shad)->clas->m_FreeShadow(bbt_shad);
	return 0;
}
BBINT openb3d_openb3dex_ResetShadow(struct openb3d_openb3dex_TShadowObject_obj* bbt_shad){
	bbt_shad->_openb3d_openb3dex_tshadowobject_vcreated [0U]=0;
	return 0;
}
BBINT openb3d_openb3dex_SetShadowColor(BBINT bbt_R,BBINT bbt_G,BBINT bbt_B,BBINT bbt_A){
	SetShadowColor(bbt_R,bbt_G,bbt_B,bbt_A);
	return 0;
}
struct openb3d_openb3dex_TStencil_obj* openb3d_openb3dex_CreateStencil(){
	return openb3d_openb3dex_TStencil_CreateStencil_TTStencil();
}
BBINT openb3d_openb3dex_StencilAlpha(struct openb3d_openb3dex_TStencil_obj* bbt_stencil,BBFLOAT bbt_a){
	(bbt_stencil)->clas->m_StencilAlpha_f(bbt_stencil,bbt_a);
	return 0;
}
BBINT openb3d_openb3dex_StencilClsColor(struct openb3d_openb3dex_TStencil_obj* bbt_stencil,BBFLOAT bbt_r,BBFLOAT bbt_g,BBFLOAT bbt_b){
	(bbt_stencil)->clas->m_StencilClsColor_fff(bbt_stencil,bbt_r,bbt_g,bbt_b);
	return 0;
}
BBINT openb3d_openb3dex_StencilClsMode(struct openb3d_openb3dex_TStencil_obj* bbt_stencil,BBINT bbt_cls_color,BBINT bbt_cls_zbuffer){
	(bbt_stencil)->clas->m_StencilClsMode_ii(bbt_stencil,bbt_cls_color,bbt_cls_zbuffer);
	return 0;
}
BBINT openb3d_openb3dex_StencilMesh(struct openb3d_openb3dex_TStencil_obj* bbt_stencil,struct openb3d_openb3dex_TMesh_obj* bbt_mesh,BBINT bbt_Mode){
	(bbt_stencil)->clas->m_StencilMesh_TTMeshi(bbt_stencil,bbt_mesh,bbt_Mode);
	return 0;
}
BBINT openb3d_openb3dex_StencilMode(struct openb3d_openb3dex_TStencil_obj* bbt_stencil,BBINT bbt_m,BBINT bbt_o){
	(bbt_stencil)->clas->m_StencilMode_ii(bbt_stencil,bbt_m,bbt_o);
	return 0;
}
BBINT openb3d_openb3dex_UseStencil(struct openb3d_openb3dex_TStencil_obj* bbt_stencil){
	UseStencil(openb3d_openb3dex_TStencil_GetInstance_pb_TTStencil(bbt_stencil));
	return 0;
}
struct openb3d_openb3dex_TVoxelSprite_obj* openb3d_openb3dex_CreateVoxelSprite(BBINT bbt_slices,struct openb3d_openb3dex_TEntity_obj* bbt_parent){
	return openb3d_openb3dex_TVoxelSprite_CreateVoxelSprite_TTVoxelSprite_iTTEntity(bbt_slices,bbt_parent);
}
BBINT openb3d_openb3dex_VoxelSpriteMaterial(struct openb3d_openb3dex_TVoxelSprite_obj* bbt_voxelspr,struct openb3d_openb3dex_TMaterial_obj* bbt_mat){
	(bbt_voxelspr)->clas->m_VoxelSpriteMaterial_TTMaterial(bbt_voxelspr,bbt_mat);
	return 0;
}
static int __bb_openb3d_openb3dex_openb3dex_inited = 0;
int __bb_openb3d_openb3dex_openb3dex(){
	if (!__bb_openb3d_openb3dex_openb3dex_inited) {
		__bb_openb3d_openb3dex_openb3dex_inited = 1;
		__bb_brl_blitz_blitz();
		__bb_openb3d_openb3dlib_openb3dlib();
		__bb_brl_glmax2d_glmax2d();
		__bb_brl_bmploader_bmploader();
		__bb_brl_pngloader_pngloader();
		__bb_brl_jpgloader_jpgloader();
		__bb_brl_retro_retro();
		__bb_brl_map_map();
		bbObjectRegisterType(&openb3d_openb3dex_TGlobal);
		bbObjectRegisterType(&openb3d_openb3dex_TEntity);
		bbObjectRegisterType(&openb3d_openb3dex_TCamera);
		bbObjectRegisterType(&openb3d_openb3dex_TLight);
		bbObjectRegisterType(&openb3d_openb3dex_TPivot);
		bbObjectRegisterType(&openb3d_openb3dex_TMesh);
		bbObjectRegisterType(&openb3d_openb3dex_TSprite);
		bbObjectRegisterType(&openb3d_openb3dex_TBone);
		bbObjectRegisterType(&openb3d_openb3dex_TSurface);
		bbObjectRegisterType(&openb3d_openb3dex_TTexture);
		bbObjectRegisterType(&openb3d_openb3dex_TTextureFilter);
		bbObjectRegisterType(&openb3d_openb3dex_TBrush);
		bbObjectRegisterType(&openb3d_openb3dex_TAnimation);
		bbObjectRegisterType(&openb3d_openb3dex_TAnimationKeys);
		bbObjectRegisterType(&openb3d_openb3dex_TPick);
		bbObjectRegisterType(&openb3d_openb3dex_TVector);
		bbObjectRegisterType(&openb3d_openb3dex_TMatrix);
		bbObjectRegisterType(&openb3d_openb3dex_TQuaternion);
		bbObjectRegisterType(&openb3d_openb3dex_TBlitz2D);
		bbObjectRegisterType(&openb3d_openb3dex_TUtility);
		bbObjectRegisterType(&openb3d_openb3dex_TDebug);
		bbObjectRegisterType(&openb3d_openb3dex_TTerrain);
		bbObjectRegisterType(&openb3d_openb3dex_TMaterial);
		bbObjectRegisterType(&openb3d_openb3dex_TShader);
		bbObjectRegisterType(&openb3d_openb3dex_TShadowObject);
		bbObjectRegisterType(&openb3d_openb3dex_THardwareInfo);
		bbObjectRegisterType(&openb3d_openb3dex_TGLShader);
		bbObjectRegisterType(&openb3d_openb3dex_TStencil);
		bbObjectRegisterType(&openb3d_openb3dex_TFluid);
		bbObjectRegisterType(&openb3d_openb3dex_TBlob);
		bbObjectRegisterType(&openb3d_openb3dex_TGeosphere);
		bbObjectRegisterType(&openb3d_openb3dex_TOcTree);
		bbObjectRegisterType(&openb3d_openb3dex_TVoxelSprite);
		bbObjectRegisterType(&openb3d_openb3dex_TAction);
		bbObjectRegisterType(&openb3d_openb3dex_TConstraint);
		bbObjectRegisterType(&openb3d_openb3dex_TRigidBody);
		bbObjectRegisterType(&openb3d_openb3dex_TParticleBatch);
		bbObjectRegisterType(&openb3d_openb3dex_TParticleEmitter);
		openb3d_openb3dex_TGlobal_alpha_enable=0;
		openb3d_openb3dex_TGlobal_blend_mode=0;
		openb3d_openb3dex_TGlobal_fx1=0;
		openb3d_openb3dex_TGlobal_fx2=0;
		openb3d_openb3dex_TCamera_cam_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TGlobal_camera_in_use=&bbNullObject;
		openb3d_openb3dex_TGlobal_fog_enabled=0;
		openb3d_openb3dex_TEntity_entity_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TEntity_entity_list_id=0;
		openb3d_openb3dex_TEntity_ent_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TEntity_animate_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TEntity_animate_list_id=0;
		openb3d_openb3dex_TCamera_cam_list_id=0;
		openb3d_openb3dex_TLight_light_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TLight_light_list_id=0;
		openb3d_openb3dex_TPick_ent_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TPick_ent_list_id=0;
		openb3d_openb3dex_TShadowObject_shadow_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TShadowObject_shadow_list_id=0;
		openb3d_openb3dex_TShadowObject_shad_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TTerrain_terrain_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TTerrain_terrain_list_id=0;
		openb3d_openb3dex_TTexture_tex_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TTexture_tex_list_id=0;
		openb3d_openb3dex_TTexture_tex_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TGlobal_root_ent=&bbNullObject;
		openb3d_openb3dex_TSurface_surf_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TBrush_brush_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TShader_shader_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TMatrix_matrix_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TEntity_child_list_queue=brl_linkedlist_CreateList();
		openb3d_openb3dex_TAnimationKeys_animkeys_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TStencil_stencil_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_THardwareInfo_DepthStencil=0;
		openb3d_openb3dex_TGlobal_Shadows_enabled=0;
		openb3d_openb3dex_TGlobal_height=0;
		openb3d_openb3dex_TPick_picked_ent=&bbNullObject;
		openb3d_openb3dex_TPick_picked_surface=&bbNullObject;
		openb3d_openb3dex_TAction_action_map=bbObjectNew(&brl_map_TMap);
		openb3d_openb3dex_TAction_action_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TAction_action_list_id=0;
		openb3d_openb3dex_TGlobal_ambient_shader=&bbNullObject;
		openb3d_openb3dex_TGlobal_width=0;
		openb3d_openb3dex_TGlobal_Mode=0;
		openb3d_openb3dex_TGlobal_depth=0;
		openb3d_openb3dex_TGlobal_rate=0;
		openb3d_openb3dex_TGlobal_ambient_red=0;
		openb3d_openb3dex_TGlobal_ambient_green=0;
		openb3d_openb3dex_TGlobal_ambient_blue=0;
		openb3d_openb3dex_TGlobal_vbo_enabled=0;
		openb3d_openb3dex_TGlobal_vbo_min_tris=0;
		openb3d_openb3dex_TGlobal_anim_speed=0;
		openb3d_openb3dex_TGlobal_gfx=&bbNullObject;
		openb3d_openb3dex_TEntity_tformed_x=0;
		openb3d_openb3dex_TEntity_tformed_y=0;
		openb3d_openb3dex_TEntity_tformed_z=0;
		openb3d_openb3dex_TCamera_projected_x=0;
		openb3d_openb3dex_TCamera_projected_y=0;
		openb3d_openb3dex_TCamera_projected_z=0;
		openb3d_openb3dex_TLight_light_no=0;
		openb3d_openb3dex_TLight_no_lights=0;
		openb3d_openb3dex_TLight_max_lights=0;
		openb3d_openb3dex_TLight_gl_light=0;
		openb3d_openb3dex_TPick_picked_x=0;
		openb3d_openb3dex_TPick_picked_y=0;
		openb3d_openb3dex_TPick_picked_z=0;
		openb3d_openb3dex_TPick_picked_nx=0;
		openb3d_openb3dex_TPick_picked_ny=0;
		openb3d_openb3dex_TPick_picked_nz=0;
		openb3d_openb3dex_TPick_picked_time=0;
		openb3d_openb3dex_TPick_picked_triangle=0;
		openb3d_openb3dex_TShadowObject_VolumeLength=0;
		openb3d_openb3dex_TShadowObject_top_caps=0;
		openb3d_openb3dex_TShadowObject_parallel=0;
		openb3d_openb3dex_TShadowObject_light_x=0;
		openb3d_openb3dex_TShadowObject_light_y=0;
		openb3d_openb3dex_TShadowObject_light_z=0;
		openb3d_openb3dex_TShadowObject_midStencilVal=0;
		openb3d_openb3dex_TShadowObject_ShadowRed=0;
		openb3d_openb3dex_TShadowObject_ShadowGreen=0;
		openb3d_openb3dex_TShadowObject_ShadowBlue=0;
		openb3d_openb3dex_TShadowObject_ShadowAlpha=0;
		openb3d_openb3dex_TTerrain_triangleindex=0;
		openb3d_openb3dex_THardwareInfo_Vendor=&bbEmptyString;
		openb3d_openb3dex_THardwareInfo_Renderer=&bbEmptyString;
		openb3d_openb3dex_THardwareInfo_OGLVersion=&bbEmptyString;
		openb3d_openb3dex_THardwareInfo_Extensions=&bbEmptyString;
		openb3d_openb3dex_THardwareInfo_GLTCSupport=0;
		openb3d_openb3dex_THardwareInfo_S3TCSupport=0;
		openb3d_openb3dex_THardwareInfo_AnIsoSupport=0;
		openb3d_openb3dex_THardwareInfo_MultiTexSupport=0;
		openb3d_openb3dex_THardwareInfo_TexBlendSupport=0;
		openb3d_openb3dex_THardwareInfo_CubemapSupport=0;
		openb3d_openb3dex_THardwareInfo_DepthmapSupport=0;
		openb3d_openb3dex_THardwareInfo_VBOSupport=0;
		openb3d_openb3dex_THardwareInfo_VPSupport=0;
		openb3d_openb3dex_THardwareInfo_FPSupport=0;
		openb3d_openb3dex_THardwareInfo_ShaderSupport=0;
		openb3d_openb3dex_THardwareInfo_VSSupport=0;
		openb3d_openb3dex_THardwareInfo_FSSupport=0;
		openb3d_openb3dex_THardwareInfo_SLSupport=0;
		openb3d_openb3dex_THardwareInfo_FBOSupport=0;
		openb3d_openb3dex_THardwareInfo_MaxTextures=0;
		openb3d_openb3dex_THardwareInfo_MaxTexSize=0;
		openb3d_openb3dex_THardwareInfo_MaxLights=0;
		openb3d_openb3dex_TLight_ambient=bbArrayNew("f", 2, 8, 4);
		openb3d_openb3dex_TLight_diffuse=bbArrayNew("f", 2, 8, 4);
		openb3d_openb3dex_TLight_specular=bbArrayNew("f", 2, 8, 4);
		openb3d_openb3dex_TLight_position=bbArrayNew("f", 2, 8, 4);
		openb3d_openb3dex_TLight_spotDirection=bbArrayNew("f", 2, 8, 3);
		openb3d_openb3dex_TLight_spotExponent=bbArrayNew("f", 2, 8, 1);
		openb3d_openb3dex_TLight_spotCutoff=bbArrayNew("f", 2, 8, 1);
		openb3d_openb3dex_TLight_constantAtt=bbArrayNew("f", 2, 8, 1);
		openb3d_openb3dex_TLight_linearAtt=bbArrayNew("f", 2, 8, 1);
		openb3d_openb3dex_TLight_quadraticAtt=bbArrayNew("f", 2, 8, 1);
		openb3d_openb3dex_TTextureFilter_filter_list=brl_linkedlist_CreateList();
		openb3d_openb3dex_TDebug_cno=0;
		openb3d_openb3dex_TDebug_surf_no=0;
		openb3d_openb3dex_TDebug_info=1;
		openb3d_openb3dex_TDebug_show_ents=1;
		openb3d_openb3dex_TDebug_bounding_sphere=&bbNullObject;
		openb3d_openb3dex_TDebug_debug_mesh=&bbNullObject;
		openb3d_openb3dex_TDebug_debug_surf=&bbNullObject;
		openb3d_openb3dex_TDebug_marker=&bbNullObject;
		openb3d_openb3dex_THardwareInfo_ScreenWidth=brl_system_DesktopWidth();
		openb3d_openb3dex_THardwareInfo_ScreenHeight=brl_system_DesktopHeight();
		openb3d_openb3dex_THardwareInfo_ScreenDepth=brl_system_DesktopDepth();
		openb3d_openb3dex_THardwareInfo_ScreenHertz=brl_system_DesktopHertz();
		return 0;
	}
	return 0;
}