-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Asset Interfaces. Refactor Custom Batteries stuff to be more inline with SMLHelpers systems. Make ModPrefabCache actually a cache instead of just a thing that deletes prefabs after 30 seconds. Bye Bye Abstract assets and PrefabHandler Move all patching to awake. Will probably break something... but they should not need to be done after mods are loaded if we have the patching done right. And if we don't then it needs to be fixed instead of hidden by delaying the patches. Fixed the Reflection Helper saying the Battery tabs that we added were being added by unity instead of smlhelper. Removed automatic calling of the sync version of GetGameObject unless the person inherits IModPrefabSync and sets the action.
- Loading branch information
1 parent
63f2358
commit 8e21fda
Showing
62 changed files
with
1,502 additions
and
2,998 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
namespace SMLHelper.Examples; | ||
|
||
using SMLHelper.Assets; | ||
using SMLHelper.Assets.Interfaces; | ||
using SMLHelper.Crafting; | ||
using SMLHelper.Handlers; | ||
|
||
#if SUBNAUTICA | ||
using static CraftData; | ||
#endif | ||
|
||
public class NuclearBattery: ICraftable, ICustomBattery | ||
{ | ||
public CraftTree.Type FabricatorType => CraftTree.Type.Fabricator; | ||
public string[] StepsToFabricatorTab => CustomBatteryHandler.BatteryCraftPath; | ||
public float CraftingTime => 1; | ||
public BatteryModel BatteryModel => BatteryModel.IonBattery; | ||
public BatteryType BatteryType => BatteryType.Battery; | ||
public float PowerCapacity => 69420; | ||
public RecipeData RecipeData { get; } = new() | ||
{ | ||
craftAmount = 1, | ||
Ingredients = new() | ||
{ | ||
new Ingredient(TechType.ReactorRod, 1), | ||
new Ingredient(TechType.Lead, 2), | ||
new Ingredient(TechType.CopperWire, 1) | ||
}, | ||
LinkedItems = new() | ||
{ | ||
TechType.DepletedReactorRod | ||
} | ||
}; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.