It’s more likely than you think. First have a look at the video below:
So, how does this work? Using the new predicted networked variables, entities remember in which layer they are:
function _R.Entity:GetLayer() return math.Clamp( self:GetDTInt( 0 ), 1, 20 ) end function _R.Entity:SetLayer( layer ) self:SetDTInt( 0, layer ) end
With that information, the server makes entities in different layers not collide using the ShouldCollide hook. In this hook, a pair of entities is passed to you and you specify whether they should collide or not. Clientside Entity.SetNoDraw is used in the RenderScene hook. If an entity is in the same layer as the local player, it’s visible, otherwise it’s not. Simple.
But it’s not without its problems yet. Here’s a list of the known problems at the moment:
- Sound is still heard throughout all layers.
- Constraints (ropes, hydraulics, …) can be seen throughout all layers.
- Some effects show throughout all layers and some don’t show anymore at all.
- E2 holograms aren’t layered yet, which causes trouble.
And on top of that, the tool – in its current state – is obviously ideal for spammers. I’m currently working on the constraint issue and I am confident the other problems will be solved over time too.
To solve the spamming issue, my idea is to have a scoreboard in the STOOL menu which shows every layer with the amount of entities and the players into it.
Tell me what you think of it!
Nice work, also im lately trying to add you to steam again… Miss having the Overv guy around
I tried it on his Dev server, its fuckn awesome :3
That’s pretty cool tbh
Pretty fucking awesome.
Win.
Epic. Win.