Jump to content

dxDraw Piority


.:HyPeX:.

Recommended Posts

You can set onClientRender priorities for that. Higher priority = under everything (executes first), lower priority - over everything (executes last). This is the way it works:

local renderUnder() 
  -- First Layer 
end 
addEventHandler("onClientRender",root,renderUnder,true,"high+5") -- "high + 5" is an optional value if you need more layers like that, you can simply use "high" without any problems. 
  
local renderMiddle() 
  -- Second Layer 
end 
addEventHandler("onClientRender",root,renderMiddle) -- We don't change it because it has "normal" priority already.  
  
function renderOverlap() 
  -- Third Layer 
end 
addEventHandler("onClientRender",root,renderOverlap,true,"low-5") -- The most top layer. Same as first one, -5 isn't necessary and it's used when you really need to. That's just an example.  
  

You can split them around all resources, start whenever you want, change timing when render is added, but the layers will still look as they should.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...