Missing friendlyfire after previous commit (#805)

* Missing friendlyfire after previous  commit
Fixes https://github.com/s1lentq/ReGameDLL_CS/pull/798 issue.
This commit is contained in:
Unreal Karaulov 2023-03-31 20:57:16 +03:00 committed by GitHub
parent dce06e91c2
commit 4a7a63533c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -150,7 +150,7 @@ void CFuncVehicle::Blocked(CBaseEntity *pOther)
if (pOther->Classify() == CLASS_PLAYER) if (pOther->Classify() == CLASS_PLAYER)
{ {
CBasePlayer* playerOther = static_cast<CBasePlayer*>(pOther); CBasePlayer* playerOther = static_cast<CBasePlayer*>(pOther);
if (!playerDriver || g_pGameRules->PlayerRelationship(playerDriver, playerOther) == GR_TEAMMATE) if (!playerDriver || !g_pGameRules->FPlayerCanTakeDamage(playerOther, playerDriver))
{ {
// Just kick player // Just kick player
return; return;