peds starting to work

This commit is contained in:
aap
2020-05-09 17:05:26 +02:00
parent 989ded6052
commit 97d5698e0c
20 changed files with 171 additions and 262 deletions

View File

@ -67,8 +67,6 @@ CEventList::RegisterEvent(eEventType type, eEventEntity entityType, CEntity *ent
switch(entityType){
case EVENT_ENTITY_PED:
ref = CPools::GetPedRef((CPed*)ent);
if(ent->GetModelIndex() >= MI_GANG01 && ent->GetModelIndex() <= MI_CRIMINAL02)
copsDontCare = true;
break;
case EVENT_ENTITY_VEHICLE:
ref = CPools::GetVehicleRef((CVehicle*)ent);

View File

@ -861,15 +861,16 @@ CFileLoader::LoadPedObject(const char *line)
{
int id;
char model[24], txd[24];
char pedType[24], pedStats[24], animGroup[24];
char pedType[24], pedStats[24], animGroup[24], animFile[16];
int carsCanDrive;
CPedModelInfo *mi;
int animGroupId;
int radio1, radio2;
if(sscanf(line, "%d %s %s %s %s %s %x",
sscanf(line, "%d %s %s %s %s %s %x %s %d %d",
&id, model, txd,
pedType, pedStats, animGroup, &carsCanDrive) != 7)
return;
pedType, pedStats, animGroup, &carsCanDrive,
animFile, &radio1, &radio2);
mi = CModelInfo::AddPedModel(id);
mi->SetName(model);

View File

@ -140,9 +140,9 @@ void ChangePlayerCheat()
do
{
do
modelId = CGeneral::GetRandomNumberInRange(0, MI_CAS_WOM+1);
modelId = CGeneral::GetRandomNumberInRange(0, MI_WFYG2+1);
while (!CModelInfo::GetModelInfo(modelId));
} while (modelId >= MI_SPECIAL01 && modelId <= MI_SPECIAL04 || modelId == MI_TAXI_D);
} while (modelId == MI_TAXI_D);
uint8 flags = CStreaming::ms_aInfoForModel[modelId].m_flags;
ped->DeleteRwObject();

View File

@ -108,8 +108,8 @@ enum Config {
NUMPEDROUTES = 200,
NUMPHONES = 50,
NUMPEDGROUPS = 31,
NUMMODELSPERPEDGROUP = 8, // TODO(MIAMI): 16 once we have peds
NUMPEDGROUPS = 67,
NUMMODELSPERPEDGROUP = 16,
NUMSHOTINFOS = 100,
NUMROADBLOCKS = 300,