summaryrefslogtreecommitdiffhomepage
path: root/StarsEx/Element.h
diff options
context:
space:
mode:
authorAki <please@ignore.pl>2024-03-26 01:45:33 +0100
committerAki <please@ignore.pl>2024-03-26 01:49:16 +0100
commitea4c0557d0b7c2317e03d3d3aaefd6063c99f091 (patch)
treedad4634faf3c17f3642d736f62350df88c117a59 /StarsEx/Element.h
parent38332f77dc1e7bb03776631101eff6e8ad8bcaef (diff)
downloadstarshatter-ea4c0557d0b7c2317e03d3d3aaefd6063c99f091.zip
starshatter-ea4c0557d0b7c2317e03d3d3aaefd6063c99f091.tar.gz
starshatter-ea4c0557d0b7c2317e03d3d3aaefd6063c99f091.tar.bz2
DWORD replaced with std::uint32_t in non-Win32-related parts
With the exception of some netcode. This brings some important questions and solidifies me in pursuing better abstract over definitions. It might also be a good idea to have distinct aliases or compound types for time and (net) identifiers.
Diffstat (limited to 'StarsEx/Element.h')
-rw-r--r--StarsEx/Element.h20
1 files changed, 9 insertions, 11 deletions
diff --git a/StarsEx/Element.h b/StarsEx/Element.h
index 8f188e4..cefe533 100644
--- a/StarsEx/Element.h
+++ b/StarsEx/Element.h
@@ -11,14 +11,15 @@
Package Element (e.g. Flight) class
*/
-#ifndef Element_h
-#define Element_h
+#pragma once
+
+#include <cstdint>
+
+#include <List.h>
+#include <Text.h>
-#include "Types.h"
#include "Geometry.h"
#include "SimObject.h"
-#include "List.h"
-#include "Text.h"
// +--------------------------------------------------------------------+
@@ -48,8 +49,8 @@ public:
virtual int GetIFF() const { return iff; }
int Player() const { return player; }
void SetPlayer(int p) { player = p; }
- DWORD GetLaunchTime() const { return launch_time; }
- void SetLaunchTime(DWORD t);
+ std::uint32_t GetLaunchTime() const { return launch_time; }
+ void SetLaunchTime(std::uint32_t t);
int IntelLevel() const { return intel; }
void SetIntelLevel(int i) { intel = i; }
@@ -158,7 +159,7 @@ protected:
CombatGroup* combat_group;
CombatUnit* combat_unit;
- DWORD launch_time;
+ std::uint32_t launch_time;
double hold_time;
bool rogue;
@@ -166,6 +167,3 @@ protected:
bool zone_lock;
int load[16];
};
-
-#endif // Element_h
-