Skip to content

Commit

Permalink
Fixed bug where AGI Strings were not starting as empty.
Browse files Browse the repository at this point in the history
  • Loading branch information
lanceewing committed Dec 30, 2022
1 parent 9f3ccec commit 418fbcd
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions AGILE/GameState.cs
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,7 @@ public GameState(Game game)
/// </summary>
public void Init()
{
ClearStrings();
ClearVars();
Vars[Defines.MACHINE_TYPE] = 0; // IBM PC
Vars[Defines.MONITOR_TYPE] = 3; // EGA
Expand Down Expand Up @@ -463,5 +464,16 @@ public void ClearControllers()
Controllers[i] = false;
}
}

/// <summary>
/// Clears all of the AGI Strings to be empty.
/// </summary>
public void ClearStrings()
{
for (int i = 0; i < Defines.NUMSTRINGS; i++)
{
Strings[i] = "";
}
}
}
}

0 comments on commit 418fbcd

Please sign in to comment.