2019-05-19 19:28:10 +00:00
|
|
|
#include "common.h"
|
|
|
|
#include "patcher.h"
|
|
|
|
#include "Ped.h"
|
|
|
|
#include "Pools.h"
|
|
|
|
|
2019-06-13 00:35:26 +00:00
|
|
|
Bool &CPed::bNastyLimbsCheat = *(Bool*)0x95CD44;
|
|
|
|
Bool &CPed::bPedCheat2 = *(Bool*)0x95CD5A;
|
|
|
|
Bool &CPed::bPedCheat3 = *(Bool*)0x95CD59;
|
|
|
|
|
2019-06-02 15:13:56 +00:00
|
|
|
void *CPed::operator new(size_t sz) { return CPools::GetPedPool()->New(); }
|
|
|
|
void CPed::operator delete(void *p, size_t sz) { CPools::GetPedPool()->Delete((CPed*)p); }
|
2019-05-19 19:28:10 +00:00
|
|
|
|
|
|
|
WRAPPER void CPed::KillPedWithCar(CVehicle *veh, float impulse) { EAXJMP(0x4EC430); }
|
2019-05-28 06:39:36 +00:00
|
|
|
|
|
|
|
static char ObjectiveText[34][28] = {
|
|
|
|
"No Obj",
|
|
|
|
"Wait on Foot",
|
|
|
|
"Flee on Foot Till Safe",
|
|
|
|
"Guard Spot",
|
|
|
|
"Guard Area",
|
|
|
|
"Wait in Car",
|
|
|
|
"Wait in Car then Getout",
|
|
|
|
"Kill Char on Foot",
|
|
|
|
"Kill Char Any Means",
|
|
|
|
"Flee Char on Foot Till Safe",
|
|
|
|
"Flee Char on Foot Always",
|
|
|
|
"GoTo Char on Foot",
|
|
|
|
"Follow Char in Formation",
|
|
|
|
"Leave Car",
|
|
|
|
"Enter Car as Passenger",
|
|
|
|
"Enter Car as Driver",
|
|
|
|
"Follow Car in Car",
|
|
|
|
"Fire at Obj from Vehicle",
|
|
|
|
"Destroy Obj",
|
|
|
|
"Destroy Car",
|
|
|
|
"GoTo Area Any Means",
|
|
|
|
"GoTo Area on Foot",
|
|
|
|
"Run to Area",
|
|
|
|
"GoTo Area in Car",
|
|
|
|
"Follow Car on Foot Woffset",
|
|
|
|
"Guard Attack",
|
|
|
|
"Set Leader",
|
|
|
|
"Follow Route",
|
|
|
|
"Solicit",
|
|
|
|
"Take Taxi",
|
|
|
|
"Catch Train",
|
|
|
|
"Buy IceCream",
|
|
|
|
"Steal Any Car",
|
|
|
|
"Mug Char",
|
|
|
|
};
|
|
|
|
|
|
|
|
static char StateText[56][18] = {
|
|
|
|
"None", // 1
|
|
|
|
"Idle",
|
|
|
|
"Look Entity",
|
|
|
|
"Look Heading",
|
|
|
|
"Wander Range",
|
|
|
|
"Wander Path",
|
|
|
|
"Seek Pos",
|
|
|
|
"Seek Entity",
|
|
|
|
"Flee Pos",
|
|
|
|
"Flee Entity",
|
|
|
|
"Pursue",
|
|
|
|
"Follow Path",
|
|
|
|
"Sniper Mode",
|
|
|
|
"Rocket Mode",
|
|
|
|
"Dummy",
|
|
|
|
"Pause",
|
|
|
|
"Attack",
|
|
|
|
"Fight",
|
|
|
|
"Face Phone",
|
|
|
|
"Make Call",
|
|
|
|
"Chat",
|
|
|
|
"Mug",
|
|
|
|
"AimGun",
|
|
|
|
"AI Control",
|
|
|
|
"Seek Car",
|
|
|
|
"Seek InBoat",
|
|
|
|
"Follow Route",
|
|
|
|
"C.P.R.",
|
|
|
|
"Solicit",
|
|
|
|
"Buy IceCream",
|
|
|
|
"Investigate",
|
|
|
|
"Step away",
|
|
|
|
"STATES_NO_AI",
|
|
|
|
"On Fire",
|
|
|
|
"Jump",
|
|
|
|
"Fall",
|
|
|
|
"GetUp",
|
|
|
|
"Stagger",
|
|
|
|
"Dive away",
|
|
|
|
"STATES_NO_ST",
|
|
|
|
"Enter Train",
|
|
|
|
"Exit Train",
|
|
|
|
"Arrest Plyr",
|
|
|
|
"Driving",
|
|
|
|
"Passenger",
|
|
|
|
"Taxi Passngr",
|
|
|
|
"Open Door",
|
|
|
|
"Die",
|
|
|
|
"Dead",
|
|
|
|
"CarJack",
|
|
|
|
"Drag fm Car",
|
|
|
|
"Enter Car",
|
|
|
|
"Steal Car",
|
|
|
|
"Exit Car",
|
|
|
|
"Hands Up",
|
|
|
|
"Arrested",
|
|
|
|
};
|
|
|
|
|
|
|
|
static char PersonalityTypeText[32][18] = {
|
|
|
|
"Player",
|
|
|
|
"Cop",
|
|
|
|
"Medic",
|
|
|
|
"Fireman",
|
|
|
|
"Gang 1",
|
|
|
|
"Gang 2",
|
|
|
|
"Gang 3",
|
|
|
|
"Gang 4",
|
|
|
|
"Gang 5",
|
|
|
|
"Gang 6",
|
|
|
|
"Gang 7",
|
|
|
|
"Street Guy",
|
|
|
|
"Suit Guy",
|
|
|
|
"Sensible Guy",
|
|
|
|
"Geek Guy",
|
|
|
|
"Old Guy",
|
|
|
|
"Tough Guy",
|
|
|
|
"Street Girl",
|
|
|
|
"Suit Girl",
|
|
|
|
"Sensible Girl",
|
|
|
|
"Geek Girl",
|
|
|
|
"Old Girl",
|
|
|
|
"Tough Girl",
|
|
|
|
"Tramp",
|
|
|
|
"Tourist",
|
|
|
|
"Prostitute",
|
|
|
|
"Criminal",
|
|
|
|
"Busker",
|
|
|
|
"Taxi Driver",
|
|
|
|
"Psycho",
|
|
|
|
"Steward",
|
|
|
|
"Sports Fan",
|
|
|
|
};
|
|
|
|
|
|
|
|
static char WaitStateText[21][16] = {
|
|
|
|
"No Wait",
|
|
|
|
"Traffic Lights",
|
|
|
|
"Pause CrossRoad",
|
|
|
|
"Look CrossRoad",
|
|
|
|
"Look Ped",
|
|
|
|
"Look Shop",
|
|
|
|
"Look Accident",
|
|
|
|
"FaceOff Gang",
|
|
|
|
"Double Back",
|
|
|
|
"Hit Wall",
|
|
|
|
"Turn 180deg",
|
|
|
|
"Surprised",
|
|
|
|
"Ped Stuck",
|
|
|
|
"Look About",
|
|
|
|
"Play Duck",
|
|
|
|
"Play Cower",
|
|
|
|
"Play Taxi",
|
|
|
|
"Play HandsUp",
|
|
|
|
"Play HandsCower",
|
|
|
|
"Play Chat",
|
|
|
|
"Finish Flee",
|
|
|
|
};
|
|
|
|
|
|
|
|
bool
|
|
|
|
CPed::UseGroundColModel(void)
|
|
|
|
{
|
|
|
|
return m_nPedState == PED_FALL ||
|
|
|
|
m_nPedState == PED_DIVE_AWAY ||
|
|
|
|
m_nPedState == PED_DIE ||
|
|
|
|
m_nPedState == PED_DEAD;
|
|
|
|
}
|