989onan bot (talk | contribs) Automated: update SyncDelegates |
add info |
||
Line 3: | Line 3: | ||
|Name=Texture Ref Editor | |Name=Texture Ref Editor | ||
}} | }} | ||
The '''TextureRefEditor''' component is commonly used in inspectors for materials and other components that use images/textures. | |||
== | == Fields == | ||
{{Table ComponentFields | {{Table ComponentFields | ||
|_targetRef|{{RootFieldType|RelayRef`1|[[Type:AssetRef`1|AssetRef`1]]<[[Type:ITexture2D|ITexture2D]]>}}|TypeAdv0=true| | |_targetRef|{{RootFieldType|RelayRef`1|[[Type:AssetRef`1|AssetRef`1]]<[[Type:ITexture2D|ITexture2D]]>}}|TypeAdv0=true| The field to make a visual for. | ||
|_drive|{{RootFieldType|DriveRef`1|[[Type:AssetRef`1|AssetRef`1]]<[[Type:ITexture2D|ITexture2D]]>}}|TypeAdv1=true| | |_drive|{{RootFieldType|DriveRef`1|[[Type:AssetRef`1|AssetRef`1]]<[[Type:ITexture2D|ITexture2D]]>}}|TypeAdv1=true| The field to drive with the contents of <code>_targetRef</code> or a placeholder texture if null. | ||
|_clearReferenceButton|'''[[Component:Button|Button]]'''|TypeAdv2=true| | |_clearReferenceButton|'''[[Component:Button|Button]]'''|TypeAdv2=true| The button used to clear <code>_targetRef</code> | ||
|_openInspectorButton|'''[[Component:Button|Button]]'''|TypeAdv3=true| | |_openInspectorButton|'''[[Component:Button|Button]]'''|TypeAdv3=true| The button to open an inspector for <code>_targetRef</code>. | ||
|_copyTextureButton|'''[[Component:Button|Button]]'''|TypeAdv4=true| | |_copyTextureButton|'''[[Component:Button|Button]]'''|TypeAdv4=true| The button to copy the texture in <code>_targetRef</code>. | ||
|_pasteTextureButton|'''[[Component:Button|Button]]'''|TypeAdv5=true| | |_pasteTextureButton|'''[[Component:Button|Button]]'''|TypeAdv5=true| The button to paste a texture into <code>_targetRef</code>. | ||
|_referenceText|{{RootFieldType|FieldDrive`1|[[Type:String|String]]}}|TypeAdv6=true| | |_referenceText|{{RootFieldType|FieldDrive`1|[[Type:String|String]]}}|TypeAdv6=true| The field to drive with the description of the contents of <code>_targetRef</code>. | ||
|_infoText|{{RootFieldType|FieldDrive`1|[[Type:String|String]]}}|TypeAdv7=true| | |_infoText|{{RootFieldType|FieldDrive`1|[[Type:String|String]]}}|TypeAdv7=true| The field to drive with the info of <code>_targetRef</code>. | ||
|_isNormalMap|Bool| | |_isNormalMap|Bool| Whether <code>_targetRef</code> should be interpreted as a normal map. | ||
}} | }} | ||
== Sync Delegates == | == Sync Delegates == | ||
{{Table ComponentTriggers | {{Table ComponentTriggers | ||
|ClearReference:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |ClearReference:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when the reference <code>_targetRef</code> is cleared via the UI button. | ||
|OpenInspectorButton:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |OpenInspectorButton:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when an inspector is asked to be opened through this component for <code>_targetRef</code>. | ||
|CopyTexture:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |CopyTexture:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when a copy texture is called through this component for <code>_targetRef</code>. | ||
|PasteTexture:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |PasteTexture:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when the user asks to paste a texture into <code>_targetRef</code> through this component. | ||
|SetTexture:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| | |SetTexture:[[Type:ButtonEventHandler|ButtonEventHandler]]|[[Type:ButtonEventHandler|ButtonEventHandler]]|true| Called when the texture for <code>_targetRef</code> is set through this component. | ||
}} | }} | ||
== | == Usage == | ||
Commonly used in inspectors. Using inspector specific components is a common tactic in [[Ref Hacking]]. | |||
== Examples == | == Examples == | ||
Material inspector views. | |||
== See Also == | == See Also == | ||
* [[Ref Hacking]] | |||
[[Category:Components:Uncategorized{{#translation:}}|Texture Ref Editor]] | [[Category:Components:Uncategorized{{#translation:}}|Texture Ref Editor]] | ||
[[Category:Components{{#translation:}}|Texture Ref Editor]] | [[Category:Components{{#translation:}}|Texture Ref Editor]] | ||
Latest revision as of 17:20, 30 April 2025
Component image 
Texture Ref Editor component as seen in the Scene Inspector

The TextureRefEditor component is commonly used in inspectors for materials and other components that use images/textures.
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. |
_targetRef
|
direct RelayRef`1<AssetRef`1<ITexture2D>> | The field to make a visual for. |
_drive
|
reference drive of AssetRef`1<ITexture2D> | The field to drive with the contents of _targetRef or a placeholder texture if null.
|
_clearReferenceButton
|
Button | The button used to clear _targetRef
|
_openInspectorButton
|
Button | The button to open an inspector for _targetRef .
|
_copyTextureButton
|
Button | The button to copy the texture in _targetRef .
|
_pasteTextureButton
|
Button | The button to paste a texture into _targetRef .
|
_referenceText
|
field drive of String | The field to drive with the description of the contents of _targetRef .
|
_infoText
|
field drive of String | The field to drive with the info of _targetRef .
|
_isNormalMap
|
Bool | Whether _targetRef should be interpreted as a normal map.
|
Sync Delegates
Method Name | Method type and Arguments. | Is the method hidden? | Description |
---|---|---|---|
ClearReference:ButtonEventHandler
|
ButtonEventHandler | ✓ | Called when the reference _targetRef is cleared via the UI button.
|
OpenInspectorButton:ButtonEventHandler
|
ButtonEventHandler | ✓ | Called when an inspector is asked to be opened through this component for _targetRef .
|
CopyTexture:ButtonEventHandler
|
ButtonEventHandler | ✓ | Called when a copy texture is called through this component for _targetRef .
|
PasteTexture:ButtonEventHandler
|
ButtonEventHandler | ✓ | Called when the user asks to paste a texture into _targetRef through this component.
|
SetTexture:ButtonEventHandler
|
ButtonEventHandler | ✓ | Called when the texture for _targetRef is set through this component.
|
Usage
Commonly used in inspectors. Using inspector specific components is a common tactic in Ref Hacking.
Examples
Material inspector views.