mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
meteor scale
This commit is contained in:
parent
4d06292d5c
commit
edbd2ee5a7
@ -45,6 +45,8 @@ namespace NewHorizons.Builder.Props
|
|||||||
}
|
}
|
||||||
private static void FixMeteor(MeteorController meteor, PropModule.VolcanoInfo info)
|
private static void FixMeteor(MeteorController meteor, PropModule.VolcanoInfo info)
|
||||||
{
|
{
|
||||||
|
meteor.transform.localScale = Vector3.one * info.scale;
|
||||||
|
|
||||||
var mat = meteor.GetComponentInChildren<MeshRenderer>().material;
|
var mat = meteor.GetComponentInChildren<MeshRenderer>().material;
|
||||||
mat.SetColor("_Color", info.stoneTint == null ? defaultStoneTint : info.stoneTint.ToColor());
|
mat.SetColor("_Color", info.stoneTint == null ? defaultStoneTint : info.stoneTint.ToColor());
|
||||||
mat.SetColor("_EmissionColor", info.lavaTint == null ? defaultLavaTint : info.lavaTint.ToColor());
|
mat.SetColor("_EmissionColor", info.lavaTint == null ? defaultLavaTint : info.lavaTint.ToColor());
|
||||||
|
|||||||
1
NewHorizons/External/Modules/PropModule.cs
vendored
1
NewHorizons/External/Modules/PropModule.cs
vendored
@ -66,6 +66,7 @@ namespace NewHorizons.External.Modules
|
|||||||
public class VolcanoInfo
|
public class VolcanoInfo
|
||||||
{
|
{
|
||||||
public MVector3 position = null;
|
public MVector3 position = null;
|
||||||
|
public float scale = 1;
|
||||||
public MColor stoneTint = null;
|
public MColor stoneTint = null;
|
||||||
public MColor lavaTint = null;
|
public MColor lavaTint = null;
|
||||||
public float minLaunchSpeed = 50f;
|
public float minLaunchSpeed = 50f;
|
||||||
|
|||||||
@ -822,6 +822,11 @@
|
|||||||
"$ref": "#/$defs/vector3",
|
"$ref": "#/$defs/vector3",
|
||||||
"description": "The position of this volcano."
|
"description": "The position of this volcano."
|
||||||
},
|
},
|
||||||
|
"scale": {
|
||||||
|
"type": "number",
|
||||||
|
"description": "The scale of the meteors.",
|
||||||
|
"default": 1
|
||||||
|
},
|
||||||
"stoneTint": {
|
"stoneTint": {
|
||||||
"$ref": "#/$defs/color",
|
"$ref": "#/$defs/color",
|
||||||
"description": "The colour of the meteor's stone."
|
"description": "The colour of the meteor's stone."
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user