From 4225e9d570af861828ddb461322f413ac6d2a9c3 Mon Sep 17 00:00:00 2001 From: Blixibon Date: Sun, 31 May 2020 08:57:19 -0500 Subject: [PATCH] Minor VScript VPC fixes + misc. adjustments --- sp/src/game/client/client_mapbase.vpc | 2 +- sp/src/game/server/server_mapbase.vpc | 2 +- sp/src/game/shared/mapbase/vscript_funcs_shared.cpp | 3 ++- sp/src/vpc_scripts/groups.vgc | 1 + 4 files changed, 5 insertions(+), 3 deletions(-) diff --git a/sp/src/game/client/client_mapbase.vpc b/sp/src/game/client/client_mapbase.vpc index cdb07dfd..85f76cc7 100644 --- a/sp/src/game/client/client_mapbase.vpc +++ b/sp/src/game/client/client_mapbase.vpc @@ -34,7 +34,7 @@ $Project $File "$SRCDIR\game\shared\mapbase\matchers.cpp" $File "$SRCDIR\game\shared\mapbase\matchers.h" $File "$SRCDIR\game\shared\mapbase\vscript_funcs_shared.cpp" [$MAPBASE_VSCRIPT] - $File "$SRCDIR\game\shared\mapbase\vscript_funcs_hl2.cpp" [$MAPBASE_VSCRIPT && ($HL2||$EPISODIC)] + $File "$SRCDIR\game\shared\mapbase\vscript_funcs_hl2.cpp" [$MAPBASE_VSCRIPT] $File "mapbase\c_func_clientclip.cpp" } diff --git a/sp/src/game/server/server_mapbase.vpc b/sp/src/game/server/server_mapbase.vpc index 5868584e..0fd586da 100644 --- a/sp/src/game/server/server_mapbase.vpc +++ b/sp/src/game/server/server_mapbase.vpc @@ -34,7 +34,7 @@ $Project $File "$SRCDIR\game\shared\mapbase\matchers.cpp" $File "$SRCDIR\game\shared\mapbase\matchers.h" $File "$SRCDIR\game\shared\mapbase\vscript_funcs_shared.cpp" [$MAPBASE_VSCRIPT] - $File "$SRCDIR\game\shared\mapbase\vscript_funcs_hl2.cpp" [$MAPBASE_VSCRIPT && ($HL2||$EPISODIC)] + $File "$SRCDIR\game\shared\mapbase\vscript_funcs_hl2.cpp" [$MAPBASE_VSCRIPT] $File "mapbase\ai_grenade.cpp" $File "mapbase\ai_grenade.h" diff --git a/sp/src/game/shared/mapbase/vscript_funcs_shared.cpp b/sp/src/game/shared/mapbase/vscript_funcs_shared.cpp index 398b136c..d533ef4c 100644 --- a/sp/src/game/shared/mapbase/vscript_funcs_shared.cpp +++ b/sp/src/game/shared/mapbase/vscript_funcs_shared.cpp @@ -50,7 +50,6 @@ public: } else { - DevMsg( "VScript NetPropManager: Prop name is \"%s\"\n", pProp->GetName() ); if (FStrEq( pProp->GetName(), pszPropName )) return pProp; } @@ -647,6 +646,8 @@ void RegisterSharedScriptFunctions() ScriptRegisterFunction( g_pScriptVM, RandomFloat, "Generate a random floating point number within a range, inclusive." ); ScriptRegisterFunction( g_pScriptVM, RandomInt, "Generate a random integer within a range, inclusive." ); + ScriptRegisterFunction( g_pScriptVM, AngleDiff, "Returns the number of degrees difference between two yaw angles." ); + #ifndef CLIENT_DLL ScriptRegisterFunctionNamed( g_pScriptVM, NDebugOverlay::BoxDirection, "DebugDrawBoxDirection", "Draw a debug forward box" ); ScriptRegisterFunctionNamed( g_pScriptVM, NDebugOverlay::Text, "DebugDrawText", "Draw a debug overlay text" ); diff --git a/sp/src/vpc_scripts/groups.vgc b/sp/src/vpc_scripts/groups.vgc index fa9cf45a..7354a28e 100644 --- a/sp/src/vpc_scripts/groups.vgc +++ b/sp/src/vpc_scripts/groups.vgc @@ -22,6 +22,7 @@ $Group "game" "server" "tier1" "vgui_controls" + "vscript" } $Group "shaders"