mirror of
https://gitlab.com/GaryOderNichts/re3-wiiu.git
synced 2024-11-27 19:44:15 +01:00
VC vehicles just barely working now
This commit is contained in:
parent
a8d8c0690d
commit
05a1d64fbb
@ -100,13 +100,13 @@ enum eVehicleModel {
|
|||||||
LINERUN,
|
LINERUN,
|
||||||
PEREN,
|
PEREN,
|
||||||
SENTINEL,
|
SENTINEL,
|
||||||
PATRIOT,
|
RIO,
|
||||||
FIRETRUK,
|
FIRETRUK,
|
||||||
TRASH,
|
TRASH,
|
||||||
STRETCH,
|
STRETCH,
|
||||||
MANANA,
|
MANANA,
|
||||||
INFERNUS,
|
INFERNUS,
|
||||||
BLISTA,
|
VOODOO,
|
||||||
PONY,
|
PONY,
|
||||||
MULE,
|
MULE,
|
||||||
CHEETAH,
|
CHEETAH,
|
||||||
@ -115,11 +115,11 @@ enum eVehicleModel {
|
|||||||
MOONBEAM,
|
MOONBEAM,
|
||||||
ESPERANT,
|
ESPERANT,
|
||||||
TAXI,
|
TAXI,
|
||||||
KURUMA,
|
WASHING,
|
||||||
BOBCAT,
|
BOBCAT,
|
||||||
MRWHOOP,
|
MRWHOOP,
|
||||||
BFINJECT,
|
BFINJECT,
|
||||||
CORPSE,
|
HUNTER,
|
||||||
POLICE,
|
POLICE,
|
||||||
ENFORCER,
|
ENFORCER,
|
||||||
SECURICA,
|
SECURICA,
|
||||||
@ -128,42 +128,83 @@ enum eVehicleModel {
|
|||||||
BUS,
|
BUS,
|
||||||
RHINO,
|
RHINO,
|
||||||
BARRACKS,
|
BARRACKS,
|
||||||
TRAIN,
|
CUBAN,
|
||||||
CHOPPER,
|
CHOPPER,
|
||||||
DODO,
|
ANGEL,
|
||||||
COACH,
|
COACH,
|
||||||
CABBIE,
|
CABBIE,
|
||||||
STALLION,
|
STALLION,
|
||||||
RUMPO,
|
RUMPO,
|
||||||
RCBANDIT,
|
RCBANDIT,
|
||||||
BELLYUP,
|
ROMERO,
|
||||||
MRWONGS,
|
PACKER,
|
||||||
MAFIA,
|
SENTXS,
|
||||||
YARDIE,
|
ADMIRAL,
|
||||||
YAKUZA,
|
SQUALO,
|
||||||
DIABLOS,
|
SEASPAR,
|
||||||
COLUMB,
|
PIZZABOY,
|
||||||
HOODS,
|
GANGBUR,
|
||||||
AIRTRAIN,
|
AIRTRAIN,
|
||||||
DEADDODO,
|
DEADDODO,
|
||||||
SPEEDER,
|
SPEEDER,
|
||||||
REEFER,
|
REEFER,
|
||||||
PANLANT,
|
TROPIC,
|
||||||
FLATBED,
|
FLATBED,
|
||||||
YANKEE,
|
YANKEE,
|
||||||
ESCAPE,
|
CADDY,
|
||||||
BORGNINE,
|
ZEBRA,
|
||||||
TOYZ,
|
TOPFUN,
|
||||||
GHOST,
|
SKIMMER,
|
||||||
CAR151,
|
PCJ600,
|
||||||
CAR152,
|
FAGGIO,
|
||||||
CAR153,
|
FREEWAY,
|
||||||
CAR154,
|
RCBARON,
|
||||||
CAR155,
|
RCRAIDER,
|
||||||
CAR156,
|
GLENDALE,
|
||||||
CAR157,
|
OCEANIC,
|
||||||
CAR158,
|
SANCHEZ,
|
||||||
CAR159,
|
SPARROW,
|
||||||
|
PATRIOT,
|
||||||
|
LOVEFIST,
|
||||||
|
COASTG,
|
||||||
|
DINGHY,
|
||||||
|
HERMES,
|
||||||
|
SABRE,
|
||||||
|
SABRETUR,
|
||||||
|
PHEONIX,
|
||||||
|
WALTON,
|
||||||
|
REGINA,
|
||||||
|
COMET,
|
||||||
|
DELUXO,
|
||||||
|
BURRITO,
|
||||||
|
SPAND,
|
||||||
|
MARQUIS,
|
||||||
|
BAGGAGE,
|
||||||
|
KAUFMAN,
|
||||||
|
MAVERICK,
|
||||||
|
VCNMAV,
|
||||||
|
RANCHER,
|
||||||
|
FBIRANCH,
|
||||||
|
VIRGO,
|
||||||
|
GREENWOO,
|
||||||
|
JETMAX,
|
||||||
|
HOTRING,
|
||||||
|
SANDKING,
|
||||||
|
BLISTAC,
|
||||||
|
POLMAV,
|
||||||
|
BOXVILLE,
|
||||||
|
BENSON,
|
||||||
|
MESA,
|
||||||
|
RCGOBLIN,
|
||||||
|
HOTRINA,
|
||||||
|
HOTRINB,
|
||||||
|
BLOODRA,
|
||||||
|
BLOODRB,
|
||||||
|
VICECHEE,
|
||||||
|
|
||||||
|
// HACK so this compiles
|
||||||
|
// TODO(MIAMI): check it out
|
||||||
|
DODO = -1
|
||||||
};
|
};
|
||||||
|
|
||||||
enum PLAY_STATUS : uint8 { PLAY_STATUS_STOPPED = 0, PLAY_STATUS_PLAYING = 1, PLAY_STATUS_FINISHED = 2 };
|
enum PLAY_STATUS : uint8 { PLAY_STATUS_STOPPED = 0, PLAY_STATUS_PLAYING = 1, PLAY_STATUS_FINISHED = 2 };
|
||||||
@ -7103,7 +7144,8 @@ struct tVehicleSampleData {
|
|||||||
uint8 m_bDoorType;
|
uint8 m_bDoorType;
|
||||||
};
|
};
|
||||||
|
|
||||||
const tVehicleSampleData aVehicleSettings[70] = {{SFX_CAR_REV_2, 2, SFX_CAR_HORN_JEEP, 26513, SFX_CAR_ALARM_1, 9935, 1},
|
// TODO(MIAMI): this is bogus. get the real data in here!
|
||||||
|
const tVehicleSampleData aVehicleSettings[110] = {{SFX_CAR_REV_2, 2, SFX_CAR_HORN_JEEP, 26513, SFX_CAR_ALARM_1, 9935, 1},
|
||||||
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_56CHEV, 11487, SFX_CAR_ALARM_1, 9935, 0},
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_56CHEV, 11487, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
{SFX_CAR_REV_8, 8, SFX_CAR_HORN_PORSCHE, 11025, SFX_CAR_ALARM_1, 10928, 1},
|
{SFX_CAR_REV_8, 8, SFX_CAR_HORN_PORSCHE, 11025, SFX_CAR_ALARM_1, 10928, 1},
|
||||||
{SFX_CAR_REV_6, 6, SFX_CAR_HORN_TRUCK, 29711, SFX_CAR_ALARM_1, 9935, 2},
|
{SFX_CAR_REV_6, 6, SFX_CAR_HORN_TRUCK, 29711, SFX_CAR_ALARM_1, 9935, 2},
|
||||||
@ -7172,6 +7214,46 @@ const tVehicleSampleData aVehicleSettings[70] = {{SFX_CAR_REV_2, 2, SFX_CAR_HORN
|
|||||||
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0},
|
||||||
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0}};
|
{SFX_CAR_REV_1, 1, SFX_CAR_HORN_JEEP, 21043, SFX_CAR_ALARM_1, 9935, 0}};
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -7989,7 +8071,7 @@ cAudioManager::ProcessVehicle(CVehicle *veh)
|
|||||||
if (handling)
|
if (handling)
|
||||||
params.m_pTransmission = &handling->Transmission;
|
params.m_pTransmission = &handling->Transmission;
|
||||||
|
|
||||||
params.m_nIndex = veh->GetModelIndex() - 90;
|
params.m_nIndex = veh->GetModelIndex() - MI_FIRST_VEHICLE;
|
||||||
if (params.m_pVehicle->GetStatus() == STATUS_SIMPLE)
|
if (params.m_pVehicle->GetStatus() == STATUS_SIMPLE)
|
||||||
velChange = params.m_pVehicle->AutoPilot.m_fMaxTrafficSpeed * 0.02f;
|
velChange = params.m_pVehicle->AutoPilot.m_fMaxTrafficSpeed * 0.02f;
|
||||||
else
|
else
|
||||||
|
@ -66,7 +66,8 @@ cMusicManager::PlayerInCar()
|
|||||||
case MI_TRAIN:
|
case MI_TRAIN:
|
||||||
case MI_SPEEDER:
|
case MI_SPEEDER:
|
||||||
case MI_REEFER:
|
case MI_REEFER:
|
||||||
case MI_GHOST: return false;
|
// case MI_GHOST:
|
||||||
|
return false;
|
||||||
default: return true;
|
default: return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -541,39 +541,41 @@ cAudioManager::SetupSuspectLastSeenReport()
|
|||||||
color_pre_modifier = gCarColourTable[color1][0];
|
color_pre_modifier = gCarColourTable[color1][0];
|
||||||
color_post_modifier = gCarColourTable[color1][2];
|
color_post_modifier = gCarColourTable[color1][2];
|
||||||
switch (veh->GetModelIndex()) {
|
switch (veh->GetModelIndex()) {
|
||||||
|
// TODO(MIAMI): just making this compile
|
||||||
#ifdef FIX_BUGS
|
#ifdef FIX_BUGS
|
||||||
case MI_COLUMB:
|
// case MI_COLUMB:
|
||||||
main_color = SFX_POLICE_RADIO_BLUE;
|
// main_color = SFX_POLICE_RADIO_BLUE;
|
||||||
color_pre_modifier = color_post_modifier = TOTAL_AUDIO_SAMPLES;
|
// color_pre_modifier = color_post_modifier = TOTAL_AUDIO_SAMPLES;
|
||||||
#endif
|
#endif
|
||||||
case MI_LANDSTAL:
|
case MI_LANDSTAL:
|
||||||
case MI_BLISTA: sample = SFX_POLICE_RADIO_CRUISER; break;
|
// case MI_BLISTA:
|
||||||
|
sample = SFX_POLICE_RADIO_CRUISER; break;
|
||||||
#ifdef FIX_BUGS
|
#ifdef FIX_BUGS
|
||||||
case MI_YARDIE:
|
// case MI_YARDIE:
|
||||||
color_pre_modifier = TOTAL_AUDIO_SAMPLES;
|
// color_pre_modifier = TOTAL_AUDIO_SAMPLES;
|
||||||
main_color = SFX_POLICE_RADIO_RED;
|
// main_color = SFX_POLICE_RADIO_RED;
|
||||||
color_post_modifier = SFX_POLICE_RADIO_YELLOW;
|
// color_post_modifier = SFX_POLICE_RADIO_YELLOW;
|
||||||
sample = SFX_POLICE_RADIO_CONVERTIBLE; break;
|
// sample = SFX_POLICE_RADIO_CONVERTIBLE; break;
|
||||||
case MI_DIABLOS:
|
// case MI_DIABLOS:
|
||||||
main_color = SFX_POLICE_RADIO_BLACK;
|
// main_color = SFX_POLICE_RADIO_BLACK;
|
||||||
#endif
|
#endif
|
||||||
case MI_IDAHO:
|
case MI_IDAHO:
|
||||||
case MI_STALLION: sample = SFX_POLICE_RADIO_CONVERTIBLE; break;
|
case MI_STALLION: sample = SFX_POLICE_RADIO_CONVERTIBLE; break;
|
||||||
#ifdef FIX_BUGS
|
#ifdef FIX_BUGS
|
||||||
case MI_YAKUZA:
|
// case MI_YAKUZA:
|
||||||
color_pre_modifier = TOTAL_AUDIO_SAMPLES;
|
// color_pre_modifier = TOTAL_AUDIO_SAMPLES;
|
||||||
main_color = SFX_POLICE_RADIO_SILVER;
|
// main_color = SFX_POLICE_RADIO_SILVER;
|
||||||
color_post_modifier = SFX_POLICE_RADIO_RED;
|
// color_post_modifier = SFX_POLICE_RADIO_RED;
|
||||||
#endif
|
#endif
|
||||||
case MI_STINGER:
|
case MI_STINGER:
|
||||||
case MI_INFERNUS:
|
case MI_INFERNUS:
|
||||||
case MI_CHEETAH:
|
case MI_CHEETAH:
|
||||||
case MI_BANSHEE: sample = SFX_POLICE_RADIO_SPORTS_CAR; break;
|
case MI_BANSHEE: sample = SFX_POLICE_RADIO_SPORTS_CAR; break;
|
||||||
#ifdef FIX_BUGS
|
#ifdef FIX_BUGS
|
||||||
case MI_MAFIA:
|
// case MI_MAFIA:
|
||||||
color_pre_modifier = color_post_modifier = TOTAL_AUDIO_SAMPLES;
|
// color_pre_modifier = color_post_modifier = TOTAL_AUDIO_SAMPLES;
|
||||||
main_color = SFX_POLICE_RADIO_GREY;
|
// main_color = SFX_POLICE_RADIO_GREY;
|
||||||
case MI_KURUMA:
|
case MI_WASHING:
|
||||||
#endif
|
#endif
|
||||||
case MI_PEREN:
|
case MI_PEREN:
|
||||||
case MI_SENTINEL:
|
case MI_SENTINEL:
|
||||||
@ -588,21 +590,18 @@ cAudioManager::SetupSuspectLastSeenReport()
|
|||||||
case MI_TRASH:
|
case MI_TRASH:
|
||||||
case MI_BARRACKS: sample = SFX_POLICE_RADIO_TRUCK; break;
|
case MI_BARRACKS: sample = SFX_POLICE_RADIO_TRUCK; break;
|
||||||
case MI_STRETCH: sample = SFX_POLICE_RADIO_LIMO; break;
|
case MI_STRETCH: sample = SFX_POLICE_RADIO_LIMO; break;
|
||||||
#ifdef FIX_BUGS
|
|
||||||
case MI_CORPSE:
|
|
||||||
#endif
|
|
||||||
case MI_MANANA:
|
case MI_MANANA:
|
||||||
case MI_ESPERANT: sample = SFX_POLICE_RADIO_2_DOOR; break;
|
case MI_ESPERANT: sample = SFX_POLICE_RADIO_2_DOOR; break;
|
||||||
#ifdef FIX_BUGS
|
#ifdef FIX_BUGS
|
||||||
case MI_HOODS:
|
// case MI_HOODS:
|
||||||
color_pre_modifier = TOTAL_AUDIO_SAMPLES;
|
// color_pre_modifier = TOTAL_AUDIO_SAMPLES;
|
||||||
main_color = SFX_POLICE_RADIO_BLUE;
|
// main_color = SFX_POLICE_RADIO_BLUE;
|
||||||
color_post_modifier = SFX_POLICE_RADIO_GREEN;
|
// color_post_modifier = SFX_POLICE_RADIO_GREEN;
|
||||||
case MI_BELLYUP:
|
// case MI_BELLYUP:
|
||||||
case MI_YANKEE:
|
case MI_YANKEE:
|
||||||
case MI_TOYZ:
|
case MI_TOPFUN:
|
||||||
case MI_MRWONGS:
|
// case MI_MRWONGS:
|
||||||
case MI_PANLANT:
|
// case MI_PANLANT:
|
||||||
#endif
|
#endif
|
||||||
case MI_PONY:
|
case MI_PONY:
|
||||||
case MI_MULE:
|
case MI_MULE:
|
||||||
@ -613,7 +612,8 @@ cAudioManager::SetupSuspectLastSeenReport()
|
|||||||
case MI_AMBULAN: sample = SFX_POLICE_RADIO_AMBULANCE; break;
|
case MI_AMBULAN: sample = SFX_POLICE_RADIO_AMBULANCE; break;
|
||||||
case MI_TAXI:
|
case MI_TAXI:
|
||||||
case MI_CABBIE:
|
case MI_CABBIE:
|
||||||
case MI_BORGNINE: sample = SFX_POLICE_RADIO_TAXI; break;
|
case MI_ZEBRA: sample = SFX_POLICE_RADIO_TAXI; break;
|
||||||
|
case MI_KAUFMAN: sample = SFX_POLICE_RADIO_TAXI; break;
|
||||||
case MI_MRWHOOP:
|
case MI_MRWHOOP:
|
||||||
sample = SFX_POLICE_RADIO_ICE_CREAM_VAN;
|
sample = SFX_POLICE_RADIO_ICE_CREAM_VAN;
|
||||||
break;
|
break;
|
||||||
@ -622,7 +622,7 @@ cAudioManager::SetupSuspectLastSeenReport()
|
|||||||
#ifdef FIX_BUGS
|
#ifdef FIX_BUGS
|
||||||
case MI_SPEEDER:
|
case MI_SPEEDER:
|
||||||
case MI_REEFER:
|
case MI_REEFER:
|
||||||
case MI_GHOST:
|
// case MI_GHOST:
|
||||||
#endif
|
#endif
|
||||||
case MI_PREDATOR: sample = SFX_POLICE_RADIO_BOAT; break;
|
case MI_PREDATOR: sample = SFX_POLICE_RADIO_BOAT; break;
|
||||||
case MI_BUS:
|
case MI_BUS:
|
||||||
|
@ -302,9 +302,14 @@ CCarCtrl::GenerateOneRandomCar()
|
|||||||
case RICH:
|
case RICH:
|
||||||
case EXEC:
|
case EXEC:
|
||||||
case WORKER:
|
case WORKER:
|
||||||
case SPECIAL:
|
|
||||||
case BIG:
|
case BIG:
|
||||||
case TAXI:
|
case TAXI:
|
||||||
|
// TODO(MIAMI): check this
|
||||||
|
case MOPED:
|
||||||
|
case MOTORBIKE:
|
||||||
|
case LEISUREBOAT:
|
||||||
|
case WORKERBOAT:
|
||||||
|
//
|
||||||
case MAFIA:
|
case MAFIA:
|
||||||
case TRIAD:
|
case TRIAD:
|
||||||
case DIABLO:
|
case DIABLO:
|
||||||
@ -318,7 +323,7 @@ CCarCtrl::GenerateOneRandomCar()
|
|||||||
pCar->AutoPilot.m_nCruiseSpeed = CGeneral::GetRandomNumberInRange(9, 14);
|
pCar->AutoPilot.m_nCruiseSpeed = CGeneral::GetRandomNumberInRange(9, 14);
|
||||||
if (carClass == EXEC)
|
if (carClass == EXEC)
|
||||||
pCar->AutoPilot.m_nCruiseSpeed = CGeneral::GetRandomNumberInRange(12, 18);
|
pCar->AutoPilot.m_nCruiseSpeed = CGeneral::GetRandomNumberInRange(12, 18);
|
||||||
else if (carClass == POOR || carClass == SPECIAL)
|
else if (carClass == POOR)
|
||||||
pCar->AutoPilot.m_nCruiseSpeed = CGeneral::GetRandomNumberInRange(7, 10);
|
pCar->AutoPilot.m_nCruiseSpeed = CGeneral::GetRandomNumberInRange(7, 10);
|
||||||
CVehicleModelInfo* pVehicleInfo = pCar->GetModelInfo();
|
CVehicleModelInfo* pVehicleInfo = pCar->GetModelInfo();
|
||||||
if (pVehicleInfo->GetColModel()->boundingBox.max.y - pCar->GetModelInfo()->GetColModel()->boundingBox.min.y > 10.0f || carClass == BIG) {
|
if (pVehicleInfo->GetColModel()->boundingBox.max.y - pCar->GetModelInfo()->GetColModel()->boundingBox.min.y > 10.0f || carClass == BIG) {
|
||||||
@ -475,7 +480,12 @@ CCarCtrl::GenerateOneRandomCar()
|
|||||||
case RICH:
|
case RICH:
|
||||||
case EXEC:
|
case EXEC:
|
||||||
case WORKER:
|
case WORKER:
|
||||||
case SPECIAL:
|
// TODO(MIAMI): check this
|
||||||
|
case MOPED:
|
||||||
|
case MOTORBIKE:
|
||||||
|
case LEISUREBOAT:
|
||||||
|
case WORKERBOAT:
|
||||||
|
//
|
||||||
case BIG:
|
case BIG:
|
||||||
case TAXI:
|
case TAXI:
|
||||||
case MAFIA:
|
case MAFIA:
|
||||||
@ -550,16 +560,17 @@ CCarCtrl::ChooseModel(CZoneInfo* pZone, CVector* pPos, int* pClass) {
|
|||||||
int32 model = -1;
|
int32 model = -1;
|
||||||
while (model == -1 || !CStreaming::HasModelLoaded(model)){
|
while (model == -1 || !CStreaming::HasModelLoaded(model)){
|
||||||
int rnd = CGeneral::GetRandomNumberInRange(0, 1000);
|
int rnd = CGeneral::GetRandomNumberInRange(0, 1000);
|
||||||
|
// TODO(MIAMI): new car classes
|
||||||
if (rnd < pZone->carThreshold[0])
|
if (rnd < pZone->carThreshold[0])
|
||||||
model = CCarCtrl::ChooseCarModel((*pClass = POOR));
|
model = CCarCtrl::ChooseCarModel((*pClass = NORMAL));
|
||||||
else if (rnd < pZone->carThreshold[1])
|
else if (rnd < pZone->carThreshold[1])
|
||||||
model = CCarCtrl::ChooseCarModel((*pClass = RICH));
|
model = CCarCtrl::ChooseCarModel((*pClass = POOR));
|
||||||
else if (rnd < pZone->carThreshold[2])
|
else if (rnd < pZone->carThreshold[2])
|
||||||
model = CCarCtrl::ChooseCarModel((*pClass = EXEC));
|
model = CCarCtrl::ChooseCarModel((*pClass = RICH));
|
||||||
else if (rnd < pZone->carThreshold[3])
|
else if (rnd < pZone->carThreshold[3])
|
||||||
model = CCarCtrl::ChooseCarModel((*pClass = WORKER));
|
model = CCarCtrl::ChooseCarModel((*pClass = EXEC));
|
||||||
else if (rnd < pZone->carThreshold[4])
|
else if (rnd < pZone->carThreshold[4])
|
||||||
model = CCarCtrl::ChooseCarModel((*pClass = SPECIAL));
|
model = CCarCtrl::ChooseCarModel((*pClass = WORKER));
|
||||||
else if (rnd < pZone->carThreshold[5])
|
else if (rnd < pZone->carThreshold[5])
|
||||||
model = CCarCtrl::ChooseCarModel((*pClass = BIG));
|
model = CCarCtrl::ChooseCarModel((*pClass = BIG));
|
||||||
else if (rnd < pZone->copThreshold)
|
else if (rnd < pZone->copThreshold)
|
||||||
@ -597,7 +608,12 @@ CCarCtrl::ChooseCarModel(int32 vehclass)
|
|||||||
case RICH:
|
case RICH:
|
||||||
case EXEC:
|
case EXEC:
|
||||||
case WORKER:
|
case WORKER:
|
||||||
case SPECIAL:
|
// TODO(MIAMI): check this
|
||||||
|
case MOPED:
|
||||||
|
case MOTORBIKE:
|
||||||
|
case LEISUREBOAT:
|
||||||
|
case WORKERBOAT:
|
||||||
|
//
|
||||||
case BIG:
|
case BIG:
|
||||||
case TAXI:
|
case TAXI:
|
||||||
{
|
{
|
||||||
|
@ -23,14 +23,19 @@ enum{
|
|||||||
|
|
||||||
class CCarCtrl
|
class CCarCtrl
|
||||||
{
|
{
|
||||||
|
public:
|
||||||
enum eCarClass {
|
enum eCarClass {
|
||||||
POOR = 0,
|
NORMAL = 0,
|
||||||
|
POOR,
|
||||||
RICH,
|
RICH,
|
||||||
EXEC,
|
EXEC,
|
||||||
WORKER,
|
WORKER,
|
||||||
SPECIAL,
|
|
||||||
BIG,
|
BIG,
|
||||||
TAXI,
|
TAXI,
|
||||||
|
MOPED,
|
||||||
|
MOTORBIKE,
|
||||||
|
LEISUREBOAT,
|
||||||
|
WORKERBOAT,
|
||||||
TOTAL_CUSTOM_CLASSES,
|
TOTAL_CUSTOM_CLASSES,
|
||||||
MAFIA,
|
MAFIA,
|
||||||
TRIAD,
|
TRIAD,
|
||||||
@ -43,7 +48,7 @@ class CCarCtrl
|
|||||||
GANG9,
|
GANG9,
|
||||||
COPS
|
COPS
|
||||||
};
|
};
|
||||||
public:
|
|
||||||
static void SwitchVehicleToRealPhysics(CVehicle*);
|
static void SwitchVehicleToRealPhysics(CVehicle*);
|
||||||
static void AddToCarArray(int32 id, int32 vehclass);
|
static void AddToCarArray(int32 id, int32 vehclass);
|
||||||
static void UpdateCarCount(CVehicle*, bool);
|
static void UpdateCarCount(CVehicle*, bool);
|
||||||
|
@ -106,8 +106,9 @@
|
|||||||
|
|
||||||
const int32 gaCarsToCollectInCraigsGarages[TOTAL_COLLECTCARS_GARAGES][TOTAL_COLLECTCARS_CARS] =
|
const int32 gaCarsToCollectInCraigsGarages[TOTAL_COLLECTCARS_GARAGES][TOTAL_COLLECTCARS_CARS] =
|
||||||
{
|
{
|
||||||
{ MI_SECURICA, MI_MOONBEAM, MI_COACH, MI_FLATBED, MI_LINERUN, MI_TRASH, MI_PATRIOT, MI_MRWHOOP, MI_BLISTA, MI_MULE, MI_YANKEE, MI_BOBCAT, MI_DODO, MI_BUS, MI_RUMPO, MI_PONY },
|
// TODO(MIAMI): bogus
|
||||||
{ MI_SENTINEL, MI_CHEETAH, MI_BANSHEE, MI_IDAHO, MI_INFERNUS, MI_TAXI, MI_KURUMA, MI_STRETCH, MI_PEREN, MI_STINGER, MI_MANANA, MI_LANDSTAL, MI_STALLION, MI_BFINJECT, MI_CABBIE, MI_ESPERANT },
|
{ MI_SECURICA, MI_MOONBEAM, MI_COACH, MI_FLATBED, MI_LINERUN, MI_TRASH, MI_PATRIOT, MI_MRWHOOP, MI_BLISTAC, MI_MULE, MI_YANKEE, MI_BOBCAT, MI_DODO, MI_BUS, MI_RUMPO, MI_PONY },
|
||||||
|
{ MI_SENTINEL, MI_CHEETAH, MI_BANSHEE, MI_IDAHO, MI_INFERNUS, MI_TAXI, MI_WASHING, MI_STRETCH, MI_PEREN, MI_STINGER, MI_MANANA, MI_LANDSTAL, MI_STALLION, MI_BFINJECT, MI_CABBIE, MI_ESPERANT },
|
||||||
{ MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_CHEETAH, MI_TAXI, MI_ESPERANT, MI_SENTINEL, MI_IDAHO }
|
{ MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_LANDSTAL, MI_CHEETAH, MI_TAXI, MI_ESPERANT, MI_SENTINEL, MI_IDAHO }
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -1612,8 +1613,6 @@ bool CGarages::HasThisCarBeenCollected(int16 garage, uint8 id)
|
|||||||
|
|
||||||
bool CGarage::DoesCraigNeedThisCar(int32 mi)
|
bool CGarage::DoesCraigNeedThisCar(int32 mi)
|
||||||
{
|
{
|
||||||
if (mi == MI_CORPSE)
|
|
||||||
mi = MI_MANANA;
|
|
||||||
int ct = CGarages::GetCarsCollectedIndexForGarageType(m_eGarageType);
|
int ct = CGarages::GetCarsCollectedIndexForGarageType(m_eGarageType);
|
||||||
for (int i = 0; i < TOTAL_COLLECTCARS_CARS; i++) {
|
for (int i = 0; i < TOTAL_COLLECTCARS_CARS; i++) {
|
||||||
if (mi == gaCarsToCollectInCraigsGarages[ct][i])
|
if (mi == gaCarsToCollectInCraigsGarages[ct][i])
|
||||||
@ -1624,8 +1623,6 @@ bool CGarage::DoesCraigNeedThisCar(int32 mi)
|
|||||||
|
|
||||||
bool CGarage::HasCraigCollectedThisCar(int32 mi)
|
bool CGarage::HasCraigCollectedThisCar(int32 mi)
|
||||||
{
|
{
|
||||||
if (mi == MI_CORPSE)
|
|
||||||
mi = MI_MANANA;
|
|
||||||
int ct = CGarages::GetCarsCollectedIndexForGarageType(m_eGarageType);
|
int ct = CGarages::GetCarsCollectedIndexForGarageType(m_eGarageType);
|
||||||
for (int i = 0; i < TOTAL_COLLECTCARS_CARS; i++) {
|
for (int i = 0; i < TOTAL_COLLECTCARS_CARS; i++) {
|
||||||
if (mi == gaCarsToCollectInCraigsGarages[ct][i])
|
if (mi == gaCarsToCollectInCraigsGarages[ct][i])
|
||||||
@ -1636,8 +1633,6 @@ bool CGarage::HasCraigCollectedThisCar(int32 mi)
|
|||||||
|
|
||||||
bool CGarage::MarkThisCarAsCollectedForCraig(int32 mi)
|
bool CGarage::MarkThisCarAsCollectedForCraig(int32 mi)
|
||||||
{
|
{
|
||||||
if (mi == MI_CORPSE)
|
|
||||||
mi = MI_MANANA;
|
|
||||||
int ct = CGarages::GetCarsCollectedIndexForGarageType(m_eGarageType);
|
int ct = CGarages::GetCarsCollectedIndexForGarageType(m_eGarageType);
|
||||||
int index;
|
int index;
|
||||||
for (index = 0; index < TOTAL_COLLECTCARS_CARS; index++) {
|
for (index = 0; index < TOTAL_COLLECTCARS_CARS; index++) {
|
||||||
|
@ -835,13 +835,14 @@ bool CReplay::PlayBackThisFrameInterpolation(CAddressInReplayBuffer *buffer, flo
|
|||||||
CStreaming::RequestModel(mi, 0);
|
CStreaming::RequestModel(mi, 0);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
// TODO(MIAMI): don't hardcode model indices
|
||||||
if (mi == MI_DEADDODO || mi == MI_AIRTRAIN) {
|
if (mi == MI_DEADDODO || mi == MI_AIRTRAIN) {
|
||||||
new_v = new(vp->index << 8) CPlane(mi, 2);
|
new_v = new(vp->index << 8) CPlane(mi, 2);
|
||||||
}
|
}
|
||||||
else if (mi == MI_TRAIN) {
|
else if (mi == MI_TRAIN) {
|
||||||
new_v = new(vp->index << 8) CTrain(mi, 2);
|
new_v = new(vp->index << 8) CTrain(mi, 2);
|
||||||
}
|
}
|
||||||
else if (mi == MI_CHOPPER || mi == MI_ESCAPE) {
|
else if (mi == MI_CHOPPER) {
|
||||||
new_v = new(vp->index << 8) CHeli(mi, 2);
|
new_v = new(vp->index << 8) CHeli(mi, 2);
|
||||||
}
|
}
|
||||||
else if (CModelInfo::IsBoatModel(mi)){
|
else if (CModelInfo::IsBoatModel(mi)){
|
||||||
|
@ -5346,8 +5346,7 @@ int8 CRunningScript::ProcessCommands600To699(int32 command)
|
|||||||
CollectParameters(&m_nIp, 1);
|
CollectParameters(&m_nIp, 1);
|
||||||
CVehicle* pVehicle = CPools::GetVehiclePool()->GetAt(ScriptParams[0]);
|
CVehicle* pVehicle = CPools::GetVehiclePool()->GetAt(ScriptParams[0]);
|
||||||
assert(pVehicle);
|
assert(pVehicle);
|
||||||
int mi = pVehicle->GetModelIndex();
|
UpdateCompareFlag(pVehicle->IsTaxi());
|
||||||
UpdateCompareFlag(mi == MI_TAXI || mi == MI_CABBIE || mi == MI_BORGNINE);
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
case COMMAND_UNLOAD_SPECIAL_CHARACTER:
|
case COMMAND_UNLOAD_SPECIAL_CHARACTER:
|
||||||
@ -8159,7 +8158,7 @@ int8 CRunningScript::ProcessCommands900To999(int32 command)
|
|||||||
case MI_FBICAR:
|
case MI_FBICAR:
|
||||||
case MI_MRWHOOP:
|
case MI_MRWHOOP:
|
||||||
case MI_BFINJECT:
|
case MI_BFINJECT:
|
||||||
case MI_CORPSE:
|
// case MI_CORPSE:
|
||||||
case MI_POLICE:
|
case MI_POLICE:
|
||||||
case MI_ENFORCER:
|
case MI_ENFORCER:
|
||||||
case MI_SECURICA:
|
case MI_SECURICA:
|
||||||
@ -8172,27 +8171,27 @@ int8 CRunningScript::ProcessCommands900To999(int32 command)
|
|||||||
case MI_DODO:
|
case MI_DODO:
|
||||||
case MI_COACH:
|
case MI_COACH:
|
||||||
case MI_RCBANDIT:
|
case MI_RCBANDIT:
|
||||||
case MI_BELLYUP:
|
// case MI_BELLYUP:
|
||||||
case MI_MRWONGS:
|
// case MI_MRWONGS:
|
||||||
case MI_MAFIA:
|
// case MI_MAFIA:
|
||||||
case MI_YARDIE:
|
case MI_VOODOO:
|
||||||
case MI_YAKUZA:
|
// case MI_YAKUZA:
|
||||||
case MI_DIABLOS:
|
// case MI_DIABLOS:
|
||||||
case MI_COLUMB:
|
// case MI_COLUMB:
|
||||||
case MI_HOODS:
|
// case MI_HOODS:
|
||||||
case MI_AIRTRAIN:
|
case MI_AIRTRAIN:
|
||||||
case MI_DEADDODO:
|
case MI_DEADDODO:
|
||||||
case MI_SPEEDER:
|
case MI_SPEEDER:
|
||||||
case MI_REEFER:
|
case MI_REEFER:
|
||||||
case MI_PANLANT:
|
// case MI_PANLANT:
|
||||||
case MI_FLATBED:
|
case MI_FLATBED:
|
||||||
case MI_YANKEE:
|
case MI_YANKEE:
|
||||||
case MI_ESCAPE:
|
// case MI_ESCAPE:
|
||||||
case MI_BORGNINE:
|
case MI_ZEBRA:
|
||||||
case MI_TOYZ:
|
case MI_TOPFUN:
|
||||||
case MI_GHOST:
|
// case MI_GHOST:
|
||||||
case MI_MIAMI_RCBARON:
|
case MI_RCBARON:
|
||||||
case MI_MIAMI_RCRAIDER:
|
case MI_RCRAIDER:
|
||||||
model = -1;
|
model = -1;
|
||||||
break;
|
break;
|
||||||
case MI_IDAHO:
|
case MI_IDAHO:
|
||||||
@ -8202,13 +8201,13 @@ int8 CRunningScript::ProcessCommands900To999(int32 command)
|
|||||||
case MI_PATRIOT:
|
case MI_PATRIOT:
|
||||||
case MI_MANANA:
|
case MI_MANANA:
|
||||||
case MI_INFERNUS:
|
case MI_INFERNUS:
|
||||||
case MI_BLISTA:
|
// case MI_BLISTA:
|
||||||
case MI_PONY:
|
case MI_PONY:
|
||||||
case MI_CHEETAH:
|
case MI_CHEETAH:
|
||||||
case MI_MOONBEAM:
|
case MI_MOONBEAM:
|
||||||
case MI_ESPERANT:
|
case MI_ESPERANT:
|
||||||
case MI_TAXI:
|
case MI_TAXI:
|
||||||
case MI_KURUMA:
|
case MI_WASHING:
|
||||||
case MI_BOBCAT:
|
case MI_BOBCAT:
|
||||||
case MI_BANSHEE:
|
case MI_BANSHEE:
|
||||||
case MI_CABBIE:
|
case MI_CABBIE:
|
||||||
|
@ -4907,7 +4907,7 @@ CCam::Process_FollowCar_SA(const CVector& CameraTarget, float TargetOrientation,
|
|||||||
|
|
||||||
bool correctAlpha = true;
|
bool correctAlpha = true;
|
||||||
// if (SA checks if we aren't in work car, why?) {
|
// if (SA checks if we aren't in work car, why?) {
|
||||||
if (!isCar || car->GetModelIndex() != MI_YARDIE) {
|
if (!isCar || car->GetModelIndex() != MI_VOODOO) {
|
||||||
correctAlpha = false;
|
correctAlpha = false;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -781,21 +781,22 @@ CFileLoader::LoadVehicleObject(const char *line)
|
|||||||
{
|
{
|
||||||
int id;
|
int id;
|
||||||
char model[24], txd[24];
|
char model[24], txd[24];
|
||||||
char type[8], handlingId[16], gamename[32], vehclass[12];
|
char type[8], handlingId[16], gamename[32], anims[16], vehclass[12];
|
||||||
uint32 frequency, comprules;
|
uint32 frequency, comprules;
|
||||||
int32 level, misc;
|
int32 level, misc;
|
||||||
float wheelScale;
|
float wheelScale;
|
||||||
CVehicleModelInfo *mi;
|
CVehicleModelInfo *mi;
|
||||||
char *p;
|
char *p;
|
||||||
|
|
||||||
sscanf(line, "%d %s %s %s %s %s %s %d %d %x %d %f",
|
sscanf(line, "%d %s %s %s %s %s %s %s %d %d %x %d %f",
|
||||||
&id, model, txd,
|
&id, model, txd,
|
||||||
type, handlingId, gamename, vehclass,
|
type, handlingId, gamename, anims, vehclass,
|
||||||
&frequency, &level, &comprules, &misc, &wheelScale);
|
&frequency, &level, &comprules, &misc, &wheelScale);
|
||||||
|
|
||||||
mi = CModelInfo::AddVehicleModel(id);
|
mi = CModelInfo::AddVehicleModel(id);
|
||||||
mi->SetName(model);
|
mi->SetName(model);
|
||||||
mi->SetTexDictionary(txd);
|
mi->SetTexDictionary(txd);
|
||||||
|
// TODO(MIAMI): anims
|
||||||
for(p = gamename; *p; p++)
|
for(p = gamename; *p; p++)
|
||||||
if(*p == '_') *p = ' ';
|
if(*p == '_') *p = ' ';
|
||||||
strncpy(mi->m_gameName, gamename, 32);
|
strncpy(mi->m_gameName, gamename, 32);
|
||||||
@ -826,34 +827,52 @@ CFileLoader::LoadVehicleObject(const char *line)
|
|||||||
mi->m_handlingId = mod_HandlingManager.GetHandlingId(handlingId);
|
mi->m_handlingId = mod_HandlingManager.GetHandlingId(handlingId);
|
||||||
|
|
||||||
// Well this is kinda dumb....
|
// Well this is kinda dumb....
|
||||||
if(strncmp(vehclass, "poorfamily", 11) == 0){
|
if(strncmp(vehclass, "normal", 7) == 0){
|
||||||
mi->m_vehicleClass = VEHICLE_CLASS_POOR;
|
mi->m_vehicleClass = CCarCtrl::NORMAL;
|
||||||
while(frequency-- > 0)
|
while(frequency-- > 0)
|
||||||
CCarCtrl::AddToCarArray(id, VEHICLE_CLASS_POOR);
|
CCarCtrl::AddToCarArray(id, CCarCtrl::NORMAL);
|
||||||
|
}else if(strncmp(vehclass, "poorfamily", 11) == 0){
|
||||||
|
mi->m_vehicleClass = CCarCtrl::POOR;
|
||||||
|
while(frequency-- > 0)
|
||||||
|
CCarCtrl::AddToCarArray(id, CCarCtrl::POOR);
|
||||||
}else if(strncmp(vehclass, "richfamily", 11) == 0){
|
}else if(strncmp(vehclass, "richfamily", 11) == 0){
|
||||||
mi->m_vehicleClass = VEHICLE_CLASS_RICH;
|
mi->m_vehicleClass = CCarCtrl::RICH;
|
||||||
while(frequency-- > 0)
|
while(frequency-- > 0)
|
||||||
CCarCtrl::AddToCarArray(id, VEHICLE_CLASS_RICH);
|
CCarCtrl::AddToCarArray(id, CCarCtrl::RICH);
|
||||||
}else if(strncmp(vehclass, "executive", 10) == 0){
|
}else if(strncmp(vehclass, "executive", 10) == 0){
|
||||||
mi->m_vehicleClass = VEHICLE_CLASS_EXECUTIVE;
|
mi->m_vehicleClass = CCarCtrl::EXEC;
|
||||||
while(frequency-- > 0)
|
while(frequency-- > 0)
|
||||||
CCarCtrl::AddToCarArray(id, VEHICLE_CLASS_EXECUTIVE);
|
CCarCtrl::AddToCarArray(id, CCarCtrl::EXEC);
|
||||||
}else if(strncmp(vehclass, "worker", 7) == 0){
|
}else if(strncmp(vehclass, "worker", 7) == 0){
|
||||||
mi->m_vehicleClass = VEHICLE_CLASS_WORKER;
|
mi->m_vehicleClass = CCarCtrl::WORKER;
|
||||||
while(frequency-- > 0)
|
while(frequency-- > 0)
|
||||||
CCarCtrl::AddToCarArray(id, VEHICLE_CLASS_WORKER);
|
CCarCtrl::AddToCarArray(id, CCarCtrl::WORKER);
|
||||||
}else if(strncmp(vehclass, "special", 8) == 0){
|
|
||||||
mi->m_vehicleClass = VEHICLE_CLASS_SPECIAL;
|
|
||||||
while(frequency-- > 0)
|
|
||||||
CCarCtrl::AddToCarArray(id, VEHICLE_CLASS_SPECIAL);
|
|
||||||
}else if(strncmp(vehclass, "big", 4) == 0){
|
}else if(strncmp(vehclass, "big", 4) == 0){
|
||||||
mi->m_vehicleClass = VEHICLE_CLASS_BIG;
|
mi->m_vehicleClass = CCarCtrl::BIG;
|
||||||
while(frequency-- > 0)
|
while(frequency-- > 0)
|
||||||
CCarCtrl::AddToCarArray(id, VEHICLE_CLASS_BIG);
|
CCarCtrl::AddToCarArray(id, CCarCtrl::BIG);
|
||||||
}else if(strncmp(vehclass, "taxi", 5) == 0){
|
}else if(strncmp(vehclass, "taxi", 5) == 0){
|
||||||
mi->m_vehicleClass = VEHICLE_CLASS_TAXI;
|
mi->m_vehicleClass = CCarCtrl::TAXI;
|
||||||
while(frequency-- > 0)
|
while(frequency-- > 0)
|
||||||
CCarCtrl::AddToCarArray(id, VEHICLE_CLASS_TAXI);
|
CCarCtrl::AddToCarArray(id, CCarCtrl::TAXI);
|
||||||
|
}else if(strncmp(vehclass, "moped", 6) == 0){
|
||||||
|
mi->m_vehicleClass = CCarCtrl::MOPED;
|
||||||
|
while(frequency-- > 0)
|
||||||
|
CCarCtrl::AddToCarArray(id, CCarCtrl::MOPED);
|
||||||
|
}else if(strncmp(vehclass, "motorbike", 10) == 0){
|
||||||
|
mi->m_vehicleClass = CCarCtrl::MOTORBIKE;
|
||||||
|
while(frequency-- > 0)
|
||||||
|
CCarCtrl::AddToCarArray(id, CCarCtrl::MOTORBIKE);
|
||||||
|
}else if(strncmp(vehclass, "leisureboat", 12) == 0){
|
||||||
|
mi->m_vehicleClass = CCarCtrl::LEISUREBOAT;
|
||||||
|
while(frequency-- > 0)
|
||||||
|
CCarCtrl::AddToCarArray(id, CCarCtrl::LEISUREBOAT);
|
||||||
|
}else if(strncmp(vehclass, "workerboat", 11) == 0){
|
||||||
|
mi->m_vehicleClass = CCarCtrl::WORKERBOAT;
|
||||||
|
while(frequency-- > 0)
|
||||||
|
CCarCtrl::AddToCarArray(id, CCarCtrl::WORKERBOAT);
|
||||||
|
}else if(strncmp(vehclass, "ignore", 11) == 0){
|
||||||
|
mi->m_vehicleClass = -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -354,7 +354,7 @@ CPlayerInfo::Process(void)
|
|||||||
bool startTaxiTimer = true;
|
bool startTaxiTimer = true;
|
||||||
if (m_bUnusedTaxiThing && m_pPed->bInVehicle) {
|
if (m_bUnusedTaxiThing && m_pPed->bInVehicle) {
|
||||||
CVehicle *veh = m_pPed->m_pMyVehicle;
|
CVehicle *veh = m_pPed->m_pMyVehicle;
|
||||||
if ((veh->GetModelIndex() == MI_TAXI || veh->GetModelIndex() == MI_CABBIE || veh->GetModelIndex() == MI_BORGNINE)
|
if (veh->IsTaxi()
|
||||||
&& veh->pDriver == m_pPed && veh->m_nNumPassengers != 0) {
|
&& veh->pDriver == m_pPed && veh->m_nNumPassengers != 0) {
|
||||||
for (uint32 timePassed = CTimer::GetTimeInMilliseconds() - m_nUnusedTaxiTimer; timePassed >= 1000; m_nUnusedTaxiTimer += 1000) {
|
for (uint32 timePassed = CTimer::GetTimeInMilliseconds() - m_nUnusedTaxiTimer; timePassed >= 1000; m_nUnusedTaxiTimer += 1000) {
|
||||||
timePassed -= 1000;
|
timePassed -= 1000;
|
||||||
|
@ -1285,8 +1285,11 @@ CStreaming::StreamVehiclesAndPeds(void)
|
|||||||
else if(ms_numVehiclesLoaded <= desiredNumVehiclesLoaded){
|
else if(ms_numVehiclesLoaded <= desiredNumVehiclesLoaded){
|
||||||
for(i = 1; i <= 10; i++){
|
for(i = 1; i <= 10; i++){
|
||||||
model = CCarCtrl::ChooseCarModel(modelQualityClass);
|
model = CCarCtrl::ChooseCarModel(modelQualityClass);
|
||||||
|
// TODO(MIAMI): check this
|
||||||
|
if(model < 0)
|
||||||
|
continue;
|
||||||
modelQualityClass++;
|
modelQualityClass++;
|
||||||
if(modelQualityClass >= NUM_VEHICLE_CLASSES)
|
if(modelQualityClass >= CCarCtrl::TOTAL_CUSTOM_CLASSES)
|
||||||
modelQualityClass = 0;
|
modelQualityClass = 0;
|
||||||
|
|
||||||
// check if we want to load this model
|
// check if we want to load this model
|
||||||
@ -1374,6 +1377,10 @@ CStreaming::StreamZoneModels(const CVector &pos)
|
|||||||
ms_loadedGangs &= ~bit;
|
ms_loadedGangs &= ~bit;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO(MIAMI): check this
|
||||||
|
if(CGangs::GetGangInfo(i)->m_nVehicleMI < 0)
|
||||||
|
continue;
|
||||||
|
|
||||||
if(gangCarsToLoad & bit && (ms_loadedGangCars & bit) == 0){
|
if(gangCarsToLoad & bit && (ms_loadedGangCars & bit) == 0){
|
||||||
RequestModel(CGangs::GetGangInfo(i)->m_nVehicleMI, STREAMFLAGS_DONT_REMOVE);
|
RequestModel(CGangs::GetGangInfo(i)->m_nVehicleMI, STREAMFLAGS_DONT_REMOVE);
|
||||||
}else if((gangCarsToLoad & bit) == 0 && ms_loadedGangCars & bit){
|
}else if((gangCarsToLoad & bit) == 0 && ms_loadedGangCars & bit){
|
||||||
|
@ -61,7 +61,7 @@ enum Config {
|
|||||||
// Cull zones
|
// Cull zones
|
||||||
NUMATTRIBZONES = 704,
|
NUMATTRIBZONES = 704,
|
||||||
|
|
||||||
NUMHANDLINGS = 57,
|
NUMHANDLINGS = 106,
|
||||||
|
|
||||||
PATHNODESIZE = 4500,
|
PATHNODESIZE = 4500,
|
||||||
|
|
||||||
|
@ -193,11 +193,17 @@ ResetCamStatics(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static const char *carnames[] = {
|
static const char *carnames[] = {
|
||||||
"landstal", "idaho", "stinger", "linerun", "peren", "sentinel", "patriot", "firetruk", "trash", "stretch", "manana", "infernus", "blista", "pony",
|
"landstal", "idaho", "stinger", "linerun", "peren", "sentinel" "rio", "firetruk", "trash", "stretch", "manana",
|
||||||
"mule", "cheetah", "ambulan", "fbicar", "moonbeam", "esperant", "taxi", "kuruma", "bobcat", "mrwhoop", "bfinject", "corpse", "police", "enforcer",
|
"infernus", "voodoo", "pony", "mule", "cheetah", "ambulan", "fbicar", "moonbeam", "esperant", "taxi", "washing",
|
||||||
"securica", "banshee", "predator", "bus", "rhino", "barracks", "train", "chopper", "dodo", "coach", "cabbie", "stallion", "rumpo", "rcbandit",
|
"bobcat", "mrwhoop", "bfinject", "hunter", "police", "enforcer", "securica", "banshee", "predator", "bus",
|
||||||
"bellyup", "mrwongs", "mafia", "yardie", "yakuza", "diablos", "columb", "hoods", "airtrain", "deaddodo", "speeder", "reefer", "panlant", "flatbed",
|
"rhino", "barracks", "cuban", "chopper", "angel", "coach", "cabbie", "stallion", "rumpo", "rcbandit", "romero",
|
||||||
"yankee", "escape", "borgnine", "toyz", "ghost",
|
"packer", "sentxs", "admiral", "squalo", "seaspar", "pizzaboy", "gangbur", "airtrain", "deaddodo", "speeder",
|
||||||
|
"reefer", "tropic", "flatbed", "yankee", "caddy", "zebra", "topfun", "skimmer", "pcj600", "faggio", "freeway",
|
||||||
|
"rcbaron", "rcraider", "glendale", "oceanic", "sanchez", "sparrow", "patriot", "lovefist", "coastg", "dinghy",
|
||||||
|
"hermes", "sabre", "sabretur", "pheonix", "walton", "regina", "comet", "deluxo", "burrito", "spand", "marquis",
|
||||||
|
"baggage", "kaufman", "maverick", "vcnmav", "rancher", "fbiranch", "virgo", "greenwoo", "jetmax", "hotring",
|
||||||
|
"sandking", "blistac", "polmav", "boxville", "benson", "mesa", "rcgoblin", "hotrina", "hotrinb",
|
||||||
|
"bloodra", "bloodrb", "vicechee",
|
||||||
};
|
};
|
||||||
|
|
||||||
static std::list<CTweakVar *> TweakVarsList;
|
static std::list<CTweakVar *> TweakVarsList;
|
||||||
@ -292,14 +298,12 @@ DebugMenuPopulate(void)
|
|||||||
DebugMenuAddCmd("Cheats", "Nasty limbs", NastyLimbsCheat);
|
DebugMenuAddCmd("Cheats", "Nasty limbs", NastyLimbsCheat);
|
||||||
|
|
||||||
static int spawnCarId = MI_LANDSTAL;
|
static int spawnCarId = MI_LANDSTAL;
|
||||||
e = DebugMenuAddVar("Spawn", "Spawn Car ID", &spawnCarId, nil, 1, MI_LANDSTAL, MI_GHOST, carnames);
|
e = DebugMenuAddVar("Spawn", "Spawn Car ID", &spawnCarId, nil, 1, MI_LANDSTAL, MI_VICECHEE, carnames);
|
||||||
DebugMenuEntrySetWrap(e, true);
|
DebugMenuEntrySetWrap(e, true);
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Car", [](){
|
DebugMenuAddCmd("Spawn", "Spawn Car", [](){
|
||||||
if(spawnCarId == MI_TRAIN ||
|
if(spawnCarId == MI_CHOPPER ||
|
||||||
spawnCarId == MI_CHOPPER ||
|
|
||||||
spawnCarId == MI_AIRTRAIN ||
|
spawnCarId == MI_AIRTRAIN ||
|
||||||
spawnCarId == MI_DEADDODO ||
|
spawnCarId == MI_DEADDODO)
|
||||||
spawnCarId == MI_ESCAPE)
|
|
||||||
return;
|
return;
|
||||||
SpawnCar(spawnCarId);
|
SpawnCar(spawnCarId);
|
||||||
});
|
});
|
||||||
@ -311,13 +315,13 @@ DebugMenuPopulate(void)
|
|||||||
DebugMenuAddCmd("Spawn", "Spawn Cheetah", [](){ SpawnCar(MI_CHEETAH); });
|
DebugMenuAddCmd("Spawn", "Spawn Cheetah", [](){ SpawnCar(MI_CHEETAH); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Esperanto", [](){ SpawnCar(MI_ESPERANT); });
|
DebugMenuAddCmd("Spawn", "Spawn Esperanto", [](){ SpawnCar(MI_ESPERANT); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Stallion", [](){ SpawnCar(MI_STALLION); });
|
DebugMenuAddCmd("Spawn", "Spawn Stallion", [](){ SpawnCar(MI_STALLION); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Kuruma", [](){ SpawnCar(MI_KURUMA); });
|
DebugMenuAddCmd("Spawn", "Spawn Washington", [](){ SpawnCar(MI_WASHING); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Taxi", [](){ SpawnCar(MI_TAXI); });
|
DebugMenuAddCmd("Spawn", "Spawn Taxi", [](){ SpawnCar(MI_TAXI); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Police", [](){ SpawnCar(MI_POLICE); });
|
DebugMenuAddCmd("Spawn", "Spawn Police", [](){ SpawnCar(MI_POLICE); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Enforcer", [](){ SpawnCar(MI_ENFORCER); });
|
DebugMenuAddCmd("Spawn", "Spawn Enforcer", [](){ SpawnCar(MI_ENFORCER); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Banshee", [](){ SpawnCar(MI_BANSHEE); });
|
DebugMenuAddCmd("Spawn", "Spawn Banshee", [](){ SpawnCar(MI_BANSHEE); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Yakuza", [](){ SpawnCar(MI_YAKUZA); });
|
DebugMenuAddCmd("Spawn", "Spawn Cuban", [](){ SpawnCar(MI_CUBAN); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Yardie", [](){ SpawnCar(MI_YARDIE); });
|
DebugMenuAddCmd("Spawn", "Spawn Voodoo", [](){ SpawnCar(MI_VOODOO); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Dodo", [](){ SpawnCar(MI_DODO); });
|
DebugMenuAddCmd("Spawn", "Spawn Dodo", [](){ SpawnCar(MI_DODO); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Rhino", [](){ SpawnCar(MI_RHINO); });
|
DebugMenuAddCmd("Spawn", "Spawn Rhino", [](){ SpawnCar(MI_RHINO); });
|
||||||
DebugMenuAddCmd("Spawn", "Spawn Firetruck", [](){ SpawnCar(MI_FIRETRUCK); });
|
DebugMenuAddCmd("Spawn", "Spawn Firetruck", [](){ SpawnCar(MI_FIRETRUCK); });
|
||||||
|
@ -1528,7 +1528,8 @@ CPhysical::ProcessCollisionSectorList(CPtrList *lists)
|
|||||||
|
|
||||||
if(A->GetModelIndex() == MI_RCBANDIT)
|
if(A->GetModelIndex() == MI_RCBANDIT)
|
||||||
adhesion *= 0.2f;
|
adhesion *= 0.2f;
|
||||||
else if(IsBoatModel(A->GetModelIndex())){
|
// TODO(MIAMI): check this
|
||||||
|
else if(A->IsVehicle() && ((CVehicle*)A)->IsBoat()){
|
||||||
if(aColPoints[i].normal.z > 0.6f){
|
if(aColPoints[i].normal.z > 0.6f){
|
||||||
if(CSurfaceTable::GetAdhesionGroup(aColPoints[i].surfaceB) == ADHESIVE_LOOSE)
|
if(CSurfaceTable::GetAdhesionGroup(aColPoints[i].surfaceB) == ADHESIVE_LOOSE)
|
||||||
adhesion *= 3.0f;
|
adhesion *= 3.0f;
|
||||||
|
@ -257,19 +257,20 @@ enum
|
|||||||
MI_BUSKER4,
|
MI_BUSKER4,
|
||||||
// three more peds possible
|
// three more peds possible
|
||||||
|
|
||||||
MI_LANDSTAL = 130,
|
MI_FIRST_VEHICLE = 130,
|
||||||
|
MI_LANDSTAL = MI_FIRST_VEHICLE,
|
||||||
MI_IDAHO,
|
MI_IDAHO,
|
||||||
MI_STINGER,
|
MI_STINGER,
|
||||||
MI_LINERUN,
|
MI_LINERUN,
|
||||||
MI_PEREN,
|
MI_PEREN,
|
||||||
MI_SENTINEL,
|
MI_SENTINEL,
|
||||||
MI_PATRIOT,
|
MI_RIO,
|
||||||
MI_FIRETRUCK,
|
MI_FIRETRUCK,
|
||||||
MI_TRASH,
|
MI_TRASH,
|
||||||
MI_STRETCH,
|
MI_STRETCH,
|
||||||
MI_MANANA,
|
MI_MANANA,
|
||||||
MI_INFERNUS,
|
MI_INFERNUS,
|
||||||
MI_BLISTA,
|
MI_VOODOO,
|
||||||
MI_PONY,
|
MI_PONY,
|
||||||
MI_MULE,
|
MI_MULE,
|
||||||
MI_CHEETAH,
|
MI_CHEETAH,
|
||||||
@ -278,11 +279,11 @@ enum
|
|||||||
MI_MOONBEAM,
|
MI_MOONBEAM,
|
||||||
MI_ESPERANT,
|
MI_ESPERANT,
|
||||||
MI_TAXI,
|
MI_TAXI,
|
||||||
MI_KURUMA,
|
MI_WASHING,
|
||||||
MI_BOBCAT,
|
MI_BOBCAT,
|
||||||
MI_MRWHOOP,
|
MI_MRWHOOP,
|
||||||
MI_BFINJECT,
|
MI_BFINJECT,
|
||||||
MI_CORPSE,
|
MI_HUNTER,
|
||||||
MI_POLICE,
|
MI_POLICE,
|
||||||
MI_ENFORCER,
|
MI_ENFORCER,
|
||||||
MI_SECURICA,
|
MI_SECURICA,
|
||||||
@ -291,38 +292,82 @@ enum
|
|||||||
MI_BUS,
|
MI_BUS,
|
||||||
MI_RHINO,
|
MI_RHINO,
|
||||||
MI_BARRACKS,
|
MI_BARRACKS,
|
||||||
MI_TRAIN,
|
MI_CUBAN,
|
||||||
MI_CHOPPER,
|
MI_CHOPPER,
|
||||||
MI_DODO,
|
MI_ANGEL,
|
||||||
MI_COACH,
|
MI_COACH,
|
||||||
MI_CABBIE,
|
MI_CABBIE,
|
||||||
MI_STALLION,
|
MI_STALLION,
|
||||||
MI_RUMPO,
|
MI_RUMPO,
|
||||||
MI_RCBANDIT,
|
MI_RCBANDIT,
|
||||||
MI_BELLYUP,
|
MI_ROMERO,
|
||||||
MI_MRWONGS,
|
MI_PACKER,
|
||||||
MI_MAFIA,
|
MI_SENTXS,
|
||||||
MI_YARDIE,
|
MI_ADMIRAL,
|
||||||
MI_YAKUZA,
|
MI_SQUALO,
|
||||||
MI_DIABLOS,
|
MI_SEASPAR,
|
||||||
MI_COLUMB ,
|
MI_PIZZABOY,
|
||||||
MI_HOODS,
|
MI_GANGBUR,
|
||||||
MI_AIRTRAIN,
|
MI_AIRTRAIN,
|
||||||
MI_DEADDODO,
|
MI_DEADDODO,
|
||||||
MI_SPEEDER,
|
MI_SPEEDER,
|
||||||
MI_REEFER,
|
MI_REEFER,
|
||||||
MI_PANLANT,
|
MI_TROPIC,
|
||||||
MI_FLATBED,
|
MI_FLATBED,
|
||||||
MI_YANKEE,
|
MI_YANKEE,
|
||||||
MI_ESCAPE,
|
MI_CADDY,
|
||||||
MI_BORGNINE,
|
MI_ZEBRA,
|
||||||
MI_TOYZ,
|
MI_TOPFUN,
|
||||||
MI_GHOST,
|
MI_SKIMMER,
|
||||||
|
MI_PCJ600,
|
||||||
// leftovers on PC
|
MI_FAGGIO,
|
||||||
MI_MIAMI_RCBARON = 194,
|
MI_FREEWAY,
|
||||||
MI_MIAMI_RCRAIDER = 195,
|
MI_RCBARON,
|
||||||
MI_MIAMI_SPARROW = 199,
|
MI_RCRAIDER,
|
||||||
|
MI_GLENDALE,
|
||||||
|
MI_OCEANIC,
|
||||||
|
MI_SANCHEZ,
|
||||||
|
MI_SPARROW,
|
||||||
|
MI_PATRIOT,
|
||||||
|
MI_LOVEFIST,
|
||||||
|
MI_COASTG,
|
||||||
|
MI_DINGHY,
|
||||||
|
MI_HERMES,
|
||||||
|
MI_SABRE,
|
||||||
|
MI_SABRETUR,
|
||||||
|
MI_PHEONIX,
|
||||||
|
MI_WALTON,
|
||||||
|
MI_REGINA,
|
||||||
|
MI_COMET,
|
||||||
|
MI_DELUXO,
|
||||||
|
MI_BURRITO,
|
||||||
|
MI_SPAND,
|
||||||
|
MI_MARQUIS,
|
||||||
|
MI_BAGGAGE,
|
||||||
|
MI_KAUFMAN,
|
||||||
|
MI_MAVERICK,
|
||||||
|
MI_VCNMAV,
|
||||||
|
MI_RANCHER,
|
||||||
|
MI_FBIRANCH,
|
||||||
|
MI_VIRGO,
|
||||||
|
MI_GREENWOO,
|
||||||
|
MI_JETMAX,
|
||||||
|
MI_HOTRING,
|
||||||
|
MI_SANDKING,
|
||||||
|
MI_BLISTAC,
|
||||||
|
MI_POLMAV,
|
||||||
|
MI_BOXVILLE,
|
||||||
|
MI_BENSON,
|
||||||
|
MI_MESA,
|
||||||
|
MI_RCGOBLIN,
|
||||||
|
MI_HOTRINA,
|
||||||
|
MI_HOTRINB,
|
||||||
|
MI_BLOODRA,
|
||||||
|
MI_BLOODRB,
|
||||||
|
MI_VICECHEE,
|
||||||
|
// HACK
|
||||||
|
MI_TRAIN = -1,
|
||||||
|
MI_DODO = -2,
|
||||||
|
|
||||||
MI_GRENADE = 258,
|
MI_GRENADE = 258,
|
||||||
MI_AK47,
|
MI_AK47,
|
||||||
@ -393,6 +438,7 @@ IsBodyPart(int16 id)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// This is bad and should perhaps not be used
|
// This is bad and should perhaps not be used
|
||||||
|
/*
|
||||||
inline bool
|
inline bool
|
||||||
IsBoatModel(int16 id)
|
IsBoatModel(int16 id)
|
||||||
{
|
{
|
||||||
@ -401,6 +447,7 @@ IsBoatModel(int16 id)
|
|||||||
id == MI_SPEEDER ||
|
id == MI_SPEEDER ||
|
||||||
id == MI_GHOST;
|
id == MI_GHOST;
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
|
|
||||||
inline bool
|
inline bool
|
||||||
IsPedModel(int16 id)
|
IsPedModel(int16 id)
|
||||||
|
@ -35,17 +35,6 @@ enum eVehicleType {
|
|||||||
NUM_VEHICLE_TYPES
|
NUM_VEHICLE_TYPES
|
||||||
};
|
};
|
||||||
|
|
||||||
enum {
|
|
||||||
VEHICLE_CLASS_POOR,
|
|
||||||
VEHICLE_CLASS_RICH,
|
|
||||||
VEHICLE_CLASS_EXECUTIVE,
|
|
||||||
VEHICLE_CLASS_WORKER,
|
|
||||||
VEHICLE_CLASS_SPECIAL,
|
|
||||||
VEHICLE_CLASS_BIG,
|
|
||||||
VEHICLE_CLASS_TAXI,
|
|
||||||
NUM_VEHICLE_CLASSES
|
|
||||||
};
|
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
NUM_VEHICLE_POSITIONS = 10
|
NUM_VEHICLE_POSITIONS = 10
|
||||||
};
|
};
|
||||||
|
@ -15,13 +15,13 @@ CGangInfo::CGangInfo() :
|
|||||||
|
|
||||||
void CGangs::Initialise(void)
|
void CGangs::Initialise(void)
|
||||||
{
|
{
|
||||||
Gang[GANG_MAFIA].m_nVehicleMI = MI_MAFIA;
|
Gang[GANG_MAFIA].m_nVehicleMI = -1;
|
||||||
Gang[GANG_TRIAD].m_nVehicleMI = MI_BELLYUP;
|
Gang[GANG_TRIAD].m_nVehicleMI = -1;
|
||||||
Gang[GANG_DIABLOS].m_nVehicleMI = MI_DIABLOS;
|
Gang[GANG_DIABLOS].m_nVehicleMI = -1;
|
||||||
Gang[GANG_YAKUZA].m_nVehicleMI = MI_YAKUZA;
|
Gang[GANG_YAKUZA].m_nVehicleMI = -1;
|
||||||
Gang[GANG_YARDIE].m_nVehicleMI = MI_YARDIE;
|
Gang[GANG_YARDIE].m_nVehicleMI = -1;
|
||||||
Gang[GANG_COLUMB].m_nVehicleMI = MI_COLUMB;
|
Gang[GANG_COLUMB].m_nVehicleMI = -1;
|
||||||
Gang[GANG_HOODS].m_nVehicleMI = MI_HOODS;
|
Gang[GANG_HOODS].m_nVehicleMI = -1;
|
||||||
Gang[GANG_7].m_nVehicleMI = -1;
|
Gang[GANG_7].m_nVehicleMI = -1;
|
||||||
Gang[GANG_8].m_nVehicleMI = -1;
|
Gang[GANG_8].m_nVehicleMI = -1;
|
||||||
#ifdef FIX_BUGS
|
#ifdef FIX_BUGS
|
||||||
|
@ -11976,7 +11976,7 @@ CPed::RegisterThreatWithGangPeds(CEntity *attacker)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (attackerPed && attackerPed->IsPlayer() && (attackerPed->m_nPedState == PED_CARJACK || attackerPed->bInVehicle)) {
|
if (attackerPed && attackerPed->IsPlayer() && (attackerPed->m_nPedState == PED_CARJACK || attackerPed->bInVehicle)) {
|
||||||
if (!attackerPed->m_pMyVehicle || attackerPed->m_pMyVehicle->GetModelIndex() != MI_TOYZ) {
|
if (!attackerPed->m_pMyVehicle || attackerPed->m_pMyVehicle->GetModelIndex() != MI_TOPFUN) {
|
||||||
int16 lastVehicle;
|
int16 lastVehicle;
|
||||||
CEntity *vehicles[8];
|
CEntity *vehicles[8];
|
||||||
CWorld::FindObjectsInRange(GetPosition(), 30.0f, true, &lastVehicle, 6, vehicles, false, true, false, false, false);
|
CWorld::FindObjectsInRange(GetPosition(), 30.0f, true, &lastVehicle, 6, vehicles, false, true, false, false, false);
|
||||||
@ -15670,7 +15670,7 @@ CPed::SetExitCar(CVehicle *veh, uint32 wantedDoorNode)
|
|||||||
} else {
|
} else {
|
||||||
if (veh->GetUp().z > -0.8f) {
|
if (veh->GetUp().z > -0.8f) {
|
||||||
bool addDoorSmoke = false;
|
bool addDoorSmoke = false;
|
||||||
if (veh->GetModelIndex() == MI_YARDIE)
|
if (veh->GetModelIndex() == MI_VOODOO)
|
||||||
addDoorSmoke = true;
|
addDoorSmoke = true;
|
||||||
|
|
||||||
switch (m_vehEnterType) {
|
switch (m_vehEnterType) {
|
||||||
|
@ -748,7 +748,8 @@ CPopulation::AddPedInCar(CVehicle* car)
|
|||||||
break;
|
break;
|
||||||
case MI_TAXI:
|
case MI_TAXI:
|
||||||
case MI_CABBIE:
|
case MI_CABBIE:
|
||||||
case MI_BORGNINE:
|
case MI_ZEBRA:
|
||||||
|
case MI_KAUFMAN:
|
||||||
if (CGeneral::GetRandomTrueFalse()) {
|
if (CGeneral::GetRandomTrueFalse()) {
|
||||||
pedType = PEDTYPE_CIVMALE;
|
pedType = PEDTYPE_CIVMALE;
|
||||||
preferredModel = MI_TAXI_D;
|
preferredModel = MI_TAXI_D;
|
||||||
|
@ -1884,13 +1884,11 @@ WinMain(HINSTANCE instance,
|
|||||||
StaticPatcher::Apply();
|
StaticPatcher::Apply();
|
||||||
SystemParametersInfo(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, nil, SPIF_SENDCHANGE);
|
SystemParametersInfo(SPI_SETFOREGROUNDLOCKTIMEOUT, 0, nil, SPIF_SENDCHANGE);
|
||||||
|
|
||||||
/*
|
|
||||||
// TODO: make this an option somewhere
|
// TODO: make this an option somewhere
|
||||||
AllocConsole();
|
AllocConsole();
|
||||||
freopen("CONIN$", "r", stdin);
|
freopen("CONIN$", "r", stdin);
|
||||||
freopen("CONOUT$", "w", stdout);
|
freopen("CONOUT$", "w", stdout);
|
||||||
freopen("CONOUT$", "w", stderr);
|
freopen("CONOUT$", "w", stderr);
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Initialize the platform independent data.
|
* Initialize the platform independent data.
|
||||||
|
@ -195,7 +195,7 @@ CAutomobile::CAutomobile(int32 id, uint8 CreatedBy)
|
|||||||
CMatrix mat2(RwFrameGetMatrix(m_aCarNodes[CAR_WHEEL_LF]));
|
CMatrix mat2(RwFrameGetMatrix(m_aCarNodes[CAR_WHEEL_LF]));
|
||||||
mat1.GetPosition() += CVector(mat2.GetPosition().x + 0.1f, 0.0f, mat2.GetPosition().z);
|
mat1.GetPosition() += CVector(mat2.GetPosition().x + 0.1f, 0.0f, mat2.GetPosition().z);
|
||||||
mat1.UpdateRW();
|
mat1.UpdateRW();
|
||||||
}else if(GetModelIndex() == MI_MIAMI_SPARROW || GetModelIndex() == MI_MIAMI_RCRAIDER){
|
}else if(GetModelIndex() == MI_SPARROW || GetModelIndex() == MI_RCRAIDER){
|
||||||
RpAtomicSetFlags((RpAtomic*)GetFirstObject(m_aCarNodes[CAR_WHEEL_LF]), 0);
|
RpAtomicSetFlags((RpAtomic*)GetFirstObject(m_aCarNodes[CAR_WHEEL_LF]), 0);
|
||||||
RpAtomicSetFlags((RpAtomic*)GetFirstObject(m_aCarNodes[CAR_WHEEL_RF]), 0);
|
RpAtomicSetFlags((RpAtomic*)GetFirstObject(m_aCarNodes[CAR_WHEEL_RF]), 0);
|
||||||
RpAtomicSetFlags((RpAtomic*)GetFirstObject(m_aCarNodes[CAR_WHEEL_LB]), 0);
|
RpAtomicSetFlags((RpAtomic*)GetFirstObject(m_aCarNodes[CAR_WHEEL_LB]), 0);
|
||||||
@ -490,8 +490,7 @@ CAutomobile::ProcessControl(void)
|
|||||||
TankControl();
|
TankControl();
|
||||||
BlowUpCarsInPath();
|
BlowUpCarsInPath();
|
||||||
break;
|
break;
|
||||||
case MI_YARDIE:
|
case MI_VOODOO:
|
||||||
// beta also had esperanto here it seems
|
|
||||||
HydraulicControl();
|
HydraulicControl();
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
@ -673,9 +672,9 @@ CAutomobile::ProcessControl(void)
|
|||||||
acceleration /= m_fForceMultiplier;
|
acceleration /= m_fForceMultiplier;
|
||||||
|
|
||||||
// unused
|
// unused
|
||||||
if(GetModelIndex() == MI_MIAMI_RCBARON ||
|
if(GetModelIndex() == MI_RCBARON ||
|
||||||
GetModelIndex() == MI_MIAMI_RCRAIDER ||
|
GetModelIndex() == MI_RCRAIDER ||
|
||||||
GetModelIndex() == MI_MIAMI_SPARROW)
|
GetModelIndex() == MI_SPARROW)
|
||||||
acceleration = 0.0f;
|
acceleration = 0.0f;
|
||||||
|
|
||||||
brake = m_fBrakePedal * pHandling->fBrakeDeceleration * CTimer::GetTimeStep();
|
brake = m_fBrakePedal * pHandling->fBrakeDeceleration * CTimer::GetTimeStep();
|
||||||
@ -1001,7 +1000,7 @@ CAutomobile::ProcessControl(void)
|
|||||||
m_bSirenOrAlarm = !m_bSirenOrAlarm;
|
m_bSirenOrAlarm = !m_bSirenOrAlarm;
|
||||||
}else
|
}else
|
||||||
m_nCarHornTimer = 0;
|
m_nCarHornTimer = 0;
|
||||||
}else if(GetModelIndex() != MI_YARDIE && !CVehicle::bCheat3){
|
}else if(GetModelIndex() != MI_VOODOO && !CVehicle::bCheat3){
|
||||||
if(Pads[0].GetHorn())
|
if(Pads[0].GetHorn())
|
||||||
m_nCarHornTimer = 1;
|
m_nCarHornTimer = 1;
|
||||||
else
|
else
|
||||||
@ -1012,7 +1011,7 @@ CAutomobile::ProcessControl(void)
|
|||||||
// Flying
|
// Flying
|
||||||
|
|
||||||
if(GetStatus() != STATUS_PLAYER && GetStatus() != STATUS_PLAYER_REMOTE && GetStatus() != STATUS_PHYSICS){
|
if(GetStatus() != STATUS_PLAYER && GetStatus() != STATUS_PLAYER_REMOTE && GetStatus() != STATUS_PHYSICS){
|
||||||
if(GetModelIndex() == MI_MIAMI_RCRAIDER || GetModelIndex() == MI_MIAMI_SPARROW)
|
if(GetModelIndex() == MI_RCRAIDER || GetModelIndex() == MI_SPARROW)
|
||||||
m_aWheelSpeed[0] = Max(m_aWheelSpeed[0]-0.0005f, 0.0f);
|
m_aWheelSpeed[0] = Max(m_aWheelSpeed[0]-0.0005f, 0.0f);
|
||||||
}else if((GetModelIndex() == MI_DODO || CVehicle::bAllDodosCheat) &&
|
}else if((GetModelIndex() == MI_DODO || CVehicle::bAllDodosCheat) &&
|
||||||
m_vecMoveSpeed.Magnitude() > 0.0f && CTimer::GetTimeStep() > 0.0f){
|
m_vecMoveSpeed.Magnitude() > 0.0f && CTimer::GetTimeStep() > 0.0f){
|
||||||
@ -1022,9 +1021,9 @@ CAutomobile::ProcessControl(void)
|
|||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
FlyingControl(FLIGHT_MODEL_DODO);
|
FlyingControl(FLIGHT_MODEL_DODO);
|
||||||
}else if(GetModelIndex() == MI_MIAMI_RCBARON){
|
}else if(GetModelIndex() == MI_RCBARON){
|
||||||
FlyingControl(FLIGHT_MODEL_RCPLANE);
|
FlyingControl(FLIGHT_MODEL_RCPLANE);
|
||||||
}else if(GetModelIndex() == MI_MIAMI_RCRAIDER || GetModelIndex() == MI_MIAMI_SPARROW || bAllCarCheat){
|
}else if(GetModelIndex() == MI_RCRAIDER || GetModelIndex() == MI_SPARROW || bAllCarCheat){
|
||||||
#ifdef ALLCARSHELI_CHEAT
|
#ifdef ALLCARSHELI_CHEAT
|
||||||
if (bAllCarCheat)
|
if (bAllCarCheat)
|
||||||
FlyingControl(FLIGHT_MODEL_HELI);
|
FlyingControl(FLIGHT_MODEL_HELI);
|
||||||
@ -1591,7 +1590,8 @@ CAutomobile::PreRender(void)
|
|||||||
|
|
||||||
case MI_TAXI:
|
case MI_TAXI:
|
||||||
case MI_CABBIE:
|
case MI_CABBIE:
|
||||||
case MI_BORGNINE:
|
case MI_ZEBRA:
|
||||||
|
case MI_KAUFMAN:
|
||||||
if(bTaxiLight){
|
if(bTaxiLight){
|
||||||
CVector pos = GetPosition() + GetUp()*0.95f;
|
CVector pos = GetPosition() + GetUp()*0.95f;
|
||||||
CCoronas::RegisterCorona((uintptr)this + 21,
|
CCoronas::RegisterCorona((uintptr)this + 21,
|
||||||
|
@ -287,8 +287,8 @@ CBoat::ProcessControl(void)
|
|||||||
AddWakePoint(GetPosition());
|
AddWakePoint(GetPosition());
|
||||||
|
|
||||||
float steerFactor = 1.0f - DotProduct(m_vecMoveSpeed, GetForward());
|
float steerFactor = 1.0f - DotProduct(m_vecMoveSpeed, GetForward());
|
||||||
if (GetModelIndex() == MI_GHOST)
|
// if (GetModelIndex() == MI_GHOST)
|
||||||
steerFactor = 1.0f - DotProduct(m_vecMoveSpeed, GetForward())*0.3f;
|
// steerFactor = 1.0f - DotProduct(m_vecMoveSpeed, GetForward())*0.3f;
|
||||||
if(steerFactor < 0.0f) steerFactor = 0.0f;
|
if(steerFactor < 0.0f) steerFactor = 0.0f;
|
||||||
|
|
||||||
CVector propeller(0.0f, -pHandling->Dimension.y*m_fPropellerY, -pHandling->Dimension.z*m_fPropellerZ);
|
CVector propeller(0.0f, -pHandling->Dimension.y*m_fPropellerY, -pHandling->Dimension.z*m_fPropellerZ);
|
||||||
|
@ -21,7 +21,6 @@ const char VehicleNames[NUMHANDLINGS][14] = {
|
|||||||
"STRETCH",
|
"STRETCH",
|
||||||
"MANANA",
|
"MANANA",
|
||||||
"INFERNUS",
|
"INFERNUS",
|
||||||
"BLISTA",
|
|
||||||
"PONY",
|
"PONY",
|
||||||
"MULE",
|
"MULE",
|
||||||
"CHEETAH",
|
"CHEETAH",
|
||||||
@ -38,7 +37,6 @@ const char VehicleNames[NUMHANDLINGS][14] = {
|
|||||||
"ENFORCER",
|
"ENFORCER",
|
||||||
"SECURICA",
|
"SECURICA",
|
||||||
"BANSHEE",
|
"BANSHEE",
|
||||||
"PREDATOR",
|
|
||||||
"BUS",
|
"BUS",
|
||||||
"RHINO",
|
"RHINO",
|
||||||
"BARRACKS",
|
"BARRACKS",
|
||||||
@ -50,22 +48,73 @@ const char VehicleNames[NUMHANDLINGS][14] = {
|
|||||||
"STALLION",
|
"STALLION",
|
||||||
"RUMPO",
|
"RUMPO",
|
||||||
"RCBANDIT",
|
"RCBANDIT",
|
||||||
"BELLYUP",
|
|
||||||
"MRWONGS",
|
|
||||||
"MAFIA",
|
"MAFIA",
|
||||||
"YARDIE",
|
|
||||||
"YAKUZA",
|
|
||||||
"DIABLOS",
|
|
||||||
"COLUMB",
|
|
||||||
"HOODS",
|
|
||||||
"AIRTRAIN",
|
"AIRTRAIN",
|
||||||
"DEADDODO",
|
"DEADDODO",
|
||||||
"SPEEDER",
|
|
||||||
"REEFER",
|
|
||||||
"PANLANT",
|
|
||||||
"FLATBED",
|
"FLATBED",
|
||||||
"YANKEE",
|
"YANKEE",
|
||||||
"BORGNINE"
|
"GOLFCART",
|
||||||
|
"VOODOO",
|
||||||
|
"WASHING",
|
||||||
|
"CUBAN",
|
||||||
|
"ROMERO",
|
||||||
|
"PACKER",
|
||||||
|
"ADMIRAL",
|
||||||
|
"GANGBUR",
|
||||||
|
"ZEBRA",
|
||||||
|
"TOPFUN",
|
||||||
|
"GLENDALE",
|
||||||
|
"OCEANIC",
|
||||||
|
"HERMES",
|
||||||
|
"SABRE1",
|
||||||
|
"SABRETUR",
|
||||||
|
"PHEONIX",
|
||||||
|
"WALTON",
|
||||||
|
"REGINA",
|
||||||
|
"COMET",
|
||||||
|
"DELUXO",
|
||||||
|
"BURRITO",
|
||||||
|
"SPAND",
|
||||||
|
"BAGGAGE",
|
||||||
|
"KAUFMAN",
|
||||||
|
"RANCHER",
|
||||||
|
"FBIRANCH",
|
||||||
|
"VIRGO",
|
||||||
|
"GREENWOO",
|
||||||
|
"HOTRING",
|
||||||
|
"SANDKING",
|
||||||
|
"BLISTAC",
|
||||||
|
"BOXVILLE",
|
||||||
|
"BENSON",
|
||||||
|
"DESPERAD",
|
||||||
|
"LOVEFIST",
|
||||||
|
"BLOODRA",
|
||||||
|
"BLOODRB",
|
||||||
|
"BIKE",
|
||||||
|
"MOPED",
|
||||||
|
"DIRTBIKE",
|
||||||
|
"ANGEL",
|
||||||
|
"FREEWAY",
|
||||||
|
"PREDATOR",
|
||||||
|
"SPEEDER",
|
||||||
|
"REEFER",
|
||||||
|
"RIO",
|
||||||
|
"SQUALO",
|
||||||
|
"TROPIC",
|
||||||
|
"COASTGRD",
|
||||||
|
"DINGHY",
|
||||||
|
"MARQUIS",
|
||||||
|
"CUPBOAT",
|
||||||
|
"SEAPLANE",
|
||||||
|
"SPARROW",
|
||||||
|
"SEASPAR",
|
||||||
|
"MAVERICK",
|
||||||
|
"COASTMAV",
|
||||||
|
"POLMAV",
|
||||||
|
"HUNTER",
|
||||||
|
"RCBARON",
|
||||||
|
"RCGOBLIN",
|
||||||
|
"RCCOPTER"
|
||||||
};
|
};
|
||||||
|
|
||||||
cHandlingDataMgr::cHandlingDataMgr(void)
|
cHandlingDataMgr::cHandlingDataMgr(void)
|
||||||
@ -117,7 +166,9 @@ cHandlingDataMgr::LoadHandlingData(void)
|
|||||||
// yeah, this is kinda crappy
|
// yeah, this is kinda crappy
|
||||||
if(strncmp(line, ";the end", 9) == 0)
|
if(strncmp(line, ";the end", 9) == 0)
|
||||||
keepGoing = 0;
|
keepGoing = 0;
|
||||||
else if(line[0] != ';'){
|
// else if(line[0] != ';'){
|
||||||
|
// TODO(MIAMI): read boat, bike, flying values
|
||||||
|
else if(line[0] != ';' && line[0] != '%' && line[0] != '!' && line[0] != '$'){
|
||||||
field = 0;
|
field = 0;
|
||||||
strcpy(delim, " \t");
|
strcpy(delim, " \t");
|
||||||
// FIX: game seems to use a do-while loop here
|
// FIX: game seems to use a do-while loop here
|
||||||
@ -158,11 +209,14 @@ cHandlingDataMgr::LoadHandlingData(void)
|
|||||||
case 27: handling->fSuspensionLowerLimit = strtod(word, nil); break;
|
case 27: handling->fSuspensionLowerLimit = strtod(word, nil); break;
|
||||||
case 28: handling->fSuspensionBias = strtod(word, nil); break;
|
case 28: handling->fSuspensionBias = strtod(word, nil); break;
|
||||||
case 29:
|
case 29:
|
||||||
|
// TODO(MIAMI): suspension anti-dive multiplier
|
||||||
|
break;
|
||||||
|
case 30:
|
||||||
sscanf(word, "%x", &handling->Flags);
|
sscanf(word, "%x", &handling->Flags);
|
||||||
handling->Transmission.Flags = handling->Flags;
|
handling->Transmission.Flags = handling->Flags;
|
||||||
break;
|
break;
|
||||||
case 30: handling->FrontLights = atoi(word); break;
|
case 31: handling->FrontLights = atoi(word); break;
|
||||||
case 31: handling->RearLights = atoi(word); break;
|
case 32: handling->RearLights = atoi(word); break;
|
||||||
}
|
}
|
||||||
field++;
|
field++;
|
||||||
}
|
}
|
||||||
|
@ -139,5 +139,4 @@ public:
|
|||||||
bool HasRearWheelDrive(eHandlingId id) { return HandlingData[id].Transmission.nDriveType == 'R'; }
|
bool HasRearWheelDrive(eHandlingId id) { return HandlingData[id].Transmission.nDriveType == 'R'; }
|
||||||
bool HasFrontWheelDrive(eHandlingId id) { return HandlingData[id].Transmission.nDriveType == 'F'; }
|
bool HasFrontWheelDrive(eHandlingId id) { return HandlingData[id].Transmission.nDriveType == 'F'; }
|
||||||
};
|
};
|
||||||
VALIDATE_SIZE(cHandlingDataMgr, 0x3030);
|
|
||||||
extern cHandlingDataMgr mod_HandlingManager;
|
extern cHandlingDataMgr mod_HandlingManager;
|
||||||
|
@ -776,7 +776,6 @@ CHeli::InitHelis(void)
|
|||||||
for(i = 0; i < NUM_HELIS; i++)
|
for(i = 0; i < NUM_HELIS; i++)
|
||||||
pHelis[i] = nil;
|
pHelis[i] = nil;
|
||||||
|
|
||||||
((CVehicleModelInfo*)CModelInfo::GetModelInfo(MI_ESCAPE))->SetColModel(&CTempColModels::ms_colModelPed1);
|
|
||||||
((CVehicleModelInfo*)CModelInfo::GetModelInfo(MI_CHOPPER))->SetColModel(&CTempColModels::ms_colModelPed1);
|
((CVehicleModelInfo*)CModelInfo::GetModelInfo(MI_CHOPPER))->SetColModel(&CTempColModels::ms_colModelPed1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -787,10 +786,7 @@ GenerateHeli(bool catalina)
|
|||||||
CVector heliPos;
|
CVector heliPos;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
if(catalina)
|
heli = new CHeli(MI_CHOPPER, PERMANENT_VEHICLE);
|
||||||
heli = new CHeli(MI_ESCAPE, PERMANENT_VEHICLE);
|
|
||||||
else
|
|
||||||
heli = new CHeli(MI_CHOPPER, PERMANENT_VEHICLE);
|
|
||||||
|
|
||||||
if(catalina)
|
if(catalina)
|
||||||
heliPos = CVector(-224.0f, 201.0f, 83.0f);
|
heliPos = CVector(-224.0f, 201.0f, 83.0f);
|
||||||
@ -867,18 +863,6 @@ CHeli::UpdateHelis(void)
|
|||||||
pHelis[HELI_SCRIPT]->m_heliStatus = HELI_STATUS_FLY_AWAY;
|
pHelis[HELI_SCRIPT]->m_heliStatus = HELI_STATUS_FLY_AWAY;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Handle Catalina's heli
|
|
||||||
if(CatalinaHeliOn){
|
|
||||||
if(CStreaming::HasModelLoaded(MI_ESCAPE) && pHelis[HELI_CATALINA] == nil){
|
|
||||||
pHelis[HELI_CATALINA] = GenerateHeli(true);
|
|
||||||
pHelis[HELI_CATALINA]->m_heliType = HELI_TYPE_CATALINA;
|
|
||||||
}else
|
|
||||||
CStreaming::RequestModel(MI_ESCAPE, STREAMFLAGS_DONT_REMOVE);
|
|
||||||
}else{
|
|
||||||
if(pHelis[HELI_CATALINA])
|
|
||||||
pHelis[HELI_CATALINA]->m_heliStatus = HELI_STATUS_FLY_AWAY;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Delete helis that we no longer need
|
// Delete helis that we no longer need
|
||||||
for(i = 0; i < NUM_HELIS; i++)
|
for(i = 0; i < NUM_HELIS; i++)
|
||||||
if(pHelis[i] && pHelis[i]->m_heliStatus == HELI_STATUS_FLY_AWAY && pHelis[i]->GetPosition().z > 150.0f){
|
if(pHelis[i] && pHelis[i]->m_heliStatus == HELI_STATUS_FLY_AWAY && pHelis[i]->GetPosition().z > 150.0f){
|
||||||
|
@ -385,7 +385,7 @@ CVehicle::FlyingControl(eFlightModel flightModel)
|
|||||||
case FLIGHT_MODEL_HELI:
|
case FLIGHT_MODEL_HELI:
|
||||||
{
|
{
|
||||||
CVector vecMoveResistance;
|
CVector vecMoveResistance;
|
||||||
if (GetModelIndex() == MI_MIAMI_SPARROW)
|
if (GetModelIndex() == MI_SPARROW)
|
||||||
vecMoveResistance = vecHeliMoveRes;
|
vecMoveResistance = vecHeliMoveRes;
|
||||||
else
|
else
|
||||||
vecMoveResistance = vecRCHeliMoveRes;
|
vecMoveResistance = vecRCHeliMoveRes;
|
||||||
@ -436,7 +436,7 @@ CVehicle::FlyingControl(eFlightModel flightModel)
|
|||||||
ApplyTurnForce(fYaw * GetForward() * fYawVar * m_fTurnMass * CTimer::GetTimeStep(), GetRight());
|
ApplyTurnForce(fYaw * GetForward() * fYawVar * m_fTurnMass * CTimer::GetTimeStep(), GetRight());
|
||||||
|
|
||||||
CVector vecResistance;
|
CVector vecResistance;
|
||||||
if (GetModelIndex() == MI_MIAMI_SPARROW)
|
if (GetModelIndex() == MI_SPARROW)
|
||||||
vecResistance = vecHeliResistance;
|
vecResistance = vecHeliResistance;
|
||||||
else
|
else
|
||||||
vecResistance = vecRCHeliResistance;
|
vecResistance = vecRCHeliResistance;
|
||||||
@ -875,24 +875,7 @@ CVehicle::IsVehicleNormal(void)
|
|||||||
{
|
{
|
||||||
if (!pDriver || m_nNumPassengers != 0 || GetStatus() == STATUS_WRECKED)
|
if (!pDriver || m_nNumPassengers != 0 || GetStatus() == STATUS_WRECKED)
|
||||||
return false;
|
return false;
|
||||||
switch (GetModelIndex()){
|
return GetModelInfo()->m_vehicleClass != -1;
|
||||||
case MI_FIRETRUCK:
|
|
||||||
case MI_AMBULAN:
|
|
||||||
case MI_TAXI:
|
|
||||||
case MI_POLICE:
|
|
||||||
case MI_ENFORCER:
|
|
||||||
case MI_BUS:
|
|
||||||
case MI_RHINO:
|
|
||||||
case MI_BARRACKS:
|
|
||||||
case MI_DODO:
|
|
||||||
case MI_COACH:
|
|
||||||
case MI_CABBIE:
|
|
||||||
case MI_RCBANDIT:
|
|
||||||
case MI_BORGNINE:
|
|
||||||
return false;
|
|
||||||
default:
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
@ -1091,7 +1074,7 @@ CVehicle::SetDriver(CPed *driver)
|
|||||||
driver->GiveWeapon(WEAPONTYPE_SHOTGUN, 5);
|
driver->GiveWeapon(WEAPONTYPE_SHOTGUN, 5);
|
||||||
else if(GetModelIndex() == MI_ENFORCER)
|
else if(GetModelIndex() == MI_ENFORCER)
|
||||||
driver->m_fArmour = Max(driver->m_fArmour, 100.0f);
|
driver->m_fArmour = Max(driver->m_fArmour, 100.0f);
|
||||||
else if(GetModelIndex() == MI_CABBIE || GetModelIndex() == MI_BORGNINE)
|
else if(GetModelIndex() == MI_CABBIE || GetModelIndex() == MI_ZEBRA) // TODO(MIAMI): check zebra
|
||||||
CWorld::Players[CWorld::PlayerInFocus].m_nMoney += 25;
|
CWorld::Players[CWorld::PlayerInFocus].m_nMoney += 25;
|
||||||
bFreebies = false;
|
bFreebies = false;
|
||||||
}
|
}
|
||||||
|
@ -290,7 +290,7 @@ public:
|
|||||||
|
|
||||||
bool IsAlarmOn(void) { return m_nAlarmState != 0 && m_nAlarmState != -1; }
|
bool IsAlarmOn(void) { return m_nAlarmState != 0 && m_nAlarmState != -1; }
|
||||||
CVehicleModelInfo* GetModelInfo() { return (CVehicleModelInfo*)CModelInfo::GetModelInfo(GetModelIndex()); }
|
CVehicleModelInfo* GetModelInfo() { return (CVehicleModelInfo*)CModelInfo::GetModelInfo(GetModelIndex()); }
|
||||||
bool IsTaxi(void) { return GetModelIndex() == MI_TAXI || GetModelIndex() == MI_CABBIE || GetModelIndex() == MI_BORGNINE; }
|
bool IsTaxi(void) { return GetModelIndex() == MI_TAXI || GetModelIndex() == MI_CABBIE || GetModelIndex() == MI_ZEBRA || GetModelIndex() == MI_KAUFMAN; }
|
||||||
AnimationId GetDriverAnim(void) { return IsCar() && bLowVehicle ? ANIM_CAR_LSIT : (IsBoat() && GetModelIndex() != MI_SPEEDER ? ANIM_DRIVE_BOAT : ANIM_CAR_SIT); }
|
AnimationId GetDriverAnim(void) { return IsCar() && bLowVehicle ? ANIM_CAR_LSIT : (IsBoat() && GetModelIndex() != MI_SPEEDER ? ANIM_DRIVE_BOAT : ANIM_CAR_SIT); }
|
||||||
|
|
||||||
static bool bWheelsOnlyCheat;
|
static bool bWheelsOnlyCheat;
|
||||||
|
Loading…
Reference in New Issue
Block a user