Added a cfg.js.example file so as not to accidentally overwrite user's cfg.js settings that is already on localhost. Updated README.md to reflect the necessary changes. (To start, rename cfg.js.example to cfg.js).

This commit is contained in:
Ru Chern 2016-08-21 09:06:20 +10:00
parent 3562af2a4e
commit 336796e7bf
No known key found for this signature in database
GPG Key ID: D7B9FD049BFDBEC2
3 changed files with 55 additions and 2 deletions

3
.gitignore vendored
View File

@ -1,2 +1,3 @@
node_modules/
scripts/
scripts/
cfg.js

View File

@ -21,6 +21,8 @@ ______ _____ _____ _____
## Setup
Copy and rename ``cfg.js.example`` to ``cfg.js``.
Open ``cfg.js`` and fill the following fields:
````js
@ -60,4 +62,4 @@ Depending on your OS, you need to run either ``run-linux.sh`` or ``run-windows.b
If everything went fine, it should look like:
![Preview](http://image.prntscr.com/image/6ce92058147b4067b8027c42258a198c.png "")
![Preview](http://image.prntscr.com/image/6ce92058147b4067b8027c42258a198c.png "")

50
cfg.js.example Normal file
View File

@ -0,0 +1,50 @@
export default {
// Server settings
MAX_CONNECTIONS: 64,
PORT: 3000,
GAME_MODE: 0,
SAVE_INTERVAL: 60000,
PLAYER_CONNECTION_TIMEOUT: 1800000,
MINIMUM_CLIENT_VERSION: "0.33.0",
DEFAULT_CONSOLE_COLOR: 32,
TRANSFER_ACCOUNTS: false,
// Choose a database type
DATABASE_TYPE: "MYSQL",
// MySQL credentials
MYSQL_PORT: 3306,
MYSQL_HOST_IP: "127.0.0.1",
MYSQL_DB_NAME: "pogosql",
MYSQL_USERNAME: "root",
MYSQL_PASSWORD: "",
MYSQL_TABLE: "users",
// MongoDB credentials
MONGO_PORT: 27017,
MONGO_HOST_IP: "127.0.0.1",
MONGO_DB_NAME: "pokemongo",
MONGO_COLLECTION_USERS: "users",
// Used for asset download session
DOWNLOAD_PROVIDER: "GOOGLE",
DOWNLOAD_USERNAME: "USERNAME",
DOWNLOAD_PASSWORD: "PASSWORD",
// Google maps api key
GMAPS_KEY: "AIzaSyDF9rkP8lhcddBtvH9gVFzjnNo13WtmJIM",
// Server debug options
DEBUG_DUMP_PATH: "./logs/",
DEBUG_DUMP_TRAFFIC: true,
DEBUG_LOG_REQUESTS: true,
// Better dont touch these
TICK_INTERVAL: 1,
BOOT_TIMEOUT: 10000,
// Currently supported pokemon
MAX_POKEMON_NATIONAL_ID: 151,
DUMP_ASSET_PATH: "data/"
}