summaryrefslogtreecommitdiff
path: root/src/T2DLL/T2OutDecoration.h
diff options
context:
space:
mode:
authorAsh Wolf <ninji@wuffs.org>2023-06-28 22:22:32 +0100
committerAsh Wolf <ninji@wuffs.org>2023-06-28 22:22:32 +0100
commitc0c336500955a23e344651e5412c9d9d441ef4ee (patch)
tree790769c748db307cf3314f6e896e2f61c68561a2 /src/T2DLL/T2OutDecoration.h
parent37e364b2c6cc7487a1c888d256a73e5337bb7189 (diff)
downloadt2win-c0c336500955a23e344651e5412c9d9d441ef4ee.tar.gz
t2win-c0c336500955a23e344651e5412c9d9d441ef4ee.zip
first pass of T2DLL
Diffstat (limited to 'src/T2DLL/T2OutDecoration.h')
-rw-r--r--src/T2DLL/T2OutDecoration.h52
1 files changed, 42 insertions, 10 deletions
diff --git a/src/T2DLL/T2OutDecoration.h b/src/T2DLL/T2OutDecoration.h
index c865bab..9dcc8a3 100644
--- a/src/T2DLL/T2OutDecoration.h
+++ b/src/T2DLL/T2OutDecoration.h
@@ -1,20 +1,52 @@
#pragma once
#include "common.h"
+#include "LArray.h"
+#include "T2EventItem.h"
-class T2OutDecoration {
+class AFX_EXT_CLASS T2OutDecoration : public T2EventItem {
public:
- T2OutDecoration(T2TowerEvent*, CResFile*, int);
+ T2OutDecoration(T2TowerEvent* inTowerEvent, CResFile* inResFile, int inSubID);
virtual ~T2OutDecoration();
- virtual int Exec(T2TowerDoc*);
- void DoDecoration(T2TowerDoc*, VIEWMODE, int);
- virtual void ViewModeChanged(T2TowerDoc*, VIEWMODE);
- void CheckRoofTop(T2Equip*);
+ virtual DWORD GetID() { return 'OdEv'; }
+ virtual BOOL IsBeginTime(unsigned int inTime) { return true; }
+ virtual int Exec(T2TowerDoc* inDoc);
+ virtual void ViewModeChanged(T2TowerDoc* inDoc, VIEWMODE inViewMode);
+ void DoDecoration(T2TowerDoc* inDoc, VIEWMODE inViewMode, int inFrame);
+ void CheckRoofTop(T2Equip* inEquip);
+
private:
LArray* MakeLoofList();
+ LArray mArray;
+ int mCurrentViewMode;
+ int mCurrentFrame;
+};
+
+class T2OutDeco {
public:
- virtual unsigned long GetID() {}
- virtual int IsBeginTime(unsigned int) {}
- T2OutDecoration(const T2OutDecoration&) {}
- T2OutDecoration& operator=(const T2OutDecoration&) {}
+ T2OutDeco(T2OutDecoration *inOwner, int inResID, unsigned int inFrameCount);
+ ~T2OutDeco();
+ void Load(int inID);
+ void Unload();
+
+private:
+ friend class T2OutDecoration;
+
+ T2OutDecoration *mOwner;
+ int mSpriteID;
+ BOOL mLoaded;
+ int mResID;
+ int mFrameCount;
+ CRect mRect;
+ int mCurrent;
+ BOOL mVisible;
+ T2BitImage *mImage;
+ T2ImageObj *mImageObj;
+};
+
+struct T2RoofInfo {
+ CRect rect;
+ BOOL flag;
+
+ T2RoofInfo(int inLeft, int inTop, int inRight, int inBottom, BOOL inFlag);
};