Skip to content

Commit

Permalink
Cleanup log spam
Browse files Browse the repository at this point in the history
  • Loading branch information
IceRaptor committed Apr 17, 2023
1 parent be2f849 commit 0e037d2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
4 changes: 2 additions & 2 deletions CleverGirl/CleverGirl/CleverGirl.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
<AssemblyTitle>CleverGirl</AssemblyTitle>
<Product>CleverGirl</Product>
<Copyright>Copyright © 2023</Copyright>
<AssemblyVersion>2.1.0</AssemblyVersion>
<FileVersion>2.1.0</FileVersion>
<AssemblyVersion>2.1.1</AssemblyVersion>
<FileVersion>2.1.1</FileVersion>
<LangVersion>11</LangVersion>
</PropertyGroup>

Expand Down
9 changes: 2 additions & 7 deletions CleverGirl/CleverGirl/Patches/InfluenceMapEvaluatorPatches.cs
Original file line number Diff line number Diff line change
Expand Up @@ -53,21 +53,16 @@ static void Prefix(ref bool __runOriginal, InfluenceMapEvaluator __instance, flo
{
Mod.Log.Info?.Write("Generating new CompoundInfluenceMapEvaluator");
CompoundInfluenceMapEvaluator cime = new CompoundInfluenceMapEvaluator(__instance);
if (cime == null)
{
Mod.Log.Warn?.Write("Failed to create a CompoundInfluenceMapEvaluator - this is bad!");
}
__instance.evaluationCoroutine = new GraphCoroutine(cime.IncrementalEvaluate());
Mod.Log.Debug?.Write($"After IncrementalEvaluate: evaluationCoroutine: isNull? {__instance.evaluationCoroutine == null}");
}

while (Time.realtimeSinceStartup - realtimeSinceStartup <= seconds)
{
Mod.Log.Debug?.Write($"Updating evaluationCorouting: isNull? {__instance.evaluationCoroutine == null}");
__instance.evaluationCoroutine.Update();
if (__instance.evaluationComplete)
{
__instance.evaluationCoroutine = null;
Mod.Log.Info?.Write("Evaluation complete, destroying coroutine");
__instance.evaluationCoroutine = null;
break;
}
}
Expand Down

0 comments on commit 0e037d2

Please sign in to comment.