add setShader instead of using __raw
This commit is contained in:
parent
12edf6cb9a
commit
7b198abc55
5
main.xml
5
main.xml
|
@ -255,6 +255,11 @@
|
||||||
end)
|
end)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function setShader(actor, shader)
|
||||||
|
if not shader.__raw then error('uranium: cannot set shader during module loadtime! put this in uranium.init or actor:addcommand(\'Init\', ...)', 2) end
|
||||||
|
actor:SetShader(shader.__raw)
|
||||||
|
end
|
||||||
|
|
||||||
-- actors
|
-- actors
|
||||||
|
|
||||||
local actorQueue = {}
|
local actorQueue = {}
|
||||||
|
|
|
@ -70,6 +70,10 @@ function addChild(frame, actor) end
|
||||||
--- SetDrawFunction with special behavior to account for Uranium's actor loading scheme.
|
--- SetDrawFunction with special behavior to account for Uranium's actor loading scheme.
|
||||||
function setDrawFunction(frame, func) end
|
function setDrawFunction(frame, func) end
|
||||||
|
|
||||||
|
---@param actor Actor
|
||||||
|
---@param shader RageShaderProgram
|
||||||
|
function setShader(actor, shader) end
|
||||||
|
|
||||||
---@type number
|
---@type number
|
||||||
--- A simple timer. Ticks upwards at a rate of 1/sec.
|
--- A simple timer. Ticks upwards at a rate of 1/sec.
|
||||||
---
|
---
|
||||||
|
|
Loading…
Reference in New Issue