Alpine Faction Mod Development

From Red Faction Wiki
Revision as of 05:47, 13 January 2025 by Goober (talk | contribs) (→‎Level Info Tables)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)



This page lists all new and improved capabilities when designing mods for Alpine Faction.

General

RedFaction\client_mods\ - The "client_mods" folder should be used for all clientside mods in Alpine Faction, rather than the traditional RF method of dropping them into "user_maps\multi\" or "user_maps\single\"


Packfiles are loaded alphabetically from the below locations. Assets loaded by the game from packfiles can be overridden/modified by including a file with the same filename in a packfile loaded later (either alphabetically or in a later loaded location).

Packfile location loading order:

  1. Standard VPPs in root RF directory
  2. alpinefaction.vpp
  3. VPPs in user_maps\multi *
  4. VPPs in user_maps\single *
  5. VPPs in client_mods
  6. VPPs in TC mod folder (if TC mod is loaded)
* - All packfiles are loaded from user_maps\multi and user_maps\single, but assets in these packfiles will NOT override previously loaded assets unless the "Allow clientside mods to be loaded from user_maps" option is turned on in the Alpine Faction Launcher.

Level Info Tables

In Alpine Faction, whenever a map is loaded (multi or single), the client attempts to load a file named "MAPNAME_info.tbl", where MAPNAME is the level's filename (e.g. "dm02_info.tbl" is loaded when "dm02.rfl" is loaded). This file can be loaded from anywhere - user_maps\multi, user_maps\single, client_mods, or the TC mod's folder (if a TC mod is loaded).

The below options can be specified in this file, and apply as long as that map is loaded.

MAPNAME_info.tbl File

#Start

// This is a comment
$Ideal Player Count: 8
$Author Contact: "example@factionfiles.com"
$Author Website: "https://factionfiles.com"
$Description: "This is a description of the map."
$Lightmap Clamp Floor: {32,32,32}
$Lightmap Clamp Ceiling: {255,255,255}
$Player Headlamp Color: {32,32,32}
$Player Headlamp Range: 3.5
$Player Headlamp Radius: 20.0

#End

Explanation

The below options work. The other options listed above are loaded by the game but currently have no effect.

  • $Lightmap Clamp Floor - Set the minimum values per channel for clamping to be applied when lightmaps are loaded from the level file. If this option is specified for a given map, the "Full Range Lighting" option in the launcher is ignored and these values are used instead.
  • $Lightmap Clamp Ceiling - Set the maximum values per channel for clamping to be applied when lightmaps are loaded from the level file.

Alpine Options Tables

Alpine Faction exposes many previously hardcoded and inaccessible options and variables to customization by mod developers via Alpine Options table files loaded from the TC mod's directory. Each Alpine Options table file has different options that can be specified as listed below.

The available Alpine Options table files are:

  • af_game.tbl
  • af_ui.tbl
  • af_client.tbl *
* - af_client.tbl is also loaded from client_mods and can be used to set values in clientside mods. If an af_client.tbl file is loaded from both client_mods and a loaded TC mod, the one from the TC mod will take precedence.

af_game.tbl File

#Start

// This is a comment
$Default Geomod Smoke Emitter: "emitter name"
$Driller Geomod Smoke Emitter: "emitter name"
$Ice Geomod Texture: "texture.tga"
$First Level Filename: "mapname.rfl"
$Training Level Filename: "mapname.rfl"
$Use Base Game Players Config: false
$Ignore Swap Assault Rifle Controls: false
$Ignore Swap Grenade Controls: false
$Player Entity Type: 
$Player Undercover Suit Entity Type: 
$Player Undercover Scientist Entity Type: 
$Fall Damage Land Multiplier: 
$Fall Damage Slam Multiplier:
$Multiplayer Walk Speed: 
$Multiplayer Crouch Walk Speed: 
$Walkable Slope Threshold: 

#End

Explanation

  • $Default Geomod Smoke Emitter -

af_ui.tbl File

#Start

// This is a comment
$Disable Multiplayer Button: false
$Disable Singleplayer Buttons: false
$Summoner Trailer Button Action: 
 +Summoner Trailer Button URL: 
 +Summoner Trailer Button Bink Filename: 

#End

Explanation

  • $Disable Multiplayer Button -

af_client.tbl File

#Start

// This is a comment
$Assault Rifle Ammo Counter Color: "#DEADBEEF"
$Precision Rifle Scope Color: "#DEADBEEF"
$Sniper Rifle Scope Color:
$Rail Driver Fire Glow Color:
$Rail Driver Fire Flash Color:

#End

Explanation

  • $Assault Rifle Ammo Counter Color -