Depiction Engine For Unity 2023.0 (Alpha)
|
Utility methods to help with the creation of instances. More...
Static Public Member Functions | |
static Camera | CreateTargetCamera (SerializableGuid parentId, string name="Camera", double distance=1000.0d, string skyboxMaterialPath=RenderingManager.MATERIAL_BASE_PATH+"Skybox/Star-Skybox", InitializationContext initializingContext=InitializationContext.Programmatically, bool setParentAndAlign=false, bool moveToView=false) |
Create a new DepictionEngine.Camera equipped with a DepictionEngine.CameraController and target. | |
static Camera | CreateTargetCamera (Transform parent, string name="Camera", double distance=1000.0d, string skyboxMaterialPath=RenderingManager.MATERIAL_BASE_PATH+"Skybox/Star-Skybox", InitializationContext initializingContext=InitializationContext.Programmatically, bool setParentAndAlign=false, bool moveToView=false) |
Create a new DepictionEngine.Camera equipped with a DepictionEngine.CameraController and target. | |
static Planet | CreatePlanet (SerializableGuid parentId, string name, bool spherical, double size, double mass, JSONObject json=null, InitializationContext initializingContext=InitializationContext.Programmatically, bool setParentAndAlign=false, bool moveToView=false) |
Create a new planet. | |
static Planet | CreatePlanet (Transform parent, string name, bool spherical, double size, double mass, JSONObject json=null, InitializationContext initializingContext=InitializationContext.Programmatically, bool setParentAndAlign=false, bool moveToView=false) |
Create a new planet. | |
static DatasourceRoot | CreateLayer (SerializableGuid planetId, string name, JSONObject json=null, InitializationContext initializingContext=InitializationContext.Programmatically) |
Create a new DepictionEngine.DatasourceRoot. | |
static DatasourceRoot | CreateLayer (Planet planet, string name, JSONObject json=null, InitializationContext initializingContext=InitializationContext.Programmatically) |
Create a new DepictionEngine.DatasourceRoot. | |
static JSONArray | GetLoaderJson (Type loaderType, Type fallbackType) |
Creates a DepictionEngine.JSONArray containing the initialization values for a DepictionEngine.LoaderBase, DepictionEngine.FallbackValues and corresponding DepictionEngine.AssetReference that can be passed on to the json parameter of DepictionEngine.InstanceManager.Initialize or some other instancing derivative methods. | |
static JSONObject | GetComponentJson (Type type, SerializableGuid id=default) |
Creates a DepictionEngine.JSONObject of specified type so it can be passed on to the json parameter of DepictionEngine.InstanceManager.Initialize or some other instancing derivative methods. | |
static JSONNode | MergeComponentsToObjectInitializationJson (JSONNode componentsJson, JSONObject objectInitializationJson) |
Merge the componentsJson into the objectInitializationJson so it can be passed on to the json parameter of DepictionEngine.InstanceManager.Initialize or some other instancing derivative methods. | |
Utility methods to help with the creation of instances.
|
static |
Create a new DepictionEngine.DatasourceRoot.
planet | The parent DepictionEngine.Planet under which we will create the DepictionEngine.DatasourceRoot. |
name | The name of the layer. |
json | Optional initialization values. |
initializingContext | . |
|
static |
Create a new DepictionEngine.DatasourceRoot.
planetId | The id of the parent DepictionEngine.Planet under which we will create the DepictionEngine.DatasourceRoot. |
name | The name of the layer. |
json | Optional initialization values. |
initializingContext | . |
|
static |
Create a new planet.
parentId | The id of the parent UnityEngine.Transform under which we will create the DepictionEngine.Planet. |
name | The name of the planet. |
spherical | Display as a sphere (true) or flat (false)? |
size | The size (radius in spherical mode or width in flat mode), in world units. |
mass | Used to determine the amount of gravitational force to apply when DepictionEngine.Object.useGravity is enabled. |
json | Optional initialization values. |
initializingContext | |
setParentAndAlign | Sets the parent and gives the child the same layer and position (Editor Only). |
moveToView | Instantiates the GameObject at the scene pivot (Editor Only). |
|
static |
Create a new planet.
parent | The parent UnityEngine.Transform under which we will create the DepictionEngine.Planet. |
name | The name of the planet. |
spherical | Display as a sphere (true) or flat (false)? |
size | The size (radius in spherical mode or width in flat mode), in world units. |
mass | Used to determine the amount of gravitational force to apply when DepictionEngine.Object.useGravity is enabled. |
json | Optional initialization values. |
initializingContext | |
setParentAndAlign | Sets the parent and gives the child the same layer and position (Editor Only). |
moveToView | Instantiates the GameObject at the scene pivot (Editor Only). |
|
static |
Create a new DepictionEngine.Camera equipped with a DepictionEngine.CameraController and target.
parentId | The parent DepictionEngine.SerializableGuid under which we will create the DepictionEngine.Camera. |
initializingContext | |
setParentAndAlign | Sets the parent and gives the child the same layer and position (Editor Only). |
moveToView | Instantiates the GameObject at the scene pivot (Editor Only). |
|
static |
Create a new DepictionEngine.Camera equipped with a DepictionEngine.CameraController and target.
parent | The parent UnityEngine.Transform under which we will create the DepictionEngine.Camera. |
initializingContext | |
setParentAndAlign | Sets the parent and gives the child the same layer and position (Editor Only). |
moveToView | Instantiates the GameObject at the scene pivot (Editor Only). |
|
static |
Creates a DepictionEngine.JSONObject of specified type so it can be passed on to the json parameter of DepictionEngine.InstanceManager.Initialize or some other instancing derivative methods.
type | The component type. |
id | An Optional component id. If omitted a new guid will be generated. |
|
static |
Creates a DepictionEngine.JSONArray containing the initialization values for a DepictionEngine.LoaderBase, DepictionEngine.FallbackValues and corresponding DepictionEngine.AssetReference that can be passed on to the json parameter of DepictionEngine.InstanceManager.Initialize or some other instancing derivative methods.
loaderType | The DepictionEngine.LoaderBase type. |
fallbackType | The DepictionEngine.FallbackValues type. |
|
static |
Merge the componentsJson into the objectInitializationJson so it can be passed on to the json parameter of DepictionEngine.InstanceManager.Initialize or some other instancing derivative methods.
componentsJson | A DepictionEngine.JSONObject or DepictionEngine.JSONArray composed of component(s) initialization values. |
objectInitializationJson | The json to merge the component(s) values into. |