First Machine Age's Mods (Combined repo.)
Revision | 0f48e97c3a9596a5670396bdfdbccaa1a0e58961 (tree) |
---|---|
Time | 2022-01-11 07:14:40 |
Author | melchior <melchior@user...> |
Commiter | melchior |
AMR: VS 1.16 Updates
fixed AMRs Recipe API use, minor VS1.16 changes
@@ -7,7 +7,7 @@ | ||
7 | 7 | <OutputType>Library</OutputType> |
8 | 8 | <RootNamespace>AnvilMetalRecovery</RootNamespace> |
9 | 9 | <AssemblyName>AnvilMetalRecovery</AssemblyName> |
10 | - <TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion> | |
10 | + <TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion> | |
11 | 11 | </PropertyGroup> |
12 | 12 | <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> |
13 | 13 | <DebugSymbols>true</DebugSymbols> |
@@ -7,6 +7,7 @@ using Vintagestory.API.Client; | ||
7 | 7 | using Vintagestory.API.Common; |
8 | 8 | using Vintagestory.API.Server; |
9 | 9 | using Vintagestory.Client.NoObf; |
10 | +using Vintagestory.GameContent; | |
10 | 11 | using Vintagestory.Server; |
11 | 12 | |
12 | 13 | namespace AnvilMetalRecovery |
@@ -42,12 +43,18 @@ namespace AnvilMetalRecovery | ||
42 | 43 | } |
43 | 44 | } |
44 | 45 | |
46 | + internal List<SmithingRecipe> SmithingRecipies | |
47 | + { | |
48 | + get { return CoreAPI.ModLoader.GetModSystem<RecipeRegistrySystem>( ).SmithingRecipes; } | |
49 | + } | |
45 | 50 | |
46 | - /// <summary> | |
47 | - /// Valid Items that are 'recoverable' (Asset Codes) only | |
48 | - /// </summary> | |
49 | - /// <value>The item filter list.</value> | |
50 | - public List<AssetLocation> ItemFilterList { | |
51 | + | |
52 | + | |
53 | + /// <summary> | |
54 | + /// Valid Items that are 'recoverable' (Asset Codes) only | |
55 | + /// </summary> | |
56 | + /// <value>The item filter list.</value> | |
57 | + public List<AssetLocation> ItemFilterList { | |
51 | 58 | get |
52 | 59 | { |
53 | 60 | return itemToVoxelLookup.Keys.ToList( ); |
@@ -1,17 +1,16 @@ | ||
1 | 1 | using System; |
2 | -using System.Collections.Generic; | |
3 | 2 | using System.Linq; |
4 | -using System.Linq.Expressions; | |
5 | 3 | |
6 | -using Vintagestory.API.Client; | |
4 | + | |
7 | 5 | using Vintagestory.API.Common; |
8 | 6 | using Vintagestory.API.Config; |
9 | 7 | using Vintagestory.API.Datastructures; |
10 | 8 | using Vintagestory.API.Server; |
11 | -using Vintagestory.Client.NoObf; | |
9 | + | |
12 | 10 | using Vintagestory.Common; |
11 | +using Vintagestory.GameContent; | |
13 | 12 | using Vintagestory.Server; |
14 | -using Vintagestory.ServerMods; | |
13 | + | |
15 | 14 | |
16 | 15 | namespace AnvilMetalRecovery |
17 | 16 | { |
@@ -20,7 +19,7 @@ namespace AnvilMetalRecovery | ||
20 | 19 | private void MaterialDataGathering( ) |
21 | 20 | { |
22 | 21 | //Count out Voxels in smthing recipes for all metal-ingot(?) derived items; |
23 | - var examineList = ServerAPI.World.SmithingRecipes.Where(sr => sr.Enabled && sr.Ingredient.Type == EnumItemClass.Item && sr.Output.Type == EnumItemClass.Item); | |
22 | + var examineList = this.SmithingRecipies.Where(sr => sr.Enabled && sr.Ingredient.Type == EnumItemClass.Item && sr.Output.Type == EnumItemClass.Item); | |
24 | 23 | |
25 | 24 | foreach (var recipie in examineList) { |
26 | 25 |
@@ -6,7 +6,7 @@ | ||
6 | 6 | "ModID":"metalrecovery", |
7 | 7 | "version": "0.1.16", |
8 | 8 | "dependencies": { |
9 | - "game": "1.15.3", | |
9 | + "game": "1.16.0", | |
10 | 10 | "survival": "" |
11 | 11 | }, |
12 | 12 | "website": "http://nowebsite.nope" |