mirror of
https://github.com/aimrebirth/tools.git
synced 2026-04-14 17:33:25 +00:00
Improve ORGS and MMS_C_CONFIG segments.
This commit is contained in:
parent
5c88d06a62
commit
0c24d18b92
2 changed files with 48 additions and 49 deletions
|
|
@ -257,6 +257,13 @@ void mech_segment::ammo_count::load(const buffer &b)
|
|||
|
||||
void mech_segment::mech::glider_desc::load(const buffer &b)
|
||||
{
|
||||
READ(b, unk15_1); // size?
|
||||
|
||||
b.read_vector(equipments);
|
||||
|
||||
READ(b, unk40);
|
||||
READ(b, unk4);
|
||||
|
||||
//
|
||||
glider.load(b);
|
||||
//if (isPlayer())
|
||||
|
|
@ -388,13 +395,6 @@ void mech_segment::mech::load(const buffer &b)
|
|||
if (unk14 == 0)
|
||||
return;
|
||||
|
||||
READ(b, unk15_1); // size?
|
||||
|
||||
b.read_vector(equipments);
|
||||
|
||||
READ(b, unk40);
|
||||
READ(b, unk4);
|
||||
|
||||
gl.load(b);
|
||||
}
|
||||
|
||||
|
|
@ -471,6 +471,30 @@ void builds_segment::load(const buffer &b)
|
|||
b.read_vector(builds);
|
||||
}
|
||||
|
||||
void orgs_segment::org::base::mech::load(const buffer &b)
|
||||
{
|
||||
READ_STRING(b, name);
|
||||
}
|
||||
|
||||
void orgs_segment::org::base::load(const buffer &b)
|
||||
{
|
||||
READ_STRING(b, name);
|
||||
READ(b, unk2);
|
||||
READ(b, unk3);
|
||||
READ(b, unk4);
|
||||
b.read_vector(mechs);
|
||||
|
||||
u32 n;
|
||||
u32 unk0;
|
||||
READ(b, n);
|
||||
while (n--)
|
||||
READ(b, unk0);
|
||||
|
||||
READ_STRING(b, org);
|
||||
READ(b, unk5);
|
||||
READ(b, unk6);
|
||||
}
|
||||
|
||||
void orgs_segment::org::load(const buffer &b)
|
||||
{
|
||||
READ(b, unk0);
|
||||
|
|
@ -624,17 +648,11 @@ void mms_state_segment::load(const buffer &b)
|
|||
READ_STRING(b, name);
|
||||
}
|
||||
|
||||
void mms_c_config_segment::object::load(const buffer &b)
|
||||
{
|
||||
READ(b, unk0);
|
||||
gl.load(b);
|
||||
}
|
||||
|
||||
void mms_c_config_segment::load(const buffer &b)
|
||||
{
|
||||
while (!b.eof())
|
||||
{
|
||||
object o;
|
||||
mech_segment::mech::glider_desc o;
|
||||
o.load(b);
|
||||
objects.push_back(o);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -394,6 +394,13 @@ struct mech_segment : public segment
|
|||
{
|
||||
struct glider_desc
|
||||
{
|
||||
uint32_t unk15_1; // size of segment (glider_desc struct)
|
||||
|
||||
std::vector<equipment> equipments;
|
||||
|
||||
float unk40;
|
||||
uint32_t unk4[7];
|
||||
|
||||
// glider
|
||||
// g_unk = glider unknown
|
||||
|
||||
|
|
@ -456,14 +463,9 @@ struct mech_segment : public segment
|
|||
uint32_t unk13[3];
|
||||
uint8_t unk14;
|
||||
uint32_t unk15;
|
||||
uint32_t unk15_1;
|
||||
|
||||
uint32_t unk16 = 0;
|
||||
|
||||
std::vector<equipment> equipments;
|
||||
|
||||
float unk40;
|
||||
uint32_t unk4[7];
|
||||
|
||||
glider_desc gl;
|
||||
|
||||
void load(const buffer &b);
|
||||
|
|
@ -557,19 +559,8 @@ struct orgs_segment : public segment
|
|||
struct mech
|
||||
{
|
||||
std::string name;
|
||||
u32 unk0[2];
|
||||
std::string org;
|
||||
u32 unk1;
|
||||
f32 unk2;
|
||||
|
||||
void load(const buffer &b)
|
||||
{
|
||||
READ_STRING(b, name);
|
||||
READ(b, unk0);
|
||||
READ_STRING(b, org);
|
||||
READ(b, unk1);
|
||||
READ(b, unk2);
|
||||
}
|
||||
void load(const buffer &b);
|
||||
};
|
||||
|
||||
std::string name;
|
||||
|
|
@ -577,15 +568,13 @@ struct orgs_segment : public segment
|
|||
u8 unk3;
|
||||
uint32_t unk4[2];
|
||||
std::vector<mech> mechs;
|
||||
// u32 n;
|
||||
// u32 unk0[n];
|
||||
std::string org;
|
||||
u32 unk5;
|
||||
f32 unk6;
|
||||
|
||||
void load(const buffer &b)
|
||||
{
|
||||
READ_STRING(b, name);
|
||||
READ(b, unk2);
|
||||
READ(b, unk3);
|
||||
READ(b, unk4);
|
||||
b.read_vector(mechs);
|
||||
}
|
||||
void load(const buffer &b);
|
||||
};
|
||||
|
||||
uint32_t unk0[9];
|
||||
|
|
@ -657,15 +646,7 @@ struct mms_state_segment : public segment
|
|||
|
||||
struct mms_c_config_segment : public segment
|
||||
{
|
||||
struct object
|
||||
{
|
||||
u32 unk0[10]; // maybe attach to glider_desc?
|
||||
mech_segment::mech::glider_desc gl;
|
||||
|
||||
void load(const buffer &b);
|
||||
};
|
||||
|
||||
std::vector<object> objects;
|
||||
std::vector<mech_segment::mech::glider_desc> objects;
|
||||
|
||||
void load(const buffer &b);
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue