Combine Forcefield (allowing a team through something)
2 replies, posted
so in hl2 there are combine forcefields, only combine can go through them and others are just blocked. this was achieved with player clip. i want to make a combine forcefield but in lua, where only members of 1 team can go through it. i could use ents.FindInBox to check for players around it, but that would be super expensive and players could go through it that aren't supposed to, or a combine and rebel could get stuck at the same time. and the forcefield doesn't turn off, it just lets combines through seamlessly.
so how could i create something like this in gmod? if only there was a 'team clip' of sorts... hey, now that i think about it, didnt tf2 have something like that for spawn doors?
[editline]11th June 2015[/editline]
i did a collision check to check player's teams with the entity, and return false to collision if they are the same, it kinda works but for some reason collisions are super laggy, how do i fix the lag/stutter on collisions?
[url]http://steamcommunity.com/workshop/browse/?appid=4000&searchtext=CAP&childpublishedfileid=0&browsesort=textsearch§ion=items&requiredtags%5B0%5D=Addon&actualsort=textsearch&p=2[/url]
decompile and look through the code for ideas. Don't copy it though.
Sorry, you need to Log In to post a reply to this thread.