mirror of
https://github.com/halpz/re3.git
synced 2024-12-25 18:05:27 +00:00
new horn
This commit is contained in:
parent
6556cb0db9
commit
c33b93793f
|
@ -4024,10 +4024,22 @@ CAutomobile::PlayCarHorn(void)
|
|||
{
|
||||
int r;
|
||||
|
||||
if (m_nAlarmState && m_nAlarmState != -1)
|
||||
return;
|
||||
|
||||
if (GetStatus() == STATUS_WRECKED)
|
||||
return;
|
||||
|
||||
if(m_nCarHornTimer != 0)
|
||||
return;
|
||||
|
||||
r = CGeneral::GetRandomNumber() & 7;
|
||||
if (m_nCarHornDelay) {
|
||||
m_nCarHornDelay--;
|
||||
return;
|
||||
}
|
||||
|
||||
m_nCarHornDelay = (CGeneral::GetRandomNumber() & 0x7F) + 150;
|
||||
r = m_nCarHornDelay & 7;
|
||||
if(r < 2){
|
||||
m_nCarHornTimer = 45;
|
||||
}else if(r < 4){
|
||||
|
|
|
@ -101,6 +101,7 @@ CVehicle::CVehicle(uint8 CreatedBy)
|
|||
m_bSirenOrAlarm = 0;
|
||||
m_nCarHornTimer = 0;
|
||||
m_nCarHornPattern = 0;
|
||||
m_nCarHornDelay = 0;
|
||||
bPartOfConvoy = false;
|
||||
bCreatedAsPoliceVehicle = false;
|
||||
bParking = false;
|
||||
|
|
|
@ -211,8 +211,9 @@ public:
|
|||
uint8 m_bRainAudioCounter;
|
||||
uint8 m_bRainSamplesCounter;
|
||||
uint8 m_nCarHornTimer;
|
||||
uint8 m_nCarHornPattern; // last horn?
|
||||
uint8 m_nCarHornPattern;
|
||||
bool m_bSirenOrAlarm;
|
||||
uint8 m_nCarHornDelay;
|
||||
int8 m_comedyControlState;
|
||||
CStoredCollPoly m_aCollPolys[2]; // poly which is under front/rear part of car
|
||||
float m_fSteerRatio;
|
||||
|
|
Loading…
Reference in a new issue