Discover geo types and rename tiles to geo
This commit is contained in:
parent
b5fd42aed2
commit
ffae7d36fb
|
|
@ -151,7 +151,7 @@ u32 props[] = {
|
|||
endobjective
|
||||
|
||||
tag(0x09, 1)
|
||||
hoverbike(0x0100, MODEL_HOVBIKE, PAD_AZT_0000, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOTYPE3, 1000)
|
||||
hoverbike(0x0100, MODEL_HOVBIKE, PAD_AZT_0000, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOCYL, 1000)
|
||||
chr(SPAWNFLAG_ANTINONINTERACTABLE | SPAWNFLAG_BLUESIGHT, CHR_ELVIS, PAD_AZT_0106, BODY_THEKING, HEAD_ELVIS, AILIST_INIT_ELVIS, -1, -1, 1000, 200, CHRFLAG0_SKIPSAFETYCHECKS, CHRFLAG1_AIVSAI_ADVANTAGED | CHRFLAG1_NOOP_00200000, TEAM_ALLY, SQUADRON_01, -1, 0, 0, 0, 0, 0)
|
||||
weapon(0x0100, MODEL_CHRMAIANPISTOL, CHR_ELVIS, OBJFLAG_ASSIGNEDTOCHR, 0, 0, WEAPON_PHOENIX)
|
||||
#if VERSION >= VERSION_NTSC_1_0
|
||||
|
|
|
|||
|
|
@ -361,7 +361,7 @@ u32 props[] = {
|
|||
door(0x0100, MODEL_SECRETINDOOR, PAD_DISH_0192, OBJFLAG_DEACTIVATED, 0, OBJFLAG3_INFRARED, 1000, 0x005a0000, 0x03e80000, 0x012c0000, 0x012c0000, 0x00030000, 0, DOORTYPE_SWINGING, 0x00000040, 0x000001e0, 0x00000000, 0x00000000, 0x00000b00)
|
||||
tag(0x93, 1)
|
||||
hover_prop(0x00eb, MODEL_HOVERCRATE1, PAD_DISH_0141, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH | OBJFLAG_DEACTIVATED | OBJFLAG_20000000, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_REMOVEWHENDESTROYED | OBJFLAG2_BULLETPROOF | OBJFLAG2_80000000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE, 1000, 0x02010000)
|
||||
hoverbike(0x0100, MODEL_HOVBIKE, PAD_DISH_01F9, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOTYPE3, 1000)
|
||||
hoverbike(0x0100, MODEL_HOVBIKE, PAD_DISH_01F9, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOCYL, 1000)
|
||||
tag(0x42, 1)
|
||||
stdobject(0x0100, MODEL_DROPSHIP, -1, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_ILLUMINATED | OBJFLAG_00001000 | OBJFLAG_INVINCIBLE, 0, 0, 1000)
|
||||
door(0x0100, MODEL_CH_SHUTTER1, PAD_DISH_0166, OBJFLAG_ILLUMINATED | OBJFLAG_DEACTIVATED, OBJFLAG2_AICANNOTUSE, 0, 1000, 0x0000fd70, 0x0000e666, 0x00007fff, 0x00014000, 0x00000222, 0, DOORTYPE_VERTICAL, 0x00000020, 0x00000384, 0x00000000, 0x00000000, 0x00000400)
|
||||
|
|
|
|||
|
|
@ -326,7 +326,7 @@ u32 props[] = {
|
|||
autogun(0x00c0, MODEL_A51_ROOFGUN, PAD_LUE_0403, OBJFLAG_00000004, OBJFLAG2_EXCLUDE_A | OBJFLAG2_REMOVEWHENDESTROYED, 0, 1000, 0x0367, 0x00004000, 0xffffc000, 0x00000e38, 0x003c0000)
|
||||
autogun(0x00c0, MODEL_A51_ROOFGUN, PAD_LUE_0404, OBJFLAG_00000004, OBJFLAG2_EXCLUDE_A | OBJFLAG2_REMOVEWHENDESTROYED, 0, 1000, 0x0369, 0x000031c7, 0xffffce39, 0x00000e38, 0x003c0000)
|
||||
tag(0x55, 1)
|
||||
hoverbike(0x0100, MODEL_HOVBIKE, PAD_LUE_037A, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOTYPE3, 1000)
|
||||
hoverbike(0x0100, MODEL_HOVBIKE, PAD_LUE_037A, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOCYL, 1000)
|
||||
tag(0x02, 1)
|
||||
chopper(0x0a00, MODEL_A51INTERCEPTOR, PAD_LUE_0359, OBJFLAG_00000008 | OBJFLAG_00000100 | OBJFLAG_20000000, OBJFLAG2_INVISIBLE, OBJFLAG3_00000200 | OBJFLAG3_REACTTOSIGHT, 100, 0x040c)
|
||||
tag(0x03, 1)
|
||||
|
|
|
|||
|
|
@ -235,7 +235,7 @@ u32 props[] = {
|
|||
hover_prop(0x0100, MODEL_A51TROLLEY, PAD_TRA_0120, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE, 1000, 0x00010000)
|
||||
hover_prop(0x0100, MODEL_HOVERBED, PAD_TRA_0122, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_HOVERBEDSHIELD, 1000, 0x00010000)
|
||||
tag(0x35, 1)
|
||||
hoverbike(0x0100, MODEL_HOVBIKE, PAD_TRA_03FB, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOTYPE3, 1000)
|
||||
hoverbike(0x0100, MODEL_HOVBIKE, PAD_TRA_03FB, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_AISEETHROUGH, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE | OBJFLAG3_GEOCYL, 1000)
|
||||
hover_prop(0x0100, MODEL_HOVERCRATE1, PAD_TRA_011D, OBJFLAG_00000001 | OBJFLAG_00000100 | OBJFLAG_INVINCIBLE | OBJFLAG_UNCOLLECTABLE | OBJFLAG_01000000 | OBJFLAG_DEACTIVATED | OBJFLAG_20000000, OBJFLAG2_00000100 | OBJFLAG2_00000200 | OBJFLAG2_IMMUNETOGUNFIRE | OBJFLAG2_BULLETPROOF | OBJFLAG2_00200000, OBJFLAG3_PUSHABLE | OBJFLAG3_GRABBABLE, 1000, 0x02010000)
|
||||
tag(0x17, 2)
|
||||
tag(0x18, 2)
|
||||
|
|
|
|||
|
|
@ -1278,7 +1278,7 @@ void bbikeUpdateVertical(struct coord *pos)
|
|||
g_Vars.currentplayer->vv_height = g_Vars.currentplayer->headpos.y / g_Vars.currentplayer->standheight * g_Vars.currentplayer->vv_eyeheight;
|
||||
g_Vars.currentplayer->vv_manground = g_Vars.currentplayer->prop->pos.y - g_Vars.currentplayer->vv_height;
|
||||
|
||||
if (g_Vars.currentplayer->floorflags & TILEFLAG_DIE) {
|
||||
if (g_Vars.currentplayer->floorflags & GEOFLAG_DIE) {
|
||||
playerDie(true);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -95,13 +95,13 @@ void bgrabInit(void)
|
|||
|
||||
obj->hidden |= OBJHFLAG_GRABBED;
|
||||
|
||||
if (obj->flags3 & OBJFLAG3_GEOTYPE3) {
|
||||
withforce = cd000276c8(obj->geo3,
|
||||
if (obj->flags3 & OBJFLAG3_GEOCYL) {
|
||||
withforce = cd000276c8(obj->geocyl,
|
||||
g_Vars.currentplayer->prop->pos.x,
|
||||
g_Vars.currentplayer->prop->pos.z,
|
||||
VERSION >= VERSION_NTSC_1_0 ? 45 : 40, 0, 0);
|
||||
} else {
|
||||
withforce = cd000274e0(obj->geo2,
|
||||
withforce = cd000274e0(obj->geoblock,
|
||||
g_Vars.currentplayer->prop->pos.x,
|
||||
g_Vars.currentplayer->prop->pos.z,
|
||||
VERSION >= VERSION_NTSC_1_0 ? 45 : 40, 0, 0);
|
||||
|
|
@ -680,7 +680,7 @@ bool bgrab0f0cdb68(f32 angle)
|
|||
}
|
||||
} else if (var80070e80 != 0) {
|
||||
if (g_Vars.currentplayer->grabbedprop->type == PROPTYPE_OBJ) {
|
||||
if (g_Vars.currentplayer->grabbedprop->obj->flags3 & OBJFLAG3_GEOTYPE3) {
|
||||
if (g_Vars.currentplayer->grabbedprop->obj->flags3 & OBJFLAG3_GEOCYL) {
|
||||
propObjGetBbox(g_Vars.currentplayer->grabbedprop, &radius, &ymax, &ymin);
|
||||
|
||||
f0 = (var8009de78.f[0] - spa4.f[0]) * f20 + (var8009de78.f[2] - spa4.f[2]) * f22;
|
||||
|
|
@ -882,7 +882,7 @@ void bgrabUpdateVertical(void)
|
|||
g_Vars.currentplayer->vv_manground = fVar3 * (PAL ? 0.054400026798248f : 0.045499980449677f);
|
||||
}
|
||||
|
||||
if ((g_Vars.currentplayer->floorflags & TILEFLAG_DIE) &&
|
||||
if ((g_Vars.currentplayer->floorflags & GEOFLAG_DIE) &&
|
||||
g_Vars.currentplayer->vv_manground - 20.0f < g_Vars.currentplayer->vv_ground) {
|
||||
playerDie(true);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -438,7 +438,7 @@ f32 bmoveCalculateLookahead(void)
|
|||
+ (sp150.z - spf0.z) * (sp150.z - spf0.z));
|
||||
}
|
||||
|
||||
if (sp160 > 60.0f || (flags & TILEFLAG_0001)) {
|
||||
if (sp160 > 60.0f || (flags & GEOFLAG_0001)) {
|
||||
for (i = 0; i < 5; i++) {
|
||||
populated[i] = false;
|
||||
value = (i + 1) * sp160 * 0.2f;
|
||||
|
|
|
|||
|
|
@ -192,7 +192,7 @@ s32 bwalkTryMoveUpwards(f32 amount)
|
|||
f32 ymin;
|
||||
f32 radius;
|
||||
|
||||
if (g_Vars.currentplayer->floorflags & TILEFLAG_0100) {
|
||||
if (g_Vars.currentplayer->floorflags & GEOFLAG_0100) {
|
||||
g_Vars.enableslopes = false;
|
||||
} else {
|
||||
g_Vars.enableslopes = true;
|
||||
|
|
@ -244,7 +244,7 @@ bool bwalkCalculateNewPosition(struct coord *vel, f32 rotateamount, bool apply,
|
|||
f32 zdiff;
|
||||
s32 i;
|
||||
|
||||
if (g_Vars.currentplayer->floorflags & TILEFLAG_0100) {
|
||||
if (g_Vars.currentplayer->floorflags & GEOFLAG_0100) {
|
||||
g_Vars.enableslopes = false;
|
||||
} else {
|
||||
g_Vars.enableslopes = true;
|
||||
|
|
@ -905,8 +905,8 @@ void bwalkUpdateVertical(void)
|
|||
#endif
|
||||
}
|
||||
|
||||
// Kill player if standing on tile with TILEFLAG_DIE
|
||||
if ((g_Vars.currentplayer->floorflags & TILEFLAG_DIE)
|
||||
// Kill player if standing on tile with GEOFLAG_DIE
|
||||
if ((g_Vars.currentplayer->floorflags & GEOFLAG_DIE)
|
||||
&& g_Vars.currentplayer->vv_manground - 20.0f < g_Vars.currentplayer->vv_ground
|
||||
&& g_Vars.currentplayer->onladder == false
|
||||
&& onladder2 == false) {
|
||||
|
|
|
|||
|
|
@ -958,7 +958,7 @@ bool chr0f01f378(struct model *model, struct coord *arg1, struct coord *arg2, f3
|
|||
chr->sumground = chr->ground * (PAL ? 8.4175090789795f : 9.999998f);
|
||||
chr->fallspeed.y = 0.0f;
|
||||
|
||||
if (floorflags & TILEFLAG_DIE) {
|
||||
if (floorflags & GEOFLAG_DIE) {
|
||||
die = true;
|
||||
}
|
||||
}
|
||||
|
|
@ -5597,12 +5597,12 @@ bool chrUpdateGeometry(struct prop *prop, u8 **start, u8 **end)
|
|||
chr->actiontype != ACT_DRUGGEDKO &&
|
||||
(chr->chrflags & (CHRCFLAG_PERIMDISABLEDTMP | CHRCFLAG_HIDDEN)) == 0 &&
|
||||
(chr->hidden & CHRHFLAG_PERIMDISABLED) == 0) {
|
||||
chr->geo.header.type = TILETYPE_03;
|
||||
chr->geo.header.type = GEOTYPE_CYL;
|
||||
|
||||
if (chr->actiontype == ACT_DIE || chr->actiontype == ACT_DRUGGEDDROP) {
|
||||
chr->geo.header.flags = TILEFLAG_0010;
|
||||
chr->geo.header.flags = GEOFLAG_OPAQUE;
|
||||
} else {
|
||||
chr->geo.header.flags = TILEFLAG_0004 | TILEFLAG_0010;
|
||||
chr->geo.header.flags = GEOFLAG_COLLISIONS | GEOFLAG_OPAQUE;
|
||||
}
|
||||
|
||||
chr->geo.ymin = chr->manground;
|
||||
|
|
@ -5623,7 +5623,7 @@ bool chrUpdateGeometry(struct prop *prop, u8 **start, u8 **end)
|
|||
}
|
||||
|
||||
*start = (void *) &chr->geo;
|
||||
*end = *start + sizeof(struct tiletype3);
|
||||
*end = *start + sizeof(struct geocyl);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -688,8 +688,8 @@ void playerLoadDefaults(void)
|
|||
bmoveSetMode(MOVEMODE_WALK);
|
||||
|
||||
g_Vars.currentplayer->bondperimenabled = true;
|
||||
g_Vars.currentplayer->periminfo.header.type = TILETYPE_03;
|
||||
g_Vars.currentplayer->periminfo.header.flags = TILEFLAG_0004 | TILEFLAG_0010;
|
||||
g_Vars.currentplayer->periminfo.header.type = GEOTYPE_CYL;
|
||||
g_Vars.currentplayer->periminfo.header.flags = GEOFLAG_COLLISIONS | GEOFLAG_OPAQUE;
|
||||
g_Vars.currentplayer->periminfo.ymax = 0;
|
||||
g_Vars.currentplayer->periminfo.ymin = 0;
|
||||
g_Vars.currentplayer->periminfo.x = 0;
|
||||
|
|
@ -5684,7 +5684,7 @@ bool playerUpdateGeometry(struct prop *prop, u8 **start, u8 **end)
|
|||
*start = (void *) &g_Vars.players[playernum]->periminfo;
|
||||
}
|
||||
|
||||
*end = *start + sizeof(struct tiletype3);
|
||||
*end = *start + sizeof(struct geocyl);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
@ -5697,8 +5697,8 @@ bool playerUpdateGeometry(struct prop *prop, u8 **start, u8 **end)
|
|||
|
||||
void playerUpdatePerimInfo(void)
|
||||
{
|
||||
g_Vars.currentplayer->periminfo.header.type = TILETYPE_03;
|
||||
g_Vars.currentplayer->periminfo.header.flags = TILEFLAG_0004 | TILEFLAG_0010;
|
||||
g_Vars.currentplayer->periminfo.header.type = GEOTYPE_CYL;
|
||||
g_Vars.currentplayer->periminfo.header.flags = GEOFLAG_COLLISIONS | GEOFLAG_OPAQUE;
|
||||
|
||||
g_Vars.currentplayer->periminfo.ymin = g_Vars.currentplayer->vv_manground;
|
||||
g_Vars.currentplayer->periminfo.ymax = g_Vars.currentplayer->vv_manground + g_Vars.currentplayer->vv_headheight;
|
||||
|
|
|
|||
|
|
@ -237,8 +237,8 @@ void playermgrAllocatePlayer(s32 index)
|
|||
g_Vars.players[index]->prop = NULL;
|
||||
|
||||
g_Vars.players[index]->bondperimenabled = true;
|
||||
g_Vars.players[index]->periminfo.header.type = TILETYPE_03;
|
||||
g_Vars.players[index]->periminfo.header.flags = TILEFLAG_0004 | TILEFLAG_0010;
|
||||
g_Vars.players[index]->periminfo.header.type = GEOTYPE_CYL;
|
||||
g_Vars.players[index]->periminfo.header.flags = GEOFLAG_COLLISIONS | GEOFLAG_OPAQUE;
|
||||
g_Vars.players[index]->periminfo.ymax = 0;
|
||||
g_Vars.players[index]->periminfo.ymin = 0;
|
||||
g_Vars.players[index]->periminfo.x = 0;
|
||||
|
|
|
|||
|
|
@ -1047,28 +1047,28 @@ glabel var7f1aa1cc
|
|||
/* f067420: 00c01025 */ or $v0,$a2,$zero
|
||||
);
|
||||
|
||||
void func0f067424(struct modelrodata_bbox *bbox, Mtxf *mtx, struct tiletype2 *tile)
|
||||
void func0f067424(struct modelrodata_bbox *bbox, Mtxf *mtx, struct geoblock *block)
|
||||
{
|
||||
tile->header.numvertices = func0f066b5c(
|
||||
bbox->xmin, bbox->xmax, bbox->ymin, bbox->ymax, bbox->zmin, bbox->zmax, mtx, tile);
|
||||
tile->header.type = TILETYPE_02;
|
||||
tile->ymin = mtx->m[3][1] + func0f06683c(bbox, mtx);
|
||||
tile->ymax = mtx->m[3][1] + func0f06686c(bbox, mtx);
|
||||
block->header.numvertices = func0f066b5c(
|
||||
bbox->xmin, bbox->xmax, bbox->ymin, bbox->ymax, bbox->zmin, bbox->zmax, mtx, block);
|
||||
block->header.type = GEOTYPE_BLOCK;
|
||||
block->ymin = mtx->m[3][1] + func0f06683c(bbox, mtx);
|
||||
block->ymax = mtx->m[3][1] + func0f06686c(bbox, mtx);
|
||||
}
|
||||
|
||||
void func0f0674bc(struct modelrodata_type19 *rodata19, struct modelrodata_bbox *bbox, Mtxf *mtx, struct tiletype2 *tile)
|
||||
void func0f0674bc(struct modelrodata_type19 *rodata19, struct modelrodata_bbox *bbox, Mtxf *mtx, struct geoblock *block)
|
||||
{
|
||||
s32 i;
|
||||
|
||||
for (i = 0; i < rodata19->numvertices; i++) {
|
||||
tile->vertices[i][0] = mtx->m[3][0] + mtx->m[0][0] * rodata19->vertices[i].x + mtx->m[1][0] * rodata19->vertices[i].y + mtx->m[2][0] * rodata19->vertices[i].z;
|
||||
tile->vertices[i][1] = mtx->m[3][2] + mtx->m[0][2] * rodata19->vertices[i].x + mtx->m[1][2] * rodata19->vertices[i].y + mtx->m[2][2] * rodata19->vertices[i].z;
|
||||
block->vertices[i][0] = mtx->m[3][0] + mtx->m[0][0] * rodata19->vertices[i].x + mtx->m[1][0] * rodata19->vertices[i].y + mtx->m[2][0] * rodata19->vertices[i].z;
|
||||
block->vertices[i][1] = mtx->m[3][2] + mtx->m[0][2] * rodata19->vertices[i].x + mtx->m[1][2] * rodata19->vertices[i].y + mtx->m[2][2] * rodata19->vertices[i].z;
|
||||
}
|
||||
|
||||
tile->header.numvertices = rodata19->numvertices;
|
||||
tile->header.type = TILETYPE_02;
|
||||
tile->ymin = mtx->m[3][1] + func0f06683c(bbox, mtx);
|
||||
tile->ymax = mtx->m[3][1] + func0f06686c(bbox, mtx);
|
||||
block->header.numvertices = rodata19->numvertices;
|
||||
block->header.type = GEOTYPE_BLOCK;
|
||||
block->ymin = mtx->m[3][1] + func0f06683c(bbox, mtx);
|
||||
block->ymax = mtx->m[3][1] + func0f06686c(bbox, mtx);
|
||||
}
|
||||
|
||||
bool func0f0675c8(struct coord *pos, f32 arg1, struct modelrodata_bbox *bbox, Mtxf *mtx)
|
||||
|
|
@ -1429,7 +1429,7 @@ struct defaultobj *objFindByPos(struct coord *pos, s16 *rooms)
|
|||
if (prop->type == PROPTYPE_OBJ
|
||||
&& arrayIntersects(prop->rooms, rooms)
|
||||
&& propUpdateGeometry(prop, &sp38, &sp34)
|
||||
&& func000266a4(pos->x, pos->z, (struct tile *)sp38)) {
|
||||
&& func000266a4(pos->x, pos->z, (struct geo *)sp38)) {
|
||||
return prop->obj;
|
||||
}
|
||||
|
||||
|
|
@ -3940,7 +3940,7 @@ void func0f069750(s32 *arg0, s32 arg1, f32 *arg2)
|
|||
|
||||
struct var80069a70 var80069a70[];
|
||||
|
||||
void func0f069850(struct defaultobj *obj, struct coord *pos, f32 rot[3][3], struct tiletype3 *tile)
|
||||
void func0f069850(struct defaultobj *obj, struct coord *pos, f32 rot[3][3], struct geocyl *cyl)
|
||||
{
|
||||
Mtxf mtx;
|
||||
struct modelrodata_bbox *bbox = objFindBboxRodata(obj);
|
||||
|
|
@ -3958,41 +3958,41 @@ void func0f069850(struct defaultobj *obj, struct coord *pos, f32 rot[3][3], stru
|
|||
rodata19 = modelGetPartRodata(obj->model->filedata, MODELPART_HOVERBIKE_0064);
|
||||
}
|
||||
|
||||
if (obj->flags3 & OBJFLAG3_GEOTYPE3) {
|
||||
tile->header.type = TILETYPE_03;
|
||||
tile->header.flags = TILEFLAG_0004 | TILEFLAG_0008 | TILEFLAG_0010;
|
||||
if (obj->flags3 & OBJFLAG3_GEOCYL) {
|
||||
cyl->header.type = GEOTYPE_CYL;
|
||||
cyl->header.flags = GEOFLAG_COLLISIONS | GEOFLAG_0008 | GEOFLAG_OPAQUE;
|
||||
|
||||
if (obj->type == OBJTYPE_HOVERBIKE) {
|
||||
hoverbike = (struct hoverbikeobj *)obj;
|
||||
tile->ymax = hoverbike->hov.ground + var80069a70[hoverbike->hov.unk00].unk00 + modelBboxGetYMax(bbox) * obj->model->scale;
|
||||
tile->ymin = hoverbike->hov.ground + 20.0f;
|
||||
cyl->ymax = hoverbike->hov.ground + var80069a70[hoverbike->hov.unk00].unk00 + modelBboxGetYMax(bbox) * obj->model->scale;
|
||||
cyl->ymin = hoverbike->hov.ground + 20.0f;
|
||||
} else if (obj->type == OBJTYPE_HOVERPROP) {
|
||||
hoverprop = (struct hoverpropobj *)obj;
|
||||
tile->ymax = hoverprop->hov.ground + var80069a70[hoverprop->hov.unk00].unk00 + modelBboxGetYMax(bbox) * obj->model->scale;
|
||||
tile->ymin = hoverprop->hov.ground + 20.0f;
|
||||
cyl->ymax = hoverprop->hov.ground + var80069a70[hoverprop->hov.unk00].unk00 + modelBboxGetYMax(bbox) * obj->model->scale;
|
||||
cyl->ymin = hoverprop->hov.ground + 20.0f;
|
||||
} else {
|
||||
tile->ymin = mtx.m[3][1] + func0f06683c(bbox, &mtx);
|
||||
tile->ymax = mtx.m[3][1] + func0f06686c(bbox, &mtx);
|
||||
cyl->ymin = mtx.m[3][1] + func0f06683c(bbox, &mtx);
|
||||
cyl->ymax = mtx.m[3][1] + func0f06686c(bbox, &mtx);
|
||||
}
|
||||
|
||||
tile->x = pos->x;
|
||||
tile->z = pos->z;
|
||||
tile->radius = 90.0f;
|
||||
cyl->x = pos->x;
|
||||
cyl->z = pos->z;
|
||||
cyl->radius = 90.0f;
|
||||
} else {
|
||||
if (rodata19 != NULL) {
|
||||
func0f0674bc(rodata19, bbox, &mtx, (struct tiletype2 *)tile);
|
||||
func0f0674bc(rodata19, bbox, &mtx, (struct geoblock *)cyl);
|
||||
} else {
|
||||
func0f067424(bbox, &mtx, (struct tiletype2 *)tile);
|
||||
func0f067424(bbox, &mtx, (struct geoblock *)cyl);
|
||||
}
|
||||
|
||||
if (obj->type == OBJTYPE_HOVERBIKE) {
|
||||
hoverbike = (struct hoverbikeobj *)obj;
|
||||
tile->ymax = hoverbike->hov.ground + var80069a70[hoverbike->hov.unk00].unk00 + modelBboxGetYMax(bbox) * obj->model->scale;
|
||||
tile->ymin = hoverbike->hov.ground + 20.0f;
|
||||
cyl->ymax = hoverbike->hov.ground + var80069a70[hoverbike->hov.unk00].unk00 + modelBboxGetYMax(bbox) * obj->model->scale;
|
||||
cyl->ymin = hoverbike->hov.ground + 20.0f;
|
||||
} else if (obj->type == OBJTYPE_HOVERPROP) {
|
||||
hoverprop = (struct hoverpropobj *)obj;
|
||||
tile->ymax = hoverprop->hov.ground + var80069a70[hoverprop->hov.unk00].unk00 + modelBboxGetYMax(bbox) * obj->model->scale;
|
||||
tile->ymin = hoverprop->hov.ground + 20.0f;
|
||||
cyl->ymax = hoverprop->hov.ground + var80069a70[hoverprop->hov.unk00].unk00 + modelBboxGetYMax(bbox) * obj->model->scale;
|
||||
cyl->ymin = hoverprop->hov.ground + 20.0f;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -4004,23 +4004,23 @@ void func0f069b4c(struct defaultobj *obj)
|
|||
|
||||
if (ptr != NULL) {
|
||||
if ((obj->hidden2 & OBJH2FLAG_08)) {
|
||||
if (obj->flags3 & OBJFLAG3_GEOTYPE3) {
|
||||
ptr += sizeof(struct tiletype3);
|
||||
if (obj->flags3 & OBJFLAG3_GEOCYL) {
|
||||
ptr += sizeof(struct geocyl);
|
||||
} else {
|
||||
ptr += sizeof(struct tiletype2);
|
||||
ptr += sizeof(struct geoblock);
|
||||
}
|
||||
}
|
||||
|
||||
rodata = modelGetPartRodata(obj->model->filedata, MODELPART_0065);
|
||||
|
||||
if (rodata != NULL) {
|
||||
u32 flags = TILEFLAG_0001 | TILEFLAG_0002;
|
||||
u32 flags = GEOFLAG_0001 | GEOFLAG_0002;
|
||||
|
||||
if (obj->type == OBJTYPE_ESCASTEP) {
|
||||
flags |= TILEFLAG_0020;
|
||||
flags |= GEOFLAG_LIFTFLOOR;
|
||||
}
|
||||
|
||||
func0f070ca0(obj, (struct tiletype1 *)ptr, flags, NULL, &rodata->type19);
|
||||
func0f070ca0(obj, (struct geotilef *)ptr, flags, NULL, &rodata->type19);
|
||||
|
||||
ptr += 0x40;
|
||||
}
|
||||
|
|
@ -4028,16 +4028,16 @@ void func0f069b4c(struct defaultobj *obj)
|
|||
rodata = modelGetPartRodata(obj->model->filedata, MODELPART_0066);
|
||||
|
||||
if (rodata != NULL) {
|
||||
func0f070ca0(obj, (struct tiletype1 *)ptr, TILEFLAG_0004 | TILEFLAG_0008 | TILEFLAG_0010, NULL, &rodata->type19);
|
||||
func0f070ca0(obj, (struct geotilef *)ptr, GEOFLAG_COLLISIONS | GEOFLAG_0008 | GEOFLAG_OPAQUE, NULL, &rodata->type19);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void func0f069c1c(struct defaultobj *obj)
|
||||
{
|
||||
if (obj->geo3) {
|
||||
if (obj->geocyl) {
|
||||
if (obj->hidden2 & OBJH2FLAG_08) {
|
||||
func0f069850(obj, &obj->prop->pos, obj->realrot, obj->geo3);
|
||||
func0f069850(obj, &obj->prop->pos, obj->realrot, obj->geocyl);
|
||||
}
|
||||
|
||||
func0f069b4c(obj);
|
||||
|
|
@ -4222,29 +4222,29 @@ struct prop *objInit(struct defaultobj *obj, struct modelfiledata *filedata, str
|
|||
obj->model = model;
|
||||
|
||||
if (modelGetPartRodata(filedata, MODELPART_BASIC_0065)) {
|
||||
obj->numtiles++;
|
||||
obj->geocount++;
|
||||
}
|
||||
|
||||
if (modelGetPartRodata(filedata, MODELPART_BASIC_0066)) {
|
||||
obj->numtiles++;
|
||||
obj->geocount++;
|
||||
}
|
||||
|
||||
geosize = obj->numtiles * 0x40;
|
||||
geosize = obj->geocount * 0x40;
|
||||
|
||||
if (obj->flags & OBJFLAG_00000100) {
|
||||
if (obj->flags3 & OBJFLAG3_GEOTYPE3) {
|
||||
geosize += sizeof(struct tiletype3);
|
||||
if (obj->flags3 & OBJFLAG3_GEOCYL) {
|
||||
geosize += sizeof(struct geocyl);
|
||||
} else {
|
||||
geosize += sizeof(struct tiletype2);
|
||||
geosize += sizeof(struct geoblock);
|
||||
}
|
||||
|
||||
obj->numtiles++;
|
||||
obj->geocount++;
|
||||
obj->hidden2 |= OBJH2FLAG_08;
|
||||
} else {
|
||||
obj->hidden2 &= ~OBJH2FLAG_08;
|
||||
}
|
||||
|
||||
if (obj->numtiles > 0) {
|
||||
if (obj->geocount > 0) {
|
||||
obj->unkgeo = mempAlloc(ALIGN16(geosize), MEMPOOL_STAGE);
|
||||
} else {
|
||||
obj->unkgeo = NULL;
|
||||
|
|
@ -5090,10 +5090,10 @@ glabel var7f1aa200
|
|||
//
|
||||
// if (obj2) {
|
||||
// bool updated = propUpdateGeometry(obj2->prop, &sp3c, &sp38);
|
||||
// struct tiletype2 *tile2 = (struct tiletype2 *)sp3c;
|
||||
// struct geoblock *tile2 = (struct geoblock *)sp3c;
|
||||
//
|
||||
// if (updated
|
||||
// && sp3c[0] == TILETYPE_02
|
||||
// && sp3c[0] == GEOTYPE_BLOCK
|
||||
// && tile2->ymax > sp58
|
||||
// && tile2->ymin < sp58 + (max - min) * sp70.m[sp50][1] + func0f06a620(obj)) {
|
||||
// spb0.y = tile2->ymax - sp70.m[sp50][1] * min;
|
||||
|
|
@ -11567,7 +11567,7 @@ void func0f070bd0(struct modelrodata_type19 *rodata, f32 rot[3][3], struct coord
|
|||
}
|
||||
}
|
||||
|
||||
void func0f070ca0(struct defaultobj *obj, struct tiletype1 *tile, u32 flags, struct modelrodata_bbox *bbox, struct modelrodata_type19 *rodata)
|
||||
void func0f070ca0(struct defaultobj *obj, struct geotilef *tile, u32 flags, struct modelrodata_bbox *bbox, struct modelrodata_type19 *rodata)
|
||||
{
|
||||
struct coord vertices[4];
|
||||
s32 i;
|
||||
|
|
@ -11579,7 +11579,7 @@ void func0f070ca0(struct defaultobj *obj, struct tiletype1 *tile, u32 flags, str
|
|||
func0f070bd0(rodata, obj->realrot, &obj->prop->pos, vertices);
|
||||
}
|
||||
|
||||
tile->header.type = TILETYPE_01;
|
||||
tile->header.type = GEOTYPE_TILE_F;
|
||||
tile->header.flags = flags;
|
||||
tile->header.numvertices = 4;
|
||||
|
||||
|
|
@ -11634,11 +11634,11 @@ f32 liftGetY(struct liftobj *lift)
|
|||
{
|
||||
f32 y = lift->base.prop->pos.y;
|
||||
|
||||
if (lift->base.numtiles > 0) {
|
||||
struct tiletype1 *tile = lift->base.geo1;
|
||||
if (lift->base.geocount > 0) {
|
||||
struct geotilef *tile = lift->base.geotilef;
|
||||
|
||||
if (tile && tile->header.type == TILETYPE_01) {
|
||||
if (tile->header.flags & TILEFLAG_0001) {
|
||||
if (tile && tile->header.type == GEOTYPE_TILE_F) {
|
||||
if (tile->header.flags & GEOFLAG_0001) {
|
||||
y = tile->vertices[tile->max[1]].y;
|
||||
}
|
||||
}
|
||||
|
|
@ -11681,24 +11681,24 @@ void liftUpdateTiles(struct liftobj *lift, bool stationary)
|
|||
u8 *geo;
|
||||
union modelrodata *rodata;
|
||||
struct modelrodata_bbox *bbox;
|
||||
s32 numtiles;
|
||||
s32 geocount;
|
||||
u32 flags;
|
||||
s32 i;
|
||||
|
||||
lift->base.numtiles = 0;
|
||||
lift->base.geocount = 0;
|
||||
i = 0;
|
||||
|
||||
do {
|
||||
geo = (u8 *)lift->base.unkgeo + lift->base.numtiles * 0x40;
|
||||
geo = (u8 *)lift->base.unkgeo + lift->base.geocount * 0x40;
|
||||
bbox = NULL;
|
||||
rodata = NULL;
|
||||
|
||||
do {
|
||||
if (i == 0) {
|
||||
#if VERSION >= VERSION_NTSC_1_0
|
||||
flags = TILEFLAG_0001 | TILEFLAG_0002 | TILEFLAG_0008 | TILEFLAG_0010 | TILEFLAG_0020;
|
||||
flags = GEOFLAG_0001 | GEOFLAG_0002 | GEOFLAG_0008 | GEOFLAG_OPAQUE | GEOFLAG_LIFTFLOOR;
|
||||
#else
|
||||
flags = TILEFLAG_0001 | TILEFLAG_0002 | TILEFLAG_0020;
|
||||
flags = GEOFLAG_0001 | GEOFLAG_0002 | GEOFLAG_LIFTFLOOR;
|
||||
#endif
|
||||
|
||||
// Look for a non-rectangular floor with fallback to rectangular
|
||||
|
|
@ -11714,13 +11714,13 @@ void liftUpdateTiles(struct liftobj *lift, bool stationary)
|
|||
}
|
||||
}
|
||||
} else if (i == 1) {
|
||||
flags = TILEFLAG_0004;
|
||||
flags = GEOFLAG_COLLISIONS;
|
||||
rodata = modelGetPartRodata(lift->base.model->filedata, MODELPART_LIFT_WALL1);
|
||||
} else if (i == 2) {
|
||||
flags = TILEFLAG_0004;
|
||||
flags = GEOFLAG_COLLISIONS;
|
||||
rodata = modelGetPartRodata(lift->base.model->filedata, MODELPART_LIFT_WALL2);
|
||||
} else if (i == 3) {
|
||||
flags = TILEFLAG_0004;
|
||||
flags = GEOFLAG_COLLISIONS;
|
||||
rodata = modelGetPartRodata(lift->base.model->filedata, MODELPART_LIFT_WALL3);
|
||||
} else if (i == 4) {
|
||||
// The doorblock model part exists in the dataDyne tower lifts.
|
||||
|
|
@ -11728,14 +11728,14 @@ void liftUpdateTiles(struct liftobj *lift, bool stationary)
|
|||
// is moving. Without it, the player could exit the lift through
|
||||
// the doorway while it's moving.
|
||||
if (!stationary) {
|
||||
flags = TILEFLAG_0004;
|
||||
flags = GEOFLAG_COLLISIONS;
|
||||
rodata = modelGetPartRodata(lift->base.model->filedata, MODELPART_LIFT_DOORBLOCK);
|
||||
}
|
||||
} else if (i == 5) {
|
||||
#if VERSION >= VERSION_NTSC_1_0
|
||||
flags = TILEFLAG_0001 | TILEFLAG_0002 | TILEFLAG_0008 | TILEFLAG_0010 | TILEFLAG_0020;
|
||||
flags = GEOFLAG_0001 | GEOFLAG_0002 | GEOFLAG_0008 | GEOFLAG_OPAQUE | GEOFLAG_LIFTFLOOR;
|
||||
#else
|
||||
flags = TILEFLAG_0001 | TILEFLAG_0002 | TILEFLAG_0020;
|
||||
flags = GEOFLAG_0001 | GEOFLAG_0002 | GEOFLAG_LIFTFLOOR;
|
||||
#endif
|
||||
rodata = modelGetPartRodata(lift->base.model->filedata, MODELPART_LIFT_FLOORNONRECT2);
|
||||
} else {
|
||||
|
|
@ -11746,8 +11746,8 @@ void liftUpdateTiles(struct liftobj *lift, bool stationary)
|
|||
} while (!bbox && !rodata);
|
||||
|
||||
if (bbox || rodata) {
|
||||
func0f070ca0(&lift->base, (struct tiletype1 *)geo, flags, bbox, &rodata->type19);
|
||||
lift->base.numtiles++;
|
||||
func0f070ca0(&lift->base, (struct geotilef *)geo, flags, bbox, &rodata->type19);
|
||||
lift->base.geocount++;
|
||||
}
|
||||
} while (bbox || rodata);
|
||||
}
|
||||
|
|
@ -14505,7 +14505,7 @@ s32 func0f072144(struct defaultobj *obj, struct coord *arg1, f32 arg2, bool arg3
|
|||
struct hoverbikeobj *hoverbike;
|
||||
struct hoverpropobj *hoverprop;
|
||||
u8 stack[0x2f0];
|
||||
struct tiletype3 tile;
|
||||
struct geocyl cyl;
|
||||
struct prop *prop = obj->prop;
|
||||
u32 stack2;
|
||||
Mtxf spa4;
|
||||
|
|
@ -14588,12 +14588,12 @@ s32 func0f072144(struct defaultobj *obj, struct coord *arg1, f32 arg2, bool arg3
|
|||
}
|
||||
|
||||
if (cdresult == CDRESULT_NOCOLLISION) {
|
||||
func0f069850(obj, &pos, sp460, &tile);
|
||||
func0f069850(obj, &pos, sp460, &cyl);
|
||||
|
||||
if (obj->flags3 & OBJFLAG3_GEOTYPE3) {
|
||||
cdresult = cd0002a6fc(&prop->pos, &pos, tile.radius, rooms, CDTYPE_ALL, true, tile.ymax - pos.y, tile.ymin - pos.y);
|
||||
if (obj->flags3 & OBJFLAG3_GEOCYL) {
|
||||
cdresult = cd0002a6fc(&prop->pos, &pos, cyl.radius, rooms, CDTYPE_ALL, true, cyl.ymax - pos.y, cyl.ymin - pos.y);
|
||||
} else {
|
||||
cdresult = cd0002f02c((struct tiletype2 *)&tile, rooms, CDTYPE_ALL);
|
||||
cdresult = cd0002f02c((struct geoblock *)&cyl, rooms, CDTYPE_ALL);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -14609,11 +14609,11 @@ s32 func0f072144(struct defaultobj *obj, struct coord *arg1, f32 arg2, bool arg3
|
|||
propDeregisterRooms(prop);
|
||||
roomsCopy(rooms, prop->rooms);
|
||||
|
||||
if (obj->geo3 && (obj->hidden2 & OBJH2FLAG_08)) {
|
||||
if (obj->flags3 & OBJFLAG3_GEOTYPE3) {
|
||||
*obj->geo3 = tile;
|
||||
if (obj->geocyl && (obj->hidden2 & OBJH2FLAG_08)) {
|
||||
if (obj->flags3 & OBJFLAG3_GEOCYL) {
|
||||
*obj->geocyl = cyl;
|
||||
} else {
|
||||
*obj->geo2 = *(struct tiletype2 *)&tile;
|
||||
*obj->geoblock = *(struct geoblock *)&cyl;
|
||||
}
|
||||
}
|
||||
} else if (hov) {
|
||||
|
|
@ -16866,7 +16866,7 @@ void platformDisplaceProps2(struct prop *platform, Mtxf *arg1)
|
|||
|
||||
if (prop->pos.y > platform->pos.y
|
||||
&& (obj->hidden & OBJHFLAG_00008000)
|
||||
&& func000266a4(prop->pos.x, prop->pos.z, (struct tile *)sp9c)) {
|
||||
&& func000266a4(prop->pos.x, prop->pos.z, (struct geo *)sp9c)) {
|
||||
mtx3ToMtx4(obj->realrot, &sp58);
|
||||
mtx4SetTranslation(&prop->pos, &sp58);
|
||||
mtx4MultMtx4InPlace(arg1, &sp58);
|
||||
|
|
@ -50086,7 +50086,7 @@ s32 objTickPlayer(struct prop *prop)
|
|||
struct coord sp116 = {0, 0, 0};
|
||||
f32 sp112;
|
||||
s32 tagnum;
|
||||
struct tile *geos[2];
|
||||
struct geo *geos[2];
|
||||
u8 *end;
|
||||
f32 damage;
|
||||
|
||||
|
|
@ -50160,8 +50160,8 @@ s32 objTickPlayer(struct prop *prop)
|
|||
sp592 = true;
|
||||
|
||||
if (objUpdateGeometry(prop, (u8 **)geos, &end)
|
||||
&& geos[0]->type == TILETYPE_02
|
||||
&& cd0002e4c4((struct tiletype2 *) geos[0], prop->rooms, 4) == 0) {
|
||||
&& geos[0]->type == GEOTYPE_BLOCK
|
||||
&& cd0002e4c4((struct geoblock *) geos[0], prop->rooms, 4) == 0) {
|
||||
damage = ((obj->maxdamage - obj->damage) + 1) / 250.0f;
|
||||
obj->flags &= ~OBJFLAG_INVINCIBLE;
|
||||
objDamage(obj, damage, &prop->pos, WEAPON_REMOTEMINE, -1);
|
||||
|
|
@ -53641,7 +53641,7 @@ void objDestroySupportedObjects(struct prop *tableprop, s32 playernum)
|
|||
{
|
||||
if (prop->pos.y > tableprop->pos.y
|
||||
&& (obj->hidden & OBJHFLAG_00008000)
|
||||
&& func000266a4(prop->pos.x, prop->pos.z, (struct tile *)start)) {
|
||||
&& func000266a4(prop->pos.x, prop->pos.z, (struct geo *)start)) {
|
||||
objFall(obj, playernum);
|
||||
}
|
||||
}
|
||||
|
|
@ -55147,24 +55147,24 @@ bool objUpdateGeometry(struct prop *prop, u8 **start, u8 **end)
|
|||
|
||||
if (obj->unkgeo && (obj->flags3 & OBJFLAG3_WALKTHROUGH) == 0) {
|
||||
if ((obj->hidden2 & OBJH2FLAG_08)) {
|
||||
s32 len = (obj->flags3 & OBJFLAG3_GEOTYPE3) ? sizeof(struct tiletype3) : sizeof(struct tiletype2);
|
||||
s32 len = (obj->flags3 & OBJFLAG3_GEOCYL) ? sizeof(struct geocyl) : sizeof(struct geoblock);
|
||||
|
||||
if (obj->flags & OBJFLAG_00000100) {
|
||||
if ((obj->hidden & (OBJHFLAG_PERIMDISABLED | OBJHFLAG_DOORPERIMDISABLED)) == 0) {
|
||||
*start = (void *) obj->unkgeo;
|
||||
*end = (void *)((u32)obj->unkgeo + len);
|
||||
|
||||
if (obj->numtiles >= 2) {
|
||||
*end += obj->numtiles * 0x40 - 0x40;
|
||||
if (obj->geocount >= 2) {
|
||||
*end += obj->geocount * 0x40 - 0x40;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
if (obj->numtiles >= 2) {
|
||||
if (obj->geocount >= 2) {
|
||||
*start = (void *)((u32)obj->unkgeo + len);
|
||||
*end = (void *)(*start + obj->numtiles * 0x40 - 0x40);
|
||||
*end = (void *)(*start + obj->geocount * 0x40 - 0x40);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -55174,7 +55174,7 @@ bool objUpdateGeometry(struct prop *prop, u8 **start, u8 **end)
|
|||
}
|
||||
|
||||
*start = (void *) obj->unkgeo;
|
||||
*end = (void *) ((u32)obj->unkgeo + obj->numtiles * 0x40);
|
||||
*end = (void *) ((u32)obj->unkgeo + obj->geocount * 0x40);
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -55189,14 +55189,14 @@ void propObjGetBbox(struct prop *prop, f32 *radius, f32 *ymax, f32 *ymin)
|
|||
struct defaultobj *obj = prop->obj;
|
||||
|
||||
if (obj->unkgeo && obj->hidden2 & OBJH2FLAG_08) {
|
||||
if (obj->flags3 & OBJFLAG3_GEOTYPE3) {
|
||||
*radius = obj->geo3->radius;
|
||||
*ymin = obj->geo3->ymin;
|
||||
*ymax = obj->geo3->ymax;
|
||||
if (obj->flags3 & OBJFLAG3_GEOCYL) {
|
||||
*radius = obj->geocyl->radius;
|
||||
*ymin = obj->geocyl->ymin;
|
||||
*ymax = obj->geocyl->ymax;
|
||||
} else {
|
||||
*radius = model0001af80(obj->model);
|
||||
*ymin = obj->geo2->ymin;
|
||||
*ymax = obj->geo2->ymax;
|
||||
*ymin = obj->geoblock->ymin;
|
||||
*ymax = obj->geoblock->ymax;
|
||||
}
|
||||
} else {
|
||||
*radius = 1;
|
||||
|
|
@ -61087,7 +61087,7 @@ void doorUpdateTiles(struct doorobj *door)
|
|||
{
|
||||
struct modelrodata_bbox bbox;
|
||||
Mtxf spdc;
|
||||
struct tiletype2 *geo;
|
||||
struct geoblock *geo;
|
||||
Mtxf sp98;
|
||||
struct coord sp8c;
|
||||
struct coord sp80;
|
||||
|
|
@ -61173,7 +61173,7 @@ void doorUpdateTiles(struct doorobj *door)
|
|||
return;
|
||||
}
|
||||
|
||||
geo = door->base.geo2;
|
||||
geo = door->base.geoblock;
|
||||
door->base.hidden &= ~OBJHFLAG_DOORPERIMDISABLED;
|
||||
|
||||
if ((door->doorflags & DOORFLAG_0020) == 0) {
|
||||
|
|
@ -62188,12 +62188,12 @@ void doorStartOpen(struct doorobj *door)
|
|||
doorActivatePortal(door);
|
||||
|
||||
if (door->doortype == DOORTYPE_FALLAWAY) {
|
||||
struct tiletype3 *geo = door->base.geo3;
|
||||
struct geocyl *cyl = door->base.geocyl;
|
||||
door->base.flags |= OBJFLAG_CANNOT_ACTIVATE;
|
||||
door->perimfrac = 0;
|
||||
|
||||
if (geo && (door->base.flags & OBJFLAG_00000100)) {
|
||||
geo->header.numvertices = 0;
|
||||
if (cyl && (door->base.flags & OBJFLAG_00000100)) {
|
||||
cyl->header.numvertices = 0;
|
||||
door->base.flags &= ~OBJFLAG_00000100;
|
||||
}
|
||||
}
|
||||
|
|
@ -62703,7 +62703,7 @@ void doorsCalcFrac(struct doorobj *door)
|
|||
{
|
||||
propSetPerimEnabled(loopprop, false);
|
||||
|
||||
cdresult = cd0002e4c4(loopdoor->base.geo2, loopprop->rooms,
|
||||
cdresult = cd0002e4c4(loopdoor->base.geoblock, loopprop->rooms,
|
||||
CDTYPE_OBJS | CDTYPE_PLAYERS | CDTYPE_CHRS | CDTYPE_PATHBLOCKER | CDTYPE_OBJSNOTSAFEORHELI);
|
||||
|
||||
propSetPerimEnabled(loopprop, true);
|
||||
|
|
|
|||
|
|
@ -3650,25 +3650,25 @@ void setupCreateProps(s32 stagenum)
|
|||
}
|
||||
}
|
||||
|
||||
obj->numtiles = 1;
|
||||
obj->geocount = 1;
|
||||
setupLoadModeldef(modelnum);
|
||||
modelstate = &g_ModelStates[modelnum];
|
||||
|
||||
if (modelstate->filedata) {
|
||||
if (modelGetPartRodata(modelstate->filedata, 1)) {
|
||||
obj->numtiles++;
|
||||
obj->geocount++;
|
||||
}
|
||||
if (modelGetPartRodata(modelstate->filedata, 2)) {
|
||||
obj->numtiles++;
|
||||
obj->geocount++;
|
||||
}
|
||||
if (modelGetPartRodata(modelstate->filedata, 3)) {
|
||||
obj->numtiles++;
|
||||
obj->geocount++;
|
||||
}
|
||||
if (modelGetPartRodata(modelstate->filedata, 4)) {
|
||||
obj->numtiles++;
|
||||
obj->geocount++;
|
||||
}
|
||||
if (modelGetPartRodata(modelstate->filedata, 6)) {
|
||||
obj->numtiles++;
|
||||
obj->geocount++;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -29,25 +29,25 @@ void tilesReset(void)
|
|||
|
||||
void stageParseTiles(void)
|
||||
{
|
||||
struct tile *tile = (struct tile *)(g_TileFileData.u8 + g_TileRooms[0]);
|
||||
struct tile *end = (struct tile *)(g_TileFileData.u8 + g_TileRooms[g_TileNumRooms]);
|
||||
struct geo *geo = (struct geo *)(g_TileFileData.u8 + g_TileRooms[0]);
|
||||
struct geo *end = (struct geo *)(g_TileFileData.u8 + g_TileRooms[g_TileNumRooms]);
|
||||
|
||||
while (tile < end) {
|
||||
if (tile->type == TILETYPE_00) {
|
||||
struct tiletype0 *tile0 = (struct tiletype0 *) tile;
|
||||
tile0->xmin = mult6(tile0->xmin) + 14;
|
||||
tile0->xmax = mult6(tile0->xmax) + 14;
|
||||
tile0->ymin = mult6(tile0->ymin) + 16;
|
||||
tile0->ymax = mult6(tile0->ymax) + 16;
|
||||
tile0->zmin = mult6(tile0->zmin) + 18;
|
||||
tile0->zmax = mult6(tile0->zmax) + 18;
|
||||
tile = (struct tile *)((u8 *)tile + (u32)(tile->numvertices - 0x40) * 6 + 0x18e);
|
||||
} else if (tile->type == TILETYPE_01) {
|
||||
tile = (struct tile *)((u8 *)tile + (u32)(tile->numvertices - 0x40) * 12 + 0x310);
|
||||
} else if (tile->type == TILETYPE_02) {
|
||||
tile = (struct tile *)((u8 *)tile + 0x4c);
|
||||
} else if (tile->type == TILETYPE_03) {
|
||||
tile = (struct tile *)((u8 *)tile + 0x18);
|
||||
while (geo < end) {
|
||||
if (geo->type == GEOTYPE_TILE_I) {
|
||||
struct geotilei *tile = (struct geotilei *) geo;
|
||||
tile->xmin = mult6(tile->xmin) + 14;
|
||||
tile->xmax = mult6(tile->xmax) + 14;
|
||||
tile->ymin = mult6(tile->ymin) + 16;
|
||||
tile->ymax = mult6(tile->ymax) + 16;
|
||||
tile->zmin = mult6(tile->zmin) + 18;
|
||||
tile->zmax = mult6(tile->zmax) + 18;
|
||||
geo = (struct geo *)((u8 *)geo + (u32)(geo->numvertices - 0x40) * 6 + 0x18e);
|
||||
} else if (geo->type == GEOTYPE_TILE_F) {
|
||||
geo = (struct geo *)((u8 *)geo + (u32)(geo->numvertices - 0x40) * 12 + 0x310);
|
||||
} else if (geo->type == GEOTYPE_BLOCK) {
|
||||
geo = (struct geo *)((u8 *)geo + sizeof(struct geoblock));
|
||||
} else if (geo->type == GEOTYPE_CYL) {
|
||||
geo = (struct geo *)((u8 *)geo + sizeof(struct geocyl));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ extern s32 *var8009a888;
|
|||
extern union filedataptr g_TileFileData;
|
||||
extern s32 g_TileNumRooms;
|
||||
extern u32 *g_TileRooms;
|
||||
extern struct tiletype2 var8009a918;
|
||||
extern struct geoblock var8009a918;
|
||||
extern u8 g_RdpDramStack[SP_DRAM_STACK_SIZE8];
|
||||
extern N_ALSndPlayer var8009c2d0;
|
||||
extern struct var8009c340 var8009c340;
|
||||
|
|
|
|||
|
|
@ -1125,6 +1125,28 @@
|
|||
#define GBGAME_OTHER 0
|
||||
#define GBGAME_PD 2
|
||||
|
||||
#define GEOFLAG_0001 0x0001
|
||||
#define GEOFLAG_0002 0x0002
|
||||
#define GEOFLAG_COLLISIONS 0x0004
|
||||
#define GEOFLAG_0008 0x0008
|
||||
#define GEOFLAG_OPAQUE 0x0010 // Block AI fire/sight
|
||||
#define GEOFLAG_LIFTFLOOR 0x0020
|
||||
#define GEOFLAG_LADDER 0x0040
|
||||
#define GEOFLAG_0080 0x0080
|
||||
#define GEOFLAG_0100 0x0100 // Editor: Low wall/edge
|
||||
#define GEOFLAG_UNDERWATER 0x0200
|
||||
#define GEOFLAG_0400 0x0400 // Unused
|
||||
#define GEOFLAG_AIBOTCROUCH 0x0800
|
||||
#define GEOFLAG_AIBOTDUCK 0x1000
|
||||
#define GEOFLAG_STEP 0x2000 // Ascend regardless of steepness
|
||||
#define GEOFLAG_DIE 0x4000
|
||||
#define GEOFLAG_CLIMBABLELEDGE 0x8000 // Used for most ledges in Chicago, but not near drain pickup
|
||||
|
||||
#define GEOTYPE_TILE_I 0 // Tiles with integer vertices - used for BG
|
||||
#define GEOTYPE_TILE_F 1 // Tiles with float vertices - used for lifts
|
||||
#define GEOTYPE_BLOCK 2 // Most objects - multiple x/z vertices, and a single ymin and ymax
|
||||
#define GEOTYPE_CYL 3 // Cylinder - used by chrs and the hoverbike
|
||||
|
||||
#define GOPOSFLAG_SPEED 0x03 // bits 0x01 and 0x02 combined
|
||||
#define GOPOSFLAG_INIT 0x04
|
||||
#define GOPOSFLAG_FORPATHSTART 0x08
|
||||
|
|
@ -3059,7 +3081,7 @@
|
|||
#define OBJFLAG3_PLAYERUNDROPPABLE 0x00400000 // Player does not drop item when dead
|
||||
#define OBJFLAG3_00800000 0x00800000 // Not used in scripts
|
||||
#define OBJFLAG3_01000000 0x01000000 // Not used in scripts
|
||||
#define OBJFLAG3_GEOTYPE3 0x02000000 // If set then obj uses tiletype3 else tiletype2
|
||||
#define OBJFLAG3_GEOCYL 0x02000000 // Use cylinder geometry rather than block
|
||||
#define OBJFLAG3_04000000 0x04000000 // Not used in scripts
|
||||
#define OBJFLAG3_08000000 0x08000000 // Not used in scripts
|
||||
#define OBJFLAG3_10000000 0x10000000 // Editor: "Keep Collisions After Fully Destroyed"
|
||||
|
|
@ -3975,28 +3997,6 @@
|
|||
#define TICKOP_GIVETOPLAYER 4
|
||||
#define TICKOP_5 5
|
||||
|
||||
#define TILEFLAG_0001 0x0001 // Editor: Traversable
|
||||
#define TILEFLAG_0002 0x0002
|
||||
#define TILEFLAG_0004 0x0004 // Editor: Collisions
|
||||
#define TILEFLAG_0008 0x0008
|
||||
#define TILEFLAG_0010 0x0010 // Editor: Block AI fire/sight
|
||||
#define TILEFLAG_0020 0x0020
|
||||
#define TILEFLAG_LADDER 0x0040
|
||||
#define TILEFLAG_0080 0x0080
|
||||
#define TILEFLAG_0100 0x0100 // Editor: Low wall/edge
|
||||
#define TILEFLAG_UNDERWATER 0x0200
|
||||
#define TILEFLAG_0400 0x0400
|
||||
#define TILEFLAG_AIBOTCROUCH 0x0800
|
||||
#define TILEFLAG_AIBOTDUCK 0x1000
|
||||
#define TILEFLAG_2000 0x2000 // Editor: Incline
|
||||
#define TILEFLAG_DIE 0x4000
|
||||
#define TILEFLAG_CLIMBABLELEDGE 0x8000 // used for most ledges in Chicago, but not near drain pickup
|
||||
|
||||
#define TILETYPE_00 0 // Standard BG tiles
|
||||
#define TILETYPE_01 1
|
||||
#define TILETYPE_02 2
|
||||
#define TILETYPE_03 3 // Chr/obj geometry
|
||||
|
||||
#define TIMEPRECISION_DAYS 0
|
||||
#define TIMEPRECISION_HOURS 1
|
||||
#define TIMEPRECISION_MINUTES 2
|
||||
|
|
|
|||
|
|
@ -14,22 +14,22 @@
|
|||
.set FLOORTYPE_DIRT, 7
|
||||
.set FLOORTYPE_SNOW, 8
|
||||
|
||||
.set TILEFLAG_0001, 0x0001
|
||||
.set TILEFLAG_0002, 0x0002
|
||||
.set TILEFLAG_0004, 0x0004
|
||||
.set TILEFLAG_0008, 0x0008
|
||||
.set TILEFLAG_0010, 0x0010
|
||||
.set TILEFLAG_0020, 0x0020
|
||||
.set TILEFLAG_LADDER, 0x0040
|
||||
.set TILEFLAG_0080, 0x0080
|
||||
.set TILEFLAG_0100, 0x0100
|
||||
.set TILEFLAG_UNDERWATER, 0x0200
|
||||
.set TILEFLAG_0400, 0x0400
|
||||
.set TILEFLAG_AIBOTCROUCH, 0x0800
|
||||
.set TILEFLAG_AIBOTDUCK, 0x1000
|
||||
.set TILEFLAG_2000, 0x2000
|
||||
.set TILEFLAG_DIE, 0x4000
|
||||
.set TILEFLAG_CLIMBABLELEDGE, 0x8000
|
||||
.set GEOFLAG_0001, 0x0001
|
||||
.set GEOFLAG_0002, 0x0002
|
||||
.set GEOFLAG_COLLISIONS, 0x0004
|
||||
.set GEOFLAG_0008, 0x0008
|
||||
.set GEOFLAG_OPAQUE, 0x0010
|
||||
.set GEOFLAG_LIFTFLOOR, 0x0020
|
||||
.set GEOFLAG_LADDER, 0x0040
|
||||
.set GEOFLAG_0080, 0x0080
|
||||
.set GEOFLAG_0100, 0x0100
|
||||
.set GEOFLAG_UNDERWATER, 0x0200
|
||||
.set GEOFLAG_0400, 0x0400
|
||||
.set GEOFLAG_AIBOTCROUCH, 0x0800
|
||||
.set GEOFLAG_AIBOTDUCK, 0x1000
|
||||
.set GEOFLAG_STEP, 0x2000
|
||||
.set GEOFLAG_DIE, 0x4000
|
||||
.set GEOFLAG_CLIMBABLELEDGE, 0x8000
|
||||
|
||||
.set VERSION_NTSC_BETA, 0
|
||||
.set VERSION_NTSC_1_0, 1
|
||||
|
|
|
|||
|
|
@ -50,9 +50,9 @@ f32 func0f0669bc(struct modelrodata_bbox *bbox, f32 realrot[3][3]);
|
|||
f32 func0f0669ec(struct modelrodata_bbox *bbox, f32 realrot[3][3]);
|
||||
f32 func0f066a1c(struct modelrodata_bbox *bbox, f32 arg1, f32 arg2, f32 arg3);
|
||||
f32 func0f066abc(struct modelrodata_bbox *bbox, f32 arg1, f32 arg2, f32 arg3);
|
||||
s32 func0f066b5c(f32 xmin, f32 xmax, f32 ymin, f32 ymax, f32 zmin, f32 zmax, Mtxf *mtx, struct tiletype2 *tile);
|
||||
void func0f067424(struct modelrodata_bbox *bbox, Mtxf *mtx, struct tiletype2 *tile);
|
||||
void func0f0674bc(struct modelrodata_type19 *rodata19, struct modelrodata_bbox *bbox, Mtxf *mtx, struct tiletype2 *tile);
|
||||
s32 func0f066b5c(f32 xmin, f32 xmax, f32 ymin, f32 ymax, f32 zmin, f32 zmax, Mtxf *mtx, struct geoblock *tile);
|
||||
void func0f067424(struct modelrodata_bbox *bbox, Mtxf *mtx, struct geoblock *block);
|
||||
void func0f0674bc(struct modelrodata_type19 *rodata19, struct modelrodata_bbox *bbox, Mtxf *mtx, struct geoblock *block);
|
||||
bool func0f0675c8(struct coord *pos, f32 arg1, struct modelrodata_bbox *bbox, Mtxf *mtx);
|
||||
bool func0f0677ac(struct coord *coord, struct coord *arg1, struct coord *pos, struct coord *normal, struct coord *up, struct coord *look, f32 xmin, f32 xmax, f32 ymin, f32 ymax, f32 zmin, f32 zmax);
|
||||
bool func0f0678f8(struct coord *coord, struct coord *arg1, s32 padnum);
|
||||
|
|
@ -89,7 +89,7 @@ void func0f069144(struct prop *prop, u8 *nextcol, u16 floorcol);
|
|||
void func0f069630(struct prop *prop, u8 *nextcol, u16 floorcol);
|
||||
void colourTween(u8 *col, u8 *nextcol);
|
||||
void func0f069750(s32 *arg0, s32 arg1, f32 *arg2);
|
||||
void func0f069850(struct defaultobj *obj, struct coord *pos, f32 rot[3][3], struct tiletype3 *tile);
|
||||
void func0f069850(struct defaultobj *obj, struct coord *pos, f32 rot[3][3], struct geocyl *cyl);
|
||||
void func0f069b4c(struct defaultobj *obj);
|
||||
void func0f069c1c(struct defaultobj *obj);
|
||||
void func0f069c70(struct defaultobj *obj, bool arg1, bool arg2);
|
||||
|
|
@ -136,7 +136,7 @@ void func0f07079c(struct prop *prop, bool fulltick);
|
|||
s32 glassCalculateOpacity(struct coord *pos, f32 xludist, f32 opadist, f32 arg3);
|
||||
void func0f070a1c(struct modelrodata_bbox *bbox, f32 realrot[3][3], struct coord *pos, struct coord *vertices);
|
||||
void func0f070bd0(struct modelrodata_type19 *rodata, f32 realrot[3][3], struct coord *pos, struct coord *vertices);
|
||||
void func0f070ca0(struct defaultobj *obj, struct tiletype1 *tile, u32 flags, struct modelrodata_bbox *bbox, struct modelrodata_type19 *rodata);
|
||||
void func0f070ca0(struct defaultobj *obj, struct geotilef *tile, u32 flags, struct modelrodata_bbox *bbox, struct modelrodata_type19 *rodata);
|
||||
void liftActivate(struct prop *prop, u8 liftnum);
|
||||
struct prop *liftFindByPad(s16 padnum);
|
||||
f32 liftGetY(struct liftobj *lift);
|
||||
|
|
|
|||
|
|
@ -22,45 +22,45 @@ void cd00025038(struct coord *arg0, struct coord *arg1, struct prop *prop, f32 a
|
|||
void cd000250cc(struct coord *arg0, struct coord *arg1, f32 width);
|
||||
void cd00025168(struct prop *prop);
|
||||
void cd000251ac(struct coord *arg0, struct coord *arg1, struct coord *arg2, struct prop *prop);
|
||||
void cd00025254(struct coord *arg0, struct coord *arg1, struct coord *pos, struct prop *prop, f32 arg4, struct tile *tile);
|
||||
void cd00025254(struct coord *arg0, struct coord *arg1, struct coord *pos, struct prop *prop, f32 arg4, struct geo *tile);
|
||||
void cd00025314(struct coord *pos, struct coord *arg1);
|
||||
bool cd00025364(struct coord *arg0, struct coord *arg1);
|
||||
void cd000253c4(struct tiletype2 *tile);
|
||||
void cd000253c4(struct geoblock *tile);
|
||||
s32 cd00025410(f32 arg0, f32 arg1, f32 arg2, f32 arg3);
|
||||
s32 cd000254d8(struct coord *arg0, struct coord *arg1, f32 arg2, f32 arg3, f32 arg4, f32 arg5, s32 *arg6);
|
||||
f32 cd00025654(f32 x1, f32 z1, f32 x2, f32 z2, f32 x3, f32 z3);
|
||||
f32 cd00025724(f32 x1, f32 z1, f32 x2, f32 z2);
|
||||
bool cd00025774(f32 x1, f32 z1, f32 x2, f32 z2, f32 x3, f32 z3);
|
||||
void cd00025848(f32 tilex, f32 tilez, f32 tilewidth, f32 posx, f32 posz, f32 *x1, f32 *z1, f32 *x2, f32 *z2);
|
||||
void cd00025928(struct tile *tile, struct coord *arg1);
|
||||
void cdGetFloorCol(struct tile *tile, u16 *floorcol);
|
||||
void cdGetFloorType(struct tile *tile, u8 *floortype);
|
||||
f32 cdFindGroundInTileType0AtVertex(struct tiletype0 *tile, f32 x, f32 z, s32 vertexindex);
|
||||
f32 cdFindGroundInTileType0(struct tiletype0 *tile, f32 x, f32 z);
|
||||
f32 cdFindGroundInTileType1(struct tiletype1 *tile, f32 x, f32 z);
|
||||
bool cdIs2dPointInTileType0(struct tiletype0 *tile, f32 x, f32 z);
|
||||
bool cdIs2dPointInTileType1(struct tiletype1 *tile, f32 x, f32 z);
|
||||
bool cdIs2dPointInTileType2(struct tiletype2 *tile, f32 x, f32 z);
|
||||
bool cdIs2dPointInTileType3(struct tiletype3 *tile, f32 x, f32 z);
|
||||
bool func000266a4(f32 x, f32 z, struct tile *tile);
|
||||
void cd00025928(struct geo *tile, struct coord *arg1);
|
||||
void cdGetFloorCol(struct geo *tile, u16 *floorcol);
|
||||
void cdGetFloorType(struct geo *tile, u8 *floortype);
|
||||
f32 cdFindGroundInIntTileAtVertex(struct geotilei *tile, f32 x, f32 z, s32 vertexindex);
|
||||
f32 cdFindGroundInIntTile(struct geotilei *tile, f32 x, f32 z);
|
||||
f32 cdFindGroundInFltTile(struct geotilef *tile, f32 x, f32 z);
|
||||
bool cdIs2dPointInIntTile(struct geotilei *tile, f32 x, f32 z);
|
||||
bool cdIs2dPointInFltTile(struct geotilef *tile, f32 x, f32 z);
|
||||
bool cdIs2dPointInBlock(struct geoblock *tile, f32 x, f32 z);
|
||||
bool cdIs2dPointInCyl(struct geocyl *cyl, f32 x, f32 z);
|
||||
bool func000266a4(f32 x, f32 z, struct geo *tile);
|
||||
void cdGetPropsOnPlatform(struct prop *platform, s16 *propnums, s32 len);
|
||||
bool cd00026a04(struct coord *pos, u8 *start, u8 *end, u16 flags, s32 room, struct tile **tileptr, s32 *roomptr, f32 *groundptr, bool arg8);
|
||||
void cd00026e7c(struct coord *pos, s16 *rooms, u16 arg2, struct tile **tileptr, s16 *room, f32 *arg5, struct prop **arg6, s32 arg7);
|
||||
bool cd0002709c(struct tiletype0 *tile, f32 x, f32 z, f32 width, struct prop *prop, struct collisionthing *thing);
|
||||
bool cd000272f8(struct tiletype1 *tile, f32 x, f32 z, f32 radius, struct prop *prop, struct collisionthing *thing);
|
||||
s32 cd000274e0(struct tiletype2 *tile, f32 x, f32 z, f32 width, struct prop *prop, struct collisionthing *thing);
|
||||
bool cd000276c8(struct tiletype3 *tile, f32 x, f32 z, f32 width, struct prop *prop, struct collisionthing *thing);
|
||||
bool cd00026a04(struct coord *pos, u8 *start, u8 *end, u16 flags, s32 room, struct geo **tileptr, s32 *roomptr, f32 *groundptr, bool arg8);
|
||||
void cd00026e7c(struct coord *pos, s16 *rooms, u16 arg2, struct geo **tileptr, s16 *room, f32 *arg5, struct prop **arg6, s32 arg7);
|
||||
bool cd0002709c(struct geotilei *tile, f32 x, f32 z, f32 width, struct prop *prop, struct collisionthing *thing);
|
||||
bool cd000272f8(struct geotilef *tile, f32 x, f32 z, f32 radius, struct prop *prop, struct collisionthing *thing);
|
||||
s32 cd000274e0(struct geoblock *tile, f32 x, f32 z, f32 width, struct prop *prop, struct collisionthing *thing);
|
||||
bool cd000276c8(struct geocyl *tile, f32 x, f32 z, f32 width, struct prop *prop, struct collisionthing *thing);
|
||||
void cd00027738(struct coord *pos, f32 width, u8 *start, u8 *end, u16 flags, bool checkvertical, f32 arg6, f32 arg7, struct prop *prop, struct collisionthing *things, s32 maxthings, s32 *thingnum, s32 roomnum);
|
||||
void cd00027d1c(struct coord *pos, f32 radius, s16 *rooms, u32 types, u16 arg4, u32 arg5, f32 arg6, f32 arg7, struct collisionthing *arg8, s32 arg9);
|
||||
u32 cd00027f78(void);
|
||||
s32 cd00028200(struct tiletype0 *tile, struct coord *pos, f32 width, f32 y1, f32 y2);
|
||||
s32 cd00028200(struct geotilei *tile, struct coord *pos, f32 width, f32 y1, f32 y2);
|
||||
u32 cd0002840c(void);
|
||||
u32 cd00028638(void);
|
||||
u32 cd0002885c(void);
|
||||
s32 cd00028914(u8 *start, u8 *end, struct coord *pos, f32 width, u16 flags, bool checkvertical, f32 arg6, f32 arg7, struct prop *prop, struct collisionthing *things, s32 maxthings, s32 *thingnum);
|
||||
void cd00028df0(struct coord *pos, f32 width, s16 *rooms, u32 types, u16 arg4, u32 arg5, f32 ymax, f32 ymin, struct collisionthing *arg8, s32 arg9);
|
||||
void cd0002901c(struct coord *pos, struct coord *dist, f32 width, struct collisionthing *arg3);
|
||||
f32 cd000296a0(struct collisionthing *arg0, struct coord *pos, struct tilething **arg2, f32 width);
|
||||
f32 cd000296a0(struct collisionthing *arg0, struct coord *pos, struct collisionthing **arg2, f32 width);
|
||||
bool cd00029ffc(struct coord *pos, f32 width, f32 foreheadheight, f32 inversefeettoeyesheight, s16 *rooms, u16 arg5, struct coord *laddernormal);
|
||||
bool cd0002a13c(struct coord *pos, f32 radius, f32 arg2, f32 arg3, s16 *rooms, u16 arg5);
|
||||
f32 cdFindGroundY(struct coord *pos, f32 radius, s16 *rooms, u16 *floorcol, u8 *floortype, u16 *floorflags, s16 *floorroom, s32 *inlift, struct prop **lift);
|
||||
|
|
@ -90,7 +90,7 @@ u32 cd0002b954(void);
|
|||
bool cd0002bd04(u8 *start, u8 *end, struct coord *arg2, struct coord *arg3, struct coord *arg4, s32 arg5, s32 arg6, s32 arg7, f32 arg8, f32 arg9);
|
||||
u32 cd0002c328(void);
|
||||
u32 cd0002c528(void);
|
||||
bool cd0002c714(u8 *start, u8 *end, struct coord *arg2, struct coord *arg3, struct coord *arg4, u16 arg5, s32 arg6, s32 arg7, f32 ymax, f32 ymin, f32 *arg10, struct coord *arg11, struct coord *arg12, struct coord *arg13, struct tile **tile, s32 roomnum);
|
||||
bool cd0002c714(u8 *start, u8 *end, struct coord *arg2, struct coord *arg3, struct coord *arg4, u16 arg5, s32 arg6, s32 arg7, f32 ymax, f32 ymin, f32 *arg10, struct coord *arg11, struct coord *arg12, struct coord *arg13, struct geo **tile, s32 roomnum);
|
||||
bool cd0002d15c(struct coord *pos, struct coord *coord2, s16 *rooms, u32 types, u16 arg4, s32 arg5, s32 arg6, f32 arg7, f32 arg8);
|
||||
s32 cd0002d3b0(struct coord *arg0, struct coord *arg1, s16 *arg2, s32 types, u16 arg4, s32 arg5, s32 arg6, f32 ymax, f32 ymin);
|
||||
bool cd0002d6ac(struct coord *pos, s16 *rooms, struct coord *targetpos, u32 types, u32 arg4, f32 arg5, f32 arg6);
|
||||
|
|
@ -111,15 +111,15 @@ s32 cd0002de10(struct coord *pos, s16 *rooms, struct coord *pos2, u32 types);
|
|||
s32 cd0002de34(struct coord *arg0, s16 *arg1, struct coord *arg2, s16 *arg3, u32 types, u16 arg5);
|
||||
s32 cd0002deac(struct coord *arg0, s16 *arg1, struct coord *arg2, s16 *arg3, u32 types);
|
||||
bool cd0002ded8(struct coord *arg0, struct coord *arg1, struct prop *prop);
|
||||
bool cd0002dffc(struct tiletype2 *arg0, struct tiletype2 *arg1);
|
||||
s32 cd0002e278(u8 *start, u8 *end, struct tiletype2 *ref, u16 flags);
|
||||
s32 cd0002e4c4(struct tiletype2 *geo, s16 *rooms, u32 types);
|
||||
bool cd0002dffc(struct geoblock *arg0, struct geoblock *arg1);
|
||||
s32 cd0002e278(u8 *start, u8 *end, struct geoblock *ref, u16 flags);
|
||||
s32 cd0002e4c4(struct geoblock *geo, s16 *rooms, u32 types);
|
||||
u32 cd0002e680(void);
|
||||
u32 cd0002e82c(void);
|
||||
u32 cd0002e9d8(void);
|
||||
u32 cd0002eb84(void);
|
||||
bool cd0002ed30(u8 *start, u8 *end, struct tiletype2 *tile, s32 numvertices, struct coord *arg4, struct coord *arg5, s32 arg6, struct prop *prop);
|
||||
s32 cd0002f02c(struct tiletype2 *tile, s16 *rooms, s32 types);
|
||||
bool cd0002ed30(u8 *start, u8 *end, struct geoblock *tile, s32 numvertices, struct coord *arg4, struct coord *arg5, s32 arg6, struct prop *prop);
|
||||
s32 cd0002f02c(struct geoblock *block, s16 *rooms, s32 types);
|
||||
bool cd0002f308(struct coord *viewpos, s16 *rooms, struct coord *targetpos, f32 distance, s32 arg4, u16 arg5);
|
||||
bool cd0002f450(struct coord *viewpos, s16 *rooms, struct coord *targetpos, f32 distance, s32 arg4);
|
||||
|
||||
|
|
|
|||
|
|
@ -829,14 +829,14 @@ struct aibot {
|
|||
/*0x2dc*/ u32 unk2dc;
|
||||
};
|
||||
|
||||
struct tile {
|
||||
struct geo {
|
||||
/*0x00*/ u8 type;
|
||||
/*0x01*/ u8 numvertices;
|
||||
/*0x02*/ u16 flags;
|
||||
};
|
||||
|
||||
struct tiletype0 {
|
||||
struct tile header;
|
||||
struct geotilei {
|
||||
struct geo header;
|
||||
/*0x04*/ u16 floortype;
|
||||
/*0x06*/ u8 xmin; // These are byte offsets relative to the start of tile
|
||||
/*0x07*/ u8 ymin;
|
||||
|
|
@ -848,8 +848,8 @@ struct tiletype0 {
|
|||
/*0x0e*/ s16 vertices[64][3];
|
||||
};
|
||||
|
||||
struct tiletype1 {
|
||||
struct tile header;
|
||||
struct geotilef {
|
||||
struct geo header;
|
||||
/*0x04*/ u16 floortype;
|
||||
union {
|
||||
// The arrays are surely the correct type here, but they create
|
||||
|
|
@ -872,15 +872,15 @@ struct tiletype1 {
|
|||
/*0x10*/ struct coord vertices[64];
|
||||
};
|
||||
|
||||
struct tiletype2 {
|
||||
struct tile header;
|
||||
struct geoblock {
|
||||
struct geo header;
|
||||
/*0x04*/ f32 ymax;
|
||||
/*0x08*/ f32 ymin;
|
||||
/*0x0c*/ f32 vertices[8][2];
|
||||
};
|
||||
|
||||
struct tiletype3 {
|
||||
struct tile header;
|
||||
struct geocyl {
|
||||
struct geo header;
|
||||
/*0x04*/ f32 ymax;
|
||||
/*0x08*/ f32 ymin;
|
||||
/*0x0c*/ f32 x;
|
||||
|
|
@ -888,14 +888,6 @@ struct tiletype3 {
|
|||
/*0x14*/ f32 radius;
|
||||
};
|
||||
|
||||
struct tilething {
|
||||
struct tile *tile;
|
||||
u32 unk04;
|
||||
u32 unk08;
|
||||
struct prop *lift;
|
||||
u32 floorroom;
|
||||
};
|
||||
|
||||
struct act_stand {
|
||||
/*0x2c*/ s32 prestand;
|
||||
/*0x30*/ s32 flags;
|
||||
|
|
@ -1205,7 +1197,7 @@ struct chrdata {
|
|||
/*0x12e*/ s16 chrseeshot;
|
||||
/*0x130*/ s16 chrseedie;
|
||||
/*0x132*/ s16 chrdup;
|
||||
struct tiletype3 geo;
|
||||
struct geocyl geo;
|
||||
/*0x14c*/ f32 shotbondsum;
|
||||
/*0x150*/ f32 aimuplshoulder;
|
||||
/*0x154*/ f32 aimuprshoulder;
|
||||
|
|
@ -1469,10 +1461,10 @@ struct defaultobj {
|
|||
/*0x1c*/ f32 realrot[3][3];
|
||||
/*0x40*/ u32 hidden;
|
||||
union {
|
||||
/*0x44*/ struct tiletype1 *geo1;
|
||||
/*0x44*/ struct tiletype2 *geo2;
|
||||
/*0x44*/ struct tiletype3 *geo3;
|
||||
/*0x44*/ struct tiletype3 *unkgeo; // temporary, to indicate that I don't know which geo pointer is being used
|
||||
/*0x44*/ struct geotilef *geotilef;
|
||||
/*0x44*/ struct geoblock *geoblock;
|
||||
/*0x44*/ struct geocyl *geocyl;
|
||||
/*0x44*/ struct geocyl *unkgeo; // temporary, to indicate that I don't know which geo pointer is being used
|
||||
};
|
||||
union {
|
||||
/*0x48*/ struct projectile *projectile;
|
||||
|
|
@ -1483,7 +1475,7 @@ struct defaultobj {
|
|||
/*0x50*/ u8 shadecol[4];
|
||||
/*0x54*/ u8 nextcol[4];
|
||||
/*0x58*/ u16 floorcol;
|
||||
/*0x5a*/ s8 numtiles;
|
||||
/*0x5a*/ s8 geocount;
|
||||
};
|
||||
|
||||
struct doorobj { // objtype 0x01
|
||||
|
|
@ -2678,8 +2670,8 @@ struct player {
|
|||
/*0x19c0*/ f32 vv_headheight; // 172 when Jo, regardless of crouch state
|
||||
/*0x19c4*/ f32 vv_eyeheight; // 159 when Jo, regardless of crouch state
|
||||
/*0x19c8*/ bool haschrbody;
|
||||
/*0x19cc*/ struct tiletype3 periminfo;
|
||||
/*0x19e4*/ struct tiletype3 perimshoot;
|
||||
/*0x19cc*/ struct geocyl periminfo;
|
||||
/*0x19e4*/ struct geocyl perimshoot;
|
||||
/*0x19fc*/ f32 bondprevtheta;
|
||||
/*0x1a00*/ struct coord grabbedprevpos;
|
||||
/*0x1a0c*/ f32 grabbedrotoffset;
|
||||
|
|
@ -5781,11 +5773,11 @@ struct texturepair {
|
|||
};
|
||||
|
||||
struct collisionthing {
|
||||
struct tile *tile;
|
||||
struct geo *geo;
|
||||
u32 unk04;
|
||||
s32 unk08;
|
||||
struct prop *prop;
|
||||
u32 roomnum;
|
||||
s32 room;
|
||||
};
|
||||
|
||||
struct escastepkeyframe {
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue