all repos — WarBot2020 @ 8a6b25009c535de7fa6f4f346bfd949731ed69f5

Bootleg version of "WorldWarBot 2020" done in Java and without a map.

README.md (view raw)

 1# WarBot2020
 2Bootleg version of "WorldWarBot 2020" done in Java and without a map.
 3
 4```
 5Usage: <main class> [-hv] [-m=<max_population>] [-n=<n_wars>] [-s=<source_file>]
 6  -h, --help             display a help message
 7  -m=<max_population>    filter cities for max population (default 50000)
 8  -n=<n_wars>            sets number of wars to simulate (default 500)
 9  -s=<source_file>       load data from a specific file (default data.txt)
10  -v                     only simulate one war (default false)
11```
12
13Watch out for the -v flag! If you don't include it, the program will simulate multiple wars and give you win statistics, so use that if you only want to see a single outcome.
14
15# Data collection
16The program reads coordinates and populations from data.txt in this format:
17```
18country-name(String with no spaces) population(int) latitude(double) longitude(double)
19```
20For example:
21```
22Barcellona-Pozzo-di-Gotto 41293 38.1487398 15.2113962
23```
24
25I will soon be working on a version without a population filter.