Shooting into safezone

willidshome

Well-Known Member
Does anyone know if this is possible.

I have trade/safe zones which stop the firing of weapons inside the zone but is it possible to stop people firing from outside of the zone into it ?

Reason I am asking is to stop vehicles in the safe zone been targeted.

Thanks
 
There is a way to but you would have to detect the bullet as an object entering the safezone and then send it somewhere else (normally debug)

To do that, unless someone already has, would take quite a bit.

You would also have to have a two trigger system detecting guns fired outside the safezone but still within the outer trigger and then wait to see if the round enters the first trigger and then teleport it.

Making a safezone where your players have godmode is just simpler.
 
There is a way to give godmode to vehicles but you can't loop a getObjectsNear marker or else it would cause horrible server lag, so instead you detect a person inside a vehicle.

If the person drives his vehicle into the trader, it gets godmode. When he drives it out, it loses godmode.
The issue with this fix however is that if a is left inside the safezone when it restarts, it won't have godmode, or worse, it'll have permanent godmode until it is outside the trader for another restart.
 
Thanks then I think this may be the better option

You would also have to have a two trigger system detecting guns fired outside the safezone but still within the outer trigger and then wait to see if the round enters the first trigger and then teleport it.
 
Back
Top