mirror of
https://mirror.ghproxy.com/https://github.com/dexyfex/CodeWalker
synced 2024-11-17 04:22:54 +08:00
commit
5fe554f9b3
@ -5383,7 +5383,6 @@ namespace CodeWalker.GameFiles
|
|||||||
public byte Unused13 { get; set; }
|
public byte Unused13 { get; set; }
|
||||||
public byte Unused14 { get; set; }
|
public byte Unused14 { get; set; }
|
||||||
public DirAmbience[] DirAmbiences { get; set; }
|
public DirAmbience[] DirAmbiences { get; set; }
|
||||||
public uint Unused15 { get; set; }
|
|
||||||
public struct DirAmbience : IMetaXmlItem
|
public struct DirAmbience : IMetaXmlItem
|
||||||
{
|
{
|
||||||
public MetaHash Name { get; set; }
|
public MetaHash Name { get; set; }
|
||||||
@ -5489,6 +5488,7 @@ namespace CodeWalker.GameFiles
|
|||||||
{
|
{
|
||||||
DirAmbiences[i] = new DirAmbience(br);
|
DirAmbiences[i] = new DirAmbience(br);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
public override void Write(BinaryWriter bw)
|
public override void Write(BinaryWriter bw)
|
||||||
{
|
{
|
||||||
@ -5571,8 +5571,7 @@ namespace CodeWalker.GameFiles
|
|||||||
{
|
{
|
||||||
DirAmbiences[i].Write(bw);
|
DirAmbiences[i].Write(bw);
|
||||||
}
|
}
|
||||||
if (NumDirAmbiences != 0)
|
while ((bw.BaseStream.Position & 0xF) != 0) bw.Write((byte)0); //pad out to next 16 bytes
|
||||||
{ }
|
|
||||||
}
|
}
|
||||||
public override void WriteXml(StringBuilder sb, int indent)
|
public override void WriteXml(StringBuilder sb, int indent)
|
||||||
{
|
{
|
||||||
@ -7589,28 +7588,28 @@ namespace CodeWalker.GameFiles
|
|||||||
public class Dat151ModelAudioCollisionSettings : Dat151RelData
|
public class Dat151ModelAudioCollisionSettings : Dat151RelData
|
||||||
{
|
{
|
||||||
public FlagsUint Flags { get; set; }
|
public FlagsUint Flags { get; set; }
|
||||||
public int Unk01 { get; set; }
|
public uint LastFragTime { get; set; }
|
||||||
public int Unk02 { get; set; }
|
public uint MediumIntensity { get; set; }
|
||||||
public int Unk03 { get; set; }
|
public uint HighIntensity { get; set; }
|
||||||
public MetaHash Break { get; set; }
|
public MetaHash BreakSound { get; set; }
|
||||||
public MetaHash Unk05 { get; set; }
|
public MetaHash DestroySound { get; set; }
|
||||||
public MetaHash Unk06 { get; set; }
|
public MetaHash UprootSound { get; set; }
|
||||||
public MetaHash Wind { get; set; }//sound set
|
public MetaHash WindSounds { get; set; }
|
||||||
public MetaHash Unk08 { get; set; }
|
public MetaHash SwingSound { get; set; }
|
||||||
public float Unk09 { get; set; }
|
public float MinSwingVel { get; set; }
|
||||||
public float Unk10 { get; set; }
|
public float MaxswingVel { get; set; }
|
||||||
public MetaHash Rain { get; set; }
|
public MetaHash RainLoop { get; set; }
|
||||||
public MetaHash Rattle { get; set; }
|
public MetaHash ShockwaveSound { get; set; }
|
||||||
public MetaHash Unk13 { get; set; }
|
public MetaHash RandomAmbient { get; set; }
|
||||||
public MetaHash Resonance { get; set; }
|
public MetaHash EntityResonance { get; set; }
|
||||||
public byte Unk15 { get; set; }
|
public byte Weight { get; set; }
|
||||||
public byte MaterialsCount { get; set; }
|
public byte MaterialsCount { get; set; }
|
||||||
public byte Unk16 { get; set; }
|
public byte padding00 { get; set; }
|
||||||
public byte Unk17 { get; set; }
|
public byte padding01 { get; set; }
|
||||||
public MetaHash Material { get; set; }//not used
|
public MetaHash Material { get; set; }
|
||||||
public Dat151ModelAudioCollisionSettingsMaterialItem[] Materials { get; set; }//CollisionMaterialSettings pairs
|
public Dat151ModelAudioCollisionSettingsMaterialItem[] Materials { get; set; }
|
||||||
public uint PhysicsCount { get; set; }
|
public uint FragComponentSettingsCount { get; set; }
|
||||||
public MetaHash[] Physics { get; set; }//more mod objects
|
public MetaHash[] FragComponentSettings { get; set; }
|
||||||
|
|
||||||
|
|
||||||
public Dat151ModelAudioCollisionSettings(RelFile rel) : base(rel)
|
public Dat151ModelAudioCollisionSettings(RelFile rel) : base(rel)
|
||||||
@ -7621,49 +7620,31 @@ namespace CodeWalker.GameFiles
|
|||||||
public Dat151ModelAudioCollisionSettings(RelData d, BinaryReader br) : base(d, br)
|
public Dat151ModelAudioCollisionSettings(RelData d, BinaryReader br) : base(d, br)
|
||||||
{
|
{
|
||||||
Flags = br.ReadUInt32();
|
Flags = br.ReadUInt32();
|
||||||
Unk01 = br.ReadInt32();
|
LastFragTime = br.ReadUInt32();
|
||||||
Unk02 = br.ReadInt32();
|
MediumIntensity = br.ReadUInt32();
|
||||||
Unk03 = br.ReadInt32();
|
HighIntensity = br.ReadUInt32();
|
||||||
Break = br.ReadUInt32();
|
BreakSound = br.ReadUInt32();
|
||||||
Unk05 = br.ReadUInt32();
|
DestroySound = br.ReadUInt32();
|
||||||
Unk06 = br.ReadUInt32();
|
UprootSound = br.ReadUInt32();
|
||||||
Wind = br.ReadUInt32();
|
WindSounds = br.ReadUInt32();
|
||||||
Unk08 = br.ReadUInt32();
|
SwingSound = br.ReadUInt32();
|
||||||
Unk09 = br.ReadSingle();
|
MinSwingVel = br.ReadSingle();
|
||||||
Unk10 = br.ReadSingle();
|
MaxswingVel = br.ReadSingle();
|
||||||
Rain = br.ReadUInt32();
|
RainLoop = br.ReadUInt32();
|
||||||
Rattle = br.ReadUInt32();
|
ShockwaveSound = br.ReadUInt32();
|
||||||
Unk13 = br.ReadUInt32();
|
RandomAmbient = br.ReadUInt32();
|
||||||
Resonance = br.ReadUInt32();
|
EntityResonance = br.ReadUInt32();
|
||||||
Unk15 = br.ReadByte();
|
Weight = br.ReadByte();
|
||||||
MaterialsCount = br.ReadByte();
|
MaterialsCount = br.ReadByte();
|
||||||
Unk16 = br.ReadByte();
|
padding00 = br.ReadByte();
|
||||||
Unk17 = br.ReadByte();
|
padding01 = br.ReadByte();
|
||||||
|
|
||||||
//byte tc1 = (byte)((Unk15) & 0xFF);
|
|
||||||
//byte tc2 = (byte)((Unk15 >> 8) & 0xFF);
|
|
||||||
//byte tc3 = (byte)((Unk15 >> 16) & 0xFF);
|
|
||||||
//byte tc4 = (byte)((Unk15 >> 24) & 0xFF);
|
|
||||||
|
|
||||||
switch (Unk15)//not sure what this is
|
|
||||||
{
|
|
||||||
case 0:
|
|
||||||
case 1:
|
|
||||||
case 2:
|
|
||||||
case 3:
|
|
||||||
case 4:
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
if (MaterialsCount == 0)
|
if (MaterialsCount == 0)
|
||||||
{
|
{
|
||||||
Material = br.ReadUInt32();
|
Material = br.ReadUInt32();
|
||||||
//Physics = new MetaHash[] { Material };
|
|
||||||
}
|
}
|
||||||
else //if (MaterialsCount > 0)
|
else
|
||||||
{
|
{
|
||||||
var tracks1 = new Dat151ModelAudioCollisionSettingsMaterialItem[MaterialsCount];
|
var tracks1 = new Dat151ModelAudioCollisionSettingsMaterialItem[MaterialsCount];
|
||||||
for (int i = 0; i < MaterialsCount; i++)
|
for (int i = 0; i < MaterialsCount; i++)
|
||||||
@ -7672,14 +7653,14 @@ namespace CodeWalker.GameFiles
|
|||||||
}
|
}
|
||||||
Materials = tracks1;
|
Materials = tracks1;
|
||||||
|
|
||||||
PhysicsCount = br.ReadUInt32();
|
FragComponentSettingsCount = br.ReadUInt32();
|
||||||
|
|
||||||
var tracks2 = new MetaHash[PhysicsCount];
|
var tracks2 = new MetaHash[FragComponentSettingsCount];
|
||||||
for (int i = 0; i < PhysicsCount; i++)
|
for (int i = 0; i < FragComponentSettingsCount; i++)
|
||||||
{
|
{
|
||||||
tracks2[i] = br.ReadUInt32();
|
tracks2[i] = br.ReadUInt32();
|
||||||
}
|
}
|
||||||
Physics = tracks2;
|
FragComponentSettings = tracks2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public override void Write(BinaryWriter bw)
|
public override void Write(BinaryWriter bw)
|
||||||
@ -7687,40 +7668,41 @@ namespace CodeWalker.GameFiles
|
|||||||
WriteTypeAndOffset(bw);
|
WriteTypeAndOffset(bw);
|
||||||
|
|
||||||
bw.Write(Flags);
|
bw.Write(Flags);
|
||||||
bw.Write(Unk01);
|
bw.Write(LastFragTime);
|
||||||
bw.Write(Unk02);
|
bw.Write(MediumIntensity);
|
||||||
bw.Write(Unk03);
|
bw.Write(HighIntensity);
|
||||||
bw.Write(Break);
|
bw.Write(BreakSound);
|
||||||
bw.Write(Unk05);
|
bw.Write(DestroySound);
|
||||||
bw.Write(Unk06);
|
bw.Write(UprootSound);
|
||||||
bw.Write(Wind);
|
bw.Write(WindSounds);
|
||||||
bw.Write(Unk08);
|
bw.Write(SwingSound);
|
||||||
bw.Write(Unk09);
|
bw.Write(MinSwingVel);
|
||||||
bw.Write(Unk10);
|
bw.Write(MaxswingVel);
|
||||||
bw.Write(Rain);
|
bw.Write(RainLoop);
|
||||||
bw.Write(Rattle);
|
bw.Write(ShockwaveSound);
|
||||||
bw.Write(Unk13);
|
bw.Write(RandomAmbient);
|
||||||
bw.Write(Resonance);
|
bw.Write(EntityResonance);
|
||||||
bw.Write(Unk15);
|
bw.Write(Weight);
|
||||||
bw.Write(MaterialsCount);
|
bw.Write(MaterialsCount);
|
||||||
bw.Write(Unk16);
|
bw.Write(padding00);
|
||||||
bw.Write(Unk17);
|
bw.Write(padding01);
|
||||||
|
|
||||||
|
|
||||||
if (MaterialsCount == 0)
|
if (MaterialsCount == 0)
|
||||||
{
|
{
|
||||||
bw.Write(Material);//hrmm
|
bw.Write(Material);
|
||||||
}
|
}
|
||||||
else //if (MaterialsCount > 0)
|
else
|
||||||
{
|
{
|
||||||
for (int i = 0; i < MaterialsCount; i++)
|
for (int i = 0; i < MaterialsCount; i++)
|
||||||
{
|
{
|
||||||
Materials[i].Write(bw);
|
Materials[i].Write(bw);
|
||||||
}
|
}
|
||||||
bw.Write(PhysicsCount);
|
|
||||||
for (int i = 0; i < PhysicsCount; i++)
|
bw.Write(FragComponentSettingsCount);
|
||||||
|
for (int i = 0; i < FragComponentSettingsCount; i++)
|
||||||
{
|
{
|
||||||
bw.Write(Physics[i]);
|
bw.Write(FragComponentSettings[i]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -7728,23 +7710,21 @@ namespace CodeWalker.GameFiles
|
|||||||
public override void WriteXml(StringBuilder sb, int indent)
|
public override void WriteXml(StringBuilder sb, int indent)
|
||||||
{
|
{
|
||||||
RelXml.ValueTag(sb, indent, "Flags", "0x" + Flags.Hex);
|
RelXml.ValueTag(sb, indent, "Flags", "0x" + Flags.Hex);
|
||||||
RelXml.ValueTag(sb, indent, "Unk01", Unk01.ToString());
|
RelXml.ValueTag(sb, indent, "LastFragTime", LastFragTime.ToString());
|
||||||
RelXml.ValueTag(sb, indent, "Unk02", Unk02.ToString());
|
RelXml.ValueTag(sb, indent, "MediumIntensity", MediumIntensity.ToString());
|
||||||
RelXml.ValueTag(sb, indent, "Unk03", Unk03.ToString());
|
RelXml.ValueTag(sb, indent, "HighIntensity", HighIntensity.ToString());
|
||||||
RelXml.StringTag(sb, indent, "Break", RelXml.HashString(Break));
|
RelXml.StringTag(sb, indent, "BreakSound", RelXml.HashString(BreakSound));
|
||||||
RelXml.StringTag(sb, indent, "Unk05", RelXml.HashString(Unk05));
|
RelXml.StringTag(sb, indent, "DestroySound", RelXml.HashString(DestroySound));
|
||||||
RelXml.StringTag(sb, indent, "Unk06", RelXml.HashString(Unk06));
|
RelXml.StringTag(sb, indent, "UprootSound", RelXml.HashString(UprootSound));
|
||||||
RelXml.StringTag(sb, indent, "Wind", RelXml.HashString(Wind));
|
RelXml.StringTag(sb, indent, "WindSounds", RelXml.HashString(WindSounds));
|
||||||
RelXml.StringTag(sb, indent, "Unk08", RelXml.HashString(Unk08));
|
RelXml.StringTag(sb, indent, "SwingSound", RelXml.HashString(SwingSound));
|
||||||
RelXml.ValueTag(sb, indent, "Unk09", FloatUtil.ToString(Unk09));
|
RelXml.ValueTag(sb, indent, "MinSwingVel", FloatUtil.ToString(MinSwingVel));
|
||||||
RelXml.ValueTag(sb, indent, "Unk10", FloatUtil.ToString(Unk10));
|
RelXml.ValueTag(sb, indent, "MaxswingVel", FloatUtil.ToString(MaxswingVel));
|
||||||
RelXml.StringTag(sb, indent, "Rain", RelXml.HashString(Rain));
|
RelXml.StringTag(sb, indent, "RainLoop", RelXml.HashString(RainLoop));
|
||||||
RelXml.StringTag(sb, indent, "Rattle", RelXml.HashString(Rattle));
|
RelXml.StringTag(sb, indent, "ShockwaveSound", RelXml.HashString(ShockwaveSound));
|
||||||
RelXml.StringTag(sb, indent, "Unk13", RelXml.HashString(Unk13));
|
RelXml.StringTag(sb, indent, "RandomAmbient", RelXml.HashString(RandomAmbient));
|
||||||
RelXml.StringTag(sb, indent, "Resonance", RelXml.HashString(Resonance));
|
RelXml.StringTag(sb, indent, "EntityResonance", RelXml.HashString(EntityResonance));
|
||||||
RelXml.ValueTag(sb, indent, "Unk15", Unk15.ToString());
|
RelXml.ValueTag(sb, indent, "Weight", Weight.ToString());
|
||||||
RelXml.ValueTag(sb, indent, "Unk16", Unk16.ToString());
|
|
||||||
RelXml.ValueTag(sb, indent, "Unk17", Unk17.ToString());
|
|
||||||
if (MaterialsCount == 0)
|
if (MaterialsCount == 0)
|
||||||
{
|
{
|
||||||
RelXml.StringTag(sb, indent, "Material", RelXml.HashString(Material));
|
RelXml.StringTag(sb, indent, "Material", RelXml.HashString(Material));
|
||||||
@ -7752,34 +7732,32 @@ namespace CodeWalker.GameFiles
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
RelXml.WriteItemArray(sb, Materials, indent, "Materials");
|
RelXml.WriteItemArray(sb, Materials, indent, "Materials");
|
||||||
RelXml.WriteHashItemArray(sb, Physics, indent, "Physics");
|
RelXml.WriteHashItemArray(sb, FragComponentSettings, indent, "FragComponentSettings");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
public override void ReadXml(XmlNode node)
|
public override void ReadXml(XmlNode node)
|
||||||
{
|
{
|
||||||
Flags = Xml.GetChildUIntAttribute(node, "Flags", "value");
|
Flags = Xml.GetChildUIntAttribute(node, "Flags", "value");
|
||||||
Unk01 = Xml.GetChildIntAttribute(node, "Unk01", "value");
|
LastFragTime = Xml.GetChildUIntAttribute(node, "LastFragTime", "value");
|
||||||
Unk02 = Xml.GetChildIntAttribute(node, "Unk02", "value");
|
MediumIntensity = Xml.GetChildUIntAttribute(node, "MediumIntensity", "value");
|
||||||
Unk03 = Xml.GetChildIntAttribute(node, "Unk03", "value");
|
HighIntensity = Xml.GetChildUIntAttribute(node, "HighIntensity", "value");
|
||||||
Break = XmlRel.GetHash(Xml.GetChildInnerText(node, "Break"));
|
BreakSound = XmlRel.GetHash(Xml.GetChildInnerText(node, "BreakSound"));
|
||||||
Unk05 = XmlRel.GetHash(Xml.GetChildInnerText(node, "Unk05"));
|
DestroySound = XmlRel.GetHash(Xml.GetChildInnerText(node, "DestroySound"));
|
||||||
Unk06 = XmlRel.GetHash(Xml.GetChildInnerText(node, "Unk06"));
|
UprootSound = XmlRel.GetHash(Xml.GetChildInnerText(node, "UprootSound"));
|
||||||
Wind = XmlRel.GetHash(Xml.GetChildInnerText(node, "Wind"));
|
WindSounds = XmlRel.GetHash(Xml.GetChildInnerText(node, "WindSounds"));
|
||||||
Unk08 = XmlRel.GetHash(Xml.GetChildInnerText(node, "Unk08"));
|
SwingSound = XmlRel.GetHash(Xml.GetChildInnerText(node, "SwingSound"));
|
||||||
Unk09 = Xml.GetChildFloatAttribute(node, "Unk09", "value");
|
MinSwingVel = Xml.GetChildFloatAttribute(node, "MinSwingVel", "value");
|
||||||
Unk10 = Xml.GetChildFloatAttribute(node, "Unk10", "value");
|
MaxswingVel = Xml.GetChildFloatAttribute(node, "MaxswingVel", "value");
|
||||||
Rain = XmlRel.GetHash(Xml.GetChildInnerText(node, "Rain"));
|
RainLoop = XmlRel.GetHash(Xml.GetChildInnerText(node, "RainLoop"));
|
||||||
Rattle = XmlRel.GetHash(Xml.GetChildInnerText(node, "Rattle"));
|
ShockwaveSound = XmlRel.GetHash(Xml.GetChildInnerText(node, "ShockwaveSound"));
|
||||||
Unk13 = XmlRel.GetHash(Xml.GetChildInnerText(node, "Unk13"));
|
RandomAmbient = XmlRel.GetHash(Xml.GetChildInnerText(node, "RandomAmbient"));
|
||||||
Resonance = XmlRel.GetHash(Xml.GetChildInnerText(node, "Resonance"));
|
EntityResonance = XmlRel.GetHash(Xml.GetChildInnerText(node, "EntityResonance"));
|
||||||
Unk15 = (byte)Xml.GetChildUIntAttribute(node, "Unk15", "value");
|
Weight = (byte)Xml.GetChildUIntAttribute(node, "Weight", "value");
|
||||||
Unk16 = (byte)Xml.GetChildUIntAttribute(node, "Unk16", "value");
|
|
||||||
Unk17 = (byte)Xml.GetChildUIntAttribute(node, "Unk17", "value");
|
|
||||||
Material = XmlRel.GetHash(Xml.GetChildInnerText(node, "Material"));
|
Material = XmlRel.GetHash(Xml.GetChildInnerText(node, "Material"));
|
||||||
Materials = XmlRel.ReadItemArray<Dat151ModelAudioCollisionSettingsMaterialItem>(node, "Materials");
|
Materials = XmlRel.ReadItemArray<Dat151ModelAudioCollisionSettingsMaterialItem>(node, "Materials");
|
||||||
MaterialsCount = (byte)(Materials?.Length ?? 0);
|
MaterialsCount = (byte)(Materials?.Length ?? 0);
|
||||||
Physics = XmlRel.ReadHashItemArray(node, "Physics");
|
FragComponentSettings = XmlRel.ReadHashItemArray(node, "FragComponentSettings");
|
||||||
PhysicsCount = (uint)(Physics?.Length ?? 0);
|
FragComponentSettingsCount = (uint)(FragComponentSettings?.Length ?? 0);
|
||||||
}
|
}
|
||||||
public override uint[] GetHashTableOffsets()
|
public override uint[] GetHashTableOffsets()
|
||||||
{
|
{
|
||||||
@ -7788,7 +7766,7 @@ namespace CodeWalker.GameFiles
|
|||||||
if (MaterialsCount == 0)
|
if (MaterialsCount == 0)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
else //if (MaterialsCount > 0)
|
else
|
||||||
{
|
{
|
||||||
for (uint i = 0; i < MaterialsCount; i++)
|
for (uint i = 0; i < MaterialsCount; i++)
|
||||||
{
|
{
|
||||||
@ -7797,7 +7775,7 @@ namespace CodeWalker.GameFiles
|
|||||||
offs += 8;
|
offs += 8;
|
||||||
}
|
}
|
||||||
offs += 4;
|
offs += 4;
|
||||||
for (uint i = 0; i < PhysicsCount; i++)
|
for (uint i = 0; i < FragComponentSettingsCount; i++)
|
||||||
{
|
{
|
||||||
offsets.Add(offs);
|
offsets.Add(offs);
|
||||||
offs += 4;
|
offs += 4;
|
||||||
@ -7808,7 +7786,7 @@ namespace CodeWalker.GameFiles
|
|||||||
}
|
}
|
||||||
public override MetaHash[] GetSoundHashes()
|
public override MetaHash[] GetSoundHashes()
|
||||||
{
|
{
|
||||||
return new[] { Break, Unk05, Unk06, Wind, Unk08, Rain, Rattle, Unk13, Resonance };
|
return new[] { BreakSound, DestroySound, UprootSound, WindSounds, SwingSound, RainLoop, ShockwaveSound, RandomAmbient, EntityResonance };
|
||||||
}
|
}
|
||||||
public override MetaHash[] GetGameHashes()
|
public override MetaHash[] GetGameHashes()
|
||||||
{
|
{
|
||||||
@ -7822,9 +7800,9 @@ namespace CodeWalker.GameFiles
|
|||||||
list.Add(item.OutputMaterial);
|
list.Add(item.OutputMaterial);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (Physics != null)
|
if (FragComponentSettings != null)
|
||||||
{
|
{
|
||||||
list.AddRange(Physics);
|
list.AddRange(FragComponentSettings);
|
||||||
}
|
}
|
||||||
return list.ToArray();
|
return list.ToArray();
|
||||||
}
|
}
|
||||||
@ -9872,7 +9850,7 @@ namespace CodeWalker.GameFiles
|
|||||||
RotationAngle = Xml.GetChildFloatAttribute(node, "RotationAngle", "value");
|
RotationAngle = Xml.GetChildFloatAttribute(node, "RotationAngle", "value");
|
||||||
NextShoreline = Xml.GetChildUIntAttribute(node, "NextShoreline", "value");
|
NextShoreline = Xml.GetChildUIntAttribute(node, "NextShoreline", "value");
|
||||||
RiverType = Xml.GetChildUIntAttribute(node, "RiverType", "value");
|
RiverType = Xml.GetChildUIntAttribute(node, "RiverType", "value");
|
||||||
DefaultHeight = Xml.GetChildUIntAttribute(node, "DefaultHeight", "value");
|
DefaultHeight = Xml.GetChildFloatAttribute(node, "DefaultHeight", "value");
|
||||||
Points = Xml.GetChildRawVector3Array(node, "Points");
|
Points = Xml.GetChildRawVector3Array(node, "Points");
|
||||||
PointsCount = (uint)(Points?.Length ?? 0);
|
PointsCount = (uint)(Points?.Length ?? 0);
|
||||||
}
|
}
|
||||||
@ -10615,8 +10593,6 @@ namespace CodeWalker.GameFiles
|
|||||||
ChassisStressSensitivityScalar = br.ReadSingle();
|
ChassisStressSensitivityScalar = br.ReadSingle();
|
||||||
ChassisStressVolumeBoost = br.ReadInt32();
|
ChassisStressVolumeBoost = br.ReadInt32();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
var bytesleft = br.BaseStream.Length - br.BaseStream.Position;
|
var bytesleft = br.BaseStream.Length - br.BaseStream.Position;
|
||||||
switch (bytesleft) // Check for additional left over bytes
|
switch (bytesleft) // Check for additional left over bytes
|
||||||
{
|
{
|
||||||
@ -10628,12 +10604,13 @@ namespace CodeWalker.GameFiles
|
|||||||
case 36: // if 36 additional bytes, read remaining values
|
case 36: // if 36 additional bytes, read remaining values
|
||||||
VehicleRainSound = br.ReadUInt32();
|
VehicleRainSound = br.ReadUInt32();
|
||||||
AdditionalRevsIncreaseSmoothing = br.ReadUInt16();
|
AdditionalRevsIncreaseSmoothing = br.ReadUInt16();
|
||||||
|
AdditionalRevsDecreaseSmoothing = br.ReadUInt16();
|
||||||
AdditionalGearChangeSmoothing = br.ReadUInt16();
|
AdditionalGearChangeSmoothing = br.ReadUInt16();
|
||||||
AdditionalGearChangeSmoothingTime = br.ReadUInt16();
|
AdditionalGearChangeSmoothingTime = br.ReadUInt16();
|
||||||
ConvertibleRoofInteriorSoundSet = br.ReadUInt32();
|
ConvertibleRoofInteriorSoundSet = br.ReadUInt32();
|
||||||
VehicleRainSoundInterior = br.ReadUInt32();
|
VehicleRainSoundInterior = br.ReadUInt32();
|
||||||
CabinToneLoop = br.ReadUInt32();
|
CabinToneLoop = br.ReadUInt32();
|
||||||
InteriorViewEngineOpenness = br.ReadInt32();
|
InteriorViewEngineOpenness = br.ReadSingle();
|
||||||
JumpLandSoundInterior = br.ReadUInt32();
|
JumpLandSoundInterior = br.ReadUInt32();
|
||||||
DamagedJumpLandSoundInterior = br.ReadUInt32();
|
DamagedJumpLandSoundInterior = br.ReadUInt32();
|
||||||
break;
|
break;
|
||||||
@ -10722,6 +10699,7 @@ namespace CodeWalker.GameFiles
|
|||||||
if ((VehicleRainSoundInterior != 0) || (JumpLandSoundInterior != 0) || (DamagedJumpLandSoundInterior != 0))
|
if ((VehicleRainSoundInterior != 0) || (JumpLandSoundInterior != 0) || (DamagedJumpLandSoundInterior != 0))
|
||||||
{
|
{
|
||||||
bw.Write(AdditionalRevsIncreaseSmoothing);
|
bw.Write(AdditionalRevsIncreaseSmoothing);
|
||||||
|
bw.Write(AdditionalRevsDecreaseSmoothing);
|
||||||
bw.Write(AdditionalGearChangeSmoothing);
|
bw.Write(AdditionalGearChangeSmoothing);
|
||||||
bw.Write(AdditionalGearChangeSmoothingTime);
|
bw.Write(AdditionalGearChangeSmoothingTime);
|
||||||
bw.Write(ConvertibleRoofInteriorSoundSet);
|
bw.Write(ConvertibleRoofInteriorSoundSet);
|
||||||
@ -10804,6 +10782,8 @@ namespace CodeWalker.GameFiles
|
|||||||
RelXml.ValueTag(sb, indent, "ClatterVolumeBoost", ClatterVolumeBoost.ToString());
|
RelXml.ValueTag(sb, indent, "ClatterVolumeBoost", ClatterVolumeBoost.ToString());
|
||||||
RelXml.ValueTag(sb, indent, "ChassisStressSensitivityScalar", FloatUtil.ToString(ChassisStressSensitivityScalar));
|
RelXml.ValueTag(sb, indent, "ChassisStressSensitivityScalar", FloatUtil.ToString(ChassisStressSensitivityScalar));
|
||||||
RelXml.ValueTag(sb, indent, "ChassisStressVolumeBoost", ChassisStressVolumeBoost.ToString());
|
RelXml.ValueTag(sb, indent, "ChassisStressVolumeBoost", ChassisStressVolumeBoost.ToString());
|
||||||
|
|
||||||
|
|
||||||
RelXml.StringTag(sb, indent, "VehicleRainSound", RelXml.HashString(VehicleRainSound));
|
RelXml.StringTag(sb, indent, "VehicleRainSound", RelXml.HashString(VehicleRainSound));
|
||||||
RelXml.ValueTag(sb, indent, "AdditionalRevsIncreaseSmoothing", AdditionalRevsIncreaseSmoothing.ToString());
|
RelXml.ValueTag(sb, indent, "AdditionalRevsIncreaseSmoothing", AdditionalRevsIncreaseSmoothing.ToString());
|
||||||
RelXml.ValueTag(sb, indent, "AdditionalRevsDecreaseSmoothing", AdditionalRevsDecreaseSmoothing.ToString());
|
RelXml.ValueTag(sb, indent, "AdditionalRevsDecreaseSmoothing", AdditionalRevsDecreaseSmoothing.ToString());
|
||||||
@ -10812,7 +10792,7 @@ namespace CodeWalker.GameFiles
|
|||||||
RelXml.StringTag(sb, indent, "ConvertibleRoofInteriorSoundSet", RelXml.HashString(ConvertibleRoofInteriorSoundSet));
|
RelXml.StringTag(sb, indent, "ConvertibleRoofInteriorSoundSet", RelXml.HashString(ConvertibleRoofInteriorSoundSet));
|
||||||
RelXml.StringTag(sb, indent, "VehicleRainSoundInterior", RelXml.HashString(VehicleRainSoundInterior));
|
RelXml.StringTag(sb, indent, "VehicleRainSoundInterior", RelXml.HashString(VehicleRainSoundInterior));
|
||||||
RelXml.StringTag(sb, indent, "CabinToneLoop", RelXml.HashString(CabinToneLoop));
|
RelXml.StringTag(sb, indent, "CabinToneLoop", RelXml.HashString(CabinToneLoop));
|
||||||
RelXml.ValueTag(sb, indent, "InteriorViewEngineOpenness", InteriorViewEngineOpenness.ToString());
|
RelXml.ValueTag(sb, indent, "InteriorViewEngineOpenness", FloatUtil.ToString(InteriorViewEngineOpenness));
|
||||||
RelXml.StringTag(sb, indent, "JumpLandSoundInterior", RelXml.HashString(JumpLandSoundInterior));
|
RelXml.StringTag(sb, indent, "JumpLandSoundInterior", RelXml.HashString(JumpLandSoundInterior));
|
||||||
RelXml.StringTag(sb, indent, "DamagedJumpLandSoundInterior", RelXml.HashString(DamagedJumpLandSoundInterior));
|
RelXml.StringTag(sb, indent, "DamagedJumpLandSoundInterior", RelXml.HashString(DamagedJumpLandSoundInterior));
|
||||||
}
|
}
|
||||||
@ -10848,8 +10828,8 @@ namespace CodeWalker.GameFiles
|
|||||||
IndicatorOn = XmlRel.GetHash(Xml.GetChildInnerText(node, "IndicatorOn"));
|
IndicatorOn = XmlRel.GetHash(Xml.GetChildInnerText(node, "IndicatorOn"));
|
||||||
IndicatorOff = XmlRel.GetHash(Xml.GetChildInnerText(node, "IndicatorOff"));
|
IndicatorOff = XmlRel.GetHash(Xml.GetChildInnerText(node, "IndicatorOff"));
|
||||||
Handbrake = XmlRel.GetHash(Xml.GetChildInnerText(node, "Handbrake"));
|
Handbrake = XmlRel.GetHash(Xml.GetChildInnerText(node, "Handbrake"));
|
||||||
GPSVoice = (byte)Xml.GetChildUIntAttribute(node, "AmbientRadioVol", "value");
|
GPSVoice = (byte)Xml.GetChildUIntAttribute(node, "GPSVoice", "value");
|
||||||
AmbientRadioVol = (byte)Xml.GetChildUIntAttribute(node, "GPSVoice", "value");
|
AmbientRadioVol = (byte)Xml.GetChildUIntAttribute(node, "AmbientRadioVol", "value");
|
||||||
RadioLeakage = (byte)Xml.GetChildUIntAttribute(node, "RadioLeakage", "value");
|
RadioLeakage = (byte)Xml.GetChildUIntAttribute(node, "RadioLeakage", "value");
|
||||||
ParkingTone = XmlRel.GetHash(Xml.GetChildInnerText(node, "ParkingTone"));
|
ParkingTone = XmlRel.GetHash(Xml.GetChildInnerText(node, "ParkingTone"));
|
||||||
RoofStuckSound = XmlRel.GetHash(Xml.GetChildInnerText(node, "RoofStuckSound"));
|
RoofStuckSound = XmlRel.GetHash(Xml.GetChildInnerText(node, "RoofStuckSound"));
|
||||||
@ -10886,6 +10866,8 @@ namespace CodeWalker.GameFiles
|
|||||||
ClatterVolumeBoost = Xml.GetChildIntAttribute(node, "ClatterVolumeBoost", "value");
|
ClatterVolumeBoost = Xml.GetChildIntAttribute(node, "ClatterVolumeBoost", "value");
|
||||||
ChassisStressSensitivityScalar = Xml.GetChildFloatAttribute(node, "ChassisStressSensitivityScalar", "value");
|
ChassisStressSensitivityScalar = Xml.GetChildFloatAttribute(node, "ChassisStressSensitivityScalar", "value");
|
||||||
ChassisStressVolumeBoost = Xml.GetChildIntAttribute(node, "ChassisStressVolumeBoost", "value");
|
ChassisStressVolumeBoost = Xml.GetChildIntAttribute(node, "ChassisStressVolumeBoost", "value");
|
||||||
|
|
||||||
|
|
||||||
VehicleRainSound = XmlRel.GetHash(Xml.GetChildInnerText(node, "VehicleRainSound"));
|
VehicleRainSound = XmlRel.GetHash(Xml.GetChildInnerText(node, "VehicleRainSound"));
|
||||||
AdditionalRevsIncreaseSmoothing = (ushort)Xml.GetChildUIntAttribute(node, "AdditionalRevsIncreaseSmoothing", "value");
|
AdditionalRevsIncreaseSmoothing = (ushort)Xml.GetChildUIntAttribute(node, "AdditionalRevsIncreaseSmoothing", "value");
|
||||||
AdditionalRevsDecreaseSmoothing = (ushort)Xml.GetChildUIntAttribute(node, "AdditionalRevsDecreaseSmoothing", "value");
|
AdditionalRevsDecreaseSmoothing = (ushort)Xml.GetChildUIntAttribute(node, "AdditionalRevsDecreaseSmoothing", "value");
|
||||||
@ -10894,7 +10876,7 @@ namespace CodeWalker.GameFiles
|
|||||||
ConvertibleRoofInteriorSoundSet = XmlRel.GetHash(Xml.GetChildInnerText(node, "ConvertibleRoofInteriorSoundSet"));
|
ConvertibleRoofInteriorSoundSet = XmlRel.GetHash(Xml.GetChildInnerText(node, "ConvertibleRoofInteriorSoundSet"));
|
||||||
VehicleRainSoundInterior = XmlRel.GetHash(Xml.GetChildInnerText(node, "VehicleRainSoundInterior"));
|
VehicleRainSoundInterior = XmlRel.GetHash(Xml.GetChildInnerText(node, "VehicleRainSoundInterior"));
|
||||||
CabinToneLoop = XmlRel.GetHash(Xml.GetChildInnerText(node, "CabinToneLoop"));
|
CabinToneLoop = XmlRel.GetHash(Xml.GetChildInnerText(node, "CabinToneLoop"));
|
||||||
InteriorViewEngineOpenness = Xml.GetChildIntAttribute(node, "InteriorViewEngineOpenness", "value");
|
InteriorViewEngineOpenness = Xml.GetChildFloatAttribute(node, "InteriorViewEngineOpenness", "value");
|
||||||
JumpLandSoundInterior = XmlRel.GetHash(Xml.GetChildInnerText(node, "JumpLandSoundInterior"));
|
JumpLandSoundInterior = XmlRel.GetHash(Xml.GetChildInnerText(node, "JumpLandSoundInterior"));
|
||||||
DamagedJumpLandSoundInterior = XmlRel.GetHash(Xml.GetChildInnerText(node, "DamagedJumpLandSoundInterior"));
|
DamagedJumpLandSoundInterior = XmlRel.GetHash(Xml.GetChildInnerText(node, "DamagedJumpLandSoundInterior"));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user