There the code which checking can place on this point a sentry, but its working only on plate serfaces.
I want to change it to place on any surface(like engineer), but except walls.
How to change this code to make it to allow to creating not only plate surfaces, but not the walls?
PHP Code:
...
new Float:flPos[3];
if(GetClientLookPosition(client, flPos))
if(CanBuildAtPosSentry(flPos))
...
stock bool CanBuildAtPosSentry(float fPos[3]){
float fMins[3], fMaxs[3];
fMins[0] = -20.0;
fMins[1] = -20.0;
fMins[2] = 0.0;
fMaxs[0] = 20.0;
fMaxs[1] = 20.0;
fMaxs[2] = 66.0;
TR_TraceHull(fPos, fPos, fMins, fMaxs, MASK_SOLID);
return !TR_DidHit();
}