# Routes
# This file defines all application routes (Higher priority routes first)
# https://www.playframework.com/documentation/latest/ScalaRouting
# ~~~~

# For the javascript routing
GET         /assets/js/routes        controllers.JavaScriptRoutingController.javascriptRoutes()
# Primary routes
GET         /                        controllers.MainMenuController.index()
GET         /assets/*file            controllers.Assets.versioned(path="/public", file: Asset)

# Main menu routes
GET         /mainmenu                controllers.MainMenuController.mainMenu()
GET         /rules                   controllers.MainMenuController.rules()
GET         /navSPA/:pType           controllers.MainMenuController.navSPA(pType)

POST        /createGame              controllers.MainMenuController.createGame()
POST        /joinGame                controllers.MainMenuController.joinGame()

# User authentication routes
POST        /login                   controllers.UserController.login_Post()
POST        /logout                  controllers.UserController.logoutPost()
GET         /userInfo                controllers.UserController.getUserInfo()

# In-game routes
GET         /game/:id                controllers.IngameController.game(id: String)

# Websocket
GET         /websocket               controllers.WebsocketController.socket()

# Status
GET         /status                  controllers.StatusController.requestStatus()
GET         /status/:gameId          controllers.StatusController.game(gameId: String)