#! /bin/sh

in_file="./class-dflt-tab.h"
out_file="../ex-data/class-dflt-tab.csv"

head='1 { \n'

head=$head' name dummy \n'
head=$head' class_n \n'
head=$head' { \n'
head=$head' HP MP \n'
head=$head' DEX STR QUI \n'
head=$head' INT WIS CHA \n'
head=$head' FIG MON HUN THI \n'
head=$head' MAG SOR ENC SUM \n'
head=$head' PRI SHA BAR NIN \n'
head=$head' } \n'

head=$head' } \n'

####

if [ -f $out_file ]; then
	rm $out_file
fi

for a in $head
do
	echo -n "\"$a\"," >> $out_file
done
echo "" >> $out_file

../sh/rcv-tab.awk $in_file >> $out_file
