stretch for scatter too (#396)

just copy the way details do it
This commit is contained in:
Noah 2022-09-17 19:34:33 -04:00 committed by GitHub
commit 3231848017
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 2 deletions

View File

@ -69,6 +69,7 @@ namespace NewHorizons.Builder.Props
var detailInfo = new PropModule.DetailInfo()
{
scale = propInfo.scale,
stretch = propInfo.stretch,
keepLoaded = propInfo.keepLoaded
};
var scatterPrefab = DetailBuilder.Make(go, sector, prefab, detailInfo);

View File

@ -123,7 +123,12 @@ namespace NewHorizons.External.Modules
/// <summary>
/// Scale this prop once it is placed
/// </summary>
public float scale = 1f;
[DefaultValue(1f)] public float scale = 1f;
/// <summary>
/// Scale each axis of the prop. Overrides `scale`.
/// </summary>
public MVector3 stretch;
/// <summary>
/// The number used as entropy for scattering the props

View File

@ -1376,7 +1376,12 @@
"scale": {
"type": "number",
"description": "Scale this prop once it is placed",
"format": "float"
"format": "float",
"default": 1.0
},
"stretch": {
"description": "Scale each axis of the prop. Overrides `scale`.",
"$ref": "#/definitions/MVector3"
},
"seed": {
"type": "integer",