-
Notifications
You must be signed in to change notification settings - Fork 1
/
pokemon.h
45 lines (37 loc) · 989 Bytes
/
pokemon.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#ifndef _POKEMON_H
#define _POKEMON_H
#include <stdio.h>
#define MAXMOVES 4
typedef struct _pokemon_t pokemon_t;
#include "PokeType.h"
#include "Moves.h"
#include "SaveManager.h"
#include "SpriteManager.h"
struct _pokemon_t{
int dexNumber;
char species[30];
int hp;
int atk;
int stageAtk;
int def;
int stageDef;
int spatk;
int stageSpAtk;
int spdef;
int stageSpDef;
int speed;
int stageSpeed;
int stageAcc;
int stageEva;
type_t mainType;
type_t subType;
statusEffect_t status;
int nTurnsStatus; //To count turns from toxic, frozen, sleep, etc.
move_t* moves[4];
};
pokemon_t* createPokemon(int dexNumber, char *name, int hp, int atk, int def, int spatk, int spdef, int speed, type_t mainType, type_t subType);
void resetStatus(pokemon_t* pokemon);
void printPokemon(pokemon_t *pokemon);
pokemon_t* loadPokemon(FILE* saveFile);
void savePokemon(pokemon_t *pokemon, FILE* saveFile);
#endif //_POKEMON_H