I was trying to change the price of an item in my script Max Limit Breaker and for some reason the price still stays at the default price. I was wondering if I wrote this correctly.
module Warrior_Engine
module CORE
# This hash allows you to adjust the individual item price. This allows you
# to go past the original editor limit of 999,999 gold for a single item.
CUSTOM_PRICES ={
:item => {1 => 9999999999, 30 => 123456789999},
:weapon => {},
:armor => {},
}
end
end
module RPG
class Item
include Warrior_Engine::CORE
custom_prices = CUSTOM_PRICES[:item][@id]
@price = custom_prices.nil? ? 0 : custom_prices
end
class Weapon
include Warrior_Engine::CORE
custom_prices = CUSTOM_PRICES[:weapon][@id]
@price = custom_prices.nil? ? 0 : custom_prices
end
class Armor
include Warrior_Engine::CORE
custom_prices = CUSTOM_PRICES[:armor][@id]
@price = custom_prices.nil? ? 0 : custom_prices
end
end