Skip to content

Commit

Permalink
Truckload of updates (#96)
Browse files Browse the repository at this point in the history
* dethrace: implement all missing brucetrk functions

* brender: use sqrtf in macros to avoid double->float conversion

* dethrace: implement a few key callbacks (will crash further along the line)

* dethrace: start earning some money (display credits message)

* dethrace: create spark/shrapnel objects (no render yet)

* ALL IN ONE

* brender: implement 'easy' euler functions

* brender: implement BrMatrix4PreTransform and BrTransformToTransform

* brender: add TAU constand (=2*pi)

* brender: add FIXME/STUB to render function (+ implement it)

* brender: add a few functions to the global brender header

* Add DETHRACE_FIX_BUGS macro to the cmake build system to optionally fix bugs/compiler warnings

* dethrace: implement 2 crush functions

* dethrace: use floats in FindFace + re-use local stack variable

* tNet_contents is an enum: the header aliases the start of the other messages

* dethrace: stub PDMouseButtons

* dethrace: implement a few utility functions

* dethrace: implement ChangeSelectionTo + de-inline ResetInterfaceTimeout

* dethrace: use chars instead of magic values + add fix for compiler warning about number formatting

* dethrace: compare a pointer against a NULL pointer

* dethrace: implement a lot of powerup functions

* dethrace: implement a few piping functions

* dethrace: implement a few opponent functions

* dethrace: completely implement load/save (or so I hope :D)

* dethrace: implement a few oily functions

* dethrace: implement got/lose/periodic powerup proc array

* brender: add BrXXXFindHook functions to brender header

* dethrace: register callback functions on missing material/model/map/tables

* dethrace: compare pointers with pointers and ints with ints

* Hide powercallback typedefs behind #ifdef

* dethrace: implement Del/End/PgDn APO buy buttons logic

* Add BrDiagHandlerSet to brender.h

* dethrace: SwithToRealResolution/SwitchToLoresMode call PD functions

* Use correct type when comparing against characters.

* dethrace: implement writing out and disposing crush data

* dethrace: add NonFatalError + fix entry in gError_messages

* dethrace: implement StopCarSmoking and StopCarSmokingInstantly

* dethrace: implement SkidNoise + ScrapeNoise + DamageUnitWithSmoke + DamageUnit

* dethrace: InitCarSkidStuff -> use floats instead of doubles

* Add BrPixelmapCopy + BrPixelmapPixelSet to brender header

* dethrace: implement DisableCar

* dethrace: stub out a lot of functions in sound.c

* dethrace: load and dispose pratcam data

* dethrace: minor additions to flicplay.c

* skidmark: compare floats with floats

* dethrace: implement some functions to convert face materials for different wall texturing levels

* add stub BrPixelmapCopy function + add STUB_ONCE calls in other methods

* MungeForwardSky does nothing, I think

* Use macros to initialize variables in AllocateCamera

* Implement AdjustSkid + use floats

* DRStdioOpenRead: Compare pointer against NULL

* dethrace: Implement IncrementLap

* dethrace: implement ChangeAmbientPratcam

* Implement SortOutRecover

* Implement CheckHornLocal

* Use COUNT_OF in dethrace

* Draw arrow blip on map

* Implement DRPixelmapCopy

* Fix error code value

* Stub GotPowerupX

* Add ability to run the game/tests without signal handler, this allows a debugger to attach

* Don't save a game in PDFatalError

* Fix loadsave recopy arrays

Co-authored-by: Dethrace Engineering Department <78985374+dethrace-labs@users.noreply.github.com>
  • Loading branch information
madebr and dethrace-labs committed Mar 2, 2022
1 parent 92b67a9 commit 6568a15
Show file tree
Hide file tree
Showing 49 changed files with 4,118 additions and 820 deletions.
15 changes: 12 additions & 3 deletions src/BRSRC13/CORE/MATH/angles.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#include "angles.h"
#include "CORE/MATH/matrix34.h"
#include "CORE/MATH/matrix4.h"
#include "CORE/MATH/quat.h"
#include "harness/trace.h"

order_info OrderAxes[32];
Expand Down Expand Up @@ -40,14 +43,18 @@ br_euler* BrMatrix34ToEuler(br_euler* euler, br_matrix34* mat) {
br_matrix4* BrEulerToMatrix4(br_matrix4* mat, br_euler* euler) {
br_matrix34 tmp;
LOG_TRACE("(%p, %p)", mat, euler);
NOT_IMPLEMENTED();

BrEulerToMatrix34(&tmp, euler);
BrMatrix4Copy34(mat, &tmp);
}

// IDA: br_euler* __cdecl BrMatrix4ToEuler(br_euler *dest, br_matrix4 *mat)
br_euler* BrMatrix4ToEuler(br_euler* dest, br_matrix4* mat) {
br_matrix34 tmp;
LOG_TRACE("(%p, %p)", dest, mat);
NOT_IMPLEMENTED();

BrMatrix34Copy4(&tmp, mat);
return BrMatrix34ToEuler(dest, &tmp);
}

// IDA: br_quat* __cdecl BrEulerToQuat(br_quat *q, br_euler *euler)
Expand Down Expand Up @@ -77,5 +84,7 @@ br_quat* BrEulerToQuat(br_quat* q, br_euler* euler) {
br_euler* BrQuatToEuler(br_euler* euler, br_quat* q) {
br_matrix34 mat;
LOG_TRACE("(%p, %p)", euler, q);
NOT_IMPLEMENTED();

BrQuatToMatrix34(&mat, q);
return BrMatrix34ToEuler(euler, &mat);
}
47 changes: 45 additions & 2 deletions src/BRSRC13/CORE/MATH/transfrm.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
#include "CORE/MATH/vector.h"
#include "harness/trace.h"

#include <string.h>

#define M34 BR_TRANSFORM_MATRIX34
#define MLP BR_TRANSFORM_MATRIX34_LP
#define QUT BR_TRANSFORM_QUAT
Expand Down Expand Up @@ -188,12 +190,53 @@ void BrMatrix4PreTransform(br_matrix4* mat, br_transform* xform) {
// IDA: void __cdecl BrMatrix34ToTransform(br_transform *xform, br_matrix34 *mat)
void BrMatrix34ToTransform(br_transform* xform, br_matrix34* mat) {
LOG_TRACE("(%p, %p)", xform, mat);
NOT_IMPLEMENTED();

switch (xform->type) {
case BR_TRANSFORM_MATRIX34:
memcpy(&xform->t.mat, mat, sizeof(br_matrix34));
break;
case BR_TRANSFORM_MATRIX34_LP:
memcpy(&xform->t.mat, mat, sizeof(br_matrix34));
BrMatrix34LPNormalise(&xform->t.mat, &xform->t.mat);
break;
case BR_TRANSFORM_QUAT:
BrMatrix34ToQuat(&xform->t.quat.q, mat);
BrVector3Copy(&xform->t.quat.t, (br_vector3*)mat->m[3]);
break;
case BR_TRANSFORM_EULER:
BrMatrix34ToEuler(&xform->t.euler.e, mat);
BrVector3Copy(&xform->t.quat.t, (br_vector3*)mat->m[3]);
break;
case BR_TRANSFORM_LOOK_UP:
NOT_IMPLEMENTED();
break;
case BR_TRANSFORM_TRANSLATION:
BrVector3Copy(&xform->t.quat.t, (br_vector3*)mat->m[3]);
break;
default:
TELL_ME_IF_WE_PASS_THIS_WAY();
}
}

// IDA: void __cdecl BrTransformToTransform(br_transform *dest, br_transform *src)
void BrTransformToTransform(br_transform* dest, br_transform* src) {
br_matrix34 temp;
LOG_TRACE("(%p, %p)", dest, src);
NOT_IMPLEMENTED();

if (src->type == dest->type) {
memcpy(dest, src, sizeof(br_transform));
return;
}
switch (dest->type) {
case BR_TRANSFORM_MATRIX34:
BrTransformToMatrix34(&dest->t.mat, src);
break;
case BR_TRANSFORM_MATRIX34_LP:
BrTransformToMatrix34(&dest->t.mat, src);
BrMatrix34LPNormalise(&dest->t.mat, &dest->t.mat);
break;
default:
BrTransformToMatrix34(&temp, src);
BrMatrix34ToTransform(dest, &temp);
}
}
13 changes: 12 additions & 1 deletion src/BRSRC13/CORE/PIXELMAP/pmdsptch.c
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,8 @@ void BrPixelmapDirtyRectangleDoubleBuffer(br_pixelmap* dst, br_pixelmap* src, br
void BrPixelmapPixelSet(br_pixelmap* dst, br_int_32 x, br_int_32 y, br_uint_32 colour) {
br_point p;
// LOG_TRACE("(%p, %d, %d, %d)", dst, x, y, colour);

STUB_ONCE(); // stub because this implementation is improperly (=coordinates can lie outside pixelmap + pixel format size can be > 1 bytes)
br_uint_8* dst_pix = (br_uint_8*)dst->pixels;
dst_pix[(y * dst->row_bytes) + x] = (br_uint_8)colour;
}
Expand All @@ -262,7 +264,14 @@ void BrPixelmapCopy(br_pixelmap* dst, br_pixelmap* src) {
br_rectangle s;
br_rectangle d;
LOG_TRACE("(%p, %p)", dst, src);
NOT_IMPLEMENTED();

STUB_ONCE(); // stub because this implementation is improperly (=coordinates can lie outside pixelmap + pixel format size can be > 1 bytes)

for (int y = 0; y < src->height; y++) {
for (int x = 0; x < src->width; x++) {
((br_uint_8*)dst->pixels)[y * dst->row_bytes + x] = ((br_uint_8*)src->pixels)[y * src->row_bytes + x];
}
}
}

// IDA: void __cdecl BrPixelmapLine(br_pixelmap *dst, br_int_32 x1, br_int_32 y1, br_int_32 x2, br_int_32 y2, br_uint_32 colour)
Expand All @@ -271,6 +280,8 @@ void BrPixelmapLine(br_pixelmap* dst, br_int_32 x1, br_int_32 y1, br_int_32 x2,
// br_point e;
LOG_TRACE("(%p, %d, %d, %d, %d, %d)", dst, x1, y1, x2, y2, colour);

STUB_ONCE(); // stub because this implementation is improperly (=coordinates can lie outside pixelmap + pixel format size can be > 1 bytes)

// Thanks Errol!
br_int_16 dx, dy, inx, iny, e;
dx = x2 - x1;
Expand Down
5 changes: 5 additions & 0 deletions src/BRSRC13/CORE/V1DB/render.c
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,12 @@ br_uint_32 BrOnScreenCheck(br_bounds3* bounds) {
br_token r;
LOG_TRACE("(%p)", bounds);

STUB_ONCE(); // Add call to STUB_ONCE to mark this function as not implemented.
return 1;

// FIXME: use this once the clouse clear up.
v1db.renderer->dispatch->_boundsTestF(v1db.renderer, &r, (br_bounds3_f*)bounds);
return r;
}

// IDA: br_uint_16 __usercall prependActorTransform@<AX>(br_actor *ap@<EAX>, br_uint_16 t@<EDX>)
Expand Down
7 changes: 4 additions & 3 deletions src/BRSRC13/include/brender/br_defs.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@

// Inspired by BRender SDK includes (https://rr2000.cwaboard.co.uk/R4/BRENDER/BRENDER.zip)

#define PI 3.14159265358979323846
#define PI 3.14159265358979323846
#define TAU 6.283185307179586

#define BR_MAC3(a, b, c, d, e, f) ((a) * (b) + (c) * (d) + (e) * (f))
#define BR_SQR3(a, b, c) ((a) * (a) + (b) * (b) + (c) * (c))
Expand Down Expand Up @@ -31,8 +32,8 @@
#define BR_COLOUR_RGBA(r, g, b, a) \
((((unsigned int)(a)) << 24) | (((unsigned int)(r)) << 16) | (((unsigned int)(g)) << 8) | ((unsigned int)(b)))

#define BR_LENGTH2(a, b) ((br_scalar)sqrt((a) * (a) + (b) * (b)))
#define BR_LENGTH3(a, b, c) ((br_scalar)sqrt((a) * (a) + (b) * (b) + (c) * (c)))
#define BR_LENGTH2(a, b) ((br_scalar)sqrtf((a) * (a) + (b) * (b)))
#define BR_LENGTH3(a, b, c) ((br_scalar)sqrtf((a) * (a) + (b) * (b) + (c) * (c)))
#define BR_SCALAR_EPSILON 1.192092896e-7f
#define BR_SCALAR_MAX 3.402823466e+38f
#define BR_SCALAR_MIN (-3.402823466e+38f)
Expand Down
15 changes: 15 additions & 0 deletions src/BRSRC13/include/brender/brender.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ br_pixelmap* BrMapAdd(br_pixelmap* pixelmap);
br_pixelmap* BrMapRemove(br_pixelmap* pixelmap);
br_pixelmap* BrMapFind(char* pattern);
br_uint_32 BrMapAddMany(br_pixelmap** items, int n);
br_map_find_cbfn* BrMapFindHook(br_map_find_cbfn* hook) ;

// BrMaterial
br_material* BrMaterialAllocate(char* name);
Expand All @@ -55,6 +56,7 @@ br_material* BrMaterialFind(char* pattern);
void BrMaterialFree(br_material* m);
br_uint_32 BrMaterialAddMany(br_material** items, int n);
br_uint_32 BrMaterialEnum(char* pattern, br_material_enum_cbfn* callback, void* arg);
br_material_find_cbfn* BrMaterialFindHook(br_material_find_cbfn* hook);

// BrMatrix34
void BrMatrix23Identity(br_matrix23* mat);
Expand Down Expand Up @@ -103,6 +105,7 @@ br_model* BrModelLoad(char* filename);
void BrModelFree(br_model* model);
void BrModelUpdate(br_model* model, br_uint_16 flags);
br_uint_32 BrModelLoadMany(char* filename, br_model** models, br_uint_16 num);
br_model_find_cbfn* BrModelFindHook(br_model_find_cbfn* hook);

// BrPixelmap
br_pixelmap* BrPixelmapLoad(char* filename);
Expand All @@ -114,8 +117,10 @@ br_pixelmap* BrPixelmapMatch(br_pixelmap* src, br_uint_8 match_type);
br_pixelmap* BrPixelmapAllocateSub(br_pixelmap* src, br_int_32 x, br_int_32 y, br_int_32 w, br_int_32 h);
void BrPixelmapFill(br_pixelmap* dst, br_uint_32 colour);
void BrPixelmapRectangleCopy(br_pixelmap* dst, br_int_32 dx, br_int_32 dy, br_pixelmap* src, br_int_32 sx, br_int_32 sy, br_int_32 w, br_int_32 h);
void BrPixelmapCopy(br_pixelmap* dst, br_pixelmap* src);
void BrPixelmapLine(br_pixelmap* dst, br_int_32 x1, br_int_32 y1, br_int_32 x2, br_int_32 y2, br_uint_32 colour);
void BrPixelmapRectangleFill(br_pixelmap* dst, br_int_32 x, br_int_32 y, br_int_32 w, br_int_32 h, br_uint_32 colour);
void BrPixelmapPixelSet(br_pixelmap* dst, br_int_32 x, br_int_32 y, br_uint_32 colour);
br_pixelmap* BrPixelmapAllocate(br_uint_8 type, br_int_32 w, br_int_32 h, void* pixels, int flags);
void BrPixelmapDoubleBuffer(br_pixelmap* dst, br_pixelmap* src);
void BrPixelmapText(br_pixelmap* dst, br_int_32 x, br_int_32 y, br_uint_32 colour, br_font* font, char* text);
Expand All @@ -124,6 +129,7 @@ br_uint_16 BrPixelmapTextWidth(br_pixelmap* dst, br_font* font, char* text);
// BrRes
void* BrResAllocate(void* vparent, br_size_t size, br_uint_8 res_class);
br_resource_class* BrResClassAdd(br_resource_class* rclass);
void* BrResRemove(void* vres);
void BrResFree(void* vres);
char* BrResStrDup(void* vparent, char* str);

Expand All @@ -135,6 +141,7 @@ br_pixelmap* BrTableRemove(br_pixelmap* pixelmap);
br_uint_32 BrTableAddMany(br_pixelmap** items, int n);
void BrTableUpdate(br_pixelmap* table, br_uint_16 flags);
br_uint_32 BrTableEnum(char* pattern, br_table_enum_cbfn* callback, void* arg);
br_table_find_cbfn* BrTableFindHook(br_table_find_cbfn* hook);

// BrTransform
void BrTransformToMatrix34(br_matrix34* mat, br_transform* xform);
Expand All @@ -149,6 +156,9 @@ void BrVector3SetFloat(br_vector3* v1, float f1, float f2, float f3);
// void BrVector3Accumulate(br_vector3* v1, br_vector3* v2);
// void BrVector3Normalise(br_vector3* v1, br_vector3* v2);

// BrTransform
void BrTransformToTransform(br_transform* dest, br_transform* src);

// Logging
void BrFailure(const char* s, ...);
void BrFatal(const char* name, int line, const char* s, ...);
Expand All @@ -160,10 +170,15 @@ void BrZbSceneRenderBegin(br_actor* world, br_actor* camera, br_pixelmap* colour
void BrZbSceneRenderAdd(br_actor* tree);
void BrZbSceneRenderEnd(void);

void BrZbModelRender(br_actor* actor, br_model* model, br_material* material, br_uint_8 style, int on_screen, int use_custom);

br_pixelmap* DOSGfxBegin(char* setup_string);

// Various
br_uint_32 BrOnScreenCheck(br_bounds3* bounds);

int BrWriteModeSet(int mode);
br_uint_32 BrSwap32(br_uint_32 l);
br_diaghandler* BrDiagHandlerSet(br_diaghandler* newdh);

#endif
5 changes: 5 additions & 0 deletions src/DETHRACE/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Create object files so we can link them into the main binary and into tests without building twice.
add_library(dethrace_obj OBJECT)

option(DETHRACE_FIX_BUGS "Fix Dethrace bugs" ON)

target_include_directories(dethrace_obj
PUBLIC
${CMAKE_CURRENT_SOURCE_DIR}
Expand Down Expand Up @@ -39,6 +41,9 @@ else()
/wd4996
)
endif()
if(BRENDER_FIX_BUGS)
target_compile_definitions(dethrace_obj PRIVATE DETHRACE_FIX_BUGS)
endif()

target_sources(dethrace_obj PRIVATE
common/brucetrk.c
Expand Down
92 changes: 88 additions & 4 deletions src/DETHRACE/common/brucetrk.c
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
#include "brucetrk.h"

#include "brender/brender.h"
#include "errors.h"
#include "globvars.h"
#include "globvrbm.h"
#include "harness/trace.h"
#include "init.h"
#include "utility.h"
#include "world.h"
#include "pd/sys.h"
#include <math.h>
#include <stdlib.h>
#include <string.h>
Expand Down Expand Up @@ -92,7 +95,54 @@ void StripBlendedFaces(br_actor* pActor, br_model* pModel) {
char s[256];
static tU16 nfaces_allocated;
LOG_TRACE("(%p, %p)", pActor, pModel);
STUB();

changed_one = 0;
face = &pModel->faces[0];
for (i = 0; i < pModel->nfaces; i++, face++) {
if (face->material != NULL && face->material->identifier != NULL && ((face->material->identifier[0] == '!' && face->material->identifier[1] == '!' && gDefault_blend_pc != 0) || face->material->identifier[1] == '\\' )) {
if (gMr_blendy == NULL) {
gMr_blendy = BrActorAllocate(BR_ACTOR_MODEL, NULL);
gMr_blendy->render_style = BR_RSTYLE_NONE;
gMr_blendy->model = BrModelAllocate(NULL, pModel->nvertices, pModel->nfaces);
nfaces_allocated = pModel->nfaces;
gMr_blendy->model->nfaces = 0;
gMr_blendy->model->flags |= BR_MODF_UPDATEABLE;
memcpy(gMr_blendy->model->vertices, pModel->vertices, pModel->nvertices * sizeof(br_vertex));
}
if (!AlreadyBlended(face->material)) {
if (face->material->identifier[1] == '\\') {
if (face->material->identifier[2] == '2') {
BlendifyMaterial(face->material, 25);
} else if (face->material->identifier[2] == '7') {
BlendifyMaterial(face->material, 75);
} else {
BlendifyMaterial(face->material, 50);
}
BrMaterialUpdate(face->material, BR_MATU_ALL);
}
}
if (nfaces_allocated <= gMr_blendy->model->nfaces) {
PDFatalError("Perfectly understandable error by Batwick, thank you very much Bruce.");
}
memcpy(&gMr_blendy->model->faces[gMr_blendy->model->nfaces], face, sizeof(br_face));
gMr_blendy->model->nfaces++;
if (i < (pModel->nfaces - 1)) {
memcpy(&pModel->faces[i], &pModel->faces[i + 1], (pModel->nfaces - i - 1) * sizeof(br_face));
}
pModel->nfaces--;
changed_one = 1;
i--;
face = &pModel->faces[i];
}
}
if (changed_one) {
if (pModel->nfaces != 0) {
BrModelUpdate(pModel, BR_MODU_ALL);
} else {
pActor->model = NULL;
pActor->type = BR_ACTOR_NONE;
}
}
}

// IDA: br_uint_32 __cdecl FindNonCarsCB(br_actor *pActor, tTrack_spec *pTrack_spec)
Expand All @@ -103,8 +153,42 @@ intptr_t FindNonCarsCB(br_actor* pActor, tTrack_spec* pTrack_spec) {
br_scalar r3;
LOG_TRACE("(%p, %p)", pActor, pTrack_spec);

STUB();
return 0;
if (pActor->identifier != NULL && pActor->identifier[0] == '&' && pActor->identifier[1] >= '0' && pActor->identifier[1] <= '9') {
i = (pActor->identifier[4] - '0') * 1000 + (pActor->identifier[5] - '0') * 100 + (pActor->identifier[6] - '0') * 10 + (pActor->identifier[7] - '0');
if (i < 0 || pTrack_spec->ampersand_digits <= i) {
return 1;
}
r1 = BR_SQR3(pActor->t.t.mat.m[0][0], pActor->t.t.mat.m[0][1], pActor->t.t.mat.m[0][2]);
r2 = BR_SQR3(pActor->t.t.mat.m[1][0], pActor->t.t.mat.m[1][1], pActor->t.t.mat.m[1][2]);
r3 = BR_SQR3(pActor->t.t.mat.m[2][0], pActor->t.t.mat.m[2][1], pActor->t.t.mat.m[2][2]);
if (r1 < .999f || r2 < .999f || r3 < .999f) {
dr_dprintf("non car was scaled down %s", pActor->identifier);
pActor->t.t.translate.t.v[0] += 2000.f;
}
if (r1 > 1.001f || r2 > 1.001f || r3 > 1.001f) {
r1 = 1.f / sqrtf(r1);
r2 = 1.f / sqrtf(r2);
r3 = 1.f / sqrtf(r3);
pActor->t.t.mat.m[0][0] *= r1;
pActor->t.t.mat.m[0][1] *= r1;
pActor->t.t.mat.m[0][2] *= r1;
pActor->t.t.mat.m[1][0] *= r2;
pActor->t.t.mat.m[1][1] *= r2;
pActor->t.t.mat.m[1][2] *= r2;
pActor->t.t.mat.m[2][0] *= r3;
pActor->t.t.mat.m[2][1] *= r3;
pActor->t.t.mat.m[2][2] *= r3;
dr_dprintf("non car was scaled up %s", pActor->identifier);
}
pTrack_spec->non_car_list[i] = pActor;
pActor->type_data = NULL;
return 0;
} else {
if (pActor->model != NULL && !gAusterity_mode && pActor->identifier != NULL && pActor->identifier[0] != '&') {
StripBlendedFaces(pActor, pActor->model);
}
return BrActorEnum(pActor, (br_actor_enum_cbfn*)FindNonCarsCB, pTrack_spec);
}
}

// IDA: br_uint_32 __cdecl ProcessModelsCB(br_actor *pActor, tTrack_spec *pTrack_spec)
Expand All @@ -128,7 +212,7 @@ intptr_t ProcessModelsCB(br_actor* pActor, tTrack_spec* pTrack_spec) {
for (group = 0; V11MODEL(gMr_blendy->model)->ngroups > group; ++group) {
V11MODEL(gMr_blendy->model)->groups[group].face_colours_material = gMr_blendy->model->faces[*V11MODEL(gMr_blendy->model)->groups[group].face_user].material;
}
gMr_blendy->model->flags &= 0xFF7Fu;
gMr_blendy->model->flags &= ~BR_MODF_UPDATEABLE;
DodgyModelUpdate(gMr_blendy->model);
pTrack_spec->blends[z][x] = gMr_blendy;
}
Expand Down
Loading

0 comments on commit 6568a15

Please sign in to comment.