Black Mesa

Black Mesa

89 ratings
[SOURCEMOD] Headcrab Latch Restoration
2
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
1.243 MB
Sep 3, 2022 @ 12:32am
1 Change Note ( view )

Subscribe to download
[SOURCEMOD] Headcrab Latch Restoration

Description
NOTE: THIS ADDON REQUIRES SOURCEMOD AND MANUAL INSTALLATION TO RUN. READ THIS DESCRIPTION IN FULL FOR INSTRUCTIONS.

This is a Sourcemod plugin that restores the Headcrab latching feature from the Black Mesa mod that was removed for the retail release, with additional fixes and console variables. Keep in mind that this has only been tested in Singleplayer and is not guaranteed to work on a coop server. If you run into any issues in coop let me know and I can work with you to fix them.

This plugin adds the following ConVars:
// If enabled, in the event of a latched headcrab the melee damage is canceled. // - // Default: "1" bm_headcrablatch_cancel_damage "1" // Chance for headcrabs to latch to the player's head on easy difficulty. // - // Default: "3" // Minimum: "0.000000" // Maximum: "100.000000" bm_headcrablatch_chance_easy "3" // Chance for headcrabs to latch to the player's head on hard difficulty. // - // Default: "8" // Minimum: "0.000000" // Maximum: "100.000000" bm_headcrablatch_chance_hard "8" // Chance for headcrabs to latch to the player's head on normal difficulty. // - // Default: "5" // Minimum: "0.000000" // Maximum: "100.000000" bm_headcrablatch_chance_normal "5" // Enable printing information to the console. // - // Default: "0" bm_headcrablatch_enableprint "0"

SOURCEMOD INSTALLATION
  1. Download the latest developer builds of SourceMod[www.sourcemod.net] and MetaMod:Source[www.sourcemm.net].
  2. Install both of them to your Black Mesa installation - this should be somewhere like Program Files (x86)/Steam/steamapps/common/Black Mesa/bms, though its exact location may differ based on your setup. If you downloaded them separately, drop the addons folder from MM:Source in the bms directory, followed by the addons and cfg folders from SourceMod - if you downloaded the package, extract the bms folder from it and merge it with the directory in the Black Mesa folder.
  3. In your Steam library, find Black Mesa, right-click it, and select Properties. At the bottom of the window is an option labelled Launch options. Add this to it:
    -insecure
    Do note that starting Black Mesa with this launch option enabled WILL PREVENT YOU FROM CONNECTING TO VAC-SECURED MULTIPLAYER SERVERS.
    If you should want to play multiplayer, remove the -insecure entry from the launch options.
  4. Launch the game and bring up the developer console. In it, type the following commands and press enter.
    meta sm
    If MetaMod:Source and SourceMod are installed correctly, you'll get output something like this in response:
    ] meta
    Metamod:Source Menu usage: meta <command> [arguments] alias - List or set an alias clear - Unload all plugins forcefully cmds - Show plugin commands cvars - Show plugin cvars credits - About Metamod:Source force_unload - Forcefully unload a plugin game - Information about GameDLL info - Information about a plugin list - List plugins load - Load a plugin pause - Pause a running plugin refresh - Reparse plugin files retry - Attempt to reload a plugin unload - Unload a loaded plugin unpause - Unpause a paused plugin version - Version information ] sm SourceMod Menu: Usage: sm <command> [arguments] cmds - List console commands config - Set core configuration options credits - Display credits listing cvars - View convars created by a plugin exts - Manage extensions plugins - Manage Plugins prof - Profiling version - Display version information
    If you get a message stating Unknown command, then something isn't installed properly. Double-check and make sure you've got both a metamod and sourcemod directory in your /bms/addons folder, as well as a pair of files called metamod.vdf and metamod_x64.vdf. If all four of those are present, check and make sure that you added -insecure to the launch parameters via Steam before starting the game.
  5. Subscribe to this addon and let it download (this shouldn't take very long, since it's a relatively small file). When it's done, you can find it in your workshop downloads folder for Black Mesa - this'll be somewhere like Program Files (x86)/Steam/steamapps/workshop/content/362890/2857944155. Inside, you should find a folder named Manual Install.
  6. Copy the contents of this folder into your Black Mesa directory, merging the bms folders. This will install the compiled plugin, as well as place a copy of its source code in addons/sourcemod/scripting.

    You may also view the source code on GitHub[github.com].
  7. Either restart Black Mesa, or run this command in the console:
    sm plugins refresh
    Once that's done, run this command as well:
    sm plugins list
    If installed correctly, you should see a line like this somewhere in the output:
    3 "[Black Mesa] Headcrab Latch Restoration" (1.0) by 1/4 Life

Common Issues
  • I am getting kicked to the menu on level transition:
    Remove all files from bms/addons/sourcemod/plugins not prefixed by bm_

Credits
  • First off, big thanks to KyuuGryphon for the idea of using Sourcemod for singleplayer Black Mesa in the first place, and for the excellent guide above that has been almost directly copied. Go check out all of their Sourcemod plugins on the workshop!
  • Thanks to bAddie of the Sourcemod discord for debugging assistance.
  • Thanks to Ari Bloss for editing some additional audio files for this feature.
  • Thanks to ysrael214 for the fixed hc_blur texture included in in this mod.

Supporting Workshop Items
Popular Discussions View All (2)
2
Sep 9, 2022 @ 9:58am
PINNED: Everything reminds me of her
1/4 Life
0
Sep 14, 2022 @ 2:56am
coop implementation
SHOUBI
33 Comments
twelve dollars Sep 24, 2023 @ 5:59pm 
It latched onto my head one time... and then never again. How can I fix this?
Pacman09 Aug 25, 2023 @ 8:38pm 
Resubbing fixed it.
Pacman09 Aug 25, 2023 @ 8:27pm 
For some reason this has worked for quite a while until it suddenly turned into a error texture
Thatheavyisaspy! Jul 22, 2023 @ 7:55pm 
Shuddup AF
Freshman Apr 30, 2023 @ 4:13am 
gordon and headcrab sex :gordon:
The Bucket Apr 2, 2023 @ 8:09am 
I also used the Juniez compatibility
The Bucket Apr 2, 2023 @ 8:09am 
I looked at the list of plugins and I found out that the code is "Too new"
Chocofrolik Mar 25, 2023 @ 8:22am 
@Mr.Tie
Please read the 'Common Issues' section.
MrTie Feb 27, 2023 @ 6:09am 
When I'm getting out of a vent and loading and processing to chapter questionable ethics but than game crashed but I've an idea and the idea is by delete sourcemod, metamod and this mod or just delete this mod and it's vpk
ninthlyokowarrior Jan 1, 2023 @ 12:17pm 
So, this is more a general Sourcemod thing than with this specifically, but whenever I try running this with Improved Xen, even though I cleared the filed you said to, it still crashes to the menu on the level transition