Sha256: 2c1535b609f243b5900de9e5fee2964620db4ae1f5af74eb19c6e7a9841d44d1
Contents?: true
Size: 354 Bytes
Versions: 76
Compression:
Stored size: 354 Bytes
Contents
module Ish::PremiumItem def self.included base base.send :field, :premium_tier, type: Integer, default: 0 # how many stars need to spend, to get access? 0 = free base.send :has_many, :premium_purchases, class_name: '::Gameui::PremiumPurchase', as: :item end def is_premium premium_tier > 0 end def premium?; is_premium; end end
Version data entries
76 entries across 76 versions & 1 rubygems