Add Pilots

From Battletech Modding Wiki
Jump to: navigation, search

This guide covers adding pilots to Skirmish and the Campaign

Please note the file locations are for the Steam Version, GOG may differ.

Tools needed are NOTEPAD++, DB Browser if you are going to add the pilot to the campaign and GIMP 2 is handy for picture editing.

Please note the text in the JSONS and the DB is case sensitive so be careful.

The pilot files can be found in:

\SteamLibrary\steamapps\common\BATTLETECH\BattleTech_Data\StreamingAssets\data\pilot

Firstly

Create a new folder in BattleTech_Data\StreamingAssets\ called mods

Secondly

Create a folder inside mods with a name for the mod I chose crackfox

Thirdly

Create another folder called pilots and within that folder another called jsons and another called sprites

Creating a new pilots JSON file

First of all copy an existing pilot's JSON file to your mods/crackfox/pilots/json folder and rename it.

pilot_backer_Alaniz.json for example and change it to pilot_crackfox.json

Open your new pilot file in Notepad++ and you should see the following listed below (parts to change are highlighted in BOLD and comments in bold/italic)
{
"Description": {
"Id": "pilot_backer_Alaniz", - This ideally needs to be the same as your new pilots json file so the "pilot_back_Alaniz" we change it to "pilot_crackfox".
"Name": "Dragon 66", - This is the pilots name, Change the "Dragon 66" to your pilot's nickname. So we put "Crackfox"
"FirstName": "Zin", - This is the pilots first name, Change the "Zin" to your pilot's first name. So we put "Harry".
"LastName": "Ala", - This is the pilots last name, Change the "Ala" to your pilot's last name. So we put "Rams".
"Callsign": "Dragon 66", - This is the pilots Callsign, Change the "Dragon 66" to your pilot's Callsign. So we put "Crackfox"
"Gender": "Male", - This is the characters Gender, Change the "Male" to "Female" if creating a female pilot.
"Faction": "Davion", - This is the characters faction "I will add a list of possible pilot factions to another section, for the moment leave it as Davion
"Age": "41", - Pilots age just change the number to whatever you desire.
This section is your pilots BIO just enter whatever you please within the quotations
"Details": "Dragon 66 was born Zin Ala in the Federated Suns, the child of a family of military bureaucrats. His stable, safe childhood left him craving more excitement than bureaucracy could provide, so when he was old enough, he enrolled in the planetary guards.\r\n\r\nAfter boot camp, his aptitude tests placed him in logistical support roles \u2014 not that different from what his family did, but at least he was on the more exciting front lines. Through dedicated service and commitment, Zin worked his way up from driving supply vehicles to planning their routes to overseeing entire logistical operations.\r\n\r\nAll that changed when an operation he was involved with collapsed, leaving him one of the few able-bodied soldiers able to defend a key location. He did a hero's job, but when reinforcements won through, they came with military lawyers and wagging fingers over breaches of protocol.\r\n\r\nAs a result, he ended up on Solaris VII, where he stayed just long enough to establish a reputation. But knowing he had no future there, he moved on to the Periphery, looking for a chance to once again start at the bottom and work his way up.",
"Icon": "guiTxrPort_backerAlaniz_utr" - This is the pilots portrait, the picture needs to be 512x512 PNG format with or without a transparent background, note put the file name without the extension. Call the picture something similar to the pilot name EG "pilot_crackfox_sprite"
},
"BaseGunnery": "3", - Pilots Gunnery, set to whatever you like within the quotations. For the purpose of this example change it to 4.
"BonusGunnery": 0,
"BasePiloting": "5", - Pilots Piloting, set to whatever you like within the quotations. For the purpose of this example change it to 4.
"BonusPiloting": 0,
"BaseGuts": "2", - Pilots Guts, set to whatever you like within the quotations. For the purpose of this example change it to 4.
"BonusGuts": 0,
"BaseTactics": "5", - Pilots Tactics, set to whatever you like within the quotations. For the purpose of this example change it to 4.
"BonusTactics": 0,
"ExperienceUnspent": 0,
"ExperienceSpent": 6600,
"Injuries": 0,
"Health": 3,
"LethalInjury": false,
"Incapacitated": false,
"Morale": 0,
"Voice": "m_pro03_brit", - This is the name of the voice pack the Pilot will use, there are 12 Female and 12 Male voice packs not counting story Characters. I will list the voice packs separately.
"abilityDefNames": [ - Abilities and Traits are listed in another section, I am not sure what happens if you add more than 2 active abilities as this may cause UI Issues. If adding more abilities make sure there is not a , after the last ability.
"AbilityDefP5",
"AbilityDefT5A",
"TraitDefUnsteadySet60",
"TraitDefIndirectReduceOne"
],
"AIPersonality": "Undefined",
"PilotTags": { - Not sure what bearing most of these have on the game other than pilot_backer and pilot_release_skirmish. Add pilot_release_skirmish to enable the pilot to appear in the skirmish side of the game.
"items": [
"pilot_backer", -
"BLACKLISTED",
"pilot_military",
"pilot_merchant",
"pilot_dependable",
"pilot_gladiator",
"pilot_davion"
],
For simplicity change the pilot tags to the following:

"items": [

"BLACKLISTED",

"pilot_mechwarrior",

"pilot_release_skirmish" - Only if you want the pilot to appear in Skirmish.

],
"tagSetSourceFile": ""
},
"PilotCost": 0,
"IsRonin": true,
"IsVanguard": true - Change this to false.
}

Abilities and Traits List

Pilots can have multiple abilities, Unknown if having more than 2 usable abilities will cause UI Issues.

Abilities List

"AbilityDefG5" - MULTI TARGET

"AbilityDefG8" - BREACHING SHOT

"AbilityDefP5" - EVASIVE MOVEMENT

"AbilityDefP8" - ACE PILOT

"AbilityDefGu5" - BULWARK

"AbilityDefGu8" - JUGGERNAUT

"AbilityDefT5A" - SENSOR LOCK

"AbilityDefT8A" - MASTER TACTICIAN

Trait List

Coming Soon

Faction List

Coming Soon

Voice pack List

Female Voices

"f_bear02"

"f_creep01"

"f_glum01_russian"

"f_overload01"

"f_pro01"

"f_pro01_brit"

"f_pro02_asian"

"f_pro02_irish"

"f_pro04_midwest"

"f_pro05_tanesha"

"f_pro06_tough"

"f_pro07"

Male Voices

"m_bear01"

"m_ermy01"

"m_overload02"

"m_pro01_stark_chad"

"m_pro02_david"

"m_pro03_brit"

"m_pro04_brad"

"m_pro05_rick"

"m_pro06_matthew"

"m_pro07_allan"

"m_rizzo01"

"m_vizzini01"

Adding the pilot to versionmanifest.csv

Versionmanifest.csv is located at:

\SteamLibrary\steamapps\common\BATTLETECH\BattleTech_Data\StreamingAssets\data

Make sure to create a backup of version Versionmanifest.csv

Open the file in notepad++ and scroll all the way to the bottom

We will need to add 2 new lines to the CSV file for each new pilot, DO NOT leave a gap between the lines as this will cause the game to not load.

pilot_crackfox,PilotDef,mods/crackfox/pilots/json/pilot_crackfox.json,15,2018-03-06T18:42:54.8077172Z,2018-04-05T01:11:44.7395977Z,,,FALSE,0,FALSE

pilot_crackfox_sprite,Sprite,mods/crackfox/pilots/art/pilot_crackfox_art.png,8,2018-02-27T00:45:29.5565233Z,2018-04-05T01:11:45.9835969Z,,,FALSE,0,FALSE

The sections highlisted in bold are what you need to change to your pilots json file and portrait and their location, everything after them just copy it directly without changing it.

If everything has gone to plan your new pilot should appear in the skirmish game.

Making the new pilot appear in the campaign.

You will need DB Browser for SQLite as we need to edit a SQLite database.

In folderpath \SteamLibrary\steamapps\common\BATTLETECH\BattleTech_Data\StreamingAssets\MDD

You will find the file MetadataDatabase.db

Firstly make a backup of MetadataDatabase.db

Then open the file with DB Browser.

DBBrowse.png

Click the Edit Pragmas tab and untick Foreign Keys, then click save.

Editing PilotDef Table

Click the Browse Data tab and choose PilotDef table.

Click new record.

There are 5 Columns that need an entry:

PilotDefID is the ID we gave the pilot in the JSON file. pilot_crackfox

FriendlyName is the Callsign we gave the pilot in the JSON file. Crackfox

IconID is the icon line from the JSON file. pilot_crackfox_sprite

TagSetID is a unique number for the pilot as far as I'm aware it can be anything, I gave my first pilot 1234567890 as it's unique ID.

IsRonin should be set to 1. This makes the pilot appear as a ronin in the game and the chances of the pilot appearing can be made a lot higher by changing another file.

Click Write Changes

Editing TagSet Table

Click the table and choose TagSet

Click new record

There are 2 Columns that need an entry:

TagSetID is the unique ID we put in the PilotDef Table.

TagSetTypeID enter "6" as this tells the game the ID is a pilot.

Click Write Changes

Editing the TagSetTag Table

Click the table and choose TagSetTag

Click new record (if you have more than 1 tag for the pilot in the JSON create as many new records as you need)

TagSetID is the unique ID we put in the PilotDef Table

TagName is the tags we put in the Pilot's JSON file.

Tagsettag.jpg

The example image shows 3 new records for the 3 tags we gave the pilot in the JSON file.

If everything has gone to plan your new pilot should appear in the campaign game.

Increasing the chances of your new pilot to appear in the Campaign

Open SimGameConstants.json in Notepad++ which is located in \SteamLibrary\steamapps\common\BATTLETECH\BattleTech_Data\StreamingAssets\data\simGameConstants

Find the line:

"DefaultRoninHiringChance" : 0.08,

Change 0.08 to 1 so it looks like:

"DefaultRoninHiringChance" : 1,

Save the file.

This change does not require a new game and it also makes no Proc Gen pilots appear anymore