summaryrefslogtreecommitdiff
path: root/src/KingSystem/ActorSystem/actBaseProcHandle.cpp
diff options
context:
space:
mode:
authortheo3 <arisstephenson2@gmail.com>2020-08-27 13:20:39 -0700
committertheo3 <arisstephenson2@gmail.com>2020-08-27 14:48:22 -0700
commit965d34c712d6372c5112e8d9943e48de622a9d5a (patch)
treeb6e4f487fd2a3a9db64f01b26fdb78e15d5b85dc /src/KingSystem/ActorSystem/actBaseProcHandle.cpp
parentaff4047630d082efe6f534f2866089399b467ce9 (diff)
non request BaseProcHandle stuff
refactoring baseProcHandle.cpp refactoring
Diffstat (limited to 'src/KingSystem/ActorSystem/actBaseProcHandle.cpp')
-rw-r--r--src/KingSystem/ActorSystem/actBaseProcHandle.cpp29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/KingSystem/ActorSystem/actBaseProcHandle.cpp b/src/KingSystem/ActorSystem/actBaseProcHandle.cpp
index e69de29b..5603b5be 100644
--- a/src/KingSystem/ActorSystem/actBaseProcHandle.cpp
+++ b/src/KingSystem/ActorSystem/actBaseProcHandle.cpp
@@ -0,0 +1,29 @@
+#include "KingSystem/ActorSystem/actBaseProcHandle.h"
+
+namespace ksys::act {
+
+BaseProcHandle::BaseProcHandle() {
+ mUnit = nullptr;
+ mFlag = 0;
+}
+
+BaseProcHandle::~BaseProcHandle() {
+ if (mUnit) {
+ mUnit->deleteProc(0, this);
+ mUnit = nullptr;
+ }
+ mFlag = 0;
+}
+
+bool BaseProcHandle::procReady() {
+ return mUnit && mUnit->isReady();
+}
+
+BaseProc* BaseProcHandle::getProc() {
+ if (mUnit)
+ return mUnit->getProc();
+
+ return nullptr;
+}
+
+} // namespace ksys::act \ No newline at end of file