structPokemon*new_pokemon=NULL;// Establish that we want to use the Pokemon structure
new_pokemon=malloc(sizeof(structPokemon));// Allocate memory according to the size of the strings passed to the function
if(new_pokemon!=NULL){// Proceed if the new_pokemon variable is not null
strcpy(new_pokemon->pokemon_name,pokemon_name);// Using strcpy(dest, src), takes, the character array from the function argument to the member variable of the new_pokemon struct as a destination
strcpy(new_pokemon->pokemon_type,pokemon_type);// As above, but with the pokemon type.
strcpy(new_pokemon->ability,ability);// Again, as above, but with pokemon ability
// printf("Created new pokemon at %p\n", new_pokemon); // Testing to see the memory addresses of each newly created pokemon node (Commented as this is unnecessary for a user to see)
new_pokemon->next=NULL;// Ends the linked list, setting next to NULL
}
returnnew_pokemon;// Returns the new pokemon node
};
// Player *NewPlayerNode(const char* player_name){
// Player *new_player = NULL; //
// new_player = malloc(sizeof(struct Player));
// if (new_player != NULL){
// strcpy(new_player->player_name, player_name);
// printf("Created new player at %p\n", NewPlayerNode);