EtiamNullam / MaterialColor

A modification for Klei's Oxygen Not Included
MIT License
10 stars 2 forks source link

Can't build Material.Core #1

Closed L-a-n-g-o-l-i-e-r-s closed 6 years ago

L-a-n-g-o-l-i-e-r-s commented 7 years ago

Hi there,

Don't know how to get MaterialColor.Core to compile as of 9/18 from dev branch, is it based off a different version? I haven't looked at the commits to compare, feel free to criticize me for trying to compile it on build 232512 if it isn't compatible. :disappointed:

Thanks for this great tool. :grinning:

I've got this error here in VS 2017:

------ Build started: Project: MaterialColor.Core, Configuration: Release Any CPU ------ C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\InjectionEntry.cs(111,34,111,47): error CS1061: 'BlockTileRenderer' does not contain a definition for 'highlightCell' and no extension method 'highlightCell' accepting a first argument of type 'BlockTileRenderer' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\InjectionEntry.cs(113,33,113,45): error CS1061: 'BlockTileRenderer' does not contain a definition for 'selectedCell' and no extension method 'selectedCell' accepting a first argument of type 'BlockTileRenderer' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\Helpers\ColorHelper.cs(44,60,44,75): error CS1061: 'StorageLocker' does not contain a definition for 'filteredStorage' and no extension method 'filteredStorage' accepting a first argument of type 'StorageLocker' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\Helpers\ColorHelper.cs(52,33,52,42): error CS1061: 'Ownable' does not contain a definition for 'ownedTint' and no extension method 'ownedTint' accepting a first argument of type 'Ownable' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\Helpers\ColorHelper.cs(53,33,53,44): error CS1061: 'Ownable' does not contain a definition for 'unownedTint' and no extension method 'unownedTint' accepting a first argument of type 'Ownable' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\Helpers\ColorHelper.cs(54,33,54,43): error CS1061: 'Ownable' does not contain a definition for 'UpdateTint' and no extension method 'UpdateTint' accepting a first argument of type 'Ownable' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\Helpers\ColorHelper.cs(62,64,62,79): error CS1061: 'RationBox' does not contain a definition for 'filteredStorage' and no extension method 'filteredStorage' accepting a first argument of type 'RationBox' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\Helpers\ColorHelper.cs(70,65,70,80): error CS1061: 'Refrigerator' does not contain a definition for 'filteredStorage' and no extension method 'filteredStorage' accepting a first argument of type 'Refrigerator' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\Helpers\ColorHelper.cs(97,21,97,31): error CS1061: 'FilteredStorage' does not contain a definition for 'filterTint' and no extension method 'filterTint' accepting a first argument of type 'FilteredStorage' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\Helpers\ColorHelper.cs(98,21,98,33): error CS1061: 'FilteredStorage' does not contain a definition for 'noFilterTint' and no extension method 'noFilterTint' accepting a first argument of type 'FilteredStorage' could be found (are you missing a using directive or an assembly reference?) C:\Program Files (x86)\Steam\steamapps\common\OxygenNotIncluded\OxygenNotIncluded_Data\MaterialColor.Core\InjectionEntry.cs(143,41,143,50): error CS0117: 'INPUT_BINDINGS.ROOT' does not contain a definition for 'OVERLAY12'

For those whom are trying to build the tool, barring MaterialColor.Core of the dev branch until more information is recieved, here's my convoluted way :fried_egg: : I had a lot of difficulty figuring out the layout needed to build this all, putting the files from the master into the data folder, then copying the managed folder and renaming it to GameManaged (or change it to Managed in the csproj files.) then also copying the original Assembly-CSharp.dll & UnityEngine.dll and creating a folder "libs/original" in the "tools" folder which you extracted from the master into the data folder, copy those .dll's into that folder. Also, you will need to download the onion-patcher source and extract it (the root files, keep the folder with it, do not paste files without maintaining the folder structure in the source), then you need to go to "onion-hooks/onionhooks" and edit "OnionHooks.csproj" change the hintpaths with the .dll's to include "....\Managed\dllname.dll" OR if you didn't change the of MaterialColor's various .csproj files, you would have made a copy of "Managed" and renamed it to "GameManaged" so you would need to change in "OnionHooks,csproj to be "....\GameManaged\dllname.dll", for anyone wondering how. :8ball:

EtiamNullam commented 7 years ago

@L-a-n-g-o-l-i-e-r-s You should have first checked https://github.com/fistak/MaterialColor/blob/master/BUILDING.md.

Yeah the help pages are not ready yet, I need to clean up a little. As I can see the most errors if not all are caused by wrong .dll in the GameManaged.

If you follow the building guide, you can see it requires a patched libraries to work, It's like that because I need to make several fields and methods public and then I build against that.

I'm glad someone is actually interested in the code. Feel free to ask if you still have any issues ;)