Skip to content

Updating for new EVE expansions

Ryan Holmes edited this page Nov 14, 2018 · 26 revisions

Note: this document is meant for developers. If you have no interest in pyfa development, then this doesn't offer you much

Each time EVE is updated, pyfa may need to be updated too. This document covers only the most basic activities. Please remember that sometimes more work is needed to update pyfa properly.

Preparing the Data

For this to work, you must have Phobos downloaded and extracted, as well as reverence installed. You should also switch the git branch to whichever one has the database that you want to compare to. And finally, you should open the EVE client and tab to the market to cache it. This ensures that you have proper data in your cache. Additionally, these instructions are specifically targeted using a Windows operating. Some steps below will not work with other operating systems due to their dependance on a few .pyd files from the client.

Dump Data for Phobos

The following command will dump most data from the EVE client to a directory of your chosing. Please note that this specifically targets TQ, but should be easy enough tofigure out for SISI

Note: Python 2.7 is required for this script (this is the only script that requiress 2.x)

dump_data.py.py -e E:\EVE\SharedCache\tq -d C:\path\to\dump -p C:\path\to\Phobos -r E:\EVE\SharedCache\ -c C:\path\to\cache

The -c flag may or may not be required. I find it's always best to include it, otherwise reverence may have issues finding your cache. The cache is usually located in a directory that looks like this:

C:\Users\<user>\AppData\Local\CCP\EVE\e_eve_sharedcache_tq_tranquility

where e_eve_sharedcache_tq_tranquility is a normalized path to the shared cache

Dump icons data

CCP changed how they store icon definitions on the client, and reverenced has yet to be updated to support it. Until it's been updated, or a better method is developed, the best way is to download the SDE from EVE: Developers. Copy the icons.yaml files intop the scripts/ directory, and run the sdeReadIcons.py script. This should output an icons.json file. Move this file to the Phobos dump directory.

Compile data

Now that we have the json files needed to generate the database, run compile_data.py -d C:\path\to\dump.

pyfa Update

When you prepped the data, you also generated a diff file outlining the differences between the old database and the new database. If this file is empty, then no update is needed. Otherwise, please continue.

Database

Copy eve.db into staticdata folder of pyfa.

Effects

Go through diff file. For each item with added effects, you should verify already implemented effects or implement missing ones. Let's take Rubicon 1.3's Breacher change as example:

[*] Breacher
  [-|y] shipSmallMissileEMDmgMF2
  [-|y] shipSmallMissileExpDmgMF2
  [-|y] shipSmallMissileKinDmgMF2
  [-|y] shipSmallMissileThermDmgMF2
  [+|n] shipMissileRoFMF2
  [*] agility: 3.16 => 3.18
  [*] maxVelocity: 350.0 => 360.0
  [*] powerOutput: 35.0 => 37.0
  [*] shipBonusMF2: 5.0 => -5.0

Here damage bonus was replaced with rate of fire bonus. The process of creating effects in pyfa is described at Writing Effects.

After you've finished writing new effects, remove effects which are no longer used. You can identify them using scripts/effectUsedBy.py: (note that Python 3 must be used because :reasons:)

python3 effectUsedBy.py --database=../staticdata/eve.db

It also goes through effects' .py files and prints by which items this effect is used, which eases maintenance and testing.

Market overrides

There may be cases when test items used in EVE end up in the dump. pyfa should not show these. In these cases, open service/market.py and add it to ITEMS_FORCEPUBLISHED dictionary as key with False value. There are multiple other settings to control what's shown and where, and they are pretty much self-explanatory.

Icons and Renders

To update icons, run the following command. It will go through the EVE client files and extract the various icons needs for ships and modules, resize them to the correct dimensions, and add them to the proper directories.

Please note that this will not work on non-Windows operating systems, due to it's reliance on .pyd files from the client

icons_update.py -i C:\path\to\dump\icons.json -e E:\EVE\SharedCache

Versioning

Open config.py and update version, tag, expansionName and expansionVersion variables according to versioning guidelines.

Distributives

Clean copies of resources

To make distributives for all 3 platforms, you will need clean version of pyfa and its skeletons. It might be good idea to store them in separate folder:

git clone https://github.com/DarkFenX/Pyfa.git
git clone https://github.com/DarkFenX/Pyfa-skel.git

Each time before you're going to make distributive, make sure these copies are updated, on the correct branch, and then run git clean -fdx in both. This will erase anything that is not strictly in the repository, hence why it's a good idea to have a pyfa repository to base distributives off of separate from your working repository.

Generating distributives

Windows:

python3 -m PyInstaller --noupx --clean --windowed --noconsole -y ./dist_assets/win/pyfa.spec

Once PyInstaller is done generating, please move dist_assets/win/pyfa.exe.manifest and dist_assets/win/Microoft.VC90.CRT.manifest into the distribution directory dist/pyfa. If you don't, you're gonna have a bad time (if anyone knows how to integrate this into pyinstallers command, please let me know!)

This directory can then be zipped to create a zipped distribution

To create an installer, run dist_assets\win\dist.py

OS X:

I'll have to log into my OS X machine to get these commands

Linux:

No distributable at this time. Run pyfa directly from Terminal