Don't put variable definitions in header

code-review-i
Dave Vandervies 5 years ago
parent 9ff9c206c9
commit 4c04cc39be
  1. 14
      character.c
  2. 14
      character.h

@ -6,6 +6,20 @@
#include "chargen.h" #include "chargen.h"
#include "character.h" #include "character.h"
unsigned long profs;
unsigned long languages;
char otherprofs[100];
char* background;
char* race;
char* class;
char* classes[] = {"Barbarian", "Bard", "Cleric", "Druid", "Fighter", "Monk", "Paladin", "Ranger", "Rogue", "Sorcerer", "Warlock", "Wizard" };
char* races[] = { "Dragonborn", "Dwarf", "Elf", "Gnome", "Half-Elf", "Halfling", "Half-Orc", "Human", "Tiefling" };
char* backgrounds[] = { "Acolyte", "Charlatan", "Criminal", "Entertainer", "Folk Hero", "Guild Artisan", "Hermit", "Noble", "Outlander", "Sage", "Sailor", "Soldier", "Urchin" };
int stats[6];
int mods[6];
int hp;
int dieroll(int num,int sides){ int dieroll(int num,int sides){
int total = 0; int total = 0;
for(num;num>0;num--){ for(num;num>0;num--){

@ -79,17 +79,3 @@
#define INT 3 #define INT 3
#define WIS 4 #define WIS 4
#define CHA 5 #define CHA 5
unsigned long profs;
unsigned long languages;
char otherprofs[100];
char* background;
char* race;
char* class;
char* classes[] = {"Barbarian", "Bard", "Cleric", "Druid", "Fighter", "Monk", "Paladin", "Ranger", "Rogue", "Sorcerer", "Warlock", "Wizard" };
char* races[] = { "Dragonborn", "Dwarf", "Elf", "Gnome", "Half-Elf", "Halfling", "Half-Orc", "Human", "Tiefling" };
char* backgrounds[] = { "Acolyte", "Charlatan", "Criminal", "Entertainer", "Folk Hero", "Guild Artisan", "Hermit", "Noble", "Outlander", "Sage", "Sailor", "Soldier", "Urchin" };
int stats[6];
int mods[6];
int hp;

Loading…
Cancel
Save