1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-30 21:32:42 +00:00
OpenMW/apps/openmw/mwworld/actioneat.cpp

22 lines
487 B
C++
Raw Normal View History

#include "actioneat.hpp"
#include <components/esm3/loadskil.hpp>
2014-02-23 20:11:05 +01:00
2015-09-10 18:48:34 +12:00
#include "../mwmechanics/actorutil.hpp"
#include "class.hpp"
namespace MWWorld
{
2022-09-22 21:26:05 +03:00
void ActionEat::executeImp(const Ptr& actor)
{
2022-05-12 17:29:12 +02:00
if (actor.getClass().consume(getTarget(), actor) && actor == MWMechanics::getPlayer())
2022-09-22 21:26:05 +03:00
actor.getClass().skillUsageSucceeded(actor, ESM::Skill::Alchemy, 1);
2014-02-23 20:11:05 +01:00
}
2022-09-22 21:26:05 +03:00
ActionEat::ActionEat(const MWWorld::Ptr& object)
: Action(false, object)
{
}
}