mirror of
https://github.com/SapphireServer/Sapphire.git
synced 2025-05-25 11:07:45 +00:00
Implement benediction.
This commit is contained in:
parent
7a7a2f1724
commit
71d486e806
1 changed files with 28 additions and 0 deletions
28
src/scripts/action/whm/ActionBenediction140.cpp
Normal file
28
src/scripts/action/whm/ActionBenediction140.cpp
Normal file
|
@ -0,0 +1,28 @@
|
|||
#include <Script/NativeScriptApi.h>
|
||||
#include <ScriptObject.h>
|
||||
#include <Actor/Player.h>
|
||||
#include <Action/Action.h>
|
||||
#include <Math/CalcStats.h>
|
||||
|
||||
using namespace Sapphire;
|
||||
|
||||
class ActionBenediction140 :
|
||||
public ScriptAPI::ActionScript
|
||||
{
|
||||
public:
|
||||
ActionBenediction140() :
|
||||
ScriptAPI::ActionScript( 140 )
|
||||
{
|
||||
}
|
||||
|
||||
void onExecute( Sapphire::World::Action::Action& action ) override
|
||||
{
|
||||
auto pTarget = action.getHitChara();
|
||||
if( pTarget )
|
||||
{
|
||||
action.getEffectbuilder()->heal( pTarget, pTarget, pTarget->getMaxHp() );
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
EXPOSE_SCRIPT( ActionBenediction140 );
|
Loading…
Add table
Reference in a new issue