Initial setup for script hooks (likely to be revamped)
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
27
src/Battling/ScriptHandling/Script.hpp
Normal file
27
src/Battling/ScriptHandling/Script.hpp
Normal file
@@ -0,0 +1,27 @@
|
||||
#ifndef CREATURELIB_SCRIPT_HPP
|
||||
#define CREATURELIB_SCRIPT_HPP
|
||||
|
||||
#include <any>
|
||||
#include <string>
|
||||
#include <utility>
|
||||
#include <vector>
|
||||
#include "Hooks.hpp"
|
||||
|
||||
namespace CreatureLib::Battling{
|
||||
class Script{
|
||||
const std::string _name;
|
||||
|
||||
public:
|
||||
explicit Script(std::string name) :_name(std::move(name)){}
|
||||
virtual ~Script() = default;
|
||||
|
||||
virtual void Execute(Hook hook, const std::vector<std::any>& args){};
|
||||
virtual void Stack(){};
|
||||
|
||||
const std::string& GetName(){
|
||||
return _name;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
#endif //CREATURELIB_SCRIPT_HPP
|
||||
Reference in New Issue
Block a user