make all file/network-related structs packed
This commit is contained in:
+4
-4
@@ -17,7 +17,7 @@ struct BattleParams {
|
||||
uint8_t unknown[14];
|
||||
uint32_t experience;
|
||||
uint32_t difficulty;
|
||||
};
|
||||
} __attribute__((packed));
|
||||
|
||||
struct BattleParamTable {
|
||||
BattleParams entries[2][3][4][0x60]; // online/offline, episode, difficulty, monster type
|
||||
@@ -28,13 +28,13 @@ struct BattleParamTable {
|
||||
uint8_t monster_type) const;
|
||||
const BattleParams* get_subtable(bool solo, uint8_t episode,
|
||||
uint8_t difficulty) const;
|
||||
};
|
||||
} __attribute__((packed));
|
||||
|
||||
|
||||
|
||||
struct BattleParamIndex {
|
||||
BattleParamTable table_for_episode[3];
|
||||
};
|
||||
} __attribute__((packed));
|
||||
|
||||
// an enemy entry as loaded by the game
|
||||
struct PSOEnemy {
|
||||
@@ -46,7 +46,7 @@ struct PSOEnemy {
|
||||
|
||||
PSOEnemy();
|
||||
PSOEnemy(uint32_t experience, uint32_t rt_index);
|
||||
};
|
||||
} __attribute__((packed));
|
||||
|
||||
std::vector<PSOEnemy> load_map(const char* filename, uint8_t episode,
|
||||
uint8_t difficulty, const BattleParams* bp, bool alt_enemies);
|
||||
|
||||
Reference in New Issue
Block a user