#pragma once #include "common.h" #include "T2EquipDef.h" class AFX_CLASS_EXPORT T2MoverDef : public T2EquipDef { public: T2MoverDef(DWORD, T2PluginSpecifier&, CResFile*, T2WorldDef*, T2MoverPlugin*); virtual ~T2MoverDef(); int GetMinLength() const { return mMinLength; } int GetMaxLength() const { return mMaxLength; } virtual BOOL IsMover() { return true; } virtual void GetName(CString&); virtual BOOL InitObject(T2Object*) { return false; } virtual CURSORTYPE QueryCursor(T2TowerDoc*, POINT, CString&, RECT&, POINT&, int, unsigned int, int); virtual int CalcMentenanceCostProc(const T2HaveOutViewObject*) const; virtual AREACHECKCODE AreaCheck(T2TowerDoc* inDoc, RECT& inRect, unsigned int, BOOL inShowError); virtual int ClickProc(T2TowerDoc*, RECT*, unsigned int&); virtual BOOL MakeRequestProc(T2TowerDoc*, T2Equip*); virtual PROCCODE AddModuleProc(T2TowerDoc*, T2Equip*, RECT*); virtual int GetMinMaxRangeProc(T2TowerDoc*, T2Equip*, int); virtual int HandleUpProc(T2TowerDoc*, T2Equip*, POINT); virtual int HandleDownProc(T2TowerDoc*, T2Equip*, POINT); virtual int ClickShaftProc(T2TowerDoc*, T2Equip*, POINT); virtual int CalcModulePatIndex(int numPeople); virtual int CalcModulePosProc(T2Equip*, T2MoverModule*, ERequestUpDown) { return -1; } virtual int CalcModuleRectProc(const T2Mover*, const T2MoverModule*, RECT&, int&) const { return 0; } virtual int IsaKindOfStopProc(T2TowerDoc*, T2Equip*, int, int) const; virtual T2InfoDialog* ShowInfoDialog(T2TowerDoc*, T2Mover*, CPoint); virtual int GetInfoDialogID(T2TowerDoc*, const T2Mover*, PARTCODE, int) const; virtual T2InfoDialog* ConstructInfoDialog(T2Mover*, PARTCODE, int); BOOL InitObject(T2Mover*, const POINT&); int GetSpeed(int i) const { return (i >= 0 && i < 3) ? mSpeed[i] : 0; } BOOL IsStair(); void GetAddSize(RECT& r) const; int GetDefaultWait() const; int GetMaxModule() const; void GetModuleInset(RECT& r) const; int GetMaxStop() const; T2BitImage* GetOffBitMap() const; int GetScore() const; static unsigned int GetRequiredRequestSpace(); protected: RECT mAddSize; int mMaxLength; int mMinLength; int mMaxStop; int mDefaultWait; int mSpeed[3]; int mMaxModule; int m188; int m18C; int m190; int m194; RECT mModuleInset; int mScore; int m1AC; int m1B0[3]; T2BitImage *mOffBitMap; friend class T2TowerDoc; }; inline BOOL T2MoverDef::IsStair() { return IsSetAttribute(kMoverAttrIsStair); } inline void T2MoverDef::GetAddSize(RECT& r) const { r = mAddSize; } inline int T2MoverDef::GetDefaultWait() const { return mDefaultWait; } inline int T2MoverDef::GetMaxModule() const { return mMaxModule; } inline void T2MoverDef::GetModuleInset(RECT& r) const { r = mModuleInset; } inline int T2MoverDef::GetMaxStop() const { return mMaxStop; } inline T2BitImage* T2MoverDef::GetOffBitMap() const { return mOffBitMap; } inline int T2MoverDef::GetScore() const { return mScore; } inline /*static*/ unsigned int T2MoverDef::GetRequiredRequestSpace() { return 4; }