Philiater
12-14-2012, 06:01 PM
Spent awhile trying to stumble my way through this one myself, but failed.
any way to make sorter put the empty jars and the jars with contents in separate categories?
Drafix already did the coding for me but was wondering if it could be integrated (lines 98-104 of current version):
else
item_name = item.full_name.sub(/containing (.*)$/) { "(#{$1})" }
if item_name.index('(')
category_name = 'jar with contents'
sorted_contents[category_name] ||= Hash.new
end
end
That way my sack looks like this:
jar with contents (16): a rosy pink glass beaker (essences of air), a frosted glass beaker (crystal cores), a light tan glass beaker (elemental cores), a twisted purple glass bottle (n'ayanad crystals), a turquoise glass beaker (s'ayanad crystals), a charcoal glass beaker (t'ayanad crystals), an umber square-necked bottle (ayanad crystals), an olive green glass beaker (radiant crimson essence dust), an azure flecked glass bottle (glowing violet motes of essence), a kelyn-rimmed amber glass jar (essences of fire), a laje-rimmed lavender glass jar (pristine sprite's hairs), a gold-rimmed carmine glass jar (stargazer lilies), a tall gold-streaked bottle (glimmering blue essence shards), a rough square glass jar (radiant crimson essence shards), an etched cubical glass jar (green malachite stones), a saffron yellow glass beaker (essences of water).
jar (14): a deep red glass beaker, a dark blue glass beaker, a dappled orange glass bottle, a lime green wavy glass bottle, a slender multicolored bottle, an iridescent citrine glass bottle, a striped rainbow glass bottle, a dark hexagonal glass jar, a small round glass jar, a grooved pyramidal glass jar, a short ovoid glass jar, a brass-rimmed crimson glass jar, a tall prismatic glass jar, a smoky octagonal glass jar.
maybe the second category should be "empty jar"? whatever just tossing it out there.
any way to make sorter put the empty jars and the jars with contents in separate categories?
Drafix already did the coding for me but was wondering if it could be integrated (lines 98-104 of current version):
else
item_name = item.full_name.sub(/containing (.*)$/) { "(#{$1})" }
if item_name.index('(')
category_name = 'jar with contents'
sorted_contents[category_name] ||= Hash.new
end
end
That way my sack looks like this:
jar with contents (16): a rosy pink glass beaker (essences of air), a frosted glass beaker (crystal cores), a light tan glass beaker (elemental cores), a twisted purple glass bottle (n'ayanad crystals), a turquoise glass beaker (s'ayanad crystals), a charcoal glass beaker (t'ayanad crystals), an umber square-necked bottle (ayanad crystals), an olive green glass beaker (radiant crimson essence dust), an azure flecked glass bottle (glowing violet motes of essence), a kelyn-rimmed amber glass jar (essences of fire), a laje-rimmed lavender glass jar (pristine sprite's hairs), a gold-rimmed carmine glass jar (stargazer lilies), a tall gold-streaked bottle (glimmering blue essence shards), a rough square glass jar (radiant crimson essence shards), an etched cubical glass jar (green malachite stones), a saffron yellow glass beaker (essences of water).
jar (14): a deep red glass beaker, a dark blue glass beaker, a dappled orange glass bottle, a lime green wavy glass bottle, a slender multicolored bottle, an iridescent citrine glass bottle, a striped rainbow glass bottle, a dark hexagonal glass jar, a small round glass jar, a grooved pyramidal glass jar, a short ovoid glass jar, a brass-rimmed crimson glass jar, a tall prismatic glass jar, a smoky octagonal glass jar.
maybe the second category should be "empty jar"? whatever just tossing it out there.