1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 10:49:57 +00:00
openmw-tes3mp/apps/openmw/mwworld/actionalchemy.cpp

25 lines
657 B
C++
Raw Normal View History

#include "actionalchemy.hpp"
#include "../mwbase/environment.hpp"
#include "../mwbase/windowmanager.hpp"
#include "../mwbase/world.hpp"
#include "../mwworld/player.hpp"
2015-09-10 06:48:34 +00:00
#include "../mwmechanics/actorutil.hpp"
namespace MWWorld
{
2012-07-27 10:00:10 +00:00
void ActionAlchemy::executeImp (const Ptr& actor)
{
2015-09-10 06:48:34 +00:00
if (actor != MWMechanics::getPlayer())
return;
2015-09-10 06:48:34 +00:00
if(MWMechanics::isPlayerInCombat()) { //Ensure we're not in combat
MWBase::Environment::get().getWindowManager()->messageBox("#{sInventoryMessage3}");
return;
}
MWBase::Environment::get().getWindowManager()->pushGuiMode(MWGui::GM_Alchemy);
}
}