As recommended by Scrawl.
@ -15,8 +15,8 @@ void printAIPackage(ESM::AIPackage p)
std::cout << " Distance: " << p.mWander.mDistance << std::endl;
std::cout << " Duration: " << p.mWander.mDuration << std::endl;
std::cout << " Time of Day: " << (int)p.mWander.mTimeOfDay << std::endl;
if (!p.mWander.mShouldRepeat)
std::cout << " Should repeat: " << p.mWander.mShouldRepeat << std::endl;
if (p.mWander.mShouldRepeat != 1)
std::cout << " Should repeat: " << (bool)(p.mWander.mShouldRepeat != 0) << std::endl;
std::cout << " Idle: ";
for (int i = 0; i != 8; i++)
@ -565,7 +565,7 @@ namespace MWGui
int eff = mShown & mAllowed & ~mForceHidden;
// Show the windows we want
mMap ->setVisible(eff & GW_Map);
mMap ->setVisible((eff & GW_Map) != 0);
mStatsWindow ->setVisible((eff & GW_Stats) != 0);
mInventoryWindow->setVisible((eff & GW_Inventory) != 0);
mInventoryWindow->setGuiMode(mode);
@ -294,7 +294,7 @@ void AiSequence::fill(const ESM::AIPackageList &list)
idles.reserve(8);
for (int i=0; i<8; ++i)
idles.push_back(data.mIdle[i]);
package = new MWMechanics::AiWander(data.mDistance, data.mDuration, data.mTimeOfDay, idles, data.mShouldRepeat);
package = new MWMechanics::AiWander(data.mDistance, data.mDuration, data.mTimeOfDay, idles, data.mShouldRepeat != 0);
}
else if (it->mType == ESM::AI_Escort)
{
@ -785,7 +785,7 @@ namespace MWMechanics
, mDuration(wander->mData.mDuration)
, mStartTime(MWWorld::TimeStamp(wander->mStartTime))
, mTimeOfDay(wander->mData.mTimeOfDay)
, mRepeat(wander->mData.mShouldRepeat)
, mRepeat(wander->mData.mShouldRepeat != 0)
, mStoredInitialActorPosition(wander->mStoredInitialActorPosition)
if (mStoredInitialActorPosition)
@ -32,7 +32,7 @@ namespace ESM
short mDuration;
unsigned char mTimeOfDay;
unsigned char mIdle[8];
bool mShouldRepeat;
unsigned char mShouldRepeat;
};
struct AITravel
@ -44,7 +44,7 @@ namespace ESM
struct AiTravelData