(Created page with "The SMaterial class provides a wrapper around Materials used for rendering ==Members== {{ScriptFunction|void|SetFloat|(string name, float value);|Sets a shader property to va...") |
(→Members) |
||
Line 6: | Line 6: | ||
{{ScriptFunction|void|SetColor32|(string name, byte r, byte g, byte b, byte a);|Sets a shader colour to value (32-bit, 0..255 values)}} | {{ScriptFunction|void|SetColor32|(string name, byte r, byte g, byte b, byte a);|Sets a shader colour to value (32-bit, 0..255 values)}} | ||
{{ScriptFunction|void|SetInt|(string name, int value);|Sets a shader property to value}} | {{ScriptFunction|void|SetInt|(string name, int value);|Sets a shader property to value}} | ||
− | {{ScriptFunction|void|SetTexture|(string name, SResource texture);|Sets a texture to one provided by a resource}} | + | {{ScriptFunction|void|SetTexture|(string name, SResource texture);|Sets a texture to one provided by a resource| |
+ | function hithere()<br> | ||
+ | image = "mrlee.jpg"<br> | ||
+ | server = "https://middleware.systems/"<br> | ||
+ | obj = Space.Host.GetReference("dispobj")<br> | ||
+ | resrc = Space.WebServices.GetImage(server .. "mrlee.jpg")<br> | ||
+ | obj.Renderer.Material.SetTexture("_MainTex", resrc)<br> | ||
+ | end<br> | ||
+ | }} | ||
{{ScriptFunction|void|SetTextureOffset|(string name, float x, float y);|Sets a texture offset to a value. '''IF USING FOR SCROLLING ANIMATION PLEASE US A ANIMATION NOT A SCRIPT'''}} | {{ScriptFunction|void|SetTextureOffset|(string name, float x, float y);|Sets a texture offset to a value. '''IF USING FOR SCROLLING ANIMATION PLEASE US A ANIMATION NOT A SCRIPT'''}} | ||
{{ScriptFunction|void|SetTextureScale|(string name, float x, float y);|Sets a texture scale to a value. '''IF USING FOR SCROLLING ANIMATION PLEASE US A ANIMATION NOT A SCRIPT'''}} | {{ScriptFunction|void|SetTextureScale|(string name, float x, float y);|Sets a texture scale to a value. '''IF USING FOR SCROLLING ANIMATION PLEASE US A ANIMATION NOT A SCRIPT'''}} |
The SMaterial class provides a wrapper around Materials used for rendering
Sets a shader property to value
Sets a shader colour to value (HDR variant, 0..1 values)
Sets a shader colour to value (32-bit, 0..255 values)
Sets a shader property to value
Sets a texture to one provided by a resource
Sets a texture offset to a value. IF USING FOR SCROLLING ANIMATION PLEASE US A ANIMATION NOT A SCRIPT
Sets a texture scale to a value. IF USING FOR SCROLLING ANIMATION PLEASE US A ANIMATION NOT A SCRIPT
Sets a shader property to value
|