IN3D / Pokemon

Recreation of pokemon, in C#.
0 stars 0 forks source link

Create Types base class #10

Closed IN3D closed 10 years ago

IN3D commented 10 years ago

Types are highly foundational to pokemon, without them we don't really have much of a game. They make up an important part of pokemon and their moves. So naturally it needs to get made before we go too much further. I've implemented types as just names (string at the moment). Types won't need to be terribly complex. something like

public class Type
{
    protected string Name { get; set; }
    protected int[] modifiers = new int[18];
}
IN3D commented 10 years ago

@BradMackey this is what I was thinking of for the xml structure, if you write it I can read it in

<root>
  <type name="Normal">
    <mod>1</mod> <!-- Normal -->
    <mod>2</mod> <!-- Fighting -->
    <mod>1</mod> <!-- Flying -->
    <mod>1</mod> <!-- Poison -->
    <mod>1</mod> <!-- Ground -->
    <mod>1</mod> <!-- Rock -->
    <mod>1</mod> <!-- Bug -->
    <mod>0</mod> <!-- Ghost -->
    <mod>1</mod> <!-- Steel -->
    <mod>1</mod> <!-- Fire -->
    <mod>1</mod> <!-- Water -->
    <mod>1</mod> <!-- Grass -->
    <mod>1</mod> <!-- Electric -->
    <mod>1</mod> <!-- Psychic -->
    <mod>1</mod> <!-- Ice -->
    <mod>1</mod> <!-- Dragon -->
    <mod>1</mod> <!-- Dark -->
    <mod>1</mod> <!-- Fairy -->
  </type>
  <!-- And more types... -->
</root>