mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
Move skybox module to separate file
This commit is contained in:
parent
02c771d1b8
commit
8e5d7369d6
@ -1,4 +1,4 @@
|
||||
using NewHorizons.External.Configs;
|
||||
using NewHorizons.External.Modules;
|
||||
using NewHorizons.Utility;
|
||||
using NewHorizons.Utility.Files;
|
||||
using NewHorizons.Utility.OWML;
|
||||
@ -13,13 +13,13 @@ namespace NewHorizons.Builder.StarSystem
|
||||
{
|
||||
private static readonly Shader _unlitShader = Shader.Find("Unlit/Texture");
|
||||
|
||||
public static void Make(StarSystemConfig.SkyboxModule module, IModBehaviour mod)
|
||||
public static void Make(SkyboxModule module, IModBehaviour mod)
|
||||
{
|
||||
NHLogger.Log("Building Skybox");
|
||||
BuildSkySphere(module, mod);
|
||||
}
|
||||
|
||||
public static GameObject BuildSkySphere(StarSystemConfig.SkyboxModule module, IModBehaviour mod)
|
||||
public static GameObject BuildSkySphere(SkyboxModule module, IModBehaviour mod)
|
||||
{
|
||||
var skybox = SearchUtilities.Find("Skybox");
|
||||
|
||||
|
||||
45
NewHorizons/External/Configs/StarSystemConfig.cs
vendored
45
NewHorizons/External/Configs/StarSystemConfig.cs
vendored
@ -175,51 +175,6 @@ namespace NewHorizons.External.Configs
|
||||
public int[] z;
|
||||
}
|
||||
|
||||
[JsonObject]
|
||||
public class SkyboxModule
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Whether to destroy the star field around the player
|
||||
/// </summary>
|
||||
public bool destroyStarField;
|
||||
|
||||
/// <summary>
|
||||
/// Whether to use a cube for the skybox instead of a smooth sphere
|
||||
/// </summary>
|
||||
public bool useCube;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's positive X direction
|
||||
/// </summary>
|
||||
public string rightPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's negative X direction
|
||||
/// </summary>
|
||||
public string leftPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's positive Y direction
|
||||
/// </summary>
|
||||
public string topPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's negative Y direction
|
||||
/// </summary>
|
||||
public string bottomPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's positive Z direction
|
||||
/// </summary>
|
||||
public string frontPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's negative Z direction
|
||||
/// </summary>
|
||||
public string backPath;
|
||||
}
|
||||
|
||||
[JsonObject]
|
||||
public class GlobalMusicModule
|
||||
{
|
||||
|
||||
48
NewHorizons/External/Modules/SkyboxModule.cs
vendored
Normal file
48
NewHorizons/External/Modules/SkyboxModule.cs
vendored
Normal file
@ -0,0 +1,48 @@
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace NewHorizons.External.Modules
|
||||
{
|
||||
[JsonObject]
|
||||
public class SkyboxModule
|
||||
{
|
||||
/// <summary>
|
||||
/// Whether to destroy the star field around the player
|
||||
/// </summary>
|
||||
public bool destroyStarField;
|
||||
|
||||
/// <summary>
|
||||
/// Whether to use a cube for the skybox instead of a smooth sphere
|
||||
/// </summary>
|
||||
public bool useCube;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's positive X direction
|
||||
/// </summary>
|
||||
public string rightPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's negative X direction
|
||||
/// </summary>
|
||||
public string leftPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's positive Y direction
|
||||
/// </summary>
|
||||
public string topPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's negative Y direction
|
||||
/// </summary>
|
||||
public string bottomPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's positive Z direction
|
||||
/// </summary>
|
||||
public string frontPath;
|
||||
|
||||
/// <summary>
|
||||
/// Relative filepath to the texture to use for the skybox's negative Z direction
|
||||
/// </summary>
|
||||
public string backPath;
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user