Skip to content

WarpWorld/CCPack-PC-MCCHaloCE

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Halo Crowd Control Effect Pack

This is an effect pack for doing Crowd Control on Halo CE on the Master Chief Collection. This is a version of the Cursed Halo crowd control pack with a few incentives removed and some modified to have no elements from Cursed Halo.

Installation

Requires:

  • Master Chief Collection on Steam. If you have it elsewhere, like Game Pass, look into how to install Steam Worshop mods on that version and it should work as well.
  • And if trying to run it locally, the CrowdControl SDK. https://developer.crowdcontrol.live/sdk/
    • Copy the contents of this repository on <folder of the CrowdControl SDK>/PackProject/HaloCE
  • Then run the Crowd Control SDK, click Load Package Source, select MCCHaloCE.cs, and then click Connect.

How it works

This effect pack works through code injection. It uses three kinds of patterns:

  1. Injecting code on game instructions that are run once every game frame (or few frames) and access interesting addresses, like the player data base address, and storing those addresses on custom memory caves that we store a pointer for. That way, we can have a constantly updated pointer to info we may want to read or modify, like health and shields.
  2. Injecting code that hijacks the behaviour of instructions, like hijacking the damage received function to multiply the damage value by a factor to increase or decrease it.
  3. Communicating with H1 scripts. For many effects, this pack uses custom H1 (Halo CE scripting language) scripts, but H1 has no way of communicating with another process or read any external files. To allow the effect pack to communicate with the scripts, I define a global variable with a specific value in the H1 script, surrounded by two other globals with specific values, and then, using the patter 1, hook into the code that reads script variables and look for those three variables, saving a pointer to the first one. Then the pack uses the pointer to change that variable, which the script reads every frame to determine what it should run.

I have already attempted to do simpler injection using pointermaps, but it does not seem to work on Halo CE. Also, every injection is based on the base address of halo1.dll, which is loaded inside the MCC. If it is not loaded, the pack will wait until it is.

Project structure

  • The entry point is MCCHaloCE.cs. The //ccpragma in the first line includes all the files into the main file so it can be loaded as an effect pack. It also contains the base elements of Crowd Control.
  • LifeCycle contains code that makes sure the pack properly connects to the game, sets everything up, and repairs any problem, like a game crash or exiting to the main menu (which overwrites injections).
  • Injections contains all the code that injects assembler. In each injection, the replaced code is copied so that if an update breaks the injections, it is easier to find.
  • Effects contains implementations for specific effects.
  • Utilities contains methods used by all the other code.
  • HaloFiles contains the H1 script code relevant to the effect pack. Note that to modify this it needs to be added on each level of the Cursed Halo source code and rebuild such levels.

How to compile halo maps

  1. Download the Halo: CE Mod Tools - MCC on steam, and open its folder (On the steam library, Right click->Manage->Browse local files). You should be on a folder named HCEEK.
  2. Run HCEEK (Extract).bat
  3. Copy the contents of HaloFiles/ccHaloModifiedSource in HCEEK, so that the data and tags subfolders merge.
  4. Copy tool_classicBuildEverything(in HaloFiles) to the HCEEK folder and run it.
  5. All the modified maps should be in the maps folder in HCEEK. You can now use them to replace the Halo 1 campaign maps.

Contributing

If you want to update broken injections or add new effects, feel free to create a pull request.

Credits

Pack created by ZePistachio The song used in the Berserker effect is provided by Vertex https://www.youtube.com/watch?v=IX8bAxvUFnc CrowdControl framework is provided by CrowdControl ( https://crowdcontrol.live/ )

License

MIT

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages