Skip to content

Commit 2af9a44

Browse files
committed
prevent sound data from overwriting itself on save
1 parent 24a81d7 commit 2af9a44

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

Dat/Objects/Vehicle/VehicleObject.cs

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -78,13 +78,13 @@ public FrictionSound? SoundPropertyFriction
7878
{
7979
ByteWriter.WriteLocoStruct(value).CopyTo(SoundPropertiesData);
8080
}
81-
else
82-
{
83-
for (var i = 0; i < MaxUnionSoundStructLength; ++i)
84-
{
85-
SoundPropertiesData[i] = 0;
86-
}
87-
}
81+
//else
82+
//{
83+
// for (var i = 0; i < MaxUnionSoundStructLength; ++i)
84+
// {
85+
// SoundPropertiesData[i] = 0;
86+
// }
87+
//}
8888
}
8989
}
9090

@@ -99,13 +99,13 @@ public Engine1Sound? SoundPropertyEngine1
9999
{
100100
ByteWriter.WriteLocoStruct(value).CopyTo(SoundPropertiesData);
101101
}
102-
else
103-
{
104-
for (var i = 0; i < MaxUnionSoundStructLength; ++i)
105-
{
106-
SoundPropertiesData[i] = 0;
107-
}
108-
}
102+
//else
103+
//{
104+
// for (var i = 0; i < MaxUnionSoundStructLength; ++i)
105+
// {
106+
// SoundPropertiesData[i] = 0;
107+
// }
108+
//}
109109
}
110110
}
111111

@@ -120,13 +120,13 @@ public Engine2Sound? SoundPropertyEngine2
120120
{
121121
ByteWriter.WriteLocoStruct(value).CopyTo(SoundPropertiesData);
122122
}
123-
else
124-
{
125-
for (var i = 0; i < MaxUnionSoundStructLength; ++i)
126-
{
127-
SoundPropertiesData[i] = 0;
128-
}
129-
}
123+
//else
124+
//{
125+
// for (var i = 0; i < MaxUnionSoundStructLength; ++i)
126+
// {
127+
// SoundPropertiesData[i] = 0;
128+
// }
129+
//}
130130
}
131131
}
132132

0 commit comments

Comments
 (0)