Phobos YR Engine Extension

Github All Releases Docs status Workflow license

Phobos

…is a WIP community project providing a set of new features and fixes for Yuri’s Revenge based on modified YRpp and Syringe to allow injecting code. It’s meant to accompany Ares rather than replace it, thus it won’t introduce incompatibilities.

You can discuss the project at a dedicated channel on C&C Mod Haven.

Installation and Usage

  1. If you don’t have Syringe installed into your mod already, you can download it together with the latest Ares package. To install simply drop Syringe.exe into your game folder (where your gamemd.exe is located). It’s highly recommended to install Ares too to get full Phobos feature set, just drop all the files from the archive except documentation folder into your game folder.

  2. Obtain a Phobos “package” (official builds can be found on releases page; read below to learn how to get nightly builds). You should end up with two files: Phobos.dll and Phobos.pdb.

  3. Place those files in the game folder (where your gamemd.exe is located).

  4. To launch the game with Phobos (and all other installed Syringe-compatible engine extensions including Ares) you need to execute Syringe.exe "gamemd.exe" [command line arguments for gamemd.exe] in command line (omit arguments if you don’t need any). RunAres.bat from Ares package does the same so you may use that as well.

If you already use Ares in your mod, you just need to drop Phobos files mentioned above in your game folder, Syringe will load Phobos automatically. This also applies to mods using XNA client with Syringe; if your mod doesn’t use Syringe and Ares (or you just haven’t set up the client) yet we recommend to use CnCNet client mod base by Starkku which is compatible with Ares and Phobos out of the box.

By default Phobos doesn’t do any very noticeable changes except a few bugfixes. To learn how to use Phobos features head over to official documentation.

Obtaining nightly builds

For those who want to help testing Phobos features as soon as they are done - you can also get a nightly build. Those versions are bleeding edge (don’t redistribute them outside of testing!) and have build information (commit and branch/tag) in them which is displayed ingame and can’t be turned off. There are two ways to get a nightly build.

  • Get an artifact via nightly.link. This is a service that allows guests to download automatic builds from GitHub. You can get a build for the latest successful (marked with a green tick) develop branch commit via this link, or get a build for any up-to-date pull request via an automatic comment that would appear in it.

  • Get an artifact manually from GitHub Actions runs. You can get an artifact for a specific commit which is built automatically with a GitHub Actions workflow, just press on a green tick, open the workflow, find and download the build artifact. This is limited to authorized users only.

Building

  1. Install Visual Studio (2019 is recommended, 2017 is minimum) with the dependencies listed in .vswhere (it will prompt you to install missing dependences when you open the project, or you can run VS installer and import the config). If you prefer to use Visual Studio Code you may install VS Build Tools with the stuff from .vswhere instead. You can also don’t use any code editor or IDE and build via command line scripts included with the project.

  2. Clone this repo recursively via your favorite git client (that will also clone YRpp).

  3. To build the extension:

  • in Visual Studio: open the solution file in VS and build it (Debug build config is recommended);

  • in VSCode: open the project folder and hit Run Build Task... (Ctrl + Shift + B);

  • barebones: run scripts/build_debug.bat.

  1. Upon build completion the resulting Phobos.dll and Phobos.pdb would be placed in the subfolder identical to the name of the buildconfig executed.

Documentation

The documentation can be found at here @ Read the Docs and is split by a few major categories, each represented with a page on the sidebar. Each page has it’s contents grouped into multiple subcategories, be it buildings, technotypes, infantries, superweapons or something else.

You can switch between versions in the bottom left corner, as well as download a PDF version.

How to read code snippets

; which section the entries should be in
; can be a freeform name - in this case the comment would explain what it is
; if no comment to be found - then it's a precise name
[SOMENAME]           ; BuildingType
; KeyName=DefaultValue ; accepted type with optional explanation
; if there's nothing to the right of equals sign - the default value is empty/absent
; if the default value is not static - it's written and explained in a comment
UIDescription=<none> ; CSF entry key

Credits

Developers

  • Belonit (Gluk-v48) - project author (Patreon, PayPal)

  • Kerbiter (Metadorius) - project co-author, project manager, DevOps, technical writer (Patreon)

  • Uranusian (Thrifinesma) - developer, CN community ambassador (Patreon, AliPay)

  • secsome (SEC-SOME) - developer (Patreon)

  • Otamaa (Fahroni, BoredEXE) - developer (PayPal)

  • FS-21 - developer

  • Starkku - developer

Contributions

  • Belonit (Gluk-v48) - project creation, disable empty spawn positions, custom gamemd icon with Command Line, full-color non-paletted PCX, SpySat, BigGap, TransactMoney, PCX Loading Screen, custom DiskLaser radius, extended tooltips, building upgrades enhancement, hide health bar, Sidebar.GDIPosition, help with CellSpread, Blowfish.dll-related errors fix, zero size map previews, semantic locomotor aliases, shields, input fix

  • Kerbiter (Metadorius) - SHP debris respect Shadow, building upgrades enhancement, extended tooltips, selection priority filtering, TurretOffset enhancement, customizable ore spawners, select next idle harvester hotkey, interceptor enhancement, zero size map previews, LaserTrails, laser fixes, CI/CD, overhauled Unicode font, docs maintenance, VSCode configs, code style

  • tomsons26 - all-around help, assistance and guidance in reverse-engineering, YR binary mappings

  • CCHyper - all-around help, current project logo, assistance and guidance in reverse-engineering, YR binary mappings

  • Ares developers - YRpp and Syringe which are used, save/load, project foundation and generally useful code from Ares, unfinished RadTypes code, prototype deployer fixes

  • ZΞPHYɌUS - win/lose themes code

  • ayylmao - help with docs

  • SMxReaver - help with docs, extensive and thorough testing

  • 4SG - help with docs

  • wiktorderelf - overhauled Unicode font

  • Uranusian (Thrifinesma) - Mind Control enhancement, custom warhead splash list, harvesters counter, promoted spawns, shields, death after dead fix, customizeable missing cameo, cameo sorting priority, placement mode responding of tab hotkeys fix, producing progress, custom ore gathering anim, NoManualMove, DeathWeapon fix, re-enable obsolete JumpjetControls, overhauled Unicode font, docs maintenance, CN docs translation

  • secsome (SEC-SOME) - debug info dump hotkey, refactoring & porting of Ares helper code, introducing more Ares-derived stuff, disguise removal warhead, Mind Control removal warhead, Mind Control enhancement, shields, AnimList.PickRandom, MoveToCell fix, unlimited waypoints, Build At trigger action buildup anim fix, Undeploy building into a unit plays EVA_NewRallyPointEstablished fix, custom ore gathering anim, TemporaryClass related crash, Retry dialog on mission failure, Default disguise for individual InfantryTypes, PowerPlant Enhancer

  • Otamaa (Fahroni, BoredEXE) - help with CellSpread, ported and fixed custom RadType code, togglable ElectricBolt bolts, customizable Chrono Locomotor properties per TechnoClass, DebrisMaximums fixes, Anim-to-Unit, NotHuman anim sequences improvements, Customizable OpenTopped Properties, hooks for ScriptType Actions 92 & 93

  • E1 Elite - TileSet 255 and above bridge repair fix

  • FS-21 - Dump Object Info enhancements, Powered.KillSpawns, Spawner.LimitRange, ScriptType Actions 71, 72, 73, 74 to 81, 92, 93, 94, 95 to 98, 111, 112, MC deployer fixes, help with docs, Automatic Passenger Deletion

  • AutoGavy - interceptor logic, warhead critical damage system

  • ChrisLv_CN - interceptor logic, LaserTrails, laser fixes, general assistance (work relicensed under following permission)

  • Xkein - general assistance, YRpp edits

  • thomassneddon - general assistance

  • Starkku - Warhead shield penetration & breaking, strafing aircraft weapon customization, vehicle DeployFire fixes/improvements, stationary VehicleTypes, Burst logic improvements

  • SukaHati (Erzoid) - Minimum interceptor guard range

  • Morton (MortonPL) - XDrawOffset

  • mevitar - honorary shield tester triple award

  • Damfoos - extensive and thorough testing

  • Rise of the East community - extensive playtesting of in-dev features

  • Chasheen (Chasheenburg) - CN docs translation

Thanks to everyone who uses Phobos, tests changes and reports bugs! You can show your appreciation and help project by displaying the logo (monochrome version can be found here) in your client/launcher (make it open Phobos GitHub page for extra fanciness), linking to Phobos repository, contributing or donating to us via the links above.