Filter suggestions

Suggestions and Ideas to improve the in-game deck editor
Post Reply
mplat
Posts: 8
Joined: Mon Dec 14, 2009 12:41 pm

Filter suggestions

Post by mplat » Tue Feb 09, 2010 7:45 am

I'm really enjoying the new filtering system, it makes the shop and the deck editor so much easier to use.

Could it be possible to still add filtering by subtype, for example when you are building a goblin deck you could see a list of all the goblin creature cards easily? I dont mean a huge list where you could select all the different subtypes but a possibility to type in the subtype by yourself. Or filtering by name of the card where you could type any part of the name, for example "raging" would find both "Raging Goblin" and "Raging Gorilla" whereas "rag" would find both of those and "Primal Rage" as well. To take this idea even further, it would also be nice to be able to save these filters by your own keywords so you would not have to type them again every time.

In any case, I was wishing for something like the filter system for a long time. Great job!

wololo
Site Admin
Posts: 3727
Joined: Wed Oct 15, 2008 12:42 am
Location: Japan

Re: Filter suggestions

Post by wololo » Tue Feb 09, 2010 8:11 am

The ideas you mention seem doable except finding "Primal Rage" based on "rag".
We can easily find cards that begin with "rag", but not ones that contain "rag".

The cards database is a simple hash and doing full text search would simply kill the performance.
Building an index is also out of the question unless we switch to something like SQLLite which is not going to happen in the months to come.

Edit: and I +1 the idea of searching by subtypes. I even think a list would be doable...

Jeck
Posts: 71
Joined: Mon Aug 17, 2009 11:53 pm
Location: Snow-covered forest

Re: Filter suggestions

Post by Jeck » Tue Feb 09, 2010 2:19 pm

Subtypes are a good idea, I'm on it. I think a list is actually preferable (it presents all available options so I can learn about new subtypes), so that's what I'll be doing.

Psyringe
Posts: 1163
Joined: Mon Aug 31, 2009 10:53 am

Re: Filter suggestions

Post by Psyringe » Tue Feb 09, 2010 2:40 pm

Since r1823, type= and subtype= lines of all cards should be correct (i.e. there are no supertypes or co-types stuffed into the subtype= line, which was necessary for a while because the parser wouldn't recognize them otherwise). This means:

- We know all types (see official rules)
- Anything that appears in a type= line and is not a type, is a supertype
- Anything that appears in a subtype= line is a subtype of at least one of the types mentioned in the type= line

With this information, we could map subtypes to types purely based on how they occur in the data (i.e. there's no need for external subtype lists or mappings). This could be useful for implementing Shapeshifters (which by definition have all creature subtypes, so to implement them, we need to know what's a creature subtype and what isn't). I don't know if you want to go this way (it's still a lot of work for a rather small number of cards), but thought I'd mention it ijn case you can make use of the information. :)

wololo
Site Admin
Posts: 3727
Joined: Wed Oct 15, 2008 12:42 am
Location: Japan

Re: Filter suggestions

Post by wololo » Tue Feb 09, 2010 11:12 pm

we already have a list containing all the types. It could be easily browsed. With a hardcoded list of types+supertypes, you get the list of subtypes. I'm pretty sure Jeck knows about this list ist Subtypes::suptypesList or something like that...

mickey_brown
Posts: 217
Joined: Sun Sep 13, 2009 6:32 am

Re: Filter suggestions

Post by mickey_brown » Wed Dec 08, 2010 1:14 am

Why no block filter?
All of the _cards.dat have a block= field in them.
Would be pretty convenient considering when you build a deck that follows the actual rules you choose a block to build from. Would also make it easier since you don't have to remember what the 3 letter name for each set is.

Post Reply