Skip to content

Commit

Permalink
1.9.4 Minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Cattlesquat committed Jan 11, 2021
1 parent 515adce commit ec6cd63
Show file tree
Hide file tree
Showing 8 changed files with 36 additions and 13 deletions.
2 changes: 1 addition & 1 deletion DeathRun/DeathRun.cs
Original file line number Diff line number Diff line change
Expand Up @@ -610,7 +610,7 @@ public static void Patch()
new Ingredient(TechType.Lithium, 2),
new Ingredient(TechType.Magnetite, 1)
};
if (!Config.NORMAL.Equals(DeathRun.config.batteryCosts))
if (Config.NORMAL.Equals(DeathRun.config.batteryCosts))
{
ingredients.Add(new Ingredient(TechType.Battery, 1));
}
Expand Down
2 changes: 1 addition & 1 deletion DeathRun/DeathRunConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ public int countDeathRunSettings ()
}


if (DEATH_VEHICLES.Equals(vehicleCosts) || NO_VEHICLES.Equals(vehicleCosts))
if (DEATH_VEHICLES.Equals(vehicleCosts) || DEATH_VEHICLES_2.Equals(vehicleCosts) || NO_VEHICLES.Equals(vehicleCosts))
{
count += 2;
}
Expand Down
29 changes: 24 additions & 5 deletions DeathRun/DeathRunUtils.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ namespace DeathRun

public class DeathRunUtils
{
public const string VERSION = "1.9.4";

public static CenterText[] centerMessages = new CenterText[] {
new CenterText(250f, true),
new CenterText(210f, true),
Expand Down Expand Up @@ -280,7 +282,7 @@ public static void ShowHighScores(bool should)
}

highScoreLabel.setAlign(TextAnchor.MiddleCenter);
highScoreLabel.ShowMessage("Death Run 1.9.3 - Best Scores");
highScoreLabel.ShowMessage("Death Run 1.9.4 - Best Scores");
highScoreTag.setAlign(TextAnchor.MiddleCenter);

int pick;
Expand Down Expand Up @@ -427,6 +429,7 @@ public class RunData
public int DeathRunSettingCount { get; set; }
public int DeathRunSettingBonus { get; set; }
public bool Victory { get; set; }
public string Version { get; set; }

public const int MAX_DEATHRUN_SETTING_COUNT = 28;

Expand Down Expand Up @@ -469,12 +472,15 @@ public RunData()
DeathRunSettingBonus = -1;

Victory = false;

Version = "";
}

public void startNewRun()
{
ID = DeathRun.statsData.getNewRunID();
Start = DeathRun.saveData.startSave.message;
Version = DeathRunUtils.VERSION;

CattleLogger.Message("Starting new run - " + ID + " " + Start);

Expand All @@ -490,14 +496,23 @@ public void countSettings()
int count = DeathRun.config.countDeathRunSettings();
int bonuses = DeathRun.config.countDeathRunBonuses();

if ((DeathRunSettingCount < 0) || (count < DeathRunSettingCount))
if ("".Equals(Version))
{
Version = DeathRunUtils.VERSION;
DeathRunSettingCount = count;
DeathRunSettingBonus = bonuses;
}

if ((DeathRunSettingBonus < 0) || (bonuses < DeathRunSettingBonus))
else
{
DeathRunSettingBonus = bonuses;
if ((DeathRunSettingCount < 0) || (count < DeathRunSettingCount))
{
DeathRunSettingCount = count;
}

if ((DeathRunSettingBonus < 0) || (bonuses < DeathRunSettingBonus))
{
DeathRunSettingBonus = bonuses;
}
}
}

Expand Down Expand Up @@ -871,6 +886,7 @@ public class DeathRunStats
public int RunCounter { get; set; }
public int RecentIndex { get; set; }
public List<RunData> HighScores { get; set; }
public string Version { get; set; }

public const int MAX_HIGH_SCORES = 10;

Expand All @@ -885,6 +901,7 @@ public void setDefaults()
VeryFirstTime = true;
RunCounter = 0;
RecentIndex = -1;
Version = "";
}

/**
Expand Down Expand Up @@ -992,6 +1009,8 @@ public void SaveStats()
{
if (DeathRun.patchFailed) return;

Version = DeathRunUtils.VERSION;

try
{
var settings = new JsonSerializerSettings
Expand Down
4 changes: 2 additions & 2 deletions DeathRun/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.9.3.0")]
[assembly: AssemblyFileVersion("1.9.3.0")]
[assembly: AssemblyVersion("1.9.4.0")]
[assembly: AssemblyFileVersion("1.9.4.0")]
4 changes: 3 additions & 1 deletion DeathRun/ReadMe.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
DEATH RUN - 1.9.3 - by Cattlesquat "standing on the shoulders of giants"
DEATH RUN - 1.9.4 - by Cattlesquat "standing on the shoulders of giants"

Turns Subnautica into a "roguelike" where everything is harder and the only real question is how LONG you can survive.

Expand All @@ -19,6 +19,8 @@ Turns Subnautica into a "roguelike" where everything is harder and the only real
• Vehicles and the Habitat Builder much more expensive

-------------------------------------------------------------------------------------------------------------
• 1.9.4 - "Alternative" Death Run Vehicles costs wasn't giving proper scoring credit.
• 1.9.4 - Habitat Builder tool recipe no longer includes inappropriate Lithium Battery
• 1.9.3 - Swim Charge Fins rebalanced (will keep up w/ Flashlight. Does not allow infinite Seaglide)
• 1.9.3 - Seamoth "Depth 3" module costs were incorrect - have fixed/patched
• 1.9.2 - Fixed broken targeting (misplaced parenthesis) that was often preventing creatures from attacking.
Expand Down
2 changes: 1 addition & 1 deletion DeathRun/mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"Id": "DeathRun",
"DisplayName": "DeathRun",
"Author": "Cattlesquat",
"Version": "1.9.3",
"Version": "1.9.4",
"Enable": true,
"AssemblyName": "DeathRun.dll",
"EntryMethod": "DeathRun.DeathRun.Patch",
Expand Down
4 changes: 3 additions & 1 deletion QMods/DeathRun/ReadMe.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
DEATH RUN - 1.9.3 - by Cattlesquat "standing on the shoulders of giants"
DEATH RUN - 1.9.4 - by Cattlesquat "standing on the shoulders of giants"

Turns Subnautica into a "roguelike" where everything is harder and the only real question is how LONG you can survive.

Expand All @@ -19,6 +19,8 @@ Turns Subnautica into a "roguelike" where everything is harder and the only real
• Vehicles and the Habitat Builder much more expensive

-------------------------------------------------------------------------------------------------------------
• 1.9.4 - "Alternative" Death Run Vehicles costs wasn't giving proper scoring credit.
• 1.9.4 - Habitat Builder tool recipe no longer includes inappropriate Lithium Battery
• 1.9.3 - Swim Charge Fins rebalanced (will keep up w/ Flashlight. Does not allow infinite Seaglide)
• 1.9.3 - Seamoth "Depth 3" module costs were incorrect - have fixed/patched
• 1.9.2 - Fixed broken targeting (misplaced parenthesis) that was often preventing creatures from attacking.
Expand Down
2 changes: 1 addition & 1 deletion QMods/DeathRun/mod.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"Id": "DeathRun",
"DisplayName": "DeathRun",
"Author": "Cattlesquat",
"Version": "1.9.3",
"Version": "1.9.4",
"Enable": true,
"AssemblyName": "DeathRun.dll",
"EntryMethod": "DeathRun.DeathRun.Patch",
Expand Down

0 comments on commit ec6cd63

Please sign in to comment.