func_ref.h 423 B

123456789101112131415161718192021222324
  1. #ifndef FUNC_REF_H
  2. #define FUNC_REF_H
  3. #include "reference.h"
  4. class FuncRef : public Reference{
  5. OBJ_TYPE(FuncRef,Reference);
  6. ObjectID id;
  7. StringName function;
  8. protected:
  9. static void _bind_methods();
  10. public:
  11. Variant call_func(const Variant** p_args, int p_argcount, Variant::CallError& r_error);
  12. void set_instance(Object *p_obj);
  13. void set_function(const StringName& p_func);
  14. FuncRef();
  15. };
  16. #endif // FUNC_REF_H