• R/O
  • HTTP
  • SSH
  • HTTPS

コミット

タグ
未設定

よく使われているワード(クリックで追加)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

First Machine Age's Mods (Combined repo.)


コミットメタ情報

リビジョン5769c9c82bcad9c36e0be11313761d124695a7a1 (tree)
日時2020-05-14 15:43:30
作者melchior <melchior@user...>
コミッターmelchior

ログメッセージ

W.I.P. XII: Big heap of assorted stuff

変更サマリ

差分

--- a/AnvilMetalRecovery/AnvilMetalRecovery.csproj
+++ b/AnvilMetalRecovery/AnvilMetalRecovery.csproj
@@ -54,14 +54,16 @@
5454 <HintPath>vs_libs\VSSurvivalMod.dll</HintPath>
5555 <Private>False</Private>
5656 </Reference>
57+ <Reference Include="Newtonsoft.Json">
58+ <HintPath>vs_libs\Newtonsoft.Json.dll</HintPath>
59+ <Private>False</Private>
60+ </Reference>
5761 </ItemGroup>
5862 <ItemGroup>
5963 <Compile Include="MetalRecoverySystem.cs" />
6064 <Compile Include="Properties\AssemblyInfo.cs" />
6165 <Compile Include="BlockEntities\MetalRecovery_BlockEntityAnvil.cs" />
62- <Compile Include="Items\ItemMallet.cs">
63- <CopyToOutputDirectory>Always</CopyToOutputDirectory>
64- </Compile>
66+ <Compile Include="Helpers.cs" />
6567 </ItemGroup>
6668 <ItemGroup>
6769 <None Include="modinfo.json">
@@ -98,7 +100,6 @@
98100 <Folder Include="BlockEntities\" />
99101 <Folder Include="assets\fma\shapes\item\tools\" />
100102 <Folder Include="assets\fma\itemtypes\tools\" />
101- <Folder Include="Items\" />
102103 <Folder Include="assets\fma\recipes\" />
103104 <Folder Include="assets\fma\recipes\grid\" />
104105 <Folder Include="assets\fma\recipes\grid\tool\" />
--- /dev/null
+++ b/AnvilMetalRecovery/Helpers.cs
@@ -0,0 +1,30 @@
1+using System;
2+
3+using Vintagestory.API.Common;
4+using Vintagestory.API.Server;
5+using Vintagestory.Common;
6+using Vintagestory.Server;
7+
8+namespace AnvilMetalRecovery
9+{
10+ internal static class Helpers
11+ {
12+ internal static void ReplaceBlockEntityType(this ClassRegistry registry, string className, Type blockentity)
13+ {
14+ if (registry.blockEntityClassnameToTypeMapping.ContainsKey(className)) {
15+ //replace it
16+ registry.blockEntityClassnameToTypeMapping[className] = blockentity;
17+ registry.blockEntityTypeToClassnameMapping[blockentity] = className;
18+ }
19+ }
20+
21+ internal static void ReplaceItemClassType(this ClassRegistry registry, string className, Type replacer)
22+ {
23+ if (registry.ItemClassToTypeMapping.ContainsKey(className)) {
24+ //replace it
25+ registry.ItemClassToTypeMapping[className] = replacer;
26+ }
27+ }
28+ }
29+}
30+
--- a/AnvilMetalRecovery/MetalRecoverySystem.cs
+++ b/AnvilMetalRecovery/MetalRecoverySystem.cs
@@ -5,16 +5,16 @@ using Vintagestory.API.Common;
55 using Vintagestory.API.Server;
66 using Vintagestory.Common;
77 using Vintagestory.Server;
8+using Vintagestory.ServerMods;
89
910 namespace AnvilMetalRecovery
1011 {
11- public class MetalRecoverySystem : ModSystem
12- {
13- internal const string anvilKey = @"Anvil";
14-
12+ public partial class MetalRecoverySystem : ModSystem
13+ {
1514 private ICoreAPI CoreAPI;
1615 private ICoreServerAPI ServerAPI;
1716 private ServerCoreAPI ServerCore { get; set; }
17+ //private RecipeLoader LoaderOfRecipies { get; set;}
1818
1919 public override bool AllowRuntimeReload {
2020 get { return false; }
@@ -27,23 +27,23 @@ namespace AnvilMetalRecovery
2727
2828 public override double ExecuteOrder( )
2929 {
30- return 0.10d;
30+ return 0.1d;
3131 }
3232
3333 public override void Start(ICoreAPI api)
3434 {
3535 this.CoreAPI = api;
36- CoreAPI.RegisterItemClass(@"ItemMallet", typeof(ItemMallet));
36+
37+ RegisterItemClasses();
38+
3739
3840 base.Start(api);
3941 }
4042
4143 public override void StartServerSide(ICoreServerAPI api)
4244 {
43- base.StartServerSide(api);
44-
4545 this.ServerAPI = api;
46-
46+ //LoaderOfRecipies = ServerAPI.ModLoader.GetModSystem<RecipeLoader>( );
4747
4848 if (api is ServerCoreAPI) {
4949 ServerCore = api as ServerCoreAPI;
@@ -52,6 +52,8 @@ namespace AnvilMetalRecovery
5252 Mod.Logger.Error("Cannot access 'ServerCoreAPI' class: API (implimentation) has changed, Contact Developer!");
5353 return;
5454 }
55+
56+ ServerCore.Event.ServerRunPhase(EnumServerRunPhase.LoadGame, OnServerLoadGame);
5557 //ServerAPI.ClassRegistry.GetBlockEntityClass
5658 //ServerAPI.RegisterBlockEntityClass(anvilKey, typeof(MetalRecovery_BlockEntityAnvil));
5759
@@ -60,46 +62,12 @@ namespace AnvilMetalRecovery
6062 Mod.Logger.VerboseDebug("Anvil Metal Recovery - should be installed...");
6163 }
6264
63- internal void GenerateMetalShavingsItems( )
64- {
65- //TODO: Automatic Generation of Item 'metal_shaving' by metal & alloy list at RUNTIME
66- var genericShaving = ServerAPI.World.ClassRegistry.CreateItem("metal_shaving");
67- //genericShaving.CombustibleProps.
68-
69- var metalProperties = new Dictionary<AssetLocation, MetalProperty>( );
70-
71- foreach (var entry in ServerAPI.Assets.GetMany<MetalProperty>(Mod.Logger, "worldproperties/"))
72- {
73- AssetLocation loc = entry.Key.Clone( );
74- loc.Path = loc.Path.Replace("worldproperties/", "");
75- loc.RemoveEnding( );
76-
77- entry.Value.Code.Domain = entry.Key.Domain;
78-
79- metalProperties.Add(loc, entry.Value);
80-
81- }
82- }
83- }
84-
85- internal static class Helpers
86- {
87- internal static void ReplaceBlockEntityType(this ClassRegistry registry, string className, Type blockentity)
65+ private void OnServerLoadGame( )
8866 {
89- if (registry.blockEntityClassnameToTypeMapping.ContainsKey(className)) {
90- //replace it
91- registry.blockEntityClassnameToTypeMapping[className] = blockentity;
92- registry.blockEntityTypeToClassnameMapping[blockentity] = className;
93- }
67+ ManipulateGridRecipies( );
9468 }
69+}
70+
9571
96- internal static void ReplaceItemClassType(this ClassRegistry registry, string className, Type replacer)
97- {
98- if (registry.ItemClassToTypeMapping.ContainsKey(className)) {
99- //replace it
100- registry.ItemClassToTypeMapping[className] = replacer;
101- }
102- }
103- }
10472 }
10573
--- a/AnvilMetalRecovery/assets/fma/itemtypes/tools/mallet.json
+++ b/AnvilMetalRecovery/assets/fma/itemtypes/tools/mallet.json
@@ -15,7 +15,7 @@
1515 heldTpHitAnimation: "smithing",
1616 shape: { base: "item/tools/mallet" },
1717 textures: {
18- "head": { base:"game:block/wood/debarked/birch"},
18+ "head": { base:"game:block/wood/debarked/oak"},
1919 "side": { base:"game:block/wood/treetrunk/oak"},
2020 "wood": { base:"game:item/tool/material/wood"}
2121 },
--- a/AnvilMetalRecovery/assets/fma/recipes/grid/tool/mallet.json
+++ b/AnvilMetalRecovery/assets/fma/recipes/grid/tool/mallet.json
@@ -2,7 +2,7 @@
22 ingredientPattern: "K H S",
33 ingredients: {
44 "K": { type: "item", code:"game:knife-*", isTool: true},
5- "H": { type: "block", code: "game:log-*", name: "head" },
5+ "H": { type: "block", code: "game:log-*", allowedVariants: ["placed-birch-ud", "placed-oak-ud", "placed-maple-ud", "placed-pine-ud", "placed-acacia-ud"], name: "head" },
66 "S": { type: "item", code: "game:stick" }
77 },
88 width: 1,
--- a/AnvilMetalRecovery/modinfo.json
+++ b/AnvilMetalRecovery/modinfo.json
@@ -3,6 +3,7 @@
33 "name": "Metal Recovery & More",
44 "description" : "Get back lost scrap and smithing discards, and more.",
55 "authors": ["Melchior"],
6+ "ModID":"metalrecovery",
67 "version": "0.1.2",
78 "dependencies": {
89 "game": "1.12.11",
--- a/Assorted/BlockBehaviors/BlockBehaviorVerticalOrientation.cs
+++ b/Assorted/BlockBehaviors/BlockBehaviorVerticalOrientation.cs
@@ -13,7 +13,7 @@ namespace FirstMachineAge
1313 private readonly string verticalKey;
1414
1515 /*
16- * abstact/"horizontalorientation"
16+ * "abstract/verticalorientation"
1717 */
1818
1919
--- /dev/null
+++ b/ElementalTools/Assignments.cs
@@ -0,0 +1,121 @@
1+using System;
2+using System.Collections.Generic;
3+
4+using System.Linq;
5+using System.Threading;
6+
7+using Vintagestory.API.Common;
8+using Vintagestory.API.Config;
9+
10+
11+
12+
13+namespace ElementalTools
14+{
15+ public partial class ElementalToolsSystem : ModSystem
16+ {
17+ internal const string anvilKey = @"Anvil";
18+ internal const string malletItemKey = @"ItemMallet";
19+ internal const string malletAssetKey = @"mallet";
20+
21+ private void RegisterItemClasses()
22+ {
23+ CoreAPI.RegisterItemClass(malletItemKey, typeof(ItemMallet));
24+ }
25+
26+
27+ private void ManipulateGridRecipies( )
28+ {
29+ uint malletizedCount = 0;
30+ //Thread.Sleep(1000);
31+ Mod.Logger.VerboseDebug($"Total GridRecipies: {CoreAPI.World.GridRecipes.Count}");
32+
33+ /*
34+ var alternateQuery = from gridRecipie in CoreAPI.World.GridRecipes
35+ where gridRecipie.Ingredients.Any(gi => gi.Value.IsTool && gi.Value.Code.BeginsWith(GlobalConstants.DefaultDomain, @"hammer"))
36+ where gridRecipie.Output.Code.BeginsWith(GlobalConstants.DefaultDomain, @"nugget") == false
37+ where gridRecipie.Output.Code.BeginsWith(GlobalConstants.DefaultDomain, @"lime") == false
38+ select gridRecipie;
39+
40+ Mod.Logger.VerboseDebug($"Found {alternateQuery.Count()} Recipies using Hammer, (non ore)");
41+
42+ if (alternateQuery.Any()) {
43+ foreach (var recipieToClone in alternateQuery.ToArray()) {
44+ var cloneRecipie = recipieToClone.Clone( );
45+ var hammerIngredient = cloneRecipie.Ingredients.First(gi => gi.Value.IsTool && gi.Value.Code.BeginsWith(GlobalConstants.DefaultDomain, @"hammer"));
46+
47+ CraftingRecipeIngredient malletIngredient = new CraftingRecipeIngredient {
48+ Type = EnumItemClass.Item,
49+ IsTool = true,
50+ Code = new AssetLocation(@"fma", malletAssetKey),
51+ IsWildCard = false,
52+ //Name = "mallet",
53+ };
54+ cloneRecipie.Ingredients[hammerIngredient.Key] = malletIngredient;
55+ ServerCore.RegisterCraftingRecipe(cloneRecipie);
56+ malletizedCount++;
57+ }
58+
59+ Mod.Logger.VerboseDebug($"Added {malletizedCount} Mallet recipies");
60+ }
61+ */
62+
63+ GridRecipe testRecipie = new GridRecipe {
64+ IngredientPattern = "M\tF",
65+ Name = new AssetLocation("fma","LogToSticks"),
66+ Height = 2,
67+ Width = 1,
68+ Ingredients =
69+ new Dictionary<string, CraftingRecipeIngredient>{
70+ {"M", new CraftingRecipeIngredient{
71+ Name = "mallet",
72+ Type = EnumItemClass.Item,
73+ Code = new AssetLocation("fma",malletAssetKey),
74+ IsTool = true,
75+ Quantity = 1,}
76+ },
77+ {"F", new CraftingRecipeIngredient{
78+ Name = "wood",
79+ Type = EnumItemClass.Item,
80+ Code = new AssetLocation(GlobalConstants.DefaultDomain,"firewood"),
81+ Quantity = 1,}
82+ },
83+ },
84+ Output = new CraftingRecipeIngredient{
85+ Type = EnumItemClass.Item,
86+ Quantity = 3,
87+ Code = new AssetLocation(GlobalConstants.DefaultDomain,"stick"),
88+ },
89+ };//Needs: ResolvedItemstack <- for Non-wildcard !!!!
90+ testRecipie.ResolveIngredients(ServerCore.World);
91+
92+ ServerCore.RegisterCraftingRecipe(testRecipie);
93+ }
94+
95+ //TODO: Recycling assignment of Smeltable properties from all smith/grid/recipe forms...
96+
97+
98+ internal void GenerateMetalShavingsItems( )
99+ {
100+ //TODO: Automatic Generation of Item 'metal_shaving' by metal & alloy list at RUNTIME
101+ var genericShaving = ServerAPI.World.ClassRegistry.CreateItem("metal_shaving");
102+ //genericShaving.CombustibleProps.
103+
104+ var metalProperties = new Dictionary<AssetLocation, MetalProperty>( );
105+
106+ foreach (var entry in ServerAPI.Assets.GetMany<MetalProperty>(Mod.Logger, "worldproperties/")) {
107+ AssetLocation loc = entry.Key.Clone( );
108+ loc.Path = loc.Path.Replace("worldproperties/", "");
109+ loc.RemoveEnding( );
110+
111+ entry.Value.Code.Domain = entry.Key.Domain;
112+
113+ metalProperties.Add(loc, entry.Value);
114+
115+ }
116+ }
117+
118+
119+ }
120+}
121+
--- /dev/null
+++ b/ElementalTools/ElementalTools.csproj
@@ -0,0 +1,97 @@
1+<?xml version="1.0" encoding="utf-8"?>
2+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+ <PropertyGroup>
4+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
5+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
6+ <ProjectGuid>{EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}</ProjectGuid>
7+ <OutputType>Library</OutputType>
8+ <RootNamespace>ElementalTools</RootNamespace>
9+ <AssemblyName>ElementalTools</AssemblyName>
10+ <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
11+ </PropertyGroup>
12+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
13+ <DebugSymbols>true</DebugSymbols>
14+ <DebugType>full</DebugType>
15+ <Optimize>false</Optimize>
16+ <OutputPath>bin\Debug</OutputPath>
17+ <DefineConstants>DEBUG;</DefineConstants>
18+ <ErrorReport>prompt</ErrorReport>
19+ <WarningLevel>4</WarningLevel>
20+ <ConsolePause>false</ConsolePause>
21+ <CustomCommands>
22+ <CustomCommands>
23+ <Command type="AfterBuild" command="7z -tzip a ${ProjectName}_${ProjectConfig}.zip" workingdir="${TargetDir}" />
24+ <Command type="AfterClean" command="rm -f *.zip" workingdir="${TargetDir}" />
25+ </CustomCommands>
26+ </CustomCommands>
27+ </PropertyGroup>
28+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
29+ <Optimize>true</Optimize>
30+ <OutputPath>bin\Release</OutputPath>
31+ <ErrorReport>prompt</ErrorReport>
32+ <WarningLevel>4</WarningLevel>
33+ <ConsolePause>false</ConsolePause>
34+ </PropertyGroup>
35+ <ItemGroup>
36+ <Reference Include="System" />
37+ <Reference Include="Newtonsoft.Json">
38+ <HintPath>vs_libs\Newtonsoft.Json.dll</HintPath>
39+ <Private>False</Private>
40+ </Reference>
41+ <Reference Include="protobuf-net">
42+ <HintPath>vs_libs\protobuf-net.dll</HintPath>
43+ <Private>False</Private>
44+ </Reference>
45+ <Reference Include="VintagestoryAPI">
46+ <HintPath>vs_libs\VintagestoryAPI.dll</HintPath>
47+ <Private>False</Private>
48+ </Reference>
49+ <Reference Include="VintagestoryLib">
50+ <HintPath>vs_libs\VintagestoryLib.dll</HintPath>
51+ <Private>False</Private>
52+ </Reference>
53+ <Reference Include="VSCreativeMod">
54+ <HintPath>vs_libs\VSCreativeMod.dll</HintPath>
55+ <Private>False</Private>
56+ </Reference>
57+ <Reference Include="VSEssentials">
58+ <HintPath>vs_libs\VSEssentials.dll</HintPath>
59+ <Private>False</Private>
60+ </Reference>
61+ <Reference Include="VSSurvivalMod">
62+ <HintPath>vs_libs\VSSurvivalMod.dll</HintPath>
63+ <Private>False</Private>
64+ </Reference>
65+ </ItemGroup>
66+ <ItemGroup>
67+ <Compile Include="ElementalToolsMod.cs" />
68+ <Compile Include="Properties\AssemblyInfo.cs" />
69+ <Compile Include="Assignments.cs" />
70+ <Compile Include="Items\ItemMallet.cs">
71+ <CopyToOutputDirectory>Always</CopyToOutputDirectory>
72+ </Compile>
73+ </ItemGroup>
74+ <ItemGroup>
75+ <Folder Include="Items\" />
76+ <Folder Include="assets\" />
77+ <Folder Include="assets\fma\" />
78+ </ItemGroup>
79+ <ItemGroup>
80+ <None Include="modinfo.json">
81+ <CopyToOutputDirectory>Always</CopyToOutputDirectory>
82+ </None>
83+ <None Include="assets\fma\itemtypes\tools\mallet.json">
84+ <CopyToOutputDirectory>Always</CopyToOutputDirectory>
85+ </None>
86+ <None Include="assets\fma\lang\en.json">
87+ <CopyToOutputDirectory>Always</CopyToOutputDirectory>
88+ </None>
89+ <None Include="assets\fma\recipes\grid\tool\mallet.json">
90+ <CopyToOutputDirectory>Always</CopyToOutputDirectory>
91+ </None>
92+ <None Include="assets\fma\shapes\item\tools\mallet.json">
93+ <CopyToOutputDirectory>Always</CopyToOutputDirectory>
94+ </None>
95+ </ItemGroup>
96+ <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
97+</Project>
\ No newline at end of file
--- /dev/null
+++ b/ElementalTools/ElementalToolsMod.cs
@@ -0,0 +1,72 @@
1+using System;
2+using System.Collections.Generic;
3+
4+using Vintagestory.API.Common;
5+using Vintagestory.API.Server;
6+using Vintagestory.Common;
7+using Vintagestory.Server;
8+using Vintagestory.ServerMods;
9+
10+namespace ElementalTools
11+{
12+ public partial class ElementalToolsSystem : ModSystem
13+ {
14+ private ICoreAPI CoreAPI;
15+ private ICoreServerAPI ServerAPI;
16+ private ServerCoreAPI ServerCore { get; set; }
17+ //private RecipeLoader LoaderOfRecipies { get; set;}
18+
19+ public override bool AllowRuntimeReload {
20+ get { return false; }
21+ }
22+
23+ public override bool ShouldLoad(EnumAppSide forSide)
24+ {
25+ return true;
26+ }
27+
28+ public override double ExecuteOrder( )
29+ {
30+ return 0.1d;
31+ }
32+
33+ public override void Start(ICoreAPI api)
34+ {
35+ this.CoreAPI = api;
36+
37+ RegisterItemClasses( );
38+
39+
40+ base.Start(api);
41+ }
42+
43+ public override void StartServerSide(ICoreServerAPI api)
44+ {
45+ this.ServerAPI = api;
46+ //LoaderOfRecipies = ServerAPI.ModLoader.GetModSystem<RecipeLoader>( );
47+
48+ if (api is ServerCoreAPI) {
49+ ServerCore = api as ServerCoreAPI;
50+ }
51+ else {
52+ Mod.Logger.Error("Cannot access 'ServerCoreAPI' class: API (implimentation) has changed, Contact Developer!");
53+ return;
54+ }
55+
56+ ServerCore.Event.ServerRunPhase(EnumServerRunPhase.LoadGame, OnServerLoadGame);
57+
58+
59+
60+
61+ Mod.Logger.VerboseDebug("Elemental Tools - should be installed...");
62+ }
63+
64+ private void OnServerLoadGame( )
65+ {
66+ ManipulateGridRecipies( );
67+ }
68+ }
69+
70+
71+}
72+
--- a/AnvilMetalRecovery/Items/ItemMallet.cs
+++ b/ElementalTools/Items/ItemMallet.cs
@@ -3,7 +3,7 @@
33 using Vintagestory.API.Common;
44 using Vintagestory.API.Config;
55
6-namespace AnvilMetalRecovery
6+namespace ElementalTools
77 {
88 public class ItemMallet : Item
99 {
@@ -28,7 +28,10 @@ namespace AnvilMetalRecovery
2828 return false;
2929 }
3030
31- if (ingredient.IsTool && ingredient.Code.BeginsWith(GlobalConstants.DefaultDomain, @"hammer")) {
31+ if (ingredient.IsTool &&
32+ (ingredient.Code.BeginsWith(GlobalConstants.DefaultDomain, @"hammer") ||
33+ ingredient.Code.BeginsWith("fma",ElementalToolsSystem.malletAssetKey)))
34+ {
3235 return true;
3336 }
3437
--- /dev/null
+++ b/ElementalTools/Properties/AssemblyInfo.cs
@@ -0,0 +1,27 @@
1+using System.Reflection;
2+using System.Runtime.CompilerServices;
3+
4+// Information about this assembly is defined by the following attributes.
5+// Change them to the values specific to your project.
6+
7+[assembly: AssemblyTitle("ElementalTools")]
8+[assembly: AssemblyDescription("")]
9+[assembly: AssemblyConfiguration("")]
10+[assembly: AssemblyCompany("")]
11+[assembly: AssemblyProduct("")]
12+[assembly: AssemblyCopyright("librarian")]
13+[assembly: AssemblyTrademark("")]
14+[assembly: AssemblyCulture("")]
15+
16+// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
17+// The form "{Major}.{Minor}.*" will automatically update the build and revision,
18+// and "{Major}.{Minor}.{Build}.*" will update just the revision.
19+
20+[assembly: AssemblyVersion("1.0.*")]
21+
22+// The following attributes are used to specify the signing key for the assembly,
23+// if desired. See the Mono documentation for more information about signing.
24+
25+//[assembly: AssemblyDelaySign(false)]
26+//[assembly: AssemblyKeyFile("")]
27+
--- /dev/null
+++ b/ElementalTools/assets/fma/itemtypes/tools/mallet.json
@@ -0,0 +1,49 @@
1+{
2+ code: "mallet",
3+ class: "ItemMallet",
4+ attributes: {
5+ handbook: {
6+ include: true
7+ },
8+ toolrackTransform: {
9+ rotation: { y: 1, z: -1 },
10+ translation: { x: -0.2 },
11+ scale: 1.5,
12+ }
13+ },
14+ tool: "hammer",
15+ heldTpHitAnimation: "smithing",
16+ shape: { base: "item/tools/mallet" },
17+ textures: {
18+ "head": { base:"game:block/wood/debarked/oak"},
19+ "side": { base:"game:block/wood/treetrunk/oak"},
20+ "wood": { base:"game:item/tool/material/wood"}
21+ },
22+ tooltier: 1,
23+ durability: 200,
24+ attackpower: 1,
25+ creativeinventory: { "general": ["*"], "items": ["*"], "tools": ["*"] },
26+ fpHandTransform: {
27+ translation: { x: 0.0468, y: -0.2, z: 0 },
28+ rotation: { x: 15, y: 15, z: 90 },
29+ scale: 2.5
30+ },
31+ guiTransform: {
32+ rotate: false,
33+ translation: { x: 0, y: 5, z: 0 },
34+ rotation: { x: -77, y: -135, z: 160 },
35+ origin: { x: 0.54, y: 0.5, z: 0.48 },
36+ scale: 2.6
37+ },
38+ groundTransform: {
39+ translation: { x: 0, y: 0, z: 0 },
40+ rotation: { x: 0, y: 0, z: 0 },
41+ origin: { x: 0.5, y: 0.45, z: 0.5 },
42+ scale: 4.5
43+ },
44+ tpHandTransform: {
45+ translation: { x: -0.75, y: -0.48, z: -0.52 },
46+ rotation: { x: 90, y: 1, z: 0 },
47+ scale: 1
48+ }
49+}
--- /dev/null
+++ b/ElementalTools/assets/fma/lang/en.json
@@ -0,0 +1,23 @@
1+{
2+ "itemdesc-metal_shaving-*": "Various small bits of metal. Looks re-smeltable.",
3+ "item-metal_shaving-*":"Metal Shavings",
4+ "item-metal_shaving-bismuth": "Bismuth Shavings",
5+ "item-metal_shaving-bismuthbronze": "Bismuth bronze Shavings",
6+ "item-metal_shaving-blackbronze": "Black bronze Shavings",
7+ "item-metal_shaving-brass": "Brass Shavings",
8+ "item-metal_shaving-chromium": "Chromium Shavings",
9+ "item-metal_shaving-copper": "Copper Shavings",
10+ "item-metal_shaving-gold": "Gold Shavings",
11+ "item-metal_shaving-iron": "Iron Shavings",
12+ "item-metal_shaving-lead": "Lead Shavings",
13+ "item-metal_shaving-platinum": "Platinum Shavings",
14+ "item-metal_shaving-rhodium": "Rhodium Shavings",
15+ "item-metal_shaving-silver": "Silver Shavings",
16+ "item-metal_shaving-stainlesssteel": "Stainless-Steel Shavings",
17+ "item-metal_shaving-steel": "Steel Shavings",
18+ "item-metal_shaving-tin": "Tin Shavings",
19+ "item-metal_shaving-tinbronze": "Tin bronze Shavings",
20+ "item-metal_shaving-titanium": "Titanium Shavings",
21+ "item-metal_shaving-uranium": "Uranium Shavings",
22+ "item-metal_shaving-zinc": "Zinc Shavings",
23+}
\ No newline at end of file
--- /dev/null
+++ b/ElementalTools/assets/fma/recipes/grid/tool/mallet.json
@@ -0,0 +1,11 @@
1+{
2+ ingredientPattern: "K H S",
3+ ingredients: {
4+ "K": { type: "item", code:"game:knife-*", isTool: true},
5+ "H": { type: "block", code: "game:log-*", allowedVariants: ["placed-birch-ud", "placed-oak-ud", "placed-maple-ud", "placed-pine-ud", "placed-acacia-ud"], name: "head" },
6+ "S": { type: "item", code: "game:stick" }
7+ },
8+ width: 1,
9+ height: 3,
10+ output: { type: "item", code: "mallet", quantity: 1 }
11+}
\ No newline at end of file
--- /dev/null
+++ b/ElementalTools/assets/fma/shapes/item/tools/mallet.json
@@ -0,0 +1,44 @@
1+{
2+ "editor": {
3+ "allAngles": false,
4+ "entityTextureMode": false
5+ },
6+ "textureWidth": 16,
7+ "textureHeight": 8,
8+ "textureSizes": {
9+ },
10+ "textures": {
11+ "head": "game:block/wood/debarked/birch",
12+ "side": "game:block/wood/treetrunk/oak",
13+ "wood": "game:item/tool/material/wood"
14+ },
15+ "elements": [
16+ {
17+ "name": "handle",
18+ "from": [ 0.5, 7.5, 7.5 ],
19+ "to": [ 13.5, 8.5, 8.5 ],
20+ "rotationOrigin": [ -3.0, 0.0, 8.0 ],
21+ "faces": {
22+ "north": { "texture": "#wood", "uv": [ 2.0, 3.0, 15.0, 4.0 ] },
23+ "east": { "texture": "#wood", "uv": [ 6.5, 5.25, 7.5, 6.25 ] },
24+ "south": { "texture": "#wood", "uv": [ 1.5, 5.5, 14.5, 6.5 ] },
25+ "west": { "texture": "#wood", "uv": [ 7.0, 3.25, 8.0, 4.25 ] },
26+ "up": { "texture": "#wood", "uv": [ 2.0, 4.0, 15.0, 5.0 ] },
27+ "down": { "texture": "#wood", "uv": [ 1.5, 4.25, 14.5, 5.25 ] }
28+ }
29+ },
30+ {
31+ "name": "Head",
32+ "from": [ 7.5, 5.5, 5.5 ],
33+ "to": [ 13.0, 10.5, 10.5 ],
34+ "rotationOrigin": [ -1.0, -1.0, -1.0 ],
35+ "faces": {
36+ "north": { "texture": "#head", "uv": [ 4.0, 2.0, 9.5, 7.0 ] },
37+ "east": { "texture": "#side", "uv": [ 5.0, 1.5, 10.0, 6.5 ] },
38+ "south": { "texture": "#head", "uv": [ 5.0, 1.75, 10.5, 6.75 ] },
39+ "west": { "texture": "#side", "uv": [ 5.5, 1.75, 10.5, 6.75 ] },
40+ "up": { "texture": "#head", "uv": [ 5.0, 1.5, 13.0, 6.5 ], "autoUv": false },
41+ "down": { "texture": "#head", "uv": [ 4.5, 1.75, 10.0, 6.75 ] }
42+ }
43+ }
44+ ]}
\ No newline at end of file
--- /dev/null
+++ b/ElementalTools/modinfo.json
@@ -0,0 +1,13 @@
1+{
2+ "type": "code",
3+ "name": "𝙴𝙻𝙴𝙼𝙴𝙽𝚃𝙰𝙻 𝚃𝙾𝙾𝙻𝚂",
4+ "description" : "Devices of great empowerment.",
5+ "authors": ["Melchior"],
6+ "ModID":"elementaltools",
7+ "version": "0.1.0",
8+ "dependencies": {
9+ "game": "1.12.14",
10+ "survival": ""
11+ },
12+ "website": "http://nowebsite.nope"
13+}
--- a/FirstMachineAge_Common/IMultiBlockModule.cs
+++ b/FirstMachineAge_Common/IMultiBlockModule.cs
@@ -16,7 +16,7 @@ namespace FirstMachineAge
1616 'Membrane' block: points to Nucleus block, but also is input/output point for AbstractCircuits / Power
1717 'Nucleus' block: houses MBM state/data & definition, as well as list of component block pos, and prototype
1818 */
19- public interface IMultiBlockModule<T> where T : Block
19+ public interface IMultiBlockModule<T> where T : Block //MultiBlock ?
2020 {
2121 ulong UniqueModuleID { get; }
2222 IMultiBlockModule<T> NucleusBlock { get; }
@@ -46,11 +46,16 @@ namespace FirstMachineAge
4646 public enum MBMType
4747 {
4848 Cyto,
49- Membrane,
49+ Membrane, //or 'Ports' / Interface
5050 Nucleus,
51- //Vacuole // a "empty" 'Space' for Hardpoints or Sub-modules?
51+ //Vacuole // a "empty" 'Space' for Hardpoints or Sub-modules? Optional slot?
5252 }
5353
5454
5555 }
5656
57+/*****
58+
59+public virtual void OnBlockPlaced <- will set BlockEntity in BASE overirde for MultiBlock : Block
60+
61+*/
--- a/First_Machine_Age.sln
+++ b/First_Machine_Age.sln
@@ -9,6 +9,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AnvilMetalRecovery", "Anvil
99 EndProject
1010 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Assorted", "Assorted\Assorted.csproj", "{805B37F5-F87D-4A63-BD3F-66AE59F1C998}"
1111 EndProject
12+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "PsudeoTarget", "PsudeoTarget\PsudeoTarget.csproj", "{DF81DB59-817A-48BA-88CC-8173E6D2919D}"
13+EndProject
14+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ElementalTools", "ElementalTools\ElementalTools.csproj", "{EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}"
15+EndProject
1216 Global
1317 GlobalSection(SolutionConfigurationPlatforms) = preSolution
1418 Debug|Any CPU = Debug|Any CPU
@@ -31,6 +35,14 @@ Global
3135 {805B37F5-F87D-4A63-BD3F-66AE59F1C998}.Debug|Any CPU.Build.0 = Debug|Any CPU
3236 {805B37F5-F87D-4A63-BD3F-66AE59F1C998}.Release|Any CPU.ActiveCfg = Release|Any CPU
3337 {805B37F5-F87D-4A63-BD3F-66AE59F1C998}.Release|Any CPU.Build.0 = Release|Any CPU
38+ {DF81DB59-817A-48BA-88CC-8173E6D2919D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
39+ {DF81DB59-817A-48BA-88CC-8173E6D2919D}.Debug|Any CPU.Build.0 = Debug|Any CPU
40+ {DF81DB59-817A-48BA-88CC-8173E6D2919D}.Release|Any CPU.ActiveCfg = Release|Any CPU
41+ {DF81DB59-817A-48BA-88CC-8173E6D2919D}.Release|Any CPU.Build.0 = Release|Any CPU
42+ {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
43+ {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}.Debug|Any CPU.Build.0 = Debug|Any CPU
44+ {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}.Release|Any CPU.ActiveCfg = Release|Any CPU
45+ {EA9BA3EC-EF08-4192-A844-4D3F398B1FFF}.Release|Any CPU.Build.0 = Release|Any CPU
3446 EndGlobalSection
3547 GlobalSection(MonoDevelopProperties) = preSolution
3648 Policies = $0
--- /dev/null
+++ b/PsudeoTarget/Program.cs
@@ -0,0 +1,12 @@
1+using System;
2+
3+namespace PsudeoTarget
4+{
5+ class MainClass
6+ {
7+ public static void Main(string[ ] args)
8+ {
9+ Console.WriteLine("Hello World!");
10+ }
11+ }
12+}
--- /dev/null
+++ b/PsudeoTarget/Properties/AssemblyInfo.cs
@@ -0,0 +1,27 @@
1+using System.Reflection;
2+using System.Runtime.CompilerServices;
3+
4+// Information about this assembly is defined by the following attributes.
5+// Change them to the values specific to your project.
6+
7+[assembly: AssemblyTitle("PsudeoTarget")]
8+[assembly: AssemblyDescription("")]
9+[assembly: AssemblyConfiguration("")]
10+[assembly: AssemblyCompany("")]
11+[assembly: AssemblyProduct("")]
12+[assembly: AssemblyCopyright("librarian")]
13+[assembly: AssemblyTrademark("")]
14+[assembly: AssemblyCulture("")]
15+
16+// The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
17+// The form "{Major}.{Minor}.*" will automatically update the build and revision,
18+// and "{Major}.{Minor}.{Build}.*" will update just the revision.
19+
20+[assembly: AssemblyVersion("1.0.*")]
21+
22+// The following attributes are used to specify the signing key for the assembly,
23+// if desired. See the Mono documentation for more information about signing.
24+
25+//[assembly: AssemblyDelaySign(false)]
26+//[assembly: AssemblyKeyFile("")]
27+
--- /dev/null
+++ b/PsudeoTarget/PsudeoTarget.csproj
@@ -0,0 +1,37 @@
1+<?xml version="1.0" encoding="utf-8"?>
2+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+ <PropertyGroup>
4+ <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
5+ <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
6+ <ProjectGuid>{DF81DB59-817A-48BA-88CC-8173E6D2919D}</ProjectGuid>
7+ <OutputType>Exe</OutputType>
8+ <RootNamespace>PsudeoTarget</RootNamespace>
9+ <AssemblyName>PsudeoTarget</AssemblyName>
10+ <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
11+ </PropertyGroup>
12+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
13+ <DebugSymbols>true</DebugSymbols>
14+ <DebugType>full</DebugType>
15+ <Optimize>false</Optimize>
16+ <OutputPath>bin\Debug</OutputPath>
17+ <DefineConstants>DEBUG;</DefineConstants>
18+ <ErrorReport>prompt</ErrorReport>
19+ <WarningLevel>4</WarningLevel>
20+ <ExternalConsole>true</ExternalConsole>
21+ </PropertyGroup>
22+ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
23+ <Optimize>true</Optimize>
24+ <OutputPath>bin\Release</OutputPath>
25+ <ErrorReport>prompt</ErrorReport>
26+ <WarningLevel>4</WarningLevel>
27+ <ExternalConsole>true</ExternalConsole>
28+ </PropertyGroup>
29+ <ItemGroup>
30+ <Reference Include="System" />
31+ </ItemGroup>
32+ <ItemGroup>
33+ <Compile Include="Program.cs" />
34+ <Compile Include="Properties\AssemblyInfo.cs" />
35+ </ItemGroup>
36+ <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
37+</Project>
\ No newline at end of file