Repository navigation
Conversation
Member
Author
|
A couple other notes:
|
Blixibon
force-pushed
the
mapbase/feature/archaic-mapbase-code-rewrite
branch
4 times, most recently
from
November 14, 2026 03:41
c5ecb3d to
adef73e
Compare
… for multiple and variable shadow map resolutions
…mized classname matching
Blixibon
force-pushed
the
mapbase/feature/archaic-mapbase-code-rewrite
branch
from
November 14, 2026 03:54
adef73e to
c460a7f
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR rewrites and refactors Mapbase code of various origin that was written early in the project to be more efficient and less janky. This targets the combined SP/MP branch due to the MP branch already containing some refactors that were needed to support TF2.
As part of this refactor, a number of particularly obscure features have been removed. Instances of this are in bold.
mapbase_shared (generic code, map-specific files)
mapbase_sharedhas been split into a header file. Mainly to declutter it, but also to move theMODTITLECOMMENTstructs out ofgameinterface.%mapname%_manifest.txt) to override the default map-specific file paths has been removed, as has themapbase_manifestentity. These were very seldom used and documented, and there was a report that the latter may not have been functional. If you need to load non-standard files, use the exposed VScript functions.mapbase_load_default_manifestcvar (which could disable all default map-specific files) is retained.Most other changes are general refactoring or organization. I would have liked to do more to revisit the way the map-specific file enum and array are defined due to how messy the
#ifdefs are, but I don't think a more intricate solution is necessary for it.mapbase_game_log
Completely removed. Was not finished or documented. A similar system should use a modified gamestats.
mapbase_con_groups (console groups)
The original idea behind console groups was to achieve a Source 2-style system where you not only have custom colors and separation for groups of console messages, but can also configure them by editing a script file. However, this feature is neither well-documented nor have I felt that this has been useful under its past implementation, as all console groups were in a hardcoded array.
Console groups are now defined as direct struct objects, and then passed by reference to
CGMsg. This allows custom console groups to be declared quickly and easily.CGMsgitself has also been refactored to use a macro instead of a dedicated function that always has to useva_list. Performance is proven to be near-identical to callingMsgdirectly.mapbase_matchers_base/matchers
Mainly pulled the matcher cvars out of
tier1and intomapbase_shared.cpp, since they had conflicts between the client/server. For now, I've only defined cvars for the server. Also cleaned up some of the comments.Remove CHudIcons
CHudIconswas added from the VDC tutorial for adding the Game Instructor. However, this actually contains duplicated functionality for loading HUD textures. In the Alien Swarm SDK,CHudIconsreplaced all HUD texture functionality, but that isn't the case in Source 2013, which appears to have been a mistake in the tutorial. The calls for loading instructor textures have been moved toCHud, as have the calls for loading them in the instructor HUD.