mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Merge branch 'master' of https://github.com/xen-42/outer-wilds-new-horizons
This commit is contained in:
commit
8c0073a661
30
README.md
30
README.md
@ -4,14 +4,40 @@ A planet creator for Outer Wilds.
|
||||
|
||||
Planets are created using a JSON file format structure, and placed in the `planets` folder.
|
||||
|
||||
There is an example planet bundled with the mod - change some values and see what happens!
|
||||
## How to create your own planets using configs:
|
||||
|
||||
Coming soon
|
||||
|
||||
There is a template [here](https://github.com/xen-42/ow-new-horizons-config-template) if you want to release your own planet mod using configs.
|
||||
|
||||
## How to use New Horizons in other mods:
|
||||
|
||||
First create the following interface in your mod:
|
||||
|
||||
```
|
||||
public interface INewHorizons
|
||||
{
|
||||
void Create(Dictionary<string, object> config);
|
||||
|
||||
void LoadConfigs(IModBehaviour mod);
|
||||
|
||||
GameObject GetPlanet(string name);
|
||||
}
|
||||
```
|
||||
|
||||
In your main `ModBehaviour` class you can get the NewHorizons API like so:
|
||||
```
|
||||
INewHorizons NewHorizonsAPI = ModHelper.Interaction.GetModApi<INewHorizons>("xen.NewHorizons")
|
||||
```
|
||||
|
||||
You can then use the API's `LoadConfigs()` method to load from a "planets" folder, or use the `Create()` and `GetPlanet` methods to create planets and do whatever with them. Just make sure you create planets in the `Start()` method or at least before the SolarSystem scene loads, or they will not be created.
|
||||
|
||||
## Credits:
|
||||
Authors:
|
||||
- xen (from New Horizons v0.1.0 onwards)
|
||||
- Mister_Nebula (created original titled Marshmallow)
|
||||
|
||||
With help from :
|
||||
Marshmallow was made with help from:
|
||||
- TAImatem
|
||||
- AmazingAlek
|
||||
- Raicuparta
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user