aboutsummaryrefslogtreecommitdiff
path: root/mp/src/game/server/nav_mesh.cpp
diff options
context:
space:
mode:
authorJohn Schoenick <[email protected]>2015-09-09 18:35:41 -0700
committerJohn Schoenick <[email protected]>2015-09-09 18:35:41 -0700
commit0d8dceea4310fde5706b3ce1c70609d72a38efdf (patch)
treec831ef32c2c801a5c5a80401736b52c7b5a528ec /mp/src/game/server/nav_mesh.cpp
parentUpdated the SDK with the latest code from the TF and HL2 branches. (diff)
downloadsource-sdk-2013-master.tar.xz
source-sdk-2013-master.zip
Updated the SDK with the latest code from the TF and HL2 branches.HEADmaster
Diffstat (limited to 'mp/src/game/server/nav_mesh.cpp')
-rw-r--r--mp/src/game/server/nav_mesh.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/mp/src/game/server/nav_mesh.cpp b/mp/src/game/server/nav_mesh.cpp
index 4c38a6f5..09326aaf 100644
--- a/mp/src/game/server/nav_mesh.cpp
+++ b/mp/src/game/server/nav_mesh.cpp
@@ -1700,6 +1700,9 @@ static ConCommand nav_clear_selected_set( "nav_clear_selected_set", CommandNavCl
//----------------------------------------------------------------------------------
CON_COMMAND_F( nav_dump_selected_set_positions, "Write the (x,y,z) coordinates of the centers of all selected nav areas to a file.", FCVAR_GAMEDLL | FCVAR_CHEAT )
{
+ if ( !UTIL_IsCommandIssuedByServerAdmin() )
+ return;
+
const NavAreaVector &selectedSet = TheNavMesh->GetSelectedSet();
CUtlBuffer fileBuffer( 4096, 1024*1024, CUtlBuffer::TEXT_BUFFER );
@@ -1732,6 +1735,9 @@ CON_COMMAND_F( nav_dump_selected_set_positions, "Write the (x,y,z) coordinates o
//----------------------------------------------------------------------------------
CON_COMMAND_F( nav_show_dumped_positions, "Show the (x,y,z) coordinate positions of the given dump file.", FCVAR_GAMEDLL | FCVAR_CHEAT )
{
+ if ( !UTIL_IsCommandIssuedByServerAdmin() )
+ return;
+
CUtlBuffer fileBuffer( 4096, 1024*1024, CUtlBuffer::TEXT_BUFFER );
// filename is local to game dir for Steam, so we need to prepend game dir for regular file save
@@ -1764,6 +1770,9 @@ CON_COMMAND_F( nav_show_dumped_positions, "Show the (x,y,z) coordinate positions
//----------------------------------------------------------------------------------
CON_COMMAND_F( nav_select_larger_than, "Select nav areas where both dimensions are larger than the given size.", FCVAR_GAMEDLL | FCVAR_CHEAT )
{
+ if ( !UTIL_IsCommandIssuedByServerAdmin() )
+ return;
+
if ( args.ArgC() > 1 )
{
float minSize = atof( args[1] );
@@ -2665,6 +2674,9 @@ void CNavMesh::CommandNavMarkWalkable( void )
{
Vector pos;
+ if ( !UTIL_IsCommandIssuedByServerAdmin() )
+ return;
+
if (nav_edit.GetBool())
{
// we are in edit mode, use the edit cursor's location