Rails.application.routes.draw do root to: "home#index", as: :home_index devise_scope :user do get "login", to: "devise/sessions#new" get "logout", to: "devise/sessions#destroy" end devise_for :users, skip: [:registrations] as :user do get "users/edit", to: "devise/registrations#edit", as: "edit_user_registration" put "users", to: "devise/registrations#update", as: "user_registration" end resources :chat_messages, only: [:index, :create] resources :locations, only: [:index, :show] resources :activities, only: [:show] resources :items, only: [:index, :show] resources :hearth_amenities, only: [] do post "/use", to: "hearth_amenities#use" end resources :characters, only: [:show, :new, :create] do post "/combat_styles", to: "characters#set_combat_styles" scope module: :characters do post "/items/unequip/:slot", to: "items#unequip", as: :item_unequip resources :items, only: [:index] do post "/equip", to: "items#equip" post "/use", to: "items#use" end resources :titles, only: [:index] do post "/activate", to: "titles#activate" end get "/hearth", to: "hearth#index" end end get "/bazaar", to: "bazaar#index" post "/bazaar", to: "bazaar#create_order", as: :bazaar_order post "/bazaar/accept/:id", to: "bazaar#accept_offer", as: :bazzar_accept_offer delete "/bazaar/cancel/:id", to: "bazaar#cancel_offer", as: :bazzar_cancel_offer post "/start_activity", to: "activities#start" post "/stop_activity", to: "game#stop_activity" post "/finish_activity", to: "game#finish_activity" end