mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
curse you stalker of dreams
This commit is contained in:
parent
bcfe939d9d
commit
aedeb80f16
@ -1,6 +1,7 @@
|
||||
using NewHorizons.External.Configs;
|
||||
using NewHorizons.External.Modules;
|
||||
using NewHorizons.Utility;
|
||||
using NewHorizons.Utility.OWML;
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
||||
@ -92,6 +93,8 @@ namespace NewHorizons.Builder.Atmosphere
|
||||
// min height override for backwards compat
|
||||
minHeight = surfaceHeight ?? minHeight;
|
||||
|
||||
if (config.ParticleFields != null)
|
||||
{
|
||||
foreach (var particleField in config.ParticleFields)
|
||||
{
|
||||
var prefab = GetPrefabByType(particleField.type);
|
||||
@ -114,6 +117,7 @@ namespace NewHorizons.Builder.Atmosphere
|
||||
|
||||
emitter.SetActive(true);
|
||||
}
|
||||
}
|
||||
|
||||
effectsGO.transform.position = planetGO.transform.position;
|
||||
effectsGO.SetActive(true);
|
||||
|
||||
@ -1,7 +1,9 @@
|
||||
using NewHorizons.External.Modules;
|
||||
using NewHorizons.External.Modules.Props;
|
||||
using NewHorizons.Utility;
|
||||
using NewHorizons.Utility.Files;
|
||||
using OWML.Common;
|
||||
using System;
|
||||
using UnityEngine;
|
||||
namespace NewHorizons.Builder.Atmosphere
|
||||
{
|
||||
@ -36,6 +38,14 @@ namespace NewHorizons.Builder.Atmosphere
|
||||
if (_dbImpostorMaterials == null) _dbImpostorMaterials = SearchUtilities.Find("DarkBramble_Body/Atmosphere_DB/FogLOD").GetComponent<MeshRenderer>().sharedMaterials.MakePrefabMaterials();
|
||||
}
|
||||
|
||||
#region obsolete
|
||||
// Never change method signatures, people directly reference the NH dll and it can break backwards compatibility
|
||||
// Dreamstalker needs this method signature
|
||||
[Obsolete]
|
||||
public static PlanetaryFogController Make(GameObject planetGO, Sector sector, AtmosphereModule atmo)
|
||||
=> Make(planetGO, sector, atmo, null);
|
||||
#endregion
|
||||
|
||||
public static PlanetaryFogController Make(GameObject planetGO, Sector sector, AtmosphereModule atmo, IModBehaviour mod)
|
||||
{
|
||||
InitPrefabs();
|
||||
|
||||
@ -33,6 +33,11 @@ namespace NewHorizons.Utility.Files
|
||||
// bug: cache only considers file path, not wrap/mips/linear. oh well
|
||||
public static Texture2D GetTexture(IModBehaviour mod, string filename, bool useMipmaps = true, bool wrap = false, bool linear = false)
|
||||
{
|
||||
if (mod == null)
|
||||
{
|
||||
NHLogger.LogError("Couldn't get texture, mod is null.");
|
||||
return null;
|
||||
}
|
||||
// Copied from OWML but without the print statement lol
|
||||
var path = Path.Combine(mod.ModHelper.Manifest.ModFolderPath, filename);
|
||||
var key = GetKey(path);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user