Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DLC Compatibility For Drains, Radiation, Radiator #55

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

BaalEvan
Copy link

Additional: Added Radiant Pipes to Radiation

Additional: Added Radiant Pipes to Radiation
@skairunner
Copy link
Owner

Hi, thanks for the PR. I mostly have a question about the new tech database methods: does the base game without the DLC also use the new method, or does there have to be some sort of compatibility switch?

@BaalEvan
Copy link
Author

BaalEvan commented May 30, 2021

Based on what i found on Github (becasue i never made any mod to ONI before) there is no new way in Vanilla but you can select target in Mod_info.yaml and upload mod with Mod Archive with Vanilla support
supportedContent: EXPANSION1_ID lastWorkingBuild: 464434

  1. Suppose you've got a mod working with the base version of ONI, on version 441000. Add a mod_info.yaml with these contents:

supportedContent: VANILLA_ID
lastWorkingBuild: 441000

  1. You decide to update your mod to work with Spaced Out!, which is at 442000.

First: make a new folder and subfolder in your mod for archiving the base version of your mod, named something like:

/archived_versions/vanilla

and copy all your mod files (including the mod_info.yaml) into that subfolder.

Then change the mod_info.yaml in the root folder of your mod to these contents:

supportedContent: EXPANSION1_ID
lastWorkingBuild: 442000
Develop your mod for the new expansion features and publish it in that root folder. Players on the base game will get the version from the archive folder, and players on Spaced Out! will get the version from the top-level folder.

  1. Later, we open up a public_testing branch for Spaced Out! that changes the build number to 443000. As before, make a new archive folder called something like:

/archived_versions/spacedout_old

and copy all your top-level mod files into it (including the mod_info.yaml).

Then change the mod_info.yaml in the root folder of your mod to these contents:

supportedContent: EXPANSION1_ID
lastWorkingBuild: 443000
You can update your mod for the preview branch and publish it in that root folder. Players on the newest preview version of the game will get the newest version of your mod, and players not on the previous will continue playing the previous version from the archive folder.

You can of course delete old archived versions as the progress of the game moves forward.

https://forums.kleientertainment.com/forums/topic/126022-setting-up-mod_infoyaml/

@BaalEvan
Copy link
Author

BaalEvan commented May 30, 2021

So best way to handle Tech Database will be:

#IF VANILLA
 // OLD WAY
#ELSEIF SPACEOUT
 // NEW WAY
#ENDIF

And then building 2 separate DLL for each version
example: https://github.com/davkas88/ModNotIncluded/blob/388403d204032dc6aa8c033c546d458233916447/Source%20Code/Insulated%20Door/InsulatedDoors.cs
OR... you can use reflection to check if there is field in Techs named Instance and based on that use correct approach
second example: https://github.com/v-limc/oni-mods/blob/a369c7848fd0fa3f22d15fbccaa29be04edb7ca3/src/commons/VUtils.cs

@skairunner
Copy link
Owner

skairunner commented May 30, 2021

I've talked with some fellow mod devs and I think that I don't want to support the DLC yet, because it's just a big pain. I will wait for full release. However, if you want to please feel free to upload your DLC changes on Steam Workshop! The only thing I ask for is to link back to the original mod & clarify you got permission. Call it "Drains [Spaced Out Beta]" or something, yeah?

@BaalEvan
Copy link
Author

Sure ;) No problem ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants