*Author

PuppyChow

  • Guest
How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg57965#msg57965
« on: April 23, 2010, 04:48:02 am »
I'm curious, because I'm planning this java application (applet if I can figure it out >_>) that will allow you to imput a deck's code and get some advice on it.

But in order to do that my program needs to recognize the card, so can someone help out so I don't have to write "If code == 4uf then card = whatever" for every single card?

*Okay, now this is about my proposed project. Do you guys think it's worth it?*

This will probably take me a long time anyway before it gets any semblance of working order, since it's hard to code something that requires lots of decisions get as precise as possible. Relatively simple things I'm considering for beta:

-Quanta you generate
-Deck size (hourglasses factored in)

And eventually...
-Figure out what the deck's goal is...
-Deck out... 60 cards or Eternity + cheap creature & time quanta?
-Otherwise, damage versus control (I'm thinking a ratio)
-Suggesting changes based on cards in a deck (if a deck has epinephrines, calculate if any creatures can get 3 or 7 attack based on cards in deck)
-Basically, making it really complex

Update: I'm going ahead with the project, and have realized that I need to do each card separately anyway >_<. So it may take awhile; bear with me.

UPDATE
*Note: This is entirely optional; I won't hate you if you don't and your benefit from doing this will be rather small. It would be nice though :)*
*Note: If you have a question, ask. Don't make an assumption. It doesn't have to be perfect, but it will make debugging a whole lot less messier*

I haven't had much time to work on my project (the deck feedback generator), but the betas mostly done except for an essential part:

Connecting a card's code to the card.

So I'm asking you guys to do your element's code for me. (Note: Aether is done). It's pretty easy, but it may take an hour or so. If you do it, I'll mention your name on the program and give ya serm karma :D. If you don't, I'll end up doing it myself, but it'll take awhile.

How to do it:

1) Open up the trainer
2) Get 1 upped and 1 unupped of every card of your element. Make a deck.
3) Get the deck code.
4) Start writing (use a text document...). How to write the code...
---------a) Write "else if (code.equals("
---------b) Write the code itself in "..."s
---------c) Close both parentheses. So far: if (code.equals("f5h"))
---------d) Write "cards[c] = new Card("namehere","type",cost,"element",attack,defense,"ability",abilitycost,"abilityelement","passiveability"
---------e) Here it gets tricky. If the card is purely for attacking or increasing attack (a morning glory, a dragon, adrenaline, blessing) add on a ,true); and if it is for defense or control add on a ,false); (like miracle, lightning, heal, emphatic bond, liquid shadow). If it could be used both ways, just add ); (like immolation, pillars, fire bolt, rage elixir).
---------e) Repeat for all cards, upped and unupped.
5) Copy-pasta here for me!

Examples of some odd cards:

Code: [Select]
else if (card.equals("xxx")) cards[c] = new Card("brimstoneeater","creature",1,"fire",2,1,"generate",0,"fire","none",true);
This one is odd since it has a skill mostly only pillars have - "generate". Though it's actually a passive ability, here it must be made into an active ability with 0 cost and an element "fire" to show that it generates FIRE quantum. Do this with creatures like Ray of Light, Damselfly, etc. Since it is for attacking only (generates some quantum too but that's neutral), it gets true added on to it.

Code: [Select]
else if (card.equals("xxx")) cards[c] = new Card("lightning","spell",2,"aether",0,0,"lightning",0,"none","none",false);
As you can see, spells permanents and shields just get ,0,0 for attack and defense, and the ability cost for spells is 0 since it is paid for by the card cost. It gets false because it is almost always used for control.

Code: [Select]
else if (card.equals("xxx")) cards[c] = new Card("animateweapon","spell",1,"other",0,0,"animate",0,"none","none");
It is an other element since it costs other quantum, and since it can be used for speed (glories) or control (pulvies), it gets neither true nor false.

Code: [Select]
else if (card.equals("xxx")) cards[c] = new Card("pest","creature",2,"dark",0,4,"burrow",1,"earth","suck",false);
This is just a card that has everything so you can check it out. False because pest steals quantum and really has no other use other than generating quantum (something neutral).



*Notes:
-This is purely quantitative, so cards that cost neutral quantum (ie animate weapon) are an element of other, not air.
-Names have no spaces and no capital letters
-Types of cards are permanent, creature, weapon, shield, and spell.
-Weapons get their flying weapon stats in the attack/defense slot.
-Don't forget ; at the end of each card!
-Don't change name for cards that are the same name upped and unupped (ie bonewall and bonewall).


List of Abilities:

none

Shields
1block, 2block, 3block, bones, dissupped, diss, dusk, fireshield, fog, hope, permafrost, phase, procrastination, reflect, thorn

Other
(listed in order of element)
fractal, lightning, lobotomize, immortalize, PU
snipe, dive, generate, generate+1, ignite, unstable, animate, thunderstorm, lightbio, firebio, queen, queenelite
steal, vampire, eclipse, nightfall, siphon, shadow, suck
aflatoxin, plague, 2poison, 3poison, poison, scavenger, boneyard, infect, graveyard, venom
evolve, stoneskin, PA, 3armor, 6armor, burrow, quicksand, petrify
antimatter, mutate, impmutate, nova, snova, lycan, seed, power, butterfly, scramble
rebirth, growth, ablaze, rage, berserk, fahrenheit, firelance, immolation, cremation, firestorm, destroy
momentum, gpull, blackhole, devour
20heal, photosynthesis, bond, adrenaline
10heal, heal, bless, miracle, luciferin
hasten, precognition, fate, dejavu, rewind
purify, freeze, icelance, tears, flood
gavel, 20max, 5heal, 3generate

If you have any questions which ability is which, just ask. But use THESE EXACT LETTERS!


Offline Planplan

  • Jr. Member
  • **
  • Posts: 130
  • Country: fr
  • Reputation Power: 8
  • Planplan is a Spark waiting for a buff.
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg57994#msg57994
« Reply #1 on: April 23, 2010, 08:22:51 am »
I don't know if it could help you, and maybe you already know that, but the cards codes are in base 32.

I just re-found something I saw a long time ago, maybe it could help you (by throwing all in a database or something).
http://elementsthegame.wikia.com/wiki/User:Chriskang/Sandbox/8

Good luck in you project, might be useful ! :)

Scaredgirl

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg57999#msg57999
« Reply #2 on: April 23, 2010, 08:41:53 am »
Very cool project. If you make it smarter then a human, we don't have to do any deck building at all. :)

Estimating optimal number of Pillars would probably be the best part of this tool and it would be easy to code because all you need really is the number of cards and total cost. All that advanced might be a bit more difficult. Just imagine all the hundreds of cards with all kinds of different abilities.

Kael Hate

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58029#msg58029
« Reply #3 on: April 23, 2010, 12:17:58 pm »
PM me your Email and I'll send you my basic Deck tool in Excel.

Scaredgirl

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58032#msg58032
« Reply #4 on: April 23, 2010, 12:34:30 pm »
PM me your Email and I'll send you my basic Deck tool in Excel.
I've been meaning to ask this..

You have made this tool in Excel but you don't seem to want to make it public. Instead you only give it to veteran players, who I assume you see as the "elite". Why not just make it public? Are you worried that some newbie is going to use it for world domination? :)

Kael Hate

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58036#msg58036
« Reply #5 on: April 23, 2010, 12:44:12 pm »
PM me your Email and I'll send you my basic Deck tool in Excel.
I've been meaning to ask this..

You have made this tool in Excel but you don't seem to want to make it public. Instead you only give it to veteran players, who I assume you see as the "elite". Why not just make it public? Are you worried that some newbie is going to use it for world domination? :)
I don't want to spend 10 years explaining it to everyman and his dog.
If its given to a smaller group of people then I can build on it with less chance of conflicting interest and save time responding only to persons who will actually use the information. (A productive form of Elitism)

Scaredgirl

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58037#msg58037
« Reply #6 on: April 23, 2010, 12:52:28 pm »
PM me your Email and I'll send you my basic Deck tool in Excel.
I've been meaning to ask this..

You have made this tool in Excel but you don't seem to want to make it public. Instead you only give it to veteran players, who I assume you see as the "elite". Why not just make it public? Are you worried that some newbie is going to use it for world domination? :)
I don't want to spend 10 years explaining it to everyman and his dog.
If its given to a smaller group of people then I can build on it with less chance of conflicting interest and save time responding only to persons who will actually use the information.
Well, that's where the forums come in. All you need to do is explain it once. If you explain is fully, and a person still doesn't get it, he was never meant to use it.

What's this "conflicting interest"? We are still talking about an Excel file, right?

I have to say that this once again sounds like a situation where you want to personally decide who is "elite" and who is "noob", dividing the community into two groups. In case you haven't noticed, most people here make their codes, files, etc. public, which is exactly how it should be in an open community. Keeping an Excel file a "secret" sounds pretty ridiculous to me.

Kael Hate

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58053#msg58053
« Reply #7 on: April 23, 2010, 01:27:50 pm »
Well, that's where the forums come in. All you need to do is explain it once. If you explain is fully, and a person still doesn't get it, he was never meant to use it.

What's this "conflicting interest"? We are still talking about an Excel file, right?

I have to say that this once again sounds like a situation where you want to personally decide who is "elite" and who is "noob", dividing the community into two groups. In case you haven't noticed, most people here make their codes, files, etc. public, which is exactly how it should be in an open community. Keeping an Excel file a "secret" sounds pretty ridiculous to me.
Conflicting Interest is in regard to requests to add functions to the tool. In the small group I can do individual Mods for Individual people giving them the best tool for their way of testing.

If I did make it public it would come with the badges "I Maintain the right to pick and choose what I want to do with my tool" (no pun intended) and "it works that way because thats how I made it"

To those who have it already, do you think the public can handle the basic version I gave you?
 

Scaredgirl

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58074#msg58074
« Reply #8 on: April 23, 2010, 02:25:33 pm »
Yeah, sorry about that previous post. It sounded a lot more "accusing" then I meant. It's your file so naturally you can do whatever you want with it. I just thought the secrecy part was a bit weird.

I wouldn't worry about "Conflicting Interest". If a person doesn't like it, who cares? And if they want to change it to fit their needs, they can do that. But we can make sure that the "official" version of the file has your name in it.

The funny part of me participating in this discussion is that I don't even know what the tool is or what it does. :)

Kael Hate

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58090#msg58090
« Reply #9 on: April 23, 2010, 03:04:22 pm »
The funny part of me participating in this discussion is that I don't even know what the tool is or what it does. :)
Biggest thing it does is let you Paste in deck code from the game and give you a shuffled deck without having to make up any cardboard proxy decks for either player.

Part of this engine I built is a Decoder to search and find card details based on the import code, this is the bit Puppy could likely take, clone, use as an architecture spec to do the job he wants.

In the vice-versa I can calculate all of the things he wishes, albeit in excel.
I'm a Breaker(QA) and Architect(BA) by trade not a Coder(Dev).

PuppyChow

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58123#msg58123
« Reply #10 on: April 23, 2010, 04:51:26 pm »
The thing is that I'm using this to also help out my java programming skills, so I kinda want to do the whole thing myself :).

And all I'm doing right now is adding in every card code since I need to do that anyway. It's boring :D.

PuppyChow

  • Guest
Re: How to decipher the card codes? https://elementscommunity.org/forum/index.php?topic=5672.msg58280#msg58280
« Reply #11 on: April 24, 2010, 01:19:24 am »
Okay, I have all the aether cards (upped and not) coded in... Just have to do the other 11 elements >_>.

And I've started working on the feedback part. Here's what I have so far:

DECK SIZE:
For 30 card decks it has no comment since that's fine.
For >30 card decks this is what it does:

First, subtracts the precognitions and sundials since those are essentially free cards that don't really alter anything.
If the deck is now "under" 30 cards, no comment on it.

If it's still above 30 cards, it counts the number of hourglasses and then forms a ratio of hourglasses : extra cards. If the ratio is bigger than or equal to .25, it's fine. This means that any deck with 55 or more cards will ALWAYS return too large, even with 6 hourglasses. If the ratio is from .20-.2499, the deck is "slightly" too large, and if the ratio is 0-.199, the deck is just too big.

For example:

45 card deck with 6 precognitions and 2 hourglasses.
So 39 card deck with 2 hourglasses.
Ratio of hourglasses to extra cards= 2:9, or .22
So it's slightly too large, which seems right to me.

Any objections to this part?

Eventually the feedback generator may suggest a way to slim it down (maybe while keeping the same ratios of each card or something).

GOOD AT WHAT IT DOES?
I'm also planning on the program asking what the deck is supposed to be used for, AI0-3, Pvp/T50, or FGs. I'm making each card either aggressive or defensive. Some (like pillars or druid) will be neutral, of course.

This uses a ratio of aggressive : defensive cards. For AI0-3, the program will look for a high ratio (6.00 or higher, basically 6 aggressive cards for every defensive/control card). For FGs it will look for a low ratio (.17 or lower, basically 6 defensive/control cards for every aggressive card).

But I'm at a loss how to do PvP/T50 decks, since are so varied. Some use a mix of cards, some focus on control, some focus on speed. Any suggestions for this?

 

anything
blarg: