AlexDocking / Eco-Mods

A mod for Eco to encourage continued player spending in the economy by offering QoL bonuses
https://mod.io/g/eco/m/xp-benefits
3 stars 1 forks source link

Server crash on start due to change in MinimapManager Object API (Eco v10.2.3) #2

Closed craisis closed 4 months ago

craisis commented 4 months ago

Eco removed MinimapManager.Objects, replacing it with MinimapManager.DeltaHashSetObjects.

On loading ModKit fails with the following error

Message:/home/container/server/Mods/UserCode/Objects/TreeObject.override.cs(209,36): error CS0119: 'ArrayUtils.Objects(Array)' is a method, which is not valid in the given context
Source:Eco.ModKit

System.Exception: /home/container/server/Mods/UserCode/Objects/TreeObject.override.cs(209,36): error CS0119: 'ArrayUtils.Objects(Array)' is a method, which is not valid in the given context
   at Eco.ModKit.RoslynCompiler.HandleCompilerError(ImmutableArray`1 diagnostics)
   at Eco.ModKit.RoslynCompiler.Compile(AssemblyLoadContext assemblyContext)
   at Eco.ModKit.RoslynCompiler..ctor(AssemblyLoadContext assemblyContext, String modsDirectory, String modsAssemblyPath)
   at Eco.ModKit.RoslynCompiler..ctor(String modsDirectory, String modsAssemblyPath)
   at Eco.ModKit.ModKitPlugin..ctor()
   at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean wrapExceptions)
Outer Exceptions:
Exception has been thrown by the target of an invocation.
AlexDocking commented 4 months ago

Hi, this indeed broke in 10.2.3. Thanks for the pull request 😄