forked from OpenNeo/impress
Reorder Item::Dyeworks
methods a bit
This commit is contained in:
parent
98ecbf029d
commit
c6fbb9b797
1 changed files with 12 additions and 12 deletions
|
@ -4,6 +4,12 @@ class Item
|
|||
dyeworks_base_item.present?
|
||||
end
|
||||
|
||||
# Whether this is a Dyeworks item whose base item can currently be purchased
|
||||
# in the NC Mall, then dyed via Dyeworks. (Owls tracks this last part!)
|
||||
def dyeworks_buyable?
|
||||
dyeworks_base_buyable? && dyeworks_dyeable?
|
||||
end
|
||||
|
||||
# Whether this is a Dyeworks item whose base item can currently be purchased
|
||||
# in the NC Mall. It may or may not currently be *dyeable* in the NC Mall,
|
||||
# because Dyeworks eligibility is often a limited-time event.
|
||||
|
@ -11,6 +17,12 @@ class Item
|
|||
dyeworks_base_item.present? && dyeworks_base_item.currently_in_mall?
|
||||
end
|
||||
|
||||
# Whether this is a Dyeworks item that can be dyed in the NC Mall ~right now,
|
||||
# either at any time or as a limited-time event. (Owls tracks this, not us!)
|
||||
def dyeworks_dyeable?
|
||||
dyeworks_permanent? || dyeworks_limited?
|
||||
end
|
||||
|
||||
# Whether this is one of the few Dyeworks items that can be dyed in the NC
|
||||
# Mall at any time, rather than as part of a limited-time event. (Owls tracks
|
||||
# this, not us!)
|
||||
|
@ -28,18 +40,6 @@ class Item
|
|||
nc_trade_value.value_text.match?(DYEWORKS_LIMITED_PATTERN)
|
||||
end
|
||||
|
||||
# Whether this is a Dyeworks item that can be dyed in the NC Mall ~right now,
|
||||
# either at any time or as a limited-time event. (Owls tracks this, not us!)
|
||||
def dyeworks_dyeable?
|
||||
dyeworks_permanent? || dyeworks_limited?
|
||||
end
|
||||
|
||||
# Whether this is a Dyeworks item whose base item can currently be purchased
|
||||
# in the NC Mall, then dyed via Dyeworks. (Owls tracks this last part!)
|
||||
def dyeworks_buyable?
|
||||
dyeworks_base_buyable? && dyeworks_dyeable?
|
||||
end
|
||||
|
||||
DYEWORKS_NAME_PATTERN = %r{
|
||||
^(
|
||||
# Most Dyeworks items have a colon in the name.
|
||||
|
|
Loading…
Reference in a new issue