Component:GradientSkyMaterial: Difference between revisions

From Resonite Wiki
Automated: update 'HighPriorityIntegration' description
add hopefully correct info.
 
Line 2: Line 2:
<translate>
<translate>
<!--T:1-->
<!--T:1-->
{{stub}}
{{Infobox Component
{{Infobox Component
|Image=GradientSkyMaterialComponent.png
|Image=GradientSkyMaterialComponent.png
|Name=Gradient Sky Material
|Name=Gradient Sky Material
}}
}}
The '''GradientSkyMaterial''' component is used in [[Component:Skybox]] to make a gradient type sky for use in worlds.


<!--T:2-->
<!--T:2-->
Line 12: Line 12:
{{Table ComponentFields
{{Table ComponentFields
|HighPriorityIntegration|Bool|{{Asset HighPriorityIntegration Field}}
|HighPriorityIntegration|Bool|{{Asset HighPriorityIntegration Field}}
|_shader|{{RootFieldType|AssetRef`1|[[Type:Shader|Shader]]}}|TypeAdv1=true| The [[Shader]] to use.
|_shader|{{RootFieldType|AssetRef`1|[[Type:Shader|Shader]]}}|TypeAdv1=true| The [[Shader]] to use. Internal.
|BaseColor|ColorX| The base color of the sky.
|BaseColor|ColorX| The base color of the sky.
|_gradients|{{RootFieldType|SyncList`1|[[#Gradient|Gradient]]}}|TypeAdv3=true| Applies a [[#Gradient|Gradient]] to the sky.
|_gradients|{{RootFieldType|SyncList`1|[[#Gradient|Gradient]]}}|TypeAdv3=true| Applies a list of [[#Gradient|Gradients]] to the sky.
}}
}}


<!--T:3-->
<!--T:3-->
== Usage ==
== Usage ==
Attach to a slot and insert into a [[Component:Skybox]] component and use the SetCurrentSky() Sync Method to use this component. Don't forget to add some <code>_gradients</code> to the list.


== Gradient ==
== Gradient ==
'''Gradient''' is a nested type used in the <code>_gradients</code> list.
'''Gradient''' is a nested type used in the <code>_gradients</code> list.


=== Fields ===
{{Table TypeFields
{{Table TypeFields
|Direction|Float3|
|Direction|Float3| The direction this gradient should point in.
|FromColor|ColorX|
|FromColor|ColorX| The color to start at for this gradient.
|ToColor|ColorX|
|ToColor|ColorX| The color to end at for this gradient.
|Spread|Float|
|Spread|Float| How much to extend the gradient from it's <code>From</code> and <code>To</code> limits beyond the transitioning section.
|From|Float|
|From|Float| Where this gradient should start from in a range from 0<->1
|To|Float|
|To|Float| Where this gradient should end at in a range from 0<->1
|Exp|Float|
|Exp|Float| The sharpness of the transition of the gradient
}}
}}


Line 40: Line 40:
<!--T:5-->
<!--T:5-->
== Related Components ==
== Related Components ==
* [[Component:Skybox]]
</translate>
</translate>
[[Category:ComponentStubs]]
[[Category:Components{{#translation:}}|Gradient Sky Material]]
[[Category:Components{{#translation:}}|Gradient Sky Material]]
[[Category:Components:Assets:Materials:Skybox{{#translation:}}|Gradient Sky Material]]
[[Category:Components:Assets:Materials:Skybox{{#translation:}}|Gradient Sky Material]]

Latest revision as of 18:17, 4 December 2024

Component image 
Gradient Sky Material component as seen in the Scene Inspector

The GradientSkyMaterial component is used in Component:Skybox to make a gradient type sky for use in worlds.

Fields

Fields
Name Type Description
persistent Bool Determines whether or not this item will be saved to the server.
UpdateOrder Int Controls the order in which this component is updated.
Enabled Bool Controls whether or not this component is enabled. Some components stop their functionality when this field is disabled, but some don't.
HighPriorityIntegration Bool If true, integrating this asset (e.g. processing procedural assets) gets higher priority than assets with this flag off. An example is user laser procedural meshes.
_shader Shader The Shader to use. Internal.
BaseColor ColorX The base color of the sky.
_gradients list of Gradient Applies a list of Gradients to the sky.

Usage

Attach to a slot and insert into a Component:Skybox component and use the SetCurrentSky() Sync Method to use this component. Don't forget to add some _gradients to the list.

Gradient

Gradient is a nested type used in the _gradients list.

Fields
Name Type Description
Direction Float3 The direction this gradient should point in.
FromColor ColorX The color to start at for this gradient.
ToColor ColorX The color to end at for this gradient.
Spread Float How much to extend the gradient from it's From and To limits beyond the transitioning section.
From Float Where this gradient should start from in a range from 0<->1
To Float Where this gradient should end at in a range from 0<->1
Exp Float The sharpness of the transition of the gradient

Examples

Related Components