What Megalith is
A game mode in Project Reclaimer is one text file: its rules, its options and its script, written in Megalith, Reclaimer's game mode language. Megalith grew from Megalo, Halo: Reach's game type language, and still reads every Megalo source as written. Write one in a text editor, drop it in a folder and play it. You need nothing but the game and this page.
New in 0.10.12Megalo is now Megalith. Nothing of yours changes: .rmeg files keep their extension, and every mode written as Megalo plays as before. The name changed because the syntax has grown well beyond Megalo: scripts now do arithmetic and mathematics, hear players spawning, joining and leaving, vehicles entered and left, and objectives picked up, dropped and scored, have a real else, break and return, functions that take values, and local variables, read and shape how players move and aim, give a second weapon, show weapon icons and each player's own key names in widgets, control seats and damage, and may be much larger files. The Megalith console runs Megalith in a running game while you host alone.
New in 0.10A source is a whole mode, so there's no template to pick and nothing to compile. Scripts can now hear damage and deaths, name any object on the map by its path, copy objects, show waypoints, play sounds, set who can hurt what, revive players where they fell, run squads and a deployment map and dress players in armor of their choosing. Conquest and Combined Arms show it all at work. Reach's own calls play in any source, and classes can be Reach's troopers and Covenant, some of which fly.
New in 0.10.5: weapon tag paths in loadouts, waypoint timers and text on Halo 3's HUD, and Reach objective items and announcer lines on Halo 3 and ODST maps.
New in 0.10.8 to 0.10.11: the round's tick, the VIP, the Juggernaut and the active hill, an object's velocity and face_toward, script menus on a controller, and Reach game variants that read the host's options and keep Reach's timers.
Megalith is Project Reclaimer's own game mode language, run by its own interpreter on the maps of every game the engine plays. It began from Megalo, the scripting language of Halo: Reach's game types, in the text form ReachVariantTool writes, and has grown so far past it that it now has a name of its own. It still reads every Megalo source as written, and all of the game's bundled modes are written in Megalith.
- Older sources play as written. Nothing added to the language changes what an earlier script means: a call keeps its arguments and its defaults, and a script's own alias or function spelled like a word added since, such as
local,else,return,minorlength, keeps its own meaning. - A mode is one file. Reclaimer's Megalith files end in
.rmeg; ReachVariantTool's.rvtfiles read the same. The file's mode header holds the game type, rules, options and script settings, and the rest is the script. It plays as it is, from yourGame Modesfolder. - Only the host runs it. Players don't install or run the script. What it does reaches them through the game: scores, teams, traits, HUD widgets and menus, sizes, waypoints, sounds, bodies and looks.
- It's checked before it runs. The game reads the whole file, the parts that never run included, and leaves out a mode that has a mistake or needs something Halo 3 can't play. Map assets, object lifetime and some argument limits can only be checked as the mode runs, so play your mode too.
- It's Reach's language and more, not all of Reach's game. Many of Reach's calls work, Megalith adds many more, and a few of Reach's have nothing to do here: see Reach's calls, and what doesn't play. Compiled game variants (
.bin,.mglo) and MegaloEdit's syntax aren't read.
The next three sections take you from nothing to a mode with a setting of its own. Then come the examples and the reference. To change a bundled mode instead, start from change a mode; to play the bundled ones, see game modes.
