aboutsummaryrefslogtreecommitdiff
path: root/engines/startrek/action.h
diff options
context:
space:
mode:
authorMatthew Stewart2018-07-03 23:55:30 -0400
committerEugene Sandulenko2018-08-09 08:37:30 +0200
commit8c71f2db84b06862b4fefbe3e79fb042e7a60666 (patch)
tree7391b512e479707aa14d6855606f00454f3e5662 /engines/startrek/action.h
parent051ea8c238510db03505cd146025c1db441ace84 (diff)
downloadscummvm-rg350-8c71f2db84b06862b4fefbe3e79fb042e7a60666.tar.gz
scummvm-rg350-8c71f2db84b06862b4fefbe3e79fb042e7a60666.tar.bz2
scummvm-rg350-8c71f2db84b06862b4fefbe3e79fb042e7a60666.zip
STARTREK: Make Action struct POD again
Diffstat (limited to 'engines/startrek/action.h')
-rw-r--r--engines/startrek/action.h14
1 files changed, 3 insertions, 11 deletions
diff --git a/engines/startrek/action.h b/engines/startrek/action.h
index 55a08da738..f6178d8858 100644
--- a/engines/startrek/action.h
+++ b/engines/startrek/action.h
@@ -29,7 +29,7 @@ namespace StarTrek {
class Room;
-enum Acton {
+enum Acton { // TODO: rename
ACTION_TICK = 0,
ACTION_WALK = 1, // Actions 1-5 are directly usable on away missions.
@@ -46,20 +46,12 @@ enum Acton {
ACTION_OPTIONS = 13 // Not really an action, but selectable from action menu
};
-struct Action : Common::Serializable {
+struct Action {
byte type;
byte b1;
byte b2;
byte b3;
- Action() {}
- Action(int _type, int _b1, int _b2, int _b3)
- : type((byte)_type),
- b1((byte)_b1),
- b2((byte)_b2),
- b3((byte)_b3) {}
-
-
// ACTION_USE, ACTION_GET, ACTION_LOOK, ACTION_TALK
byte activeObject() { return b1; }
byte passiveObject() { return b2; }
@@ -85,7 +77,7 @@ struct Action : Common::Serializable {
return (type << 24) | (b1 << 16) | (b2 << 8) | (b3 << 0);
}
- virtual void saveLoadWithSerializer(Common::Serializer &ser) {
+ void saveLoadWithSerializer(Common::Serializer &ser) {
ser.syncAsByte(type);
ser.syncAsByte(b1);
ser.syncAsByte(b2);