Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void CTargetTrackThreatModifier::ModifyTargetThreat(
- IAIObject &ownerAI, IAIObject &targetAI,
- const ITargetTrack &track,
- float &outThreatRatio,
- EAITargetThreat &outThreat) const
- {
- if (track.GetTargetType() > AITARGET_SOUND &&
- outThreat >= AITHREAT_AGGRESSIVE)
- {
- outThreatRatio = 1.0f;
- }
- }
- This suspicious code was found in CryEngineSDK project by PVS-Studio static code analyzer.
- Warning message is:
- V669 The 'outThreat' argument is a non-constant reference. The analyzer is unable to determine the position at which this argument is being modified. It is possible that the function contains an error. targettrackthreatmodifier.cpp 48
- PVS-Studio is a static analyzer for detecting bugs in the source code of applications written in C, C++, C++11, C++/CX. Site: http://www.viva64.com/en/pvs-studio/
Advertisement
Add Comment
Please, Sign In to add comment