forked from teamnwah/openmw-tes3coop
Fix a wrong use of reference that causes potential crash
This commit is contained in:
parent
471bbd0021
commit
37b9d2fb0c
1 changed files with 8 additions and 8 deletions
|
@ -11,9 +11,9 @@ namespace MWMechanics
|
||||||
{
|
{
|
||||||
/// \brief AiPackage to have an actor avoid an opening door
|
/// \brief AiPackage to have an actor avoid an opening door
|
||||||
/** The AI will retreat from the door until it has finished opening, walked far away from it, or one second has passed, in an attempt to avoid it
|
/** The AI will retreat from the door until it has finished opening, walked far away from it, or one second has passed, in an attempt to avoid it
|
||||||
**/
|
**/
|
||||||
class AiAvoidDoor : public AiPackage
|
class AiAvoidDoor : public AiPackage
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
/// Avoid door until the door is fully open
|
/// Avoid door until the door is fully open
|
||||||
AiAvoidDoor(const MWWorld::Ptr& doorPtr);
|
AiAvoidDoor(const MWWorld::Ptr& doorPtr);
|
||||||
|
@ -29,10 +29,10 @@ namespace MWMechanics
|
||||||
|
|
||||||
private:
|
private:
|
||||||
float mDuration;
|
float mDuration;
|
||||||
const MWWorld::Ptr& mDoorPtr;
|
MWWorld::Ptr mDoorPtr;
|
||||||
ESM::Position mLastPos;
|
ESM::Position mLastPos;
|
||||||
float mAdjAngle;
|
float mAdjAngle;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue