It is currently 24 Apr 2024, 22:52
   
Text Size

Forge version 1.5.22

Post MTG Forge Related Programming Questions Here

Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins

Forge version 1.5.22

Postby Chris H. » 04 Jul 2014, 16:59

Tentative target release date: Friday July 18 2014.
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: Forge version 1.5.22

Postby drdev » 17 Jul 2014, 03:44

I've added a new "Group by" option to CardManagers on both the desktop and mobile games: "Set". You can now group cards by set, with the sets being sorted in reverse chronological order. As part of this, I've also fixed it so the headers for groups with no cards in them will now be hidden instead of appearing with a "(0)" after them. Otherwise, there would be far too many empty group headers displayed when grouping by set.

SetGroups.png

Since the groups are collapsible, this can allow ItemManagers to work somewhat similar to the old "Binder View" in MTGO (may it rest in peace).

With that, are there any other group by or pile by options people would like to see?

Thanks.
-Dan
drdev
Programmer
 
Posts: 1958
Joined: 27 Jul 2013, 02:07
Has thanked: 189 times
Been thanked: 565 times

Re: Forge version 1.5.22

Postby KrazyTheFox » 17 Jul 2014, 16:26

drdev wrote:With that, are there any other group by or pile by options people would like to see?
I can't think of any other grouping options I'd want off the top of my head, but you did remind me that I wanted to add boolean expressions to the filters. I'm hoping I can complete that by tomorrow; it seems to be going well so far.

Edit: I've also added an option to use text search to search card mana costs. I'm hoping to make something like the following possible:

Code: Select all
{w}{w} && ({g}{g} || ({u}{u} && {r}{r}))
Which would find all cards that cost two white mana and either two green mana or two blue and two red mana.
User avatar
KrazyTheFox
Programmer
 
Posts: 725
Joined: 18 Mar 2014, 23:51
Has thanked: 66 times
Been thanked: 226 times

Re: Forge version 1.5.22

Postby friarsol » 17 Jul 2014, 16:55

If we're going to have a release tomorrow, we should try to update our draft rankings for M15. I played a draft yesterday where I picked up a Soul of Innistrad as like the 6th or 7th pick in a pack. While it may not be the best of those creatures, being able to suicide high powered creatures into a stalemate to remove blockers and then quickly revive them, should not be picked that late in the draft.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Forge version 1.5.22

Postby KrazyTheFox » 17 Jul 2014, 21:53

In the interest of time, I've decided to force all search values to be in quotation marks. You can escape them with your typical backslash in case you want to search for a quotation mark in text. There's still a few show-stopping bugs, but the proof of concept is sound:

Filters.png


Filters2.png


Right now it bugs out with more than two search terms and runs into an infinite loop, but this should be relatively easy to fix. I fully expect the feature to be available tomorrow for release. I'll work on improving it (removing the quote requirement, not operations, etc) for the following release.

Edit: I was way closer than I thought I was. I'm going to commit this in a few minutes, so if y'all could try and break if for me that'd be lovely.

Filters3.png


Filters4.png
User avatar
KrazyTheFox
Programmer
 
Posts: 725
Joined: 18 Mar 2014, 23:51
Has thanked: 66 times
Been thanked: 226 times

Re: Forge version 1.5.22

Postby drdev » 17 Jul 2014, 23:59

I'm confused. Are you saying we need to manually type quotation marks for search to work now? If so, that's not desirable. Quotation marks should only be used to group text together than should not be parsed as an expression.
drdev
Programmer
 
Posts: 1958
Joined: 27 Jul 2013, 02:07
Has thanked: 189 times
Been thanked: 565 times

Re: Forge version 1.5.22

Postby friarsol » 18 Jul 2014, 00:07

Yea, maybe this can wait till after release so things like that can be ironed out? We should strive not to have last minute features before release so things aren't completely broken and they have time to be tested by the svn users.
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Forge version 1.5.22

Postby KrazyTheFox » 18 Jul 2014, 02:35

drdev wrote:I'm confused. Are you saying we need to manually type quotation marks for search to work now? If so, that's not desirable. Quotation marks should only be used to group text together than should not be parsed as an expression.
Oh, no. Goodness, no. Search still functions exactly how it did before I added the changes; nothing is different about that. What has changed is if you happen to be using the boolean expression feature (it auto-detects || or && — nothing runs unless those are detected), then the search terms for the expression itself must be in quotation marks.

friarsol wrote:Yea, maybe this can wait till after release so things like that can be ironed out? We should strive not to have last minute features before release so things aren't completely broken and they have time to be tested by the svn users.
I've thoroughly tested it on my own and am confident that there aren't any bugs (and certainly not any that affect other areas of the program). I just may have missed a minor bug somewhere. I can guarantee that the regular search works 100% as it has been and that any bugs that might arise would affect the boolean searches only. I completely separated all the logic for that specific reason; only if it detects the presence of AND or OR operators does it even attempt to run it through the parser.

If you'd still prefer I removed the feature and tossed it in the next release, I understand and can do so. Provided a build isn't published early in the morning, I'll be awake early enough to revert the feature if need be.
User avatar
KrazyTheFox
Programmer
 
Posts: 725
Joined: 18 Mar 2014, 23:51
Has thanked: 66 times
Been thanked: 226 times

Re: Forge version 1.5.22

Postby friarsol » 18 Jul 2014, 03:04

KrazyTheFox wrote:If you'd still prefer I removed the feature and tossed it in the next release, I understand and can do so. Provided a build isn't published early in the morning, I'll be awake early enough to revert the feature if need be.
Ah ok, that sounds like it should be alright. I just get nervous around release especially when new features pop out of nowhere. (It reminds me too much of the things I have to fight off in my day job :lol: )
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Forge version 1.5.22

Postby drdev » 18 Jul 2014, 07:57

KrazyTheFox wrote:
drdev wrote:I'm confused. Are you saying we need to manually type quotation marks for search to work now? If so, that's not desirable. Quotation marks should only be used to group text together than should not be parsed as an expression.
Oh, no. Goodness, no. Search still functions exactly how it did before I added the changes; nothing is different about that. What has changed is if you happen to be using the boolean expression feature (it auto-detects || or && — nothing runs unless those are detected), then the search terms for the expression itself must be in quotation marks.

friarsol wrote:Yea, maybe this can wait till after release so things like that can be ironed out? We should strive not to have last minute features before release so things aren't completely broken and they have time to be tested by the svn users.
I've thoroughly tested it on my own and am confident that there aren't any bugs (and certainly not any that affect other areas of the program). I just may have missed a minor bug somewhere. I can guarantee that the regular search works 100% as it has been and that any bugs that might arise would affect the boolean searches only. I completely separated all the logic for that specific reason; only if it detects the presence of AND or OR operators does it even attempt to run it through the parser.

If you'd still prefer I removed the feature and tossed it in the next release, I understand and can do so. Provided a build isn't published early in the morning, I'll be awake early enough to revert the feature if need be.
I'm not sure if it worked before, but I can't seem to use quotes to search for multiple words where I don't get matches that contain one or both words that aren't one after the other. I want searching for "sacrifice a creature" with quotes to not return all cards with either "sacrifice" or "creature" in their text.
drdev
Programmer
 
Posts: 1958
Joined: 27 Jul 2013, 02:07
Has thanked: 189 times
Been thanked: 565 times

Re: Forge version 1.5.22

Postby KrazyTheFox » 18 Jul 2014, 12:17

drdev wrote:I'm not sure if it worked before, but I can't seem to use quotes to search for multiple words where I don't get matches that contain one or both words that aren't one after the other. I want searching for "sacrifice a creature" with quotes to not return all cards with either "sacrifice" or "creature" in their text.
Unfortunately that wasn't/isn't a feature of the search function. The current rules are to replace all commas with spaces and then split the search string by spaces with each word getting passed through the search functions. There's a lot of improvements that can still be made in this part of the program, such as allowing what you want quotes to do.


This is the code responsible for processing the search box text:
Code: Select all
String[] splitText = text.replaceAll(",", "").replaceAll("  ", " ").split(" ");

for (String s : splitText) {
            List<Predicate<CardRules>> subands = new ArrayList<Predicate<CardRules>>();

            if (inName) { subands.add(CardRulesPredicates.name(StringOp.CONTAINS_IC, s));       }
            if (inType) { subands.add(CardRulesPredicates.joinedType(StringOp.CONTAINS_IC, s)); }
                        if (inText) { subands.add(CardRulesPredicates.rules(StringOp.CONTAINS_IC, s));      }
                        if (inCost) { subands.add(CardRulesPredicates.cost(StringOp.CONTAINS_IC, s));       }

            terms.add(Predicates.or(subands));
        }
Predicate<CardRules> textFilter = invert ? Predicates.not(Predicates.or(terms)) : Predicates.and(terms);

        return Predicates.compose(textFilter, PaperCard.FN_GET_RULES);
User avatar
KrazyTheFox
Programmer
 
Posts: 725
Joined: 18 Mar 2014, 23:51
Has thanked: 66 times
Been thanked: 226 times

Re: Forge version 1.5.22

Postby Chris H. » 18 Jul 2014, 18:31

I plan to do the beta build and deploy in about five or six hours today.

While it would be nice to have the draft rankings ready to go I suspect that we will have to wait until Asepetci gets around to it. :)

And it looks like the filters have been reverted for now.
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times

Re: Forge version 1.5.22

Postby KrazyTheFox » 18 Jul 2014, 18:35

Chris H. wrote:And it looks like the filters have been reverted for now.
Different filters. :P Android had a different behavior when selecting card filters, which is now the same as the desktop version while a better solution is found.

It also looks like friarsol's already added some (preliminary?) draft rankings for M15.
User avatar
KrazyTheFox
Programmer
 
Posts: 725
Joined: 18 Mar 2014, 23:51
Has thanked: 66 times
Been thanked: 226 times

Re: Forge version 1.5.22

Postby friarsol » 18 Jul 2014, 18:41

Chris H. wrote:While it would be nice to have the draft rankings ready to go I suspect that we will have to wait until Asepetci gets around to it. :)
Oh I figured out the format he used and did it last night. There's a small issue with M15 booster generation which is related to the Conspiracy booster generation I had been working, so I'll commit that after the release (probably on Sunday night) Nothing too terrible, just cards that appear in the demo decks, that don't appear in boosters can currently show up in Forge boosters.


I probably won't be around tonight when that gets posted, so assuming no new card scripts come in before Chris releases, feel free to use this as the Forge Set Data:

Distinct Stats
Implemented (Missing) / Total = Percentage Implemented
14017 (188) / 14205 = 98.68 %

Missing Cards(188) | Open
Advantageous Proclamation
Aether Searcher
Agent of Acquisitions
Alter Reality
Arboria
Arcum's Whistle
Artificial Evolution
Autumn Willow
Aven Soulgazer
Backdraft
Backup Plan
Balduvian Shaman
Balduvian Warlord
Barbarian Guides
Barbed Wire
Bosium Strip
Brago's Favor
Bronze Tablet
Brutal Suppression
Burning-Eye Zubera
Butcher Orgg
Camouflage
Canal Dredger
Captain's Maneuver
Celestial Convergence
Chain of Acid
Chain of Silence
Chain of Smog
Chaos Orb
Cliffside Market
Coalition Flag
Coalition Honor Guard
Cogwork Grinder
Cogwork Librarian
Cogwork Spy
Cogwork Tracker
Cover of Winter
Crystal Spray
Cultural Exchange
Damping Engine
Deal Broker
Desolation
Divine Deflection
Divine Intervention
Double Stroke
Drain Power
Drought
Ekundu Cyclops
Elkin Lair
Emblazoned Golem
Equinox
Errant Minion
Ertai's Meddling
Fade Away
Falling Star
False Orders
Fasting
Fatespinner
Feed the Machine
Firestorm Phoenix
Flaming Gambit
Flash Foliage
General Jarkeld
Ghostly Flame
Giant Albatross
Giant Oyster
Glamerdye
Glen Elendra
Glimmervoid Basin
Glyph of Delusion
Glyph of Reincarnation
Goblin Artisans
Grinning Totem
Harm's Way
Hazduhr the Abbot
Hidden Retreat
Honorable Passage
I Bask in Your Silent Awe
Ice Cauldron
Illusionary Mask
Illusionary Terrain
Immediate Action
Imprison
Infernal Denizen
Infinite Authority
Iterative Analysis
Karador, Ghost Chieftain
Kilnspire District
Kor Chant
Kor Dirge
Krovikan Vampire
Lava Burst
Liege of the Hollows
Lore Seeker
Lurking Automaton
Maelstrom Archangel Avatar
Magical Hack
Magnetic Web
Malfegor Avatar
Mana Cache
Martyrdom
May Civilization Collapse
Meddle
Mercenaries
Merseine
Mind Bend
Morphic Tide
Muzzio's Preparations
My Crushing Masterstroke
Nacatl War-Pride
Nature Shields Its Own
North Star
Nova Pentacle
Ogre Enforcer
Okk
Oracle en-Vec
Orcish Conscripts
Paliano, the High City
Panglacial Wurm
Peace Talks
Pillar Tombs of Aku
Piracy
Plague of Vermin
Power Leak
Power Play
Preferred Selection
Primitive Justice
Psychic Battle
Psychic Theft
Pygmy Hippo
Pyramids
Quicksilver Elemental
Raging River
Raiding Party
Razia, Boros Archangel
Rebirth
Reflect Damage
Refraction Trap
Reverberation
Rock Hydra
Rushing-Tide Zubera
Samite Ministration
Scarred Puma
Season of the Witch
Secret Summoning
Secrets of Paradise
Sentinel Dispatch
Seraph
Shadowbane
Shahrazad
Shaman's Trance
Shared Fate
Shining Shoal
Silhouette
Sleight of Mind
Sorrow's Path
Soul Echo
Spectra Ward
Spectral Shift
Spy Network
Stand or Fall
Standard Bearer
Stensia
Street Savvy
Surrender Your Thoughts
Swirl the Mists
Taste of Paradise
Tawnos's Coffin
Tempest Efreet
The Fate of the Flammable
Three Wishes
Timmerian Fiends
Torrent of Lava
Trait Doctoring
Unexpected Potential
Urza's Miter
Viashino Bey
Volrath's Shapeshifter
War's Toll
Whim of Volrath
Whippoorwill
Whispergear Sneak
Wishmonger
Word of Command
World at War
Worldknit
Worms of the Earth
Ydwen Efreet


Set Stats | Open
Set: Implemented (Missing) / Total = Percentage Implemented
Guildpact: 165 (0) / 165 = 100.0%
Dark Ascension: 158 (0) / 158 = 100.0%
Journey into Nyx: 165 (0) / 165 = 100.0%
Theros: 234 (0) / 234 = 100.0%
Born of the Gods: 165 (0) / 165 = 100.0%
New Phyrexia: 170 (0) / 170 = 100.0%
Planeshift: 143 (0) / 143 = 100.0%
Scourge: 143 (0) / 143 = 100.0%
Return to Ravnica: 254 (0) / 254 = 100.0%
Portal Three Kingdoms: 170 (0) / 170 = 100.0%
Conflux: 145 (0) / 145 = 100.0%
Portal: 200 (0) / 200 = 100.0%
Starter 2000: 52 (0) / 52 = 100.0%
Darksteel: 165 (0) / 165 = 100.0%
Duel Decks: Jace vs. Vraska: 76 (0) / 76 = 100.0%
Morningtide: 150 (0) / 150 = 100.0%
Lorwyn: 286 (0) / 286 = 100.0%
Innistrad: 254 (0) / 254 = 100.0%
Urza's Destiny: 143 (0) / 143 = 100.0%
Modern Event Deck 2014: 26 (0) / 26 = 100.0%
Zendikar: 234 (0) / 234 = 100.0%
Shards of Alara: 234 (0) / 234 = 100.0%
Magic 2011: 234 (0) / 234 = 100.0%
Magic 2013: 234 (0) / 234 = 100.0%
Magic 2012: 234 (0) / 234 = 100.0%
Magic 2014 Core Set: 234 (0) / 234 = 100.0%
Modern Masters: 229 (0) / 229 = 100.0%
Gatecrash: 249 (0) / 249 = 100.0%
Commander 2013 Edition: 341 (0) / 341 = 100.0%
Scars of Mirrodin: 234 (0) / 234 = 100.0%
Promo set for Gatherer: 27 (0) / 27 = 100.0%
Time Spiral: 286 (0) / 286 = 100.0%
Mirrodin Besieged: 150 (0) / 150 = 100.0%
Legions: 145 (0) / 145 = 100.0%
Alara Reborn: 145 (0) / 145 = 100.0%
Tenth Edition: 367 (1) / 368 = 99.73%
Ninth Edition: 343 (1) / 344 = 99.71%
Odyssey: 334 (1) / 335 = 99.7%
Urza's Saga: 334 (1) / 335 = 99.7%
Classic Sixth Edition: 334 (1) / 335 = 99.7%
Seventh Edition: 334 (1) / 335 = 99.7%
Vintage Masters: 324 (1) / 325 = 99.69%
Magic: The Gathering-Commander: 302 (1) / 303 = 99.67%
Ravnica: City of Guilds: 290 (1) / 291 = 99.66%
Champions of Kamigawa: 290 (1) / 291 = 99.66%
Shadowmoor: 285 (1) / 286 = 99.65%
Magic 2015 Core Set: 268 (1) / 269 = 99.63%
Avacyn Restored: 233 (1) / 234 = 99.57%
Magic 2010: 233 (1) / 234 = 99.57%
Rise of the Eldrazi: 232 (1) / 233 = 99.57%
Future Sight: 179 (1) / 180 = 99.44%
Eventide: 179 (1) / 180 = 99.44%
Eighth Edition: 340 (2) / 342 = 99.42%
Mercadian Masques: 333 (2) / 335 = 99.4%
Betrayers of Kamigawa: 164 (1) / 165 = 99.39%
Fifth Dawn: 164 (1) / 165 = 99.39%
Planar Chaos: 164 (1) / 165 = 99.39%
Starter 1999: 157 (1) / 158 = 99.37%
Dragon's Maze: 155 (1) / 156 = 99.36%
Portal Second Age: 154 (1) / 155 = 99.35%
Worldwake: 144 (1) / 145 = 99.31%
Judgment: 142 (1) / 143 = 99.3%
Nemesis: 142 (1) / 143 = 99.3%
Chronicles: 115 (1) / 116 = 99.14%
Mirrodin: 288 (3) / 291 = 98.97%
Fifth Edition: 429 (5) / 434 = 98.85%
Tempest: 331 (4) / 335 = 98.81%
Weatherlight: 165 (2) / 167 = 98.8%
Saviors of Kamigawa: 163 (2) / 165 = 98.79%
Urza's Legacy: 141 (2) / 143 = 98.6%
Stronghold: 141 (2) / 143 = 98.6%
Exodus: 141 (2) / 143 = 98.6%
Torment: 141 (2) / 143 = 98.6%
Invasion: 330 (5) / 335 = 98.51%
Dissension: 177 (3) / 180 = 98.33%
Revised Edition: 291 (5) / 296 = 98.31%
Vanguard: 104 (2) / 106 = 98.11%
Fourth Edition: 361 (7) / 368 = 98.1%
Coldsnap: 152 (3) / 155 = 98.06%
Fallen Empires: 100 (2) / 102 = 98.04%
Alliances: 141 (3) / 144 = 97.92%
Planechase: 187 (4) / 191 = 97.91%
Prophecy: 140 (3) / 143 = 97.9%
Planechase 2012 Edition: 173 (4) / 177 = 97.74%
Onslaught: 327 (8) / 335 = 97.61%
Time Spiral "Timeshifted": 118 (3) / 121 = 97.52%
Mirage: 326 (9) / 335 = 97.31%
Apocalypse: 138 (5) / 143 = 96.5%
Archenemy: 184 (7) / 191 = 96.34%
Unlimited Edition: 281 (11) / 292 = 96.23%
Limited Edition Beta: 281 (11) / 292 = 96.23%
Limited Edition Alpha: 279 (11) / 290 = 96.21%
Arabian Nights: 75 (3) / 78 = 96.15%
The Dark: 114 (5) / 119 = 95.8%
Ice Age: 357 (16) / 373 = 95.71%
Homelands: 110 (5) / 115 = 95.65%
Antiquities: 81 (4) / 85 = 95.29%
Visions: 159 (8) / 167 = 95.21%
Legends: 294 (16) / 310 = 94.84%
Magic: The Gathering—Conspiracy: 184 (26) / 210 = 87.62%


Standard Stats | Open
Implemented (Missing) / Total = Percentage Implemented
1651 (2) / 1653 = 99.88 %

Missing (2):
Spectra Ward
Trait Doctoring


Modern Stats | Open
Implemented (Missing) / Total = Percentage Implemented
8117 (27) / 8144 = 99.67 %
friarsol
Global Moderator
 
Posts: 7593
Joined: 15 May 2010, 04:20
Has thanked: 243 times
Been thanked: 965 times

Re: Forge version 1.5.22

Postby Chris H. » 19 Jul 2014, 01:27

Today's build and deploy completed successfully. :)
User avatar
Chris H.
Forge Moderator
 
Posts: 6320
Joined: 04 Nov 2008, 12:11
Location: Mac OS X Yosemite
Has thanked: 644 times
Been thanked: 643 times


Return to Developer's Corner

Who is online

Users browsing this forum: No registered users and 66 guests


Who is online

In total there are 66 users online :: 0 registered, 0 hidden and 66 guests (based on users active over the past 10 minutes)
Most users ever online was 4143 on 23 Jan 2024, 08:21

Users browsing this forum: No registered users and 66 guests

Login Form