mirror of
https://github.com/OpenDriver2/REDRIVER2.git
synced 2024-11-25 11:52:32 +01:00
- convert 0x107f -> OTSIZE-1
This commit is contained in:
parent
95ee06847c
commit
ea34a1449a
@ -46,7 +46,6 @@ MODEL* gDamWheelModelPtr;
|
|||||||
CAR_DATA* active_car_list[MAX_CARS];
|
CAR_DATA* active_car_list[MAX_CARS];
|
||||||
BOUND_BOX bbox[MAX_CARS];
|
BOUND_BOX bbox[MAX_CARS];
|
||||||
u_char lightsOnDelay[MAX_CARS];
|
u_char lightsOnDelay[MAX_CARS];
|
||||||
u_short civ_clut[8][32][6];
|
|
||||||
short FrontWheelRotation[MAX_CARS]; // offset 0x0
|
short FrontWheelRotation[MAX_CARS]; // offset 0x0
|
||||||
short BackWheelRotation[MAX_CARS]; // offset 0x30
|
short BackWheelRotation[MAX_CARS]; // offset 0x30
|
||||||
|
|
||||||
@ -63,6 +62,10 @@ MODEL* gCarLowModelPtr[MAX_CAR_MODELS];
|
|||||||
MODEL* gCarDamModelPtr[MAX_CAR_MODELS];
|
MODEL* gCarDamModelPtr[MAX_CAR_MODELS];
|
||||||
MODEL* gCarCleanModelPtr[MAX_CAR_MODELS];
|
MODEL* gCarCleanModelPtr[MAX_CAR_MODELS];
|
||||||
|
|
||||||
|
// pedestrian palette at 0 and next are cars
|
||||||
|
// model_id, texture_number, palette
|
||||||
|
u_short civ_clut[8][32][6];
|
||||||
|
|
||||||
int whichCP = 0;
|
int whichCP = 0;
|
||||||
int baseSpecCP = 0;
|
int baseSpecCP = 0;
|
||||||
CAR_POLY carPolyBuffer[2001];
|
CAR_POLY carPolyBuffer[2001];
|
||||||
|
@ -788,7 +788,7 @@ void DrawBodySprite(PEDESTRIAN* pDrawingPed, int boneId, VERTTYPE v1[2], VERTTYP
|
|||||||
|
|
||||||
if (bDoingShadow != 0)
|
if (bDoingShadow != 0)
|
||||||
{
|
{
|
||||||
addPrim(current->ot + 0x107f, prims);
|
addPrim(current->ot + OTSIZE - 1, prims);
|
||||||
|
|
||||||
#ifdef PGXP
|
#ifdef PGXP
|
||||||
prims->pgxp_index = 0xffff;
|
prims->pgxp_index = 0xffff;
|
||||||
@ -1842,7 +1842,7 @@ void TannerShadow(PEDESTRIAN* pDrawingPed, VECTOR* pPedPos, SVECTOR* pLightPos,
|
|||||||
dr_env = (DR_ENV*)current->primptr;
|
dr_env = (DR_ENV*)current->primptr;
|
||||||
SetDrawEnv(dr_env, &drEnv);
|
SetDrawEnv(dr_env, &drEnv);
|
||||||
|
|
||||||
addPrim(current->ot + 0x107f, dr_env);
|
addPrim(current->ot + OTSIZE - 1, dr_env);
|
||||||
current->primptr += sizeof(DR_ENV);
|
current->primptr += sizeof(DR_ENV);
|
||||||
|
|
||||||
Tangle = ratan2(-pLightPos->vx, pLightPos->vz);
|
Tangle = ratan2(-pLightPos->vx, pLightPos->vz);
|
||||||
@ -1935,7 +1935,7 @@ void TannerShadow(PEDESTRIAN* pDrawingPed, VECTOR* pPedPos, SVECTOR* pLightPos,
|
|||||||
|
|
||||||
// clear to black and draw Tanner sprites
|
// clear to black and draw Tanner sprites
|
||||||
newShowTanner(pDrawingPed);
|
newShowTanner(pDrawingPed);
|
||||||
addPrim(current->ot + 0x107f, &tileTannerClear[current->id]);
|
addPrim(current->ot + OTSIZE - 1, &tileTannerClear[current->id]);
|
||||||
|
|
||||||
// restore vectors
|
// restore vectors
|
||||||
camera_position = cp;
|
camera_position = cp;
|
||||||
@ -1955,7 +1955,7 @@ void TannerShadow(PEDESTRIAN* pDrawingPed, VECTOR* pPedPos, SVECTOR* pLightPos,
|
|||||||
dr_env = (DR_ENV*)current->primptr;
|
dr_env = (DR_ENV*)current->primptr;
|
||||||
SetDrawEnv(dr_env, &drEnv);
|
SetDrawEnv(dr_env, &drEnv);
|
||||||
|
|
||||||
addPrim(current->ot + 0x107f, dr_env);
|
addPrim(current->ot + OTSIZE - 1, dr_env);
|
||||||
current->primptr += sizeof(DR_ENV);
|
current->primptr += sizeof(DR_ENV);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -866,7 +866,7 @@ void PlotSkyPoly(POLYFT4* polys, int skytexnum, unsigned char r, unsigned char g
|
|||||||
poly->clut = skyclut[skytexnum];
|
poly->clut = skyclut[skytexnum];
|
||||||
poly->tpage = skytpage[skytexnum];
|
poly->tpage = skytpage[skytexnum];
|
||||||
|
|
||||||
addPrim(current->ot + 0x107f, poly);
|
addPrim(current->ot + OTSIZE - 1, poly);
|
||||||
|
|
||||||
#if defined(USE_PGXP) && defined(USE_EXTENDED_PRIM_POINTERS)
|
#if defined(USE_PGXP) && defined(USE_EXTENDED_PRIM_POINTERS)
|
||||||
poly->pgxp_index = outpoints[src->v0].pgxp_index;
|
poly->pgxp_index = outpoints[src->v0].pgxp_index;
|
||||||
|
Loading…
Reference in New Issue
Block a user