mirror of
https://github.com/GTAmodding/re3.git
synced 2025-10-10 14:40:35 +00:00
script revision
This commit is contained in:
parent
ff0e039599
commit
4c822e8375
8 changed files with 155 additions and 144 deletions
|
@ -273,9 +273,17 @@ CBoat::ProcessControl(void)
|
|||
if(0.1f * m_fMass * GRAVITY*CTimer::GetTimeStep() < buoyanceImpulse.z){
|
||||
bBoatInWater = true;
|
||||
bIsInWater = true;
|
||||
if (GetUp().z < -0.6f && Abs(GetMoveSpeed().x) < 0.05 && Abs(GetMoveSpeed().y) < 0.05) {
|
||||
bIsDrowning = true;
|
||||
if (pDriver)
|
||||
pDriver->InflictDamage(nil, WEAPONTYPE_DROWNING, CTimer::GetTimeStep(), PEDPIECE_TORSO, 0);
|
||||
}
|
||||
else
|
||||
bIsDrowning = false;
|
||||
}else{
|
||||
bBoatInWater = false;
|
||||
bIsInWater = false;
|
||||
bIsDrowning = false;
|
||||
}
|
||||
|
||||
m_fVolumeUnderWater = mod_Buoyancy.m_volumeUnderWater;
|
||||
|
@ -519,6 +527,7 @@ CBoat::ProcessControl(void)
|
|||
}else{
|
||||
bBoatInWater = false;
|
||||
bIsInWater = false;
|
||||
bIsDrowning = false;
|
||||
}
|
||||
|
||||
if(m_bIsAnchored){
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue