summaryrefslogtreecommitdiff
path: root/src/T2DLL/T2Transport.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/T2DLL/T2Transport.h')
-rw-r--r--src/T2DLL/T2Transport.h73
1 files changed, 45 insertions, 28 deletions
diff --git a/src/T2DLL/T2Transport.h b/src/T2DLL/T2Transport.h
index 4fc0443..b1e0640 100644
--- a/src/T2DLL/T2Transport.h
+++ b/src/T2DLL/T2Transport.h
@@ -1,39 +1,56 @@
#pragma once
#include "common.h"
-class T2Transport {
+class AFX_EXT_CLASS T2Transport {
public:
T2Transport();
virtual ~T2Transport();
-private:
- void Initialize();
-public:
- void Init(T2Transport*, CResFile*);
- void Init(T2Transport*, int);
- void AddTransport(T2Transport*);
+ void Init(T2Transport* inParent, CResFile* inResFile);
+ void Init(T2Transport* inParent, int inArriveTime);
+ void AddTransport(T2Transport* inTransport);
int GetNofTimeTable();
- void SetStation(unsigned int);
- void UpGrade(int);
- int GetTrainType(int) const;
- unsigned int GetArriveTime(int) const;
+ void SetStation(unsigned int inStation);
+ void UpGrade(int inGrade);
+ int GetTrainType(int inIndex) const;
+ unsigned int GetArriveTime(int inIndex) const;
T2Transport* GetStoppage() const;
- int WasStoppage() const;
-protected:
- int ChkStoppage() const;
- T2Transport* GetIndObject(int) const;
-public:
- T2Transport* GetAvailable(T2DateTime*) const;
-protected:
- int IsAvailable(T2DateTime*);
-public:
- int Enter(CLink*);
- int Leave(CLink*);
+ BOOL WasStoppage() const;
+ T2Transport* GetAvailable(T2DateTime* inDateTime) const;
+ BOOL Enter(CLink* inLink);
+ BOOL Leave(CLink* inLink);
CLink* LeaveFirst();
- virtual int Stop(T2TowerDoc*);
- virtual void Read(T2Archive&);
- virtual void Write(T2Archive&);
+ BOOL IsFull() const { return mNumOfContents >= mCapacity; }
+
+ virtual int Stop(T2TowerDoc* inDoc);
+ virtual void Read(T2Archive& inArchive);
+ virtual void Write(T2Archive& inArchive);
+
+private:
+ void Initialize();
+ virtual void DoSetStatus(int inStatus) = 0;
+ virtual T2TowerDoc *DoGetTowerDoc() const = 0;
+ virtual int DoGetBeginTime() = 0;
+ virtual T2WorldDef *DoGetWorldDef() = 0;
+
+protected:
+ BOOL ChkStoppage() const;
+ T2Transport* GetIndObject(int inIndex) const;
+ BOOL IsAvailable(T2DateTime* inDateTime);
- int IsFull() const {}
- T2Transport(const T2Transport&) {}
- T2Transport& operator=(const T2Transport&) {}
+ T2Transport *mParent;
+ LArray *mArray;
+ int _C;
+ unsigned int mWidth;
+ int _14;
+ unsigned int mStation;
+ int mGrade;
+ int mTrainType;
+ int _24;
+ unsigned int mArriveTime;
+ unsigned int _2C;
+ BOOL mFlag;
+ unsigned int mCapacity;
+ unsigned int mNumOfContents;
+ CLink *mFirstLink;
+ CLink *mLastLink;
};