A Python project that models the province adjacency network of Europa Universalis IV (EU4) as a weighted graph. Used to find shortest travel paths between provinces and visualize the world map as a graph structure.
Built as a companion project to the paper "Pemanfaatan Graf dalam Implementasi Peta Dunia pada Game Europa Universalis IV" (IF2220 Discrete Mathematics, STEI ITB).
- Build an adjacency list graph representing province connections
- Find shortest paths between any two provinces using Dijkstra's algorithm
- Visualize the province graph using
matplotlibandnetworkx
- Python 3.x
- PIL (Pillow)
- networkx
- matplotlib
pip install pillow networkx matplotlibThe core logic is in map.py, which builds the province graph and runs pathfinding queries.
python map.pyMIT