1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-09 12:42:11 +00:00
OpenMW/apps/openmw/mwworld/failedaction.cpp
Marc Zinnschlag d7af9fbec6 various fixes
2012-11-22 17:24:28 +01:00

22 lines
507 B
C++

#include "failedaction.hpp"
#include "../mwbase/world.hpp"
#include "../mwbase/environment.hpp"
#include "../mwbase/windowmanager.hpp"
namespace MWWorld
{
FailedAction::FailedAction (const std::string& msg) : Action (false), message(msg)
{ }
void FailedAction::executeImp (const Ptr& actor)
{
if ( actor.getRefData().getHandle()=="player" && !(message.empty()))
{
MWBase::Environment::get().getWindowManager() ->messageBox(message, std::vector<std::string>());
}
}
}