-
Автор темы
- #1
Обратите внимание, пользователь заблокирован на форуме. Не рекомендуется проводить сделки.
код:
EntityId syringeID = -1;
bool IsTarget = false;
bool bIsDead = false;
bool bIsDeadClient = false;
EntityId projectileId = 0;
EntityId mTeamId = 0;
EntityId pTeamId = 0;
Vec3 vBonePos = Vec3{ 0, 0, 0 };
Vec3 vShootPos = Vec3{ 0, 0, 0 };
int i_BoneId = 0;
AABB aabb;
IEntityClass* pEntityClass = nullptr;
IEntityRenderProxy* pEntityRenderProxy = nullptr;
IActor* pTarget = nullptr;
IEntity* pEntity = nullptr;
IEntity* mEntity = nullptr;
IEntity* mWeaponEntity = nullptr;
IAnimationGraphState* pAnimationGraphState = nullptr;
SSystemGlobalEnvironment* pSystemGlobalEnvironment = nullptr;
IPhysicalWorld* pPhysicalWorld = nullptr;
IGameFramework* pGameFramework = nullptr;
IGame* pGame = nullptr;
IActor* pClient = nullptr;
ICVars* pVars = nullptr;
IItem* pItem = nullptr;
IWeapon* pWeapon = nullptr;
IWeaponSpecific* pWeaponSpecific = nullptr;
IActorSystem* pActorSystem = nullptr;
IEntitySystem* pEntitySystem = nullptr;
IGameRules* pGameRules = nullptr;
IEntityIt* pEntityIt = nullptr;
ICharacterInstance* mCharacter = nullptr;
ISkeletonPose* mSkeletonPose = nullptr;
if (IItemSystem* pItemSystem = pGameFramework->GetIItemSystem())
{
if (strstr(pItem->GetWeaponEntity()->GetName(), "sb")) {
EntityId m_syringeID = pClient->GetInventory()->GetCurrentItemId();
syringeID = m_syringeID;
}
if (syringeID != -1) {
if (!pItem) pItem = pItemSystem->GetItem(syringeID);
hits.push_back(SRMIHitInfo::SvRequestShootHit::RequestHit(
pClient->GetEntityId(),
HitMaterialId::mat_head,
bullet,
mCharacter->GetSkeletonPose()->GetJointIdByName(xor_a("Bip01 Body")),
vShootPos, 0.0f, pClient->GetPid()));
}
}
}