Add awakening to weapons and characters

This commit is contained in:
Justin Edmund 2022-12-21 00:41:54 -08:00
parent 1fe1c1bb36
commit c14b2eac82
3 changed files with 17 additions and 1 deletions

View file

@ -0,0 +1,6 @@
class AddAwakeningToGridWeapons < ActiveRecord::Migration[6.1]
def change
add_column :grid_weapons, :awakening_type, :integer, null: true
add_column :grid_weapons, :awakening_level, :integer, null: false, default: 1
end
end

View file

@ -0,0 +1,6 @@
class AddAwakeningToGridCharacters < ActiveRecord::Migration[6.1]
def change
add_column :grid_characters, :awakening_type, :integer, null: false, default: 0
add_column :grid_characters, :awakening_level, :integer, null: false, default: 1
end
end

View file

@ -10,7 +10,7 @@
# #
# It's strongly recommended that you check this file into your version control system. # It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema.define(version: 2022_12_03_112452) do ActiveRecord::Schema.define(version: 2022_12_21_083126) do
# These are extensions that must be enabled in order to support this database # These are extensions that must be enabled in order to support this database
enable_extension "btree_gin" enable_extension "btree_gin"
@ -65,6 +65,8 @@ ActiveRecord::Schema.define(version: 2022_12_03_112452) do
t.datetime "created_at", precision: 6, null: false t.datetime "created_at", precision: 6, null: false
t.datetime "updated_at", precision: 6, null: false t.datetime "updated_at", precision: 6, null: false
t.boolean "perpetuity", default: false, null: false t.boolean "perpetuity", default: false, null: false
t.integer "awakening_type", default: 0, null: false
t.integer "awakening_level", default: 1, null: false
t.index ["character_id"], name: "index_grid_characters_on_character_id" t.index ["character_id"], name: "index_grid_characters_on_character_id"
t.index ["party_id"], name: "index_grid_characters_on_party_id" t.index ["party_id"], name: "index_grid_characters_on_party_id"
end end
@ -98,6 +100,8 @@ ActiveRecord::Schema.define(version: 2022_12_03_112452) do
t.integer "ax_modifier2" t.integer "ax_modifier2"
t.float "ax_strength2" t.float "ax_strength2"
t.integer "element" t.integer "element"
t.integer "awakening_type"
t.integer "awakening_level", default: 1, null: false
t.index ["party_id"], name: "index_grid_weapons_on_party_id" t.index ["party_id"], name: "index_grid_weapons_on_party_id"
t.index ["weapon_id"], name: "index_grid_weapons_on_weapon_id" t.index ["weapon_id"], name: "index_grid_weapons_on_weapon_id"
end end