Coder Social home page Coder Social logo

tautomer / universalcartographicshistory Goto Github PK

View Code? Open in Web Editor NEW
1.0 3.0 0.0 193 KB

Find out the bodies you have discovered/mapped in Elite: Dangerous!

License: MIT License

Python 100.00%
elite-dangerous elitedangerous universal-cartographics

universalcartographicshistory's Introduction

Elite: Dangerous Universal Cartographics History

As an explorer, I often find it's sad that we can't have a list of all the star systems and the bodies we discovered or mapped before. I have been thinking of writing a script like this for quite a long time. Unfortunately, I couldn't find a way to know whether the bodies had been discovered before.

Thanks to user aggasalk on reddit for the hint! I can finally finish this script.

The script should be fully functional, but I have only tested the code on my own computer. It would be great if you can try the script out and tell me if it works or not and how it breaks if it doesn't work!

How to use

Make sure you have Python 3 installed on your Windows. Alternatively, type python3 in cmd or PowerShell to install a copy via Microsoft Store. Any version of Python 3 should work. No 3rd party package required.

Download the script here and save it to your computer. Double click or run the script in CLI.

Alternatively, I have packed a standalone executable with PyInstaller which behaves exactly like the script. The exe can be downloaded from the releases page.

Note: if your Python isn't the Microsoft Store version, typing python3 or python3.exe will only lead you to the Store. Make sure type python or python.exe instead.

Also note: this script should also work on Linux, as I can test it runs on my WSL2. However, I'm not sure if the default log path is ~/Saved Games/Frontier Developments/Elite Dangerous on Linux.

Some config options are provided via CLI:

Usage:
  python.exe uchistory.py [OPTION...]

Help Option:
  -h, --help              Show this message

E:D Log Path:
  -l, --log-path=         Path to the E:D log files
                          Make sure the path is quoted if there are spaces within the path. See the default below
                          Defaults to 'C:\Users\username\Saved Games\Frontier Developments\Elite Dangerous'

Output File:
  -o, --output=           Output filename and path to save the scan results
                          Defaults to 'Universal Cartographics Histroy Scan.txt' in the current folder

Output Level:
  -v, --verbose=          Output verbose level
                          Level 1 lists only the number of bodies discovered/mapped in the system
                          Level 2 lists the body names as well
                          Defaults to 2

Example output

Commander Name: Qualcomm
Total Number of First Discovery + First Mapped: 239
Total Number of First Discovery: 9632
Total Number of First Mapped: 119

System Name: Sharur
  First Discovery: 4 Bodies
    Sharur A
    Sharur B
    Sharur B A Belt Cluster 1
    Sharur B A Belt Cluster 4

System Name: Col 285 Sector ZZ-Y d57
  First Mapped: 1 Body
    Col 285 Sector ZZ-Y d57 4

System Name: Praea Euq UQ-X b1-6
  First Mapped: 15 Bodies
    Praea Euq UQ-X b1-6 A 1
    Praea Euq UQ-X b1-6 A 2
    Praea Euq UQ-X b1-6 A 3
    Praea Euq UQ-X b1-6 A 4
    Praea Euq UQ-X b1-6 A 5
    Praea Euq UQ-X b1-6 A 6
    Praea Euq UQ-X b1-6 B 1
    Praea Euq UQ-X b1-6 B 2
    Praea Euq UQ-X b1-6 B 3
    Praea Euq UQ-X b1-6 B 3 a
    Praea Euq UQ-X b1-6 B 4
    Praea Euq UQ-X b1-6 B 5
    Praea Euq UQ-X b1-6 B 6
    Praea Euq UQ-X b1-6 B 7
    Praea Euq UQ-X b1-6 B 8

How it works

Well, basically finding events like FSDJump, Scan, SAAScanComplete in all the journal files. Currently the path to the log files are assumed to be the default path, i.e., C:\Users\username\Saved Games\Frontier Developments\Elite Dangerous. An summary called Universal Cartographics Histroy Scan.txt will be saved in the same folder as the script.

Known issues

  • There some well-known systems (the ones with a unique name, not something like Col balabala) where the bodies are shown as undiscovered, or say not discovered by any one.

    For example, the first ever system I ever "honked", Sharur in the starting space.

    Sharur

    In the journal, these bodies are shown as

    {
     "timestamp":"2020-11-25T21:44:23Z",
     "event":"Scan",
     "ScanType":"NavBeaconDetail",
     "BodyName":"Sharur B A Belt Cluster 4",
     "BodyID":16,
     "Parents":[
        {
           "Ring":12
        },
        {
           "Star":2
        },
        {
           "Null":0
        }
     ],
     "StarSystem":"Sharur",
     "SystemAddress":1733187048154,
     "DistanceFromArrivalLS":41381.868618,
     "WasDiscovered":false,
     "WasMapped":false
    }
    

    No one discovered these bodies and the stars and belt clusters are not mappable, which means I can't distinguish whether they are first discovered by you or not.

    On the other hand, the planets in these systems are mappable, so for any bodies with status of "WasDiscovered":false and "WasMapped":true are completely ignored.

    If you happen to be the one who actually mapped these bodies... I'm sorry.

TODO List

  • A simple GUI probably?

  • Add an optional config file?

  • Add CI.

Find a bug?

Report it to me over GitHub. It will be great if you can attach some ED logs so that it can be easier for me to look into the problem.

Disclaimer: I'm very busy IRL recently so that I can't guarantee a fix for the issue you might have, but I'll try my best.

universalcartographicshistory's People

Contributors

tautomer avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.