-
-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Get HL2SB compiling #7
base: master
Are you sure you want to change the base?
Conversation
I agree it's time to reunify these repositories. We did it back in the Google Code days for a specific reason that no longer applies. We should push binaries to Releases so we don't end up inflating the repository in the same way we bloated the trunk history way back. I agree with your approach of using ValveSoftware/source-sdk-2013 and then reintroducing hl2sb. I think I'm forced to not attach this repository to the fork network there simply because Half-Life 2: Sandbox existed before their repository was released, so we literally predate them since the mod was first built on the 2006 branch. I think your approach across the board and what you chose to include is great. I'll try to do the hardwork of replicating this patch while preserving individual diffs. I'd like us to be able to see specific commits that address individual concerns. So for example, we could Edit: While we're at it, do we want to move to Visual Studio 2022? Maybe the process for replicating this patch is something like:
Roughly speaking, of course. Building from upstream should take place first. Of course if we could also automate this from GitHub Actions, that would be ideal. I've failed to do it in the past, though, but at the time I was using vs2013. Maybe I could get it to work with vs2022. |
Do you think its worth the hassle of keeping in sync with valve's repo? I imagine with source 2 now, that the older engines may get neglected. Also another option for a cleaner merge might be to apply a code styling to all files in the master branch of hl2sb-src, committing that. Afterwards doing the same to these changes, then commit a PR. It should reduce the changes to only code and no formatting |
Yeah, I doubt we'll ever see another push to source-sdk-2013, so it's probably not important. Even if we hypothetically needed to synchronize across disparate histories, git sort of lets you do it, it just tells you that you shouldn't. I use the same approach for normalizing code formatting, so I figured we'd do that, yes. |
I went ahead and did it since it seemed easy enough: luttje@137d5ef This diff is a lot cleaner and should be easier to work with. Given the whole XZ utils incident rocking our open-source world recently, I think it might be a good exercise for us if you pick a clang-format styling and apply that to this repo. Then I'll propose a new PR into that so the changes can be cleanly inspected. For reference, here's my process:
For better formatting in the future we should use |
I'm in communication with a Russian community about bringing on another developer, so I haven't lost sight of this. I'm just juggling at the moment. |
Alright! I'm pretty far with my own project (which I'll eventually open-source). It's turning out very similar to HL2SB and Garry's Mod, except I'm heading more in the same direction as Garry's Mod: naming Lua bindings differently from source engine functions, customizing Lua, etc. So I feel like both can exist fine side-by-side. Once it's a bit easier to make PR's here I will make some, of course in the style of the HL2SB project where they mimic the source engine naming/functionality as closely as possible. |
Pardon the messy commit. I turned off code formatting too late and checking every file line-by-line to fix it is too time consuming (plus I've been at that for some time, getting this to compile).
This PR is the result of my own project being merged over top HL2SB. My own project is the result of a fresh clone from [SourceSDK 2013 by Valve] (https://github.com/ValveSoftware/source-sdk-2013) with HL2SB code slowly copied over to it.
It is pretty late, so I'm just info dumping a bit now, some notes/todo's:
cfg/settings*.src
files to enable the gamemode picker.gameinfo.txt
using deprecated keyvaluessurface.AddCustomFontFile
.clang-format
. We can direct our IDE's to respect that in the future. I've included an example.PlayerUpdateFlashlight
src/setupprojects.sh
) to quickly setup debugging (because the vpc scripts mess that up when they touch the vs project files)I've done my best to remove any changes I made that are irrelevant to this project. However I've likely missed some.
I'm making this a draft merge. I'd like some guidance on how to best clean this PR up, so the merge becomes reviewable.
Additional notes
I'll use this list to track additional issues I find in my own project, that need fixing in HL2SB as well. They're not all related to this PR, so feel free to ask me to make separate PR's/issues for each of them.
const char *zipPath = NULL;
toconst char *zipPath = relativePath;
in luacachefile.cpp to fix constructing cache filesEnsure the lua_cache path is added as a search path, so downloaded gamemodes actually load if the client doesn't already have it in their gamemodes folder. I did this by adding this to the end ofThis can also be done by properly implementing mountaddons.cpp (which I had removed in my mod)luasrc_ExtractLcf
(and refactoring it slightly so thegamePath
var is available in the same scope):filesystem->AddSearchPath( contentSearchPath, "MOD" );
with something like: