Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

framework: Add sead::Task header #130

Merged
merged 1 commit into from
Aug 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ add_library(sead OBJECT
include/framework/seadMethodTreeMgr.h
include/framework/seadProcessMeter.h
include/framework/seadProcessMeterBar.h
include/framework/seadTask.h
include/framework/seadTaskBase.h
include/framework/seadTaskID.h
include/framework/seadTaskMgr.h
Expand Down
36 changes: 36 additions & 0 deletions include/framework/seadTask.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#pragma once

#include <framework/seadMethodTree.h>
#include <framework/seadTaskBase.h>
#include <prim/seadRuntimeTypeInfo.h>

namespace sead
{
class Task : public TaskBase
{
SEAD_RTTI_BASE(TaskBase);

public:
explicit Task(const TaskConstructArg& arg);
Task(const TaskConstructArg& arg, const char* name);
~Task() override;
void pauseCalc(bool b) override;
void pauseDraw(bool b) override;
void pauseCalcRec(bool b) override;
void pauseDrawRec(bool b) override;
void pauseCalcChild(bool b) override;
void pauseDrawChild(bool b) override;
void attachCalcImpl() override;
void attachDrawImpl() override;
void detachCalcImpl() override;
void detachDrawImpl() override;
const RuntimeTypeInfo::Interface* getCorrespondingMethodTreeMgrTypeInfo() const override;
MethodTreeNode* getMethodTreeNode(s32 method_type) override;
virtual void calc() {}
virtual void draw() {}

protected:
Sanae6 marked this conversation as resolved.
Show resolved Hide resolved
MethodTreeNode mCalcNode{nullptr};
MethodTreeNode mDrawNode{nullptr};
};
} // namespace sead