mirror of
https://github.com/celisej567/BCWSsrc.git
synced 2026-09-15 20:12:39 +03:00
Mapbase v6.0
- Fixed path_track paths saving as pointers instead of handles - Fixed player animations not falling to base class correctly - Fixed logic_externaldata creating garbage in trailing spaces - Added "SetHandModelSkin" input - Added unique colors for various types of console message, adjustable via convars - Added the ability to use map-specific weapon scripts - Added a way to display (placeholder) text entirely from Faceposer scenes - Added "autobreak" keyvalue to game_text, which automatically breaks long text into different lines - Added the ability to change a game_text's font (very limited) - Added LightToggle input to point_spotlight - Added Enable/DisableSprites on npc_manhack - Added ai_goal_police behavior from metrocops to Combine soldiers and citizens - Added func_precipitation particle rain systems from the Alien Swarm SDK - Added new func_precipitation spawnflags for controlling behavior in particle types - Added "mapbase_version" cvar which shows the version of Mapbase a mod might be running on - Fixed an oversight with NPC crouch activities which was causing npc_metropolice to stop firing in standoffs - Added toggleable patches to npc_combine AI which make soldiers less likely to stand around without shooting or rush to melee when not needed - Added key for custom logo font on env_credits scripts - Added SetSpeed and SetPushDir inputs for trigger_push - Added a bunch of I/O/KV to func_fish_pool to allow for more control over the fish - Added OnLostEnemy/Player support for npc_combine_camera - Added enhanced save/restore for the Response System, toggleable via convar - Added a convar which allows users to disable weapon autoswitching when picking up ammo - Split VScript base script into its own file - Added VScript descriptions for NPC squads and the manager class which handles them - Moved several classes, functions, etc. to the VScript library itself for future usage in other projects, like VBSP - Added VScript to VBSP with basic map file interfacing - Made some VScript documentation more clear due to deprecation of online documentation - Added VScript "hook" registration, creating a standardized system which shows up in script_help documentation - Added VScript-driven custom weapons - Added clientside VScript scopes - Added a bunch of weapon-related VScript functions - Split a bunch of cluttered VScript stuff into different files - Added VScript functions for "following" entities/bonemerging - Added VScript functions for grenades - Added a few more VScript trigger functions - Added OnDeath hook for VScript - Fixed documentation for aliased functions in VScript - Fixed $bumpmask not working on SDK_LightmappedGeneric - Made vertex blend swapping in Hammer use a constant instead of a combo (makes it easier to compile the shader, especially for $bumpmask's sake) - Fixed brush phong, etc. causing SDK_WorldVertexTransition to stop working - Added limited support for $envmapmask in the bumpmapping shader - Fixed more issues with parallax corrected cubemaps and instances - Made instance variable recursion consistent with VMFII
This commit is contained in:
@@ -20,6 +20,11 @@
|
||||
#include "byteswap.h"
|
||||
#include "worldvertextransitionfixup.h"
|
||||
|
||||
#ifdef MAPBASE_VSCRIPT
|
||||
#include "vscript/ivscript.h"
|
||||
#include "vscript_vbsp.h"
|
||||
#endif
|
||||
|
||||
extern float g_maxLightmapDimension;
|
||||
|
||||
char source[1024];
|
||||
@@ -66,6 +71,9 @@ bool g_bNoDefaultCubemaps = true;
|
||||
bool g_bSkyboxCubemaps = false;
|
||||
int g_iDefaultCubemapSize = 32;
|
||||
#endif
|
||||
#ifdef MAPBASE_VSCRIPT
|
||||
ScriptLanguage_t g_iScripting = SL_NONE;
|
||||
#endif
|
||||
|
||||
float g_defaultLuxelSize = DEFAULT_LUXEL_SIZE;
|
||||
float g_luxelScale = 1.0f;
|
||||
@@ -1185,6 +1193,72 @@ int RunVBSP( int argc, char **argv )
|
||||
Msg( "Default cubemap size = %i\n", g_iDefaultCubemapSize );
|
||||
i++;
|
||||
}
|
||||
#endif
|
||||
#ifdef MAPBASE_VSCRIPT
|
||||
else if ( !Q_stricmp( argv[i], "-scripting" ) )
|
||||
{
|
||||
const char *pszScriptLanguage = argv[i + 1];
|
||||
if( pszScriptLanguage[0] == '-')
|
||||
{
|
||||
// It's another command. Just use default
|
||||
g_iScripting = SL_DEFAULT;
|
||||
}
|
||||
else
|
||||
{
|
||||
// Use a specific language
|
||||
if( !Q_stricmp(pszScriptLanguage, "gamemonkey") )
|
||||
{
|
||||
g_iScripting = SL_GAMEMONKEY;
|
||||
}
|
||||
else if( !Q_stricmp(pszScriptLanguage, "squirrel") )
|
||||
{
|
||||
g_iScripting = SL_SQUIRREL;
|
||||
}
|
||||
else if( !Q_stricmp(pszScriptLanguage, "python") )
|
||||
{
|
||||
g_iScripting = SL_PYTHON;
|
||||
}
|
||||
else if( !Q_stricmp(pszScriptLanguage, "lua") )
|
||||
{
|
||||
g_iScripting = SL_LUA;
|
||||
}
|
||||
else
|
||||
{
|
||||
DevWarning("-server_script does not recognize a language named '%s'. virtual machine did NOT start.\n", pszScriptLanguage );
|
||||
g_iScripting = SL_NONE;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
}
|
||||
else if ( !Q_stricmp( argv[i], "-doc" ) )
|
||||
{
|
||||
// Only print the documentation
|
||||
|
||||
if (g_iScripting)
|
||||
{
|
||||
scriptmanager = (IScriptManager*)Sys_GetFactoryThis()(VSCRIPT_INTERFACE_VERSION, NULL);
|
||||
VScriptVBSPInit();
|
||||
|
||||
const char *pszArg1 = argv[i + 1];
|
||||
if (pszArg1[0] == '-')
|
||||
{
|
||||
// It's another command. Just use *
|
||||
pszArg1 = "*";
|
||||
}
|
||||
|
||||
char szCommand[512];
|
||||
_snprintf( szCommand, sizeof( szCommand ), "PrintHelp( \"%s\" );", pszArg1 );
|
||||
g_pScriptVM->Run( szCommand );
|
||||
}
|
||||
else
|
||||
{
|
||||
Warning("Cannot print documentation without scripting enabled!\n");
|
||||
}
|
||||
|
||||
DeleteCmdLine( argc, argv );
|
||||
CmdLib_Cleanup();
|
||||
CmdLib_Exit( 1 );
|
||||
}
|
||||
#endif
|
||||
else if (argv[i][0] == '-')
|
||||
{
|
||||
@@ -1319,6 +1393,15 @@ int RunVBSP( int argc, char **argv )
|
||||
sprintf( materialPath, "%smaterials", gamedir );
|
||||
InitMaterialSystem( materialPath, CmdLib_GetFileSystemFactory() );
|
||||
Msg( "materialPath: %s\n", materialPath );
|
||||
|
||||
#ifdef MAPBASE_VSCRIPT
|
||||
if (g_iScripting)
|
||||
{
|
||||
scriptmanager = (IScriptManager*)Sys_GetFactoryThis()(VSCRIPT_INTERFACE_VERSION, NULL);
|
||||
|
||||
VScriptVBSPInit();
|
||||
}
|
||||
#endif
|
||||
|
||||
// delete portal and line files
|
||||
sprintf (path, "%s.prt", source);
|
||||
@@ -1442,6 +1525,9 @@ int RunVBSP( int argc, char **argv )
|
||||
ReleasePakFileLumps();
|
||||
DeleteMaterialReplacementKeys();
|
||||
ShutdownMaterialSystem();
|
||||
#ifdef MAPBASE_VSCRIPT
|
||||
VScriptVBSPTerm();
|
||||
#endif
|
||||
CmdLib_Cleanup();
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user