diff --git a/AnvilMetalRecovery/AnvilMetalRecovery.csproj b/AnvilMetalRecovery/AnvilMetalRecovery.csproj index 6e0329e..7f2cb40 100644 --- a/AnvilMetalRecovery/AnvilMetalRecovery.csproj +++ b/AnvilMetalRecovery/AnvilMetalRecovery.csproj @@ -54,14 +54,16 @@ vs_libs\VSSurvivalMod.dll False + + vs_libs\Newtonsoft.Json.dll + False + - - Always - + @@ -98,7 +100,6 @@ - diff --git a/AnvilMetalRecovery/Helpers.cs b/AnvilMetalRecovery/Helpers.cs new file mode 100644 index 0000000..f51bf8f --- /dev/null +++ b/AnvilMetalRecovery/Helpers.cs @@ -0,0 +1,30 @@ +using System; + +using Vintagestory.API.Common; +using Vintagestory.API.Server; +using Vintagestory.Common; +using Vintagestory.Server; + +namespace AnvilMetalRecovery +{ + internal static class Helpers + { + internal static void ReplaceBlockEntityType(this ClassRegistry registry, string className, Type blockentity) + { + if (registry.blockEntityClassnameToTypeMapping.ContainsKey(className)) { + //replace it + registry.blockEntityClassnameToTypeMapping[className] = blockentity; + registry.blockEntityTypeToClassnameMapping[blockentity] = className; + } + } + + internal static void ReplaceItemClassType(this ClassRegistry registry, string className, Type replacer) + { + if (registry.ItemClassToTypeMapping.ContainsKey(className)) { + //replace it + registry.ItemClassToTypeMapping[className] = replacer; + } + } + } +} + diff --git a/AnvilMetalRecovery/MetalRecoverySystem.cs b/AnvilMetalRecovery/MetalRecoverySystem.cs index 545bcfb..d13ee43 100644 --- a/AnvilMetalRecovery/MetalRecoverySystem.cs +++ b/AnvilMetalRecovery/MetalRecoverySystem.cs @@ -5,16 +5,16 @@ using Vintagestory.API.Common; using Vintagestory.API.Server; using Vintagestory.Common; using Vintagestory.Server; +using Vintagestory.ServerMods; namespace AnvilMetalRecovery { - public class MetalRecoverySystem : ModSystem - { - internal const string anvilKey = @"Anvil"; - + public partial class MetalRecoverySystem : ModSystem + { private ICoreAPI CoreAPI; private ICoreServerAPI ServerAPI; private ServerCoreAPI ServerCore { get; set; } + //private RecipeLoader LoaderOfRecipies { get; set;} public override bool AllowRuntimeReload { get { return false; } @@ -27,23 +27,23 @@ namespace AnvilMetalRecovery public override double ExecuteOrder( ) { - return 0.10d; + return 0.1d; } public override void Start(ICoreAPI api) { this.CoreAPI = api; - CoreAPI.RegisterItemClass(@"ItemMallet", typeof(ItemMallet)); + + RegisterItemClasses(); + base.Start(api); } public override void StartServerSide(ICoreServerAPI api) { - base.StartServerSide(api); - this.ServerAPI = api; - + //LoaderOfRecipies = ServerAPI.ModLoader.GetModSystem( ); if (api is ServerCoreAPI) { ServerCore = api as ServerCoreAPI; @@ -52,6 +52,8 @@ namespace AnvilMetalRecovery Mod.Logger.Error("Cannot access 'ServerCoreAPI' class: API (implimentation) has changed, Contact Developer!"); return; } + + ServerCore.Event.ServerRunPhase(EnumServerRunPhase.LoadGame, OnServerLoadGame); //ServerAPI.ClassRegistry.GetBlockEntityClass //ServerAPI.RegisterBlockEntityClass(anvilKey, typeof(MetalRecovery_BlockEntityAnvil)); @@ -60,46 +62,12 @@ namespace AnvilMetalRecovery Mod.Logger.VerboseDebug("Anvil Metal Recovery - should be installed..."); } - internal void GenerateMetalShavingsItems( ) + private void OnServerLoadGame( ) { - //TODO: Automatic Generation of Item 'metal_shaving' by metal & alloy list at RUNTIME - var genericShaving = ServerAPI.World.ClassRegistry.CreateItem("metal_shaving"); - //genericShaving.CombustibleProps. - - var metalProperties = new Dictionary( ); - - foreach (var entry in ServerAPI.Assets.GetMany(Mod.Logger, "worldproperties/")) - { - AssetLocation loc = entry.Key.Clone( ); - loc.Path = loc.Path.Replace("worldproperties/", ""); - loc.RemoveEnding( ); - - entry.Value.Code.Domain = entry.Key.Domain; - - metalProperties.Add(loc, entry.Value); - - } - } - } - - internal static class Helpers - { - internal static void ReplaceBlockEntityType(this ClassRegistry registry, string className, Type blockentity) - { - if (registry.blockEntityClassnameToTypeMapping.ContainsKey(className)) { - //replace it - registry.blockEntityClassnameToTypeMapping[className] = blockentity; - registry.blockEntityTypeToClassnameMapping[blockentity] = className; + ManipulateGridRecipies( ); } - } - - internal static void ReplaceItemClassType(this ClassRegistry registry, string className, Type replacer) - { - if (registry.ItemClassToTypeMapping.ContainsKey(className)) { - //replace it - registry.ItemClassToTypeMapping[className] = replacer; - } - } - } +} + + } diff --git a/AnvilMetalRecovery/assets/fma/itemtypes/tools/mallet.json b/AnvilMetalRecovery/assets/fma/itemtypes/tools/mallet.json index 4e58e9d..d86e556 100644 --- a/AnvilMetalRecovery/assets/fma/itemtypes/tools/mallet.json +++ b/AnvilMetalRecovery/assets/fma/itemtypes/tools/mallet.json @@ -15,7 +15,7 @@ heldTpHitAnimation: "smithing", shape: { base: "item/tools/mallet" }, textures: { - "head": { base:"game:block/wood/debarked/birch"}, + "head": { base:"game:block/wood/debarked/oak"}, "side": { base:"game:block/wood/treetrunk/oak"}, "wood": { base:"game:item/tool/material/wood"} }, diff --git a/AnvilMetalRecovery/assets/fma/recipes/grid/tool/mallet.json b/AnvilMetalRecovery/assets/fma/recipes/grid/tool/mallet.json index 3f68586..12f8f1f 100644 --- a/AnvilMetalRecovery/assets/fma/recipes/grid/tool/mallet.json +++ b/AnvilMetalRecovery/assets/fma/recipes/grid/tool/mallet.json @@ -2,7 +2,7 @@ ingredientPattern: "K H S", ingredients: { "K": { type: "item", code:"game:knife-*", isTool: true}, - "H": { type: "block", code: "game:log-*", name: "head" }, + "H": { type: "block", code: "game:log-*", allowedVariants: ["placed-birch-ud", "placed-oak-ud", "placed-maple-ud", "placed-pine-ud", "placed-acacia-ud"], name: "head" }, "S": { type: "item", code: "game:stick" } }, width: 1, diff --git a/AnvilMetalRecovery/modinfo.json b/AnvilMetalRecovery/modinfo.json index 1ace342..85445f0 100644 --- a/AnvilMetalRecovery/modinfo.json +++ b/AnvilMetalRecovery/modinfo.json @@ -3,6 +3,7 @@ "name": "Metal Recovery & More", "description" : "Get back lost scrap and smithing discards, and more.", "authors": ["Melchior"], + "ModID":"metalrecovery", "version": "0.1.2", "dependencies": { "game": "1.12.11", diff --git a/Assorted/BlockBehaviors/BlockBehaviorVerticalOrientation.cs b/Assorted/BlockBehaviors/BlockBehaviorVerticalOrientation.cs index fffb67d..a65f876 100644 --- a/Assorted/BlockBehaviors/BlockBehaviorVerticalOrientation.cs +++ b/Assorted/BlockBehaviors/BlockBehaviorVerticalOrientation.cs @@ -13,7 +13,7 @@ namespace FirstMachineAge private readonly string verticalKey; /* - * abstact/"horizontalorientation" + * "abstract/verticalorientation" */ diff --git a/ElementalTools/Assignments.cs b/ElementalTools/Assignments.cs new file mode 100644 index 0000000..22cd825 --- /dev/null +++ b/ElementalTools/Assignments.cs @@ -0,0 +1,121 @@ +using System; +using System.Collections.Generic; + +using System.Linq; +using System.Threading; + +using Vintagestory.API.Common; +using Vintagestory.API.Config; + + + + +namespace ElementalTools +{ + public partial class ElementalToolsSystem : ModSystem + { + internal const string anvilKey = @"Anvil"; + internal const string malletItemKey = @"ItemMallet"; + internal const string malletAssetKey = @"mallet"; + + private void RegisterItemClasses() + { + CoreAPI.RegisterItemClass(malletItemKey, typeof(ItemMallet)); + } + + + private void ManipulateGridRecipies( ) + { + uint malletizedCount = 0; + //Thread.Sleep(1000); + Mod.Logger.VerboseDebug($"Total GridRecipies: {CoreAPI.World.GridRecipes.Count}"); + + /* + var alternateQuery = from gridRecipie in CoreAPI.World.GridRecipes + where gridRecipie.Ingredients.Any(gi => gi.Value.IsTool && gi.Value.Code.BeginsWith(GlobalConstants.DefaultDomain, @"hammer")) + where gridRecipie.Output.Code.BeginsWith(GlobalConstants.DefaultDomain, @"nugget") == false + where gridRecipie.Output.Code.BeginsWith(GlobalConstants.DefaultDomain, @"lime") == false + select gridRecipie; + + Mod.Logger.VerboseDebug($"Found {alternateQuery.Count()} Recipies using Hammer, (non ore)"); + + if (alternateQuery.Any()) { + foreach (var recipieToClone in alternateQuery.ToArray()) { + var cloneRecipie = recipieToClone.Clone( ); + var hammerIngredient = cloneRecipie.Ingredients.First(gi => gi.Value.IsTool && gi.Value.Code.BeginsWith(GlobalConstants.DefaultDomain, @"hammer")); + + CraftingRecipeIngredient malletIngredient = new CraftingRecipeIngredient { + Type = EnumItemClass.Item, + IsTool = true, + Code = new AssetLocation(@"fma", malletAssetKey), + IsWildCard = false, + //Name = "mallet", + }; + cloneRecipie.Ingredients[hammerIngredient.Key] = malletIngredient; + ServerCore.RegisterCraftingRecipe(cloneRecipie); + malletizedCount++; + } + + Mod.Logger.VerboseDebug($"Added {malletizedCount} Mallet recipies"); + } + */ + + GridRecipe testRecipie = new GridRecipe { + IngredientPattern = "M\tF", + Name = new AssetLocation("fma","LogToSticks"), + Height = 2, + Width = 1, + Ingredients = + new Dictionary{ + {"M", new CraftingRecipeIngredient{ + Name = "mallet", + Type = EnumItemClass.Item, + Code = new AssetLocation("fma",malletAssetKey), + IsTool = true, + Quantity = 1,} + }, + {"F", new CraftingRecipeIngredient{ + Name = "wood", + Type = EnumItemClass.Item, + Code = new AssetLocation(GlobalConstants.DefaultDomain,"firewood"), + Quantity = 1,} + }, + }, + Output = new CraftingRecipeIngredient{ + Type = EnumItemClass.Item, + Quantity = 3, + Code = new AssetLocation(GlobalConstants.DefaultDomain,"stick"), + }, + };//Needs: ResolvedItemstack <- for Non-wildcard !!!! + testRecipie.ResolveIngredients(ServerCore.World); + + ServerCore.RegisterCraftingRecipe(testRecipie); + } + + //TODO: Recycling assignment of Smeltable properties from all smith/grid/recipe forms... + + + internal void GenerateMetalShavingsItems( ) + { + //TODO: Automatic Generation of Item 'metal_shaving' by metal & alloy list at RUNTIME + var genericShaving = ServerAPI.World.ClassRegistry.CreateItem("metal_shaving"); + //genericShaving.CombustibleProps. + + var metalProperties = new Dictionary( ); + + foreach (var entry in ServerAPI.Assets.GetMany(Mod.Logger, "worldproperties/")) { + AssetLocation loc = entry.Key.Clone( ); + loc.Path = loc.Path.Replace("worldproperties/", ""); + loc.RemoveEnding( ); + + entry.Value.Code.Domain = entry.Key.Domain; + + metalProperties.Add(loc, entry.Value); + + } + } + + + } +} + diff --git a/ElementalTools/ElementalTools.csproj b/ElementalTools/ElementalTools.csproj new file mode 100644 index 0000000..58fefb5 --- /dev/null +++ b/ElementalTools/ElementalTools.csproj @@ -0,0 +1,97 @@ + + + + Debug + AnyCPU + {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF} + Library + ElementalTools + ElementalTools + v4.5 + + + true + full + false + bin\Debug + DEBUG; + prompt + 4 + false + + + + + + + + + true + bin\Release + prompt + 4 + false + + + + + vs_libs\Newtonsoft.Json.dll + False + + + vs_libs\protobuf-net.dll + False + + + vs_libs\VintagestoryAPI.dll + False + + + vs_libs\VintagestoryLib.dll + False + + + vs_libs\VSCreativeMod.dll + False + + + vs_libs\VSEssentials.dll + False + + + vs_libs\VSSurvivalMod.dll + False + + + + + + + + Always + + + + + + + + + + Always + + + Always + + + Always + + + Always + + + Always + + + + \ No newline at end of file diff --git a/ElementalTools/ElementalToolsMod.cs b/ElementalTools/ElementalToolsMod.cs new file mode 100644 index 0000000..a62c859 --- /dev/null +++ b/ElementalTools/ElementalToolsMod.cs @@ -0,0 +1,72 @@ +using System; +using System.Collections.Generic; + +using Vintagestory.API.Common; +using Vintagestory.API.Server; +using Vintagestory.Common; +using Vintagestory.Server; +using Vintagestory.ServerMods; + +namespace ElementalTools +{ + public partial class ElementalToolsSystem : ModSystem + { + private ICoreAPI CoreAPI; + private ICoreServerAPI ServerAPI; + private ServerCoreAPI ServerCore { get; set; } + //private RecipeLoader LoaderOfRecipies { get; set;} + + public override bool AllowRuntimeReload { + get { return false; } + } + + public override bool ShouldLoad(EnumAppSide forSide) + { + return true; + } + + public override double ExecuteOrder( ) + { + return 0.1d; + } + + public override void Start(ICoreAPI api) + { + this.CoreAPI = api; + + RegisterItemClasses( ); + + + base.Start(api); + } + + public override void StartServerSide(ICoreServerAPI api) + { + this.ServerAPI = api; + //LoaderOfRecipies = ServerAPI.ModLoader.GetModSystem( ); + + if (api is ServerCoreAPI) { + ServerCore = api as ServerCoreAPI; + } + else { + Mod.Logger.Error("Cannot access 'ServerCoreAPI' class: API (implimentation) has changed, Contact Developer!"); + return; + } + + ServerCore.Event.ServerRunPhase(EnumServerRunPhase.LoadGame, OnServerLoadGame); + + + + + Mod.Logger.VerboseDebug("Elemental Tools - should be installed..."); + } + + private void OnServerLoadGame( ) + { + ManipulateGridRecipies( ); + } + } + + +} + diff --git a/AnvilMetalRecovery/Items/ItemMallet.cs b/ElementalTools/Items/ItemMallet.cs similarity index 90% rename from AnvilMetalRecovery/Items/ItemMallet.cs rename to ElementalTools/Items/ItemMallet.cs index ea2b29c..f3136ab 100644 --- a/AnvilMetalRecovery/Items/ItemMallet.cs +++ b/ElementalTools/Items/ItemMallet.cs @@ -3,7 +3,7 @@ using Vintagestory.API.Common; using Vintagestory.API.Config; -namespace AnvilMetalRecovery +namespace ElementalTools { public class ItemMallet : Item { @@ -28,7 +28,10 @@ namespace AnvilMetalRecovery return false; } - if (ingredient.IsTool && ingredient.Code.BeginsWith(GlobalConstants.DefaultDomain, @"hammer")) { + if (ingredient.IsTool && + (ingredient.Code.BeginsWith(GlobalConstants.DefaultDomain, @"hammer") || + ingredient.Code.BeginsWith("fma",ElementalToolsSystem.malletAssetKey))) + { return true; } diff --git a/ElementalTools/Properties/AssemblyInfo.cs b/ElementalTools/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..c952606 --- /dev/null +++ b/ElementalTools/Properties/AssemblyInfo.cs @@ -0,0 +1,27 @@ +using System.Reflection; +using System.Runtime.CompilerServices; + +// Information about this assembly is defined by the following attributes. +// Change them to the values specific to your project. + +[assembly: AssemblyTitle("ElementalTools")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("")] +[assembly: AssemblyCopyright("librarian")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}". +// The form "{Major}.{Minor}.*" will automatically update the build and revision, +// and "{Major}.{Minor}.{Build}.*" will update just the revision. + +[assembly: AssemblyVersion("1.0.*")] + +// The following attributes are used to specify the signing key for the assembly, +// if desired. See the Mono documentation for more information about signing. + +//[assembly: AssemblyDelaySign(false)] +//[assembly: AssemblyKeyFile("")] + diff --git a/ElementalTools/assets/fma/itemtypes/tools/mallet.json b/ElementalTools/assets/fma/itemtypes/tools/mallet.json new file mode 100644 index 0000000..d86e556 --- /dev/null +++ b/ElementalTools/assets/fma/itemtypes/tools/mallet.json @@ -0,0 +1,49 @@ +{ + code: "mallet", + class: "ItemMallet", + attributes: { + handbook: { + include: true + }, + toolrackTransform: { + rotation: { y: 1, z: -1 }, + translation: { x: -0.2 }, + scale: 1.5, + } + }, + tool: "hammer", + heldTpHitAnimation: "smithing", + shape: { base: "item/tools/mallet" }, + textures: { + "head": { base:"game:block/wood/debarked/oak"}, + "side": { base:"game:block/wood/treetrunk/oak"}, + "wood": { base:"game:item/tool/material/wood"} + }, + tooltier: 1, + durability: 200, + attackpower: 1, + creativeinventory: { "general": ["*"], "items": ["*"], "tools": ["*"] }, + fpHandTransform: { + translation: { x: 0.0468, y: -0.2, z: 0 }, + rotation: { x: 15, y: 15, z: 90 }, + scale: 2.5 + }, + guiTransform: { + rotate: false, + translation: { x: 0, y: 5, z: 0 }, + rotation: { x: -77, y: -135, z: 160 }, + origin: { x: 0.54, y: 0.5, z: 0.48 }, + scale: 2.6 + }, + groundTransform: { + translation: { x: 0, y: 0, z: 0 }, + rotation: { x: 0, y: 0, z: 0 }, + origin: { x: 0.5, y: 0.45, z: 0.5 }, + scale: 4.5 + }, + tpHandTransform: { + translation: { x: -0.75, y: -0.48, z: -0.52 }, + rotation: { x: 90, y: 1, z: 0 }, + scale: 1 + } +} diff --git a/ElementalTools/assets/fma/lang/en.json b/ElementalTools/assets/fma/lang/en.json new file mode 100644 index 0000000..20efb84 --- /dev/null +++ b/ElementalTools/assets/fma/lang/en.json @@ -0,0 +1,23 @@ +{ + "itemdesc-metal_shaving-*": "Various small bits of metal. Looks re-smeltable.", + "item-metal_shaving-*":"Metal Shavings", + "item-metal_shaving-bismuth": "Bismuth Shavings", + "item-metal_shaving-bismuthbronze": "Bismuth bronze Shavings", + "item-metal_shaving-blackbronze": "Black bronze Shavings", + "item-metal_shaving-brass": "Brass Shavings", + "item-metal_shaving-chromium": "Chromium Shavings", + "item-metal_shaving-copper": "Copper Shavings", + "item-metal_shaving-gold": "Gold Shavings", + "item-metal_shaving-iron": "Iron Shavings", + "item-metal_shaving-lead": "Lead Shavings", + "item-metal_shaving-platinum": "Platinum Shavings", + "item-metal_shaving-rhodium": "Rhodium Shavings", + "item-metal_shaving-silver": "Silver Shavings", + "item-metal_shaving-stainlesssteel": "Stainless-Steel Shavings", + "item-metal_shaving-steel": "Steel Shavings", + "item-metal_shaving-tin": "Tin Shavings", + "item-metal_shaving-tinbronze": "Tin bronze Shavings", + "item-metal_shaving-titanium": "Titanium Shavings", + "item-metal_shaving-uranium": "Uranium Shavings", + "item-metal_shaving-zinc": "Zinc Shavings", +} \ No newline at end of file diff --git a/ElementalTools/assets/fma/recipes/grid/tool/mallet.json b/ElementalTools/assets/fma/recipes/grid/tool/mallet.json new file mode 100644 index 0000000..12f8f1f --- /dev/null +++ b/ElementalTools/assets/fma/recipes/grid/tool/mallet.json @@ -0,0 +1,11 @@ +{ + ingredientPattern: "K H S", + ingredients: { + "K": { type: "item", code:"game:knife-*", isTool: true}, + "H": { type: "block", code: "game:log-*", allowedVariants: ["placed-birch-ud", "placed-oak-ud", "placed-maple-ud", "placed-pine-ud", "placed-acacia-ud"], name: "head" }, + "S": { type: "item", code: "game:stick" } + }, + width: 1, + height: 3, + output: { type: "item", code: "mallet", quantity: 1 } +} \ No newline at end of file diff --git a/ElementalTools/assets/fma/shapes/item/tools/mallet.json b/ElementalTools/assets/fma/shapes/item/tools/mallet.json new file mode 100644 index 0000000..36861f6 --- /dev/null +++ b/ElementalTools/assets/fma/shapes/item/tools/mallet.json @@ -0,0 +1,44 @@ +{ + "editor": { + "allAngles": false, + "entityTextureMode": false + }, + "textureWidth": 16, + "textureHeight": 8, + "textureSizes": { + }, + "textures": { + "head": "game:block/wood/debarked/birch", + "side": "game:block/wood/treetrunk/oak", + "wood": "game:item/tool/material/wood" + }, + "elements": [ + { + "name": "handle", + "from": [ 0.5, 7.5, 7.5 ], + "to": [ 13.5, 8.5, 8.5 ], + "rotationOrigin": [ -3.0, 0.0, 8.0 ], + "faces": { + "north": { "texture": "#wood", "uv": [ 2.0, 3.0, 15.0, 4.0 ] }, + "east": { "texture": "#wood", "uv": [ 6.5, 5.25, 7.5, 6.25 ] }, + "south": { "texture": "#wood", "uv": [ 1.5, 5.5, 14.5, 6.5 ] }, + "west": { "texture": "#wood", "uv": [ 7.0, 3.25, 8.0, 4.25 ] }, + "up": { "texture": "#wood", "uv": [ 2.0, 4.0, 15.0, 5.0 ] }, + "down": { "texture": "#wood", "uv": [ 1.5, 4.25, 14.5, 5.25 ] } + } + }, + { + "name": "Head", + "from": [ 7.5, 5.5, 5.5 ], + "to": [ 13.0, 10.5, 10.5 ], + "rotationOrigin": [ -1.0, -1.0, -1.0 ], + "faces": { + "north": { "texture": "#head", "uv": [ 4.0, 2.0, 9.5, 7.0 ] }, + "east": { "texture": "#side", "uv": [ 5.0, 1.5, 10.0, 6.5 ] }, + "south": { "texture": "#head", "uv": [ 5.0, 1.75, 10.5, 6.75 ] }, + "west": { "texture": "#side", "uv": [ 5.5, 1.75, 10.5, 6.75 ] }, + "up": { "texture": "#head", "uv": [ 5.0, 1.5, 13.0, 6.5 ], "autoUv": false }, + "down": { "texture": "#head", "uv": [ 4.5, 1.75, 10.0, 6.75 ] } + } + } + ]} \ No newline at end of file diff --git a/ElementalTools/modinfo.json b/ElementalTools/modinfo.json new file mode 100644 index 0000000..39808c0 --- /dev/null +++ b/ElementalTools/modinfo.json @@ -0,0 +1,13 @@ +{ + "type": "code", + "name": "𝙴𝙻𝙴𝙼𝙴𝙽𝚃𝙰𝙻 𝚃𝙾𝙾𝙻𝚂", + "description" : "Devices of great empowerment.", + "authors": ["Melchior"], + "ModID":"elementaltools", + "version": "0.1.0", + "dependencies": { + "game": "1.12.14", + "survival": "" + }, + "website": "http://nowebsite.nope" +} diff --git a/FirstMachineAge_Common/IMultiBlockModule.cs b/FirstMachineAge_Common/IMultiBlockModule.cs index e8a5cd6..500db42 100644 --- a/FirstMachineAge_Common/IMultiBlockModule.cs +++ b/FirstMachineAge_Common/IMultiBlockModule.cs @@ -16,7 +16,7 @@ namespace FirstMachineAge 'Membrane' block: points to Nucleus block, but also is input/output point for AbstractCircuits / Power 'Nucleus' block: houses MBM state/data & definition, as well as list of component block pos, and prototype */ - public interface IMultiBlockModule where T : Block + public interface IMultiBlockModule where T : Block //MultiBlock ? { ulong UniqueModuleID { get; } IMultiBlockModule NucleusBlock { get; } @@ -46,11 +46,16 @@ namespace FirstMachineAge public enum MBMType { Cyto, - Membrane, + Membrane, //or 'Ports' / Interface Nucleus, - //Vacuole // a "empty" 'Space' for Hardpoints or Sub-modules? + //Vacuole // a "empty" 'Space' for Hardpoints or Sub-modules? Optional slot? } } +/***** + +public virtual void OnBlockPlaced <- will set BlockEntity in BASE overirde for MultiBlock : Block + +*/ diff --git a/First_Machine_Age.sln b/First_Machine_Age.sln index 184a102..4b31299 100644 --- a/First_Machine_Age.sln +++ b/First_Machine_Age.sln @@ -9,6 +9,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AnvilMetalRecovery", "Anvil EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assorted", "Assorted\Assorted.csproj", "{805B37F5-F87D-4A63-BD3F-66AE59F1C998}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PsudeoTarget", "PsudeoTarget\PsudeoTarget.csproj", "{DF81DB59-817A-48BA-88CC-8173E6D2919D}" +EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ElementalTools", "ElementalTools\ElementalTools.csproj", "{EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -31,6 +35,14 @@ Global {805B37F5-F87D-4A63-BD3F-66AE59F1C998}.Debug|Any CPU.Build.0 = Debug|Any CPU {805B37F5-F87D-4A63-BD3F-66AE59F1C998}.Release|Any CPU.ActiveCfg = Release|Any CPU {805B37F5-F87D-4A63-BD3F-66AE59F1C998}.Release|Any CPU.Build.0 = Release|Any CPU + {DF81DB59-817A-48BA-88CC-8173E6D2919D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {DF81DB59-817A-48BA-88CC-8173E6D2919D}.Debug|Any CPU.Build.0 = Debug|Any CPU + {DF81DB59-817A-48BA-88CC-8173E6D2919D}.Release|Any CPU.ActiveCfg = Release|Any CPU + {DF81DB59-817A-48BA-88CC-8173E6D2919D}.Release|Any CPU.Build.0 = Release|Any CPU + {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}.Debug|Any CPU.Build.0 = Debug|Any CPU + {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}.Release|Any CPU.ActiveCfg = Release|Any CPU + {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}.Release|Any CPU.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(MonoDevelopProperties) = preSolution Policies = $0 diff --git a/PsudeoTarget/Program.cs b/PsudeoTarget/Program.cs new file mode 100644 index 0000000..6862146 --- /dev/null +++ b/PsudeoTarget/Program.cs @@ -0,0 +1,12 @@ +using System; + +namespace PsudeoTarget +{ + class MainClass + { + public static void Main(string[ ] args) + { + Console.WriteLine("Hello World!"); + } + } +} diff --git a/PsudeoTarget/Properties/AssemblyInfo.cs b/PsudeoTarget/Properties/AssemblyInfo.cs new file mode 100644 index 0000000..62b7270 --- /dev/null +++ b/PsudeoTarget/Properties/AssemblyInfo.cs @@ -0,0 +1,27 @@ +using System.Reflection; +using System.Runtime.CompilerServices; + +// Information about this assembly is defined by the following attributes. +// Change them to the values specific to your project. + +[assembly: AssemblyTitle("PsudeoTarget")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("")] +[assembly: AssemblyCopyright("librarian")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}". +// The form "{Major}.{Minor}.*" will automatically update the build and revision, +// and "{Major}.{Minor}.{Build}.*" will update just the revision. + +[assembly: AssemblyVersion("1.0.*")] + +// The following attributes are used to specify the signing key for the assembly, +// if desired. See the Mono documentation for more information about signing. + +//[assembly: AssemblyDelaySign(false)] +//[assembly: AssemblyKeyFile("")] + diff --git a/PsudeoTarget/PsudeoTarget.csproj b/PsudeoTarget/PsudeoTarget.csproj new file mode 100644 index 0000000..284f8bf --- /dev/null +++ b/PsudeoTarget/PsudeoTarget.csproj @@ -0,0 +1,37 @@ + + + + Debug + AnyCPU + {DF81DB59-817A-48BA-88CC-8173E6D2919D} + Exe + PsudeoTarget + PsudeoTarget + v4.5 + + + true + full + false + bin\Debug + DEBUG; + prompt + 4 + true + + + true + bin\Release + prompt + 4 + true + + + + + + + + + + \ No newline at end of file