Skip to content

Commit

Permalink
update dyna racetime
Browse files Browse the repository at this point in the history
  • Loading branch information
igorseabra4 committed Sep 10, 2022
1 parent 9f507eb commit 2f34ae7
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 20 deletions.
8 changes: 5 additions & 3 deletions IndustrialPark/Assets/DYNA/DynaTypes/DynaGObjectRaceTimer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public class DynaGObjectRaceTimer : AssetDYNA
protected override short constVersion => 2;

[Category(dynaCategoryName)]
public int CountDown { get; set; }
public bool CountDown { get; set; }
[Category(dynaCategoryName)]
public int StartTime { get; set; }
[Category(dynaCategoryName)]
Expand All @@ -29,7 +29,8 @@ public DynaGObjectRaceTimer(Section_AHDR AHDR, Game game, Endianness endianness)
{
reader.BaseStream.Position = dynaDataStartPosition;

CountDown = reader.ReadInt32();
CountDown = reader.ReadByteBool();
reader.BaseStream.Position += 3;
StartTime = reader.ReadInt32();
VictoryTime = reader.ReadInt32();
WarnTime1 = reader.ReadSingle();
Expand All @@ -42,7 +43,8 @@ protected override byte[] SerializeDyna(Game game, Endianness endianness)
{
using (var writer = new EndianBinaryWriter(endianness))
{
writer.Write(CountDown);
writer.Write((byte)(CountDown ? 1 : 0));
writer.Write(new byte[3]);
writer.Write(StartTime);
writer.Write(VictoryTime);
writer.Write(WarnTime1);
Expand Down
24 changes: 8 additions & 16 deletions IndustrialPark/MainForm/MainForm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -892,35 +892,33 @@ private void viewControlsToolStripMenuItem_Click(object sender, EventArgs e)
"Ctrl + (W, A, S, D): rotate view up, left, down, right\n" +
"Q, E: decrease interval, increase interval (view move speed)\n" +
"1, 3: decrease rotation interval, increase rotation interval (view rotation speed)\n" +
"B: select previous template\n" +
"N: select next template\n" +
"B and N: select previous/next template\n" +
"C: toggles backface culling\n" +
"F: toggles wireframe mode\n" +
"G: open Asset Data Editor for selected assets\n" +
"R: reset view\n" +
"T: snap gizmos to grid\n" +
"U: toggle UI Mode\n" +
"V: cycle between gizmos\n" +
"Z: toggle mouse mode\n" +
"Z: toggle mouse mode: similar to a first person camera. The view rotates automatically as you move the mouse. Use the keyboard to move around\n" +
"F1: displays the View Config box\n" +
"Ctrl + Shift + S or F4: save all open Archive Editors\n" +
"F5: attempt to run game\n" +
"Delete: delete selected assets\n" +
"Ctrl + Shift + H: closes all windows which are not Archive Editors\n" +
"Ctrl + 1 to 9: Open the corresponding Archive Editor window\n" +
"\n" +
"Mouse controls:\n" +
"Left click on an asset to select it\n" +
"Ctrl + Left click to select multiple\n" +
"Middle click and drag to rotate view\n" +
"Mouse wheel to move forward/backward\n" +
"Right click on screen to choose a template\n" +
"Right click on screen to choose a gizmo or template\n" +
"Shift + Right click to place a template\n" +
"Ctrl + Right click and drag to pan (move view up, left, down, right)\n" +
"Mouse mode (Z): similar to a first person camera. The view rotates automatically as you move the mouse. Use the keyboard to move around.\n" +
"\n" +
"Ctrl + Shift + S or F4: Save all open editors\n" +
"Ctrl + Shift + H: Close all windows excluding archive editors\n" +
"Ctrl + 1 to 9: Open the corresponding archive editor's window\n" +
"\n" +
"Please consult the Industrial Park user guide on Heavy Iron Modding for more information");
"Please consult the Industrial Park user guide on Heavy Iron Modding for more information"
);
}

private SharpDX.Rectangle ViewRectangle => new SharpDX.Rectangle(
Expand Down Expand Up @@ -1722,8 +1720,6 @@ private void openFolderToolStripMenuItem_Click(object sender, EventArgs e)
p.SetProgressBar(0, hipList.Count, 1);
p.Show();

List<(MinfAssetParam, int, string)> minfParamsByteCount = new List<(MinfAssetParam, int, string)>();

foreach (var hip in hipList)
{
p.Text = Path.GetFileName(hip);
Expand All @@ -1734,10 +1730,6 @@ private void openFolderToolStripMenuItem_Click(object sender, EventArgs e)
p.PerformStep();
}

using (var writer = new StreamWriter(new FileStream("minfs.txt", FileMode.Create)))
foreach (var v in minfParamsByteCount)
writer.WriteLine($"{v.Item1} {v.Item2} {v.Item3}");

p.Close();
}
}
Expand Down
2 changes: 1 addition & 1 deletion IndustrialPark/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
[assembly: AssemblyCompany("Heavy Iron Modding")]
[assembly: AssemblyProduct("IndustrialPark")]
[assembly: AssemblyCopyright("Copyright © 2022 igorseabra4")]
[assembly: AssemblyTrademark("Heavy Iron Modding Modding")]
[assembly: AssemblyTrademark("Heavy Iron Modding")]
[assembly: AssemblyCulture("")]

// Definir ComVisible como false torna os tipos neste assembly invisíveis
Expand Down

0 comments on commit 2f34ae7

Please sign in to comment.