Thread: [Essentials script] Pokémon TCG mod
View Single Post
  #53    
Old September 27th, 2012, 01:11 PM
Maruno's Avatar
Maruno
Lead Dev of Pokémon Essentials
 
Join Date: Jan 2008
Location: England
Quote:
Originally Posted by hansiec View Post
I guess it's best for you to do this, I do know the basis of what you mean though and I think a full explanation would be helpful for me.
I would need to have made half the battle system before I figured out enough details to let me explain it fully. I'm mainly going on instinct at the moment.

There's so much that could go on at once in a battle that it's very off-putting. And that's not even considering the AI, which is a topic I will absolutely avoid at all costs. I'm starting to wonder if it would be easier to make it a network play-only game instead (i.e. play against other people online rather than a computer, which is also very complicated which is my point).


Quote:
Originally Posted by Awkward Squirtle View Post
Firstly, I apologise for forgetting this is an extension to Essentials - it slipped my mind when I was writing the reply.

Here's a layout I quickly threw up for the deck edit screen:

You can see the deck contents in the right pane, and switch between deck and library panes with a key press (ideally with a smooth slide animation).
There's still probably a lot missing, but you get the idea. 256x192 isn't much to work with :/

You don't necessarily make a deck based around a type. Sure, it's the easiest way, and starting players will probably do that. But more advanced players might want to make decks based around other things than type.
For example, the most popular (and powerful) deck back when the TCG was new was based around strong basic Pokémon that had efficiently-costed attacks (e.g. Hitmonchan, a 70HP Pokémon that deals 20 damage for a single Energy, or Electabuzz, capable of paralysing opponents with just a single Energy and dealing 40 damage with two).
It would be useful to have some sort of filtering function for this kind of thing.

Define a simple set of filters, such as type and evolutionary stage, and allow multiple filters (of different types) to be on at once. And allow sorting by values such as HP, attack damage, or even Pokédex number. That should be enough to satisfy the majority of players.

I would personally allow people to have incomplete decks, as long as they have at least one complete deck to use. Surely it can't be difficult to implement a check for this/automatically switch to a complete deck if cards are removed from the current deck?
I think the small screen size is too limiting after all, considering what it needs to show.

Obviously the design of the Library (and other screens) needs a lot of work. That's probably why games have whole teams of designers who know what they're doing, and we... don't.

I'd still like for some segregation in the Library, though, even if I dismiss the many-pockets interpretation (subtle physics pun). Surely you couldn't object to keeping Trainers/Energies/Pokémon cards separate? For one, it'd make filters easier.

Allowing incomplete decks is a can of worms. What if you sell a card that was used in every one of your complete decks, thus making them all incomplete? What if you toss cards so you only have 59 left, and aren't able to gain any new ones? You'll say that such situations are rare/unlikely, or the user's fault (which is true), or that the game should forbid the losing of a card were this to happen (in which case, it's easy to extrapolate this argument to come up with "no incomplete decks allowed" which is what I've done). If you suggest that a deck which becomes incomplete like this should be filled in with a random card from the Library just to keep it complete, what about if there are no cards which can legally be added to it? Again, unlikely, but still a can of worms.


Quote:
Originally Posted by Awkward Squirtle View Post
In regards to Energy costs, you're proposing a greedy algorithm (always choose the most limited Energy first). This won't necessarily work. Imagine you have an attack that costs [Metal, Darkness], and your attached energies are [BlendWLFM, DarknessMetal]. Using the greedy algorithm, you'd match DarknessMetal first, and match it with the first cost (Metal). Then, you'd pair BlendWLFM with Darkness, and what do you know, it doesn't match. You might say "well then, you'd start by pairing DarknessMetal to Darkness". But how does the game know to do this? Once you have a method that you think works, can you prove it works, for all possibilities?
Anyway, I have a suggestion on the same topic in regards to 'optional' Energy costs (e.g. Secret Wonders Blastoise's Hydro Pump). I'd give such attacks a preference as to what Energy should be left over (alternatively what Energy should be used for the attack). Blastoise's Hydro Pump should prioritise keeping Water Energy aside for its effect. If you just used the greedy algorithm, a Blastoise with 3 Water Energy and a Blend Energy GFPD would assign the 3 Waters to the main cost, leading to a 50 damage attack (when it could have done 70).
This is what I was saying earlier in this post about too many things going on at once. The simplest way out would be for the player to manually choose which cards are used for each part of the cost, but obviously this isn't appealing. No, I tell a lie: the simplest way out would be to not include difficult cards, but I'm sure people would complain about that.

One option would be to simulate all possible combinations of energy that the attached energy could provide, and check each of those against the cost. This would also work for Blastoise's effect, whereby each (cost-meeting) combination has the cost subtracted and the game accepts the result which has the most Water energy left over. This initially strikes me as rather inefficient (moreso for higher numbers of Colorless in the cost), but actually might not be so bad (and it'd be much easier to code than any "preference" method). It's not as though this needs to be calculated that often (once per turn at most).


Quote:
Originally Posted by Awkward Squirtle View Post
Filters/sorting in Ruby/RGSS are both really easy. You can use code blocks to supply sort/filter criteria to Ruby's built-in methods. For example, this code sorts a list of cards by HP (the <=> method returns -1, 0, or 1 depending on the results of comparing the left value with the right value, used by the sort method):
Code:
sortedList = cardList.sort {|a, b| a.hp <=> b.hp}
And this filters out only stage 2 cards:
Code:
stage2 = cardList.find_all {|card| card.stage == Stage2}
If you don't have experience with something, it's an opportunity to expand your skills in that area. Don't just say "I don't know how to do it, so it's not happening"
The Pokédex includes filters, and some menus in Essentials have sorting in them (usually alphabetical). I know I could figure something out. I just wanted to make sure it was necessary before I devoted any time to it (which I'm still not convinced of). Figuring out how to incorporate it into the designs is a big task, and it's an important part of the code.

I'm not doing this game because I want to expand my horizons and skills (if I were, I'd learn C++ or another useful language to do it in). I just thought it'd be nice if something like this existed for RMXP, and I was in the mood to play around. Not knowing how to do something is a valid excuse for me, particularly if it's something that obviously needs a lot of learning to achieve - I have other things to do.