From d27908b51e93b33f8af9b496bf8799cb450fb025 Mon Sep 17 00:00:00 2001 From: Ben C Date: Sat, 25 Feb 2023 23:08:43 +0000 Subject: [PATCH] Updated Schemas --- NewHorizons/Schemas/body_schema.json | 162 +++++++++++++++++---------- 1 file changed, 104 insertions(+), 58 deletions(-) diff --git a/NewHorizons/Schemas/body_schema.json b/NewHorizons/Schemas/body_schema.json index 92b1e581..b9fb6090 100644 --- a/NewHorizons/Schemas/body_schema.json +++ b/NewHorizons/Schemas/body_schema.json @@ -18,6 +18,13 @@ "description": "Unique star system containing your planet. If you set this to be a custom solar system remember to add a Spawn module to one of the bodies, or else you can't get to the system.", "default": "SolarSystem" }, + "AmbientLights": { + "type": "array", + "description": "Add ambient lights to this body", + "items": { + "$ref": "#/definitions/AmbientLightModule" + } + }, "AsteroidBelt": { "description": "Generate asteroids around this body", "$ref": "#/definitions/AsteroidBeltModule" @@ -142,6 +149,103 @@ } }, "definitions": { + "AmbientLightModule": { + "type": "object", + "additionalProperties": false, + "properties": { + "outerRadius": { + "type": [ + "null", + "number" + ], + "description": "The range of the light. Defaults to surfaceSize * 2.", + "format": "float", + "minimum": 0.0 + }, + "innerRadius": { + "type": [ + "null", + "number" + ], + "description": "The lower radius where the light is brightest, fading in from outerRadius. Defaults to surfaceSize.", + "format": "float", + "minimum": 0.0 + }, + "intensity": { + "type": "number", + "description": "The brightness of the light. For reference, Timber Hearth is `1.4`, and Giant's Deep is `0.8`.", + "format": "float", + "default": 1.0, + "minimum": 0.0 + }, + "tint": { + "description": "The tint of the light", + "$ref": "#/definitions/MColor" + }, + "isShell": { + "type": "boolean", + "description": "If true, the light will start fading away below innerRadius, instead of staying constant. This means that innerRadius will be the midpoint between the outerRadius and an inner cutoff.", + "default": false + }, + "position": { + "description": "The position of the light", + "$ref": "#/definitions/MVector3" + } + } + }, + "MColor": { + "type": "object", + "additionalProperties": false, + "properties": { + "r": { + "type": "integer", + "description": "The red component of this colour from 0-255, higher values will make the colour glow if applicable.", + "format": "int32", + "maximum": 2147483647.0, + "minimum": 0.0 + }, + "g": { + "type": "integer", + "description": "The green component of this colour from 0-255, higher values will make the colour glow if applicable.", + "format": "int32", + "maximum": 2147483647.0, + "minimum": 0.0 + }, + "b": { + "type": "integer", + "description": "The blue component of this colour from 0-255, higher values will make the colour glow if applicable.", + "format": "int32", + "maximum": 2147483647.0, + "minimum": 0.0 + }, + "a": { + "type": "integer", + "description": "The alpha (opacity) component of this colour", + "format": "int32", + "default": 255, + "maximum": 255.0, + "minimum": 0.0 + } + } + }, + "MVector3": { + "type": "object", + "additionalProperties": false, + "properties": { + "x": { + "type": "number", + "format": "float" + }, + "y": { + "type": "number", + "format": "float" + }, + "z": { + "type": "number", + "format": "float" + } + } + }, "AsteroidBeltModule": { "type": "object", "additionalProperties": false, @@ -215,41 +319,6 @@ } } }, - "MColor": { - "type": "object", - "additionalProperties": false, - "properties": { - "r": { - "type": "integer", - "description": "The red component of this colour from 0-255, higher values will make the colour glow if applicable.", - "format": "int32", - "maximum": 2147483647.0, - "minimum": 0.0 - }, - "g": { - "type": "integer", - "description": "The green component of this colour from 0-255, higher values will make the colour glow if applicable.", - "format": "int32", - "maximum": 2147483647.0, - "minimum": 0.0 - }, - "b": { - "type": "integer", - "description": "The blue component of this colour from 0-255, higher values will make the colour glow if applicable.", - "format": "int32", - "maximum": 2147483647.0, - "minimum": 0.0 - }, - "a": { - "type": "integer", - "description": "The alpha (opacity) component of this colour", - "format": "int32", - "default": 255, - "maximum": 255.0, - "minimum": 0.0 - } - } - }, "AtmosphereModule": { "type": "object", "additionalProperties": false, @@ -442,11 +511,6 @@ "type": "object", "additionalProperties": false, "properties": { - "ambientLight": { - "type": "number", - "description": "The intensity of light the dark side of the body should have. Timber Hearth has `1.4` for reference", - "format": "float" - }, "centerOfSolarSystem": { "type": "boolean", "description": "Set this to true if you are replacing the sun with a different body. Only one object in a star system should ever\nhave this set to true." @@ -504,24 +568,6 @@ } } }, - "MVector3": { - "type": "object", - "additionalProperties": false, - "properties": { - "x": { - "type": "number", - "format": "float" - }, - "y": { - "type": "number", - "format": "float" - }, - "z": { - "type": "number", - "format": "float" - } - } - }, "GravityFallOff": { "type": "string", "description": "",