[Client] Make player inventory items recharge by themselves again

This fixes 4476609872.
0.8.0
David Cernat 3 years ago
parent cf4ff3513f
commit 6875c3422f

@ -384,16 +384,7 @@ bool OMW::Engine::frame(float frametime)
{
double hours = (frametime * mEnvironment.getWorld()->getTimeScaleFactor()) / 3600.0;
mEnvironment.getWorld()->advanceTime(hours, true);
/*
Start of tes3mp change (major)
Don't unilaterally recharge world items on clients
*/
//mEnvironment.getWorld()->rechargeItems(frametime, true);
/*
End of tes3mp change (major)
*/
mEnvironment.getWorld()->rechargeItems(frametime, true);
}
}
}

@ -3916,6 +3916,12 @@ namespace MWWorld
MWWorld::Ptr player = getPlayerPtr();
player.getClass().getInventoryStore(player).rechargeItems(duration);
/*
Start of tes3mp change (major)
Don't unilaterally recharge world items on clients
*/
/*
if (activeOnly)
{
for (auto &cell : mWorldScene->getActiveCells())
@ -3925,6 +3931,10 @@ namespace MWWorld
}
else
mCells.recharge(duration);
*/
/*
End of tes3mp change (major)
*/
}
void World::teleportToClosestMarker (const MWWorld::Ptr& ptr,

Loading…
Cancel
Save