Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion Tools/auto_extract/extractor.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@
0x09: 'VariableSizeWString',
0x0A: 'HashedString',
0x0B: 'ENUM',
0x0C: 'VariableSizeString', # Technically a "filename" -> GcFilename (?)
0x0C: 'GcFilename', # Technically a "filename" -> GcFilename (?)
0x0D: 'FLAGENUM',
0x0E: 'float',
0x0F: 'double',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
<Compile Include="$(MSBuildThisFileDirectory)Source\MBIN\MBINHeader.cs" />
<Compile Include="$(MSBuildThisFileDirectory)Source\NMS\BaseTypes\Colour.cs" />
<Compile Include="$(MSBuildThisFileDirectory)Source\NMS\BaseTypes\Colour32.cs" />
<Compile Include="$(MSBuildThisFileDirectory)Source\NMS\BaseTypes\OptionalVariableSizeString.cs" />
<Compile Include="$(MSBuildThisFileDirectory)Source\NMS\BaseTypes\GcFilename.cs" />
<Compile Include="$(MSBuildThisFileDirectory)Source\NMS\BaseTypes\HashMap.cs" />
<Compile Include="$(MSBuildThisFileDirectory)Source\NMS\BaseTypes\halfVector4.cs" />
<Compile Include="$(MSBuildThisFileDirectory)Source\NMS\BaseTypes\HashedString.cs" />
Expand Down
1 change: 1 addition & 0 deletions libMBIN/Source/MXML/MXmlFile.cs
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ public static string WriteTemplate(NMSTemplate template, bool hideVersionInfo, b
Indent = true,
Encoding = Encoding.UTF8,
IndentChars = "\t",
NewLineChars = "\n"
};
using (var stringWriter = new EncodedStringWriter(Encoding.UTF8))
using (var xmlTextWriter = XmlWriter.Create(stringWriter, xmlSettings))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,20 @@
namespace libMBIN.NMS
{
[NMS(Size = 0x10, Alignment = 0x1)]
public class OptionalVariableSizeString : NMSTemplate, INMSVariableLengthString
public class GcFilename : NMSTemplate, INMSVariableLengthString
{
public string Value;

public string String {
get => StringValue();
set => Value = value;
}

public string StringValue()
{
return this.Value;
}

public string String {
get => StringValue();
set => Value = value;
}

/// <summary>
/// Returns the value held by this string.
/// </summary>
Expand All @@ -27,14 +27,14 @@ public override string ToString()
return this.Value;
}

public OptionalVariableSizeString(string str)
public GcFilename(string str)
{
this.Value = str;
}

public OptionalVariableSizeString() { }
public GcFilename() { }

public static implicit operator OptionalVariableSizeString ( string str ) => new OptionalVariableSizeString { Value = str };
public static implicit operator string ( OptionalVariableSizeString str ) => str.Value;
public static implicit operator GcFilename ( string str ) => new GcFilename { Value = str };
public static implicit operator string ( GcFilename str ) => str.Value;
}
}
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/BaseTypes/LinkableNMSTemplate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ public class LinkableNMSTemplate : NMSTemplate
// Because of this these names aren't really "real"
// (although there is a mention of `linked` in the exe)
public NMSTemplate Template;
public OptionalVariableSizeString Linked;
public VariableSizeString Linked;
}
}
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/AxisSpecification.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x7D03FF5D22FE8495, NameHash = 0x297A9843)]
[NMS(GUID = 0x691BFBA6C972C960, NameHash = 0x297A9843)]
public class AxisSpecification : NMSTemplate
{
[NMS(Index = 1)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public class GcAIShipDebugSpawnData : NMSTemplate
[NMS(Index = 12)]
/* 0x40 */ public GcSeed Seed;
[NMS(Index = 11)]
/* 0x50 */ public VariableSizeString SpecificModel;
/* 0x50 */ public GcFilename SpecificModel;
[NMS(Index = 8)]
/* 0x60 */ public float HoverHeight;
[NMS(Index = 7)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ namespace libMBIN.NMS.GameComponents
public class GcAISpaceshipInstanceData : NMSTemplate
{
[NMS(Index = 0)]
/* 0x0 */ public VariableSizeString File;
/* 0x0 */ public GcFilename File;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace libMBIN.NMS.GameComponents
public class GcAISpaceshipModelData : NMSTemplate
{
[NMS(Index = 0)]
/* 0x00 */ public VariableSizeString Filename;
/* 0x00 */ public GcFilename Filename;
[NMS(Index = 2)]
/* 0x10 */ public GcAISpaceshipRoles AIRole;
[NMS(Index = 1)]
Expand Down
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcActionSet.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x7744D8D004790BBA, NameHash = 0xE5137E66)]
[NMS(GUID = 0x77433109C9C51B32, NameHash = 0xE5137E66)]
public class GcActionSet : NMSTemplate
{
[NMS(Index = 4)]
Expand Down
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcActionSetAction.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x970E6744D4FE0095, NameHash = 0xEE278077)]
[NMS(GUID = 0x38CF8ECA91D18042, NameHash = 0xEE278077)]
public class GcActionSetAction : NMSTemplate
{
[NMS(Index = 1)]
Expand Down
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcActionSets.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x4104B27A154F104C, NameHash = 0xC212E44)]
[NMS(GUID = 0x1B2E426E7989001, NameHash = 0xC212E44)]
public class GcActionSets : NMSTemplate
{
[NMS(Index = 0)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x86A30C18932D704F, NameHash = 0x6A8BFA82)]
[NMS(GUID = 0xA2A2F2D1CA73414F, NameHash = 0x6A8BFA82)]
public class GcAdditionalOptionMissionOverride : NMSTemplate
{
[NMS(Index = 3)]
Expand Down
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcAlienPuzzleEntry.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x1030106A128A83DF, NameHash = 0x35D4E04)]
[NMS(GUID = 0xD5152A1078112EAE, NameHash = 0x35D4E04)]
public class GcAlienPuzzleEntry : NMSTemplate
{
[NMS(Index = 2)]
Expand Down
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcAlienPuzzleOption.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0xB0FF87C452348F1F, NameHash = 0x981A51EE)]
[NMS(GUID = 0xB94875D65A00403D, NameHash = 0x981A51EE)]
public class GcAlienPuzzleOption : NMSTemplate
{
[NMS(Index = 22)]
Expand Down
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcAlienPuzzleTable.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x39F11E5D98DE5E96, NameHash = 0x3987E9FB)]
[NMS(GUID = 0x957BD25A0DE42A33, NameHash = 0x3987E9FB)]
public class GcAlienPuzzleTable : NMSTemplate
{
[NMS(Index = 0)]
Expand Down
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcAmbientModeCameras.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x6DC0A88DAAA19E85, NameHash = 0xC499EBDE)]
[NMS(GUID = 0x448FC1BE24F28891, NameHash = 0xC499EBDE)]
public class GcAmbientModeCameras : NMSTemplate
{
[NMS(Index = 0)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0xCA2918F54942701, NameHash = 0x5401D7B)]
[NMS(GUID = 0xCFA88EE65D6F97C3, NameHash = 0x5401D7B)]
public class GcArchivedMultitoolData : NMSTemplate
{
[NMS(Index = 0)]
Expand Down
12 changes: 6 additions & 6 deletions libMBIN/Source/NMS/GameComponents/GcArchivedShipData.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,20 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x7B0B87CEAA5CF25F, NameHash = 0xF25F122A)]
[NMS(GUID = 0x55CD0A771B91CA73, NameHash = 0xF25F122A)]
public class GcArchivedShipData : NMSTemplate
{
[NMS(Index = 0)]
/* 0x000 */ public GcPlayerOwnershipData Ownership;
[NMS(Index = 1)]
/* 0x4D0 */ public GcCharacterCustomisationSaveData Customisation;
/* 0x4E0 */ public GcCharacterCustomisationSaveData Customisation;
[NMS(Index = 4)]
/* 0x538 */ public GcSpaceshipClasses ArchivedClass;
/* 0x548 */ public GcSpaceshipClasses ArchivedClass;
[NMS(Index = 5)]
/* 0x53C */ public GcInventoryClass ArchivedInventoryClass;
/* 0x54C */ public GcInventoryClass ArchivedInventoryClass;
[NMS(Index = 3)]
/* 0x540 */ public NMSString0x80 ArchivedName;
/* 0x550 */ public NMSString0x80 ArchivedName;
[NMS(Index = 2)]
/* 0x5C0 */ public bool UsesLegacyColours;
/* 0x5D0 */ public bool UsesLegacyColours;
}
}
12 changes: 7 additions & 5 deletions libMBIN/Source/NMS/GameComponents/GcAreaDamageData.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0xA5E5AA41C6CDB3F, NameHash = 0x65EC65D4)]
[NMS(GUID = 0x193D92C5B64E5BB4, NameHash = 0x65EC65D4)]
public class GcAreaDamageData : NMSTemplate
{
[NMS(Index = 0)]
Expand All @@ -11,13 +11,15 @@ public class GcAreaDamageData : NMSTemplate
/* 0x20 */ public float Damage;
[NMS(Index = 2)]
/* 0x24 */ public float DelayPerMetre;
[NMS(Index = 8)]
/* 0x28 */ public float PhysicsPushForce;
[NMS(Index = 1)]
/* 0x28 */ public float Radius;
/* 0x2C */ public float Radius;
[NMS(Index = 7)]
/* 0x2C */ public bool DamageCreatures;
/* 0x30 */ public bool DamageCreatures;
[NMS(Index = 6)]
/* 0x2D */ public bool DamagePlayers;
/* 0x31 */ public bool DamagePlayers;
[NMS(Index = 5)]
/* 0x2E */ public bool InstantKill;
/* 0x32 */ public bool InstantKill;
}
}
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcAreaDamageDataTable.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0xDF80596DBB1CAB, NameHash = 0x64882C9C)]
[NMS(GUID = 0x1EB712E87F4E0B2D, NameHash = 0x64882C9C)]
public class GcAreaDamageDataTable : NMSTemplate
{
[NMS(Index = 0)]
Expand Down
2 changes: 1 addition & 1 deletion libMBIN/Source/NMS/GameComponents/GcAtmosphereList.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ namespace libMBIN.NMS.GameComponents
public class GcAtmosphereList : NMSTemplate
{
[NMS(Index = 0)]
/* 0x0 */ public List<VariableSizeString> Atmospheres;
/* 0x0 */ public List<GcFilename> Atmospheres;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

namespace libMBIN.NMS.GameComponents
{
[NMS(GUID = 0x5342F07DC0998275, NameHash = 0xC0413ECB)]
[NMS(GUID = 0x470F0B16C831A296, NameHash = 0xC0413ECB)]
public class GcAudioAreaTriggerComponentData : NMSTemplate
{
[NMS(Index = 2, MxmlName = "Enter Distance")]
Expand Down
Loading
Loading