Skip to content

Commit

Permalink
bt 1.2 fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Denadan committed Aug 22, 2018
1 parent eb3fd75 commit f65c31d
Show file tree
Hide file tree
Showing 6 changed files with 5 additions and 106 deletions.
2 changes: 1 addition & 1 deletion source/Control.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public static void Init(string directory, string settingsJSON)
Validator.RegisterMechValidator(CategoryController.ValidateMech, CategoryController.ValidateMechCanBeFielded);


Logger.Log("Loaded CustomComponents v0.7.0.0.0");
Logger.Log("Loaded CustomComponents v0.7.0.1.0");
#if CCDEBUG
Logger.LogDebug("Loading Categories");
#endif
Expand Down
2 changes: 0 additions & 2 deletions source/CustomComponents.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,6 @@
<Compile Include="Validators\MechLabLocationWidget_OnMechLabDrop_Patch.cs" />
<Compile Include="Patches\MechLabLocationWidget_OnItemGrab_Patch.cs" />
<Compile Include="Components\ColorComponent.cs" />
<Compile Include="Patches\ListElementController_SalvageGear_NotListView_RefreshItemColor_Patch.cs" />
<Compile Include="Patches\ListElementController_SalvageGear_RefreshItemColor_Patch.cs" />
<Compile Include="Patches\MechComponentRef_GetUIColor_Patch.cs" />
<Compile Include="Control.cs" />
<Compile Include="CustomComponentSettings.cs" />
Expand Down

This file was deleted.

This file was deleted.

3 changes: 2 additions & 1 deletion source/Patches/MechLabLocationWidget_OnItemGrab_Patch.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
using BattleTech;
using BattleTech.UI;
using Harmony;
using Localize;

namespace CustomComponents
{
Expand All @@ -20,7 +21,7 @@ public static bool Prefix(IMechLabDraggableItem item, ref bool __result, MechLab
if(!grab_handler.OnItemGrab(item, ___mechLab, out var error))
{
if (!string.IsNullOrEmpty(error))
___mechLab.ShowDropErrorMessage(error);
___mechLab.ShowDropErrorMessage(new Text(error));
__result = false;
return false;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
using BattleTech;
using BattleTech.UI;
using Harmony;

using Localize;
using UnityEngine.EventSystems;

namespace CustomComponents
Expand All @@ -27,7 +27,7 @@ bool do_cancel(string error)

Control.Logger.LogDebug($"- Canceled: {error}");

___mechLab.ShowDropErrorMessage(error);
___mechLab.ShowDropErrorMessage(new Text(error));
___mechLab.OnDrop(eventData);
return true;
}
Expand Down

0 comments on commit f65c31d

Please sign in to comment.