 /////////////////////////
 //--Read Config Files--//
 /////////////////////////
 SetupConfig()
 {
	//Set Up Config Files
	new PokeDir[128];
	Poke_FileName( F_MAX, PokeDir );		//refresh the static config dir in Poke_FileName
	Poke_FileName( F_PokeDir, PokeDir );
	if( !dir_exists(PokeDir) )
		mkdir(PokeDir);
 }
 Poke_FileName( PokeFiles:filenum, _File[], len=127 )
 {
	static PokeDir[128];
	switch( filenum )
	{
		case F_MAX:{
							get_configsdir(PokeDir,127);
							add(PokeDir,127,"/pokemon");
		}
		case F_PokeDir:		formatex(_File,len,	"%s/"				,PokeDir);
		case F_Skill:		formatex(_File,len,	"%s/skill.cfg"		,PokeDir);
		case F_ModConfig:	formatex(_File,len,	"%s/pokemod.cfg"	,PokeDir);
		case F_Pokemon:		formatex(_File,len,	"%s/pokemon.cfg"	,PokeDir);
		case F_Items:		formatex(_File,len,	"%s/items.cfg"		,PokeDir);
		case F_Safari:		formatex(_File,len,	"%s/safari.cfg"		,PokeDir);
		case F_PokeMaps:	formatex(_File,len,	"%s/maps.cfg"		,PokeDir);
		case F_XPs:			formatex(_File,len,	"%s/xp_table.ini"	,PokeDir);
		case F_Type:		formatex(_File,len,	"%s/types.txt"	,PokeDir);
	}
	return true;
 }
 public LoadConfig()
 {
	debugMessage( 0,7,"Looking for Config Files." );

	get_localinfo("amxx_vault",g_VaultFile,127);

	SetupConfig()

	new PokeFile[128];

	//Load Config Files
	Poke_FileName( F_ModConfig, PokeFile);
	if( file_exists(PokeFile) ) {
		server_cmd("exec %s",PokeFile);
		SearchCvars();
	}
	else {
		poke_error("**WARNING** PokeMod Config File not found, making default configs");
		ResetConfig();
	}

	Poke_FileName( F_Skill, PokeFile);
	if( !file_exists(PokeFile) ){
		poke_error("**WARNING** PokeMod Skills File not found, making default");
		ResetSkillInfo();
	}
	Poke_FileName( F_Pokemon, PokeFile);
	if( !file_exists(PokeFile) ){
		poke_error("**WARNING** PokeMod Pokemon Properties File not found, making default");
		ResetPokemon();
	}
	Poke_FileName( F_Items, PokeFile);
	if( !file_exists(PokeFile) ){
		poke_error("**WARNING** PokeMod Items File not found, making default");
		ResetPokemart();
	}
	Poke_FileName( F_Safari, PokeFile);
	if( !file_exists(PokeFile) ){
		poke_error("**WARNING** PokeMod Safari file not found, making default");
		ResetSafari();
	}
	Poke_FileName( F_Type, PokeFile);
	if( !file_exists(PokeFile) ){
		poke_error("**WARNING** PokeMod Type file not found, making default");
		ResetTypeFile();
	}
	Poke_FileName( F_XPs, PokeFile);
	if( !file_exists(PokeFile) ){
		poke_error("**WARNING** PokeMod XP table file not found, making default");
		ResetXPs();
	}
	debugMessage( 0,7,"Config Files Found/Reset." );
 }
 public ResetConfig()
 {
	new PokeFile[128];
	Poke_FileName( F_ModConfig, PokeFile);

	if(file_exists(PokeFile))
		delete_file(PokeFile);

	write_file(PokeFile,	"//CVARS for PokeMod, these are loaded every map change",-1);
	write_file(PokeFile,	EMPTY, -1);

	for(new i=0; i<MAX_CVARS; i++)
		set_ppcvar_line(i, cvar_default[i]);

	write_file(PokeFile,	EMPTY, -1);
	write_file(PokeFile,	"echo \"PokeMod - Successfully Loaded PokeMod Config File\" ",-1);
 }

 public ResetPokemart()
 {
	new PokeFile[128];
	Poke_FileName( F_Items, PokeFile);

	if(file_exists(PokeFile))
		delete_file(PokeFile);

	new f = fopen(PokeFile, "at");

	fputs(f,	"// Note - Do not edit here unless you know what your doing, otherwise use pm_pokemart\n" );
	fputs(f,	"// Price = 0 (No one can buy) Price = -# (Only Admin can buy)\n" );
	fputs(f,	"// To make an item Group, place the group name in {} before the items\n" );
	fputs(f,	"// Put items then it's price, then it's properties, then it's description in quotes.\n" );
	fputs(f,	"// Put pokemon name with a dash \"-\" in front then it's price.\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"// Item Properties:\n" );
	fputs(f,	"//  \"a\" - heal item - followed by how much to heal. use -1 for full health\n" );
	fputs(f,	"//  \"b\" - catch item - followed by chance to catch\n" );
	fputs(f,	"//  \"c\" - removes all statuses\n" );
	fputs(f,	"//  \"d\" - removes burn status\n" );
	fputs(f,	"//  \"e\" - removes frozen status\n" );
	fputs(f,	"//  \"f\" - removes paralyze status\n" );
	fputs(f,	"//  \"g\" - removes asleep status\n" );
	fputs(f,	"//  \"h\" - removes slow status\n" );
	fputs(f,	"//  \"i\" - removes poison status\n" );
	fputs(f,	"//  \"j\" - teleports you to spawn\n" );
	fputs(f,	"//  \"k\" - give item to a pokemon (for evolution)\n" );
	fputs(f,	"//  \"l\" - extra pokedamage - followed by additional damage\n" );
	fputs(f,	"//  \"m\" - extra damage - followed by additional damage\n" );
	fputs(f,	"//  \"n\" - extra armor - followed by additional armor\n" );
	fputs(f,	"//  \"o\" - extra speed - followed by additional speed\n" );
	fputs(f,	"//  \"p\" - extra maxhp - followed by additional maxhp\n" );
	fputs(f,	"//  \"q\" - can't be bought\n" );
	fputs(f,	"//  \"r\" - evolution - followed by pokemon to evolve into\n" );
	fputs(f,	"//  \"s\" - levels a pokemon\n" );
	fputs(f,	"//  \"t\" - item trader - followed by item to recieve\n" );
	fputs(f,	"//  \"u\" - bicycle - followed by additional speed\n" );
	fputs(f,	"//  \"v\" - silph scope - allows you to see ghost pokemon\n" );
	fputs(f,	NEWLINE );
/*	fputs(f,	"//  \"w\" - skill - followed by the skill it will teach\n" );*/
	fputs(f,	"//  \"x\" - no drop - players don't drop this item when they die\n" );
	fputs(f,	"//  \"y\" - max amount - followed by max amount of this item players can have\n" );
	fputs(f,	"//  \"z\" - disable default use - disables default pokemod use of an item\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"// Examples:\n" );
	fputs(f,	"//  PokeBall 200 b 20 \"Lapie niskopoziomowe pokemony\"\n" );
	fputs(f,	"//  Master_Ball -16000 b 10000 x y 1 \"Automatically catches pokemon\"\n" );
	fputs(f,	"//  Potion 300 a 20 \"Leczy 20 zdrowia\"\n" );
	fputs(f,	"//  Antidote 100 i \"Leczy status zatrucia\"\n" );
	fputs(f,	"//  Full_Restore 3000 a -1 c \"Leczy wszystkie statuy i zycie\"\n" );
	fputs(f,	"//  Calcium 9800 l 10 \"Dodatkowe obrazenia pokemonow\"\n" );
	fputs(f,	"//  Fire_Stone 2100 k \"Ewoluuje pewne ogniste pokemony\"\n" );
	fputs(f,	"//  Nugget 10000 q \"sprzedaje sie za $5000\"\n" );
	fputs(f,	"//  -Bulbasaur 16000\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"{Pokeballs}\n" );
	fputs(f,	"PokeBall 200 b 20 \"Lapie niskopoziomowe pokemony\"\n" );
	fputs(f,	"Great_Ball 600 b 40 \"Lapie sredniopoziomowe pokemony\"\n" );
	fputs(f,	"Ultra_Ball 1200 b 80 \"Lapie wysokopoziomowe pokemony\"\n" );
	fputs(f,	"Master_Ball -16000 b 10000 x y 1 \"Lapie kazdego pokemona\"\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"{Items}\n" );
	fputs(f,	"Potion 300 a 20 \"Leczy 20 HP\"\n" );
	fputs(f,	"Antidote 100 i \"Leczy status: zatrucie\"\n" );
	fputs(f,	"Awakening 200 g \"Leczy status: uspienie\"\n" );
	fputs(f,	"Burn_Heal 200 d \"Leczy status: podpalenie\"\n" );
	fputs(f,	"Ice_Heal 250 e \"Leczy status: zamrozenie\"\n" );
	fputs(f,	"Paralyze_Heal 250 f \"Leczy status: sparalizowanie i spowolnienie\"\n" );
	fputs(f,	"Escape_Rope 550 j \"Teleportuje na respawn\"\n" );
	fputs(f,	"Full_Heal 600 c \"Leczy wszystkie statusyHeals all status\"\n" );
	fputs(f,	"Super_Potion 700 a 70 \"Leczy 70 HP\"\n" );
	fputs(f,	"Full_Restore 3000 a -1 c \"Leczy wszystkie statusy i przywraca cale HP\"\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"{Boosts}\n" );
	fputs(f,	"Calcium 9800 l 10 \"Extra obrazenia pokemonow\"\n" );
	fputs(f,	"Carbos 9800 o 50 \"Extra predkosc\"\n" );
	fputs(f,	"HP_Up 9800 p 25 \"Extra maksymalne HP\"\n" );
	fputs(f,	"Iron 9800 n 50 \"Extra pancerz\"\n" );
	fputs(f,	"Protein 9800 m 5 \"Extra obrazenia\"\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"{Stones}\n" );
	fputs(f,	"Fire_Stone 2100 k \"Ewoluuje pewne ogniste pokemony\"\n" );
	fputs(f,	"Leaf_Stone 2100 k \"Ewoluuje pewne lisciaste pokemony\"\n" );
	fputs(f,	"Moon_Stone 2100 k \"Ewoluuje pewne psychiczne pokemony\"\n" );
	fputs(f,	"Thunder_Stone 2100 k \"Ewoluuje pewne elektryczne pokemony\"\n" );
	fputs(f,	"Water_Stone 2100 k \"Ewoluuje pewne wodne pokemony\"\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"{Other}\n" );
	fputs(f,	"Nugget 10000 q \"Sprzedaje sie za $5000\"\n" );
	fputs(f,	"Old_Amber 5000 q r aerodactyl \"Skamienialy aerodactyl\"\n" );
	fputs(f,	"Rare_Candy 16000 k q s \"Podnosi poziom pokemona\"\n" );
	fputs(f,	"Bicycle 0 q u 200 \"Biegasz bardzo szybko\"\n" );
	fputs(f,	"Bike_Voucher 5000 q t Bicycle \"Wymienia sie na rower\"\n" );
	fputs(f,	"Silph_Scope 5000 v \"Wskazuje duchy\"\n" );
	fputs(f,	NEWLINE );
/*
	fputs(f,	"{Technical Machines}\n" );
	fputs(f,	"TM_01 0 q w Mega_Punch\n" );
	fputs(f,	"TM_02 0 q w Razor_Wind\n" );
	fputs(f,	"TM_03 0 q w Swords_Dance\n" );
	fputs(f,	"TM_04 0 q w Whirlwind\n" );
	fputs(f,	"TM_05 0 q w Mega_Kick\n" );
	fputs(f,	"TM_06 0 q w Toxic\n" );
	fputs(f,	"TM_07 0 q w Horn_Drill\n" );
	fputs(f,	"TM_08 0 q w Body_Slam\n" );
	fputs(f,	"TM_09 0 q w Take_Down\n" );
	fputs(f,	"TM_10 0 q w Double_Edge\n" );
	fputs(f,	"TM_11 0 q w BubbleBeam\n" );
	fputs(f,	"TM_12 0 q w Water_Gun\n" );
	fputs(f,	"TM_13 0 q w Ice_Beam\n" );
	fputs(f,	"TM_14 0 q w Blizzard\n" );
	fputs(f,	"TM_15 0 q w Hyper_Beam\n" );
	fputs(f,	"TM_16 0 q w Pay_Day\n" );
	fputs(f,	"TM_17 0 q w Submission\n" );
	fputs(f,	"TM_18 0 q w Counter\n" );
	fputs(f,	"TM_19 0 q w Seismic_Toss\n" );
	fputs(f,	"TM_20 0 q w Rage\n" );
	fputs(f,	"TM_21 0 q w Mega_Drain\n" );
	fputs(f,	"TM_22 0 q w Solarbeam\n" );
	fputs(f,	"TM_23 0 q w Dragon_Rage\n" );
	fputs(f,	"TM_24 0 q w Thunderbolt\n" );
	fputs(f,	"TM_25 0 q w Thunder\n" );
	fputs(f,	"TM_26 0 q w Earthquake\n" );
	fputs(f,	"TM_27 0 q w Fissure\n" );
	fputs(f,	"TM_28 0 q w Dig\n" );
	fputs(f,	"TM_29 0 q w Psychic\n" );
	fputs(f,	"TM_30 0 q w Teleport\n" );
	fputs(f,	"TM_31 0 q w Mimic\n" );
	fputs(f,	"TM_32 0 q w Double_Team\n" );
	fputs(f,	"TM_33 0 q w Reflect\n" );
	fputs(f,	"TM_34 0 q w Bide\n" );
	fputs(f,	"TM_35 0 q w Metronome\n" );
	fputs(f,	"TM_36 0 q w Self_Destruct\n" );
	fputs(f,	"TM_37 0 q w Egg_Bomb\n" );
	fputs(f,	"TM_38 0 q w Fire_Blast\n" );
	fputs(f,	"TM_39 0 q w Swift\n" );
	fputs(f,	"TM_40 0 q w Skull_Bash\n" );
	fputs(f,	"TM_41 0 q w Softboiled\n" );
	fputs(f,	"TM_42 0 q w Dream_Eater\n" );
	fputs(f,	"TM_43 0 q w Sky_Attack\n" );
	fputs(f,	"TM_44 0 q w Rest\n" );
	fputs(f,	"TM_45 0 q w Thunder_Wave\n" );
	fputs(f,	"TM_46 0 q w Psywave\n" );
	fputs(f,	"TM_47 0 q w Explosion\n" );
	fputs(f,	"TM_48 0 q w Rock_Slide\n" );
	fputs(f,	"TM_49 0 q w Tri_Attack\n" );
	fputs(f,	"TM_50 0 q w Substitute\n" );
	fputs(f,	"{Hidden Machines}\n" );
	fputs(f,	"HM_01 0 q w Cut x\n" );
	fputs(f,	"HM_02 0 q w Fly x\n" );
	fputs(f,	"HM_03 0 q w Surf x\n" );
	fputs(f,	"HM_04 0 q w Strength x\n" );
	fputs(f,	"HM_05 0 q w Flash x\n" );
	fputs(f,	NEWLINE );
*/
	fputs(f,	"-Bulbasaur 16000\n" );
	fputs(f,	"-Charmander 16000\n" );
	fputs(f,	"-Squirtle 16000\n" );
	fputs(f,	"-Pikachu 16000\n" );

	fclose(f);
 }
 public ResetTypeFile()
 {
	new PokeFile[128];
	Poke_FileName( F_Type, PokeFile);

	if(file_exists(PokeFile))
		delete_file(PokeFile)

	new f = fopen(PokeFile, "at");

	fputs(f,	"// Note - There is nothing to edit in this file\n" );
	fputs(f,	"// Note2 - These are the type flags for pokemon and skills\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"//  \"a\" - Normal\n" );
	fputs(f,	"//  \"b\" - Fire\n" );
	fputs(f,	"//  \"c\" - Water\n" );
	fputs(f,	"//  \"d\" - Electric\n" );
	fputs(f,	"//  \"e\" - Grass\n" );
	fputs(f,	"//  \"f\" - Ice\n" );
	fputs(f,	"//  \"g\" - Fighting\n" );
	fputs(f,	"//  \"h\" - Poison\n" );
	fputs(f,	"//  \"i\" - Ground\n" );
	fputs(f,	"//  \"j\" - Flying\n" );
	fputs(f,	"//  \"k\" - Psychic\n" );
	fputs(f,	"//  \"l\" - Bug\n" );
	fputs(f,	"//  \"m\" - Rock\n" );
	fputs(f,	"//  \"n\" - Ghost\n" );
	fputs(f,	"//  \"o\" - Dragon\n" );

	fclose(f);
 }
 public ResetPokemon()
 {
	new PokeFile[128];
	Poke_FileName( F_Pokemon, PokeFile);

	if(file_exists(PokeFile))
		delete_file(PokeFile)

	new f = fopen(PokeFile, "at");

	fputs(f,	"// Note - Do not edit here unless you know what your doing\n" );
	fputs(f,	"// Put pokemon name, then its number, then its skill in quotes, then it's properties, then evolutions.\n" );
	fputs(f,	"// For types, check types.txt\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"// Pokemon Properties:\n" );

	fputs(f,	"//  \"a\" - isn't an evolved form of another pokemon\n" );
	fputs(f,	"//  \"b\" - evolves - followed by level number, TRADE, or item name\n" );
	fputs(f,	"//                  - then followed by the pokemon it should evolve into\n" );
	fputs(f,	"//  \"c\" - cannot be found in pokeballs on the ground\n" );
	fputs(f,	"//  \"d\" - can be selected as a starting pokemon\n" );
	fputs(f,	"//  \"g\" - global - doesn't have to be active to use skill\n" );
	fputs(f,	"//  \"h\" - heavy - some skills will not work against heavy pokemon\n" );
	fputs(f,	"//  \"y\" - special - pokemon follows special flags for capturing\n" );
	fputs(f,	"//  \"z\" - disable use\n" );

	fputs(f,	NEWLINE );
	fputs(f,	"// Example:\n" );
	fputs(f,	"//#   Name Type_Flags \"Skill_Name\" Pokemon_Properties\n" );
	fputs(f,	"//1   Bulbasaur eh \"Leech_Seed\" abcd 16 Ivysaur\n" );
	//"Number name type attack props evolution"

	fputs(f,	NEWLINE );
	fputs(f,	"1   Bulbasaur eh \"Wysysajace_Ziarno\" abcd 16 Ivysaur\n" );
	fputs(f,	"2   Ivysaur eh \"Rozrost\" b 32 Venusaur\n" );
	fputs(f,	"3   Venusaur eh \"Promien_Sloneczny\" h\n" );
	fputs(f,	"4   Charmander b \"Furia\" abcd 16 Charmeleon\n" );
	fputs(f,	"5   Charmeleon b \"Kontra\" b 36 Charizard\n" );
	fputs(f,	"6   Charizard bj \"Ognisty_Podmuch\"\n" );
	fputs(f,	"7   Squirtle c \"Babelkowy_promien\" abcd 16 Wartortle\n" );
	fputs(f,	"8   Wartortle c \"Wodna_Bron\" b 36 Blastoise\n" );
	fputs(f,	"9   Blastoise c \"Wodna_Pompa\" h\n" );
	fputs(f,	"10  Caterpie l \"Atak_Sznurkiem\" ab 7 Metapod\n" );
	fputs(f,	"11  Metapod l \"Stwardnienie\" b 10 Butterfree\n" );
	fputs(f,	"12  Butterfree lj \"Zastepca\"\n" );
	fputs(f,	"13  Weedle lh \"Trujace_Zadlo\" ab 7 Kakuna\n" );
	fputs(f,	"14  Kakuna lh \"Stwardnienie\" b 10 Beedrill\n" );
	fputs(f,	"15  Beedrill lh \"Iglowe_Pociski\"\n" );
	fputs(f,	"16  Pidgey aj \"Podmuch_Wiatru\" ab 18 Pidgeotto\n" );
	fputs(f,	"17  Pidgeotto aj \"Traba_Powietrzna\" b 36 Pidgeot\n" );
	fputs(f,	"18  Pidgeot aj \"Lot\"\n" );
	fputs(f,	"19  Rattata a \"Hyper_Kiel\" ab 20 Raticate\n" );
	fputs(f,	"20  Raticate a \"Super_Kiel\"\n" );
	fputs(f,	"21  Spearow j \"Dziobanie\" ab 20 Fearow\n" );
	fputs(f,	"22  Fearow aj \"Wkrecajace_Dziobanie\"\n" );
	fputs(f,	"23  Ekans h \"Zwiazanie\" ab 22 Arbok\n" );
	fputs(f,	"24  Arbok h \"Gniewne_Spojrzenie\"\n" );
	fputs(f,	"25  Pikachu d \"Szybki_Atak\" abcd Thunder_Stone Raichu\n" );
	fputs(f,	"26  Raichu d \"Blyskawica\"\n" );
	fputs(f,	"27  Sandshrew i \"Piaskowy_Atak\" ab 22 Sandslash\n" );
	fputs(f,	"28  Sandslash i \"Szybkosc\"\n" );
	fputs(f,	"29  NidoranF h \"Uderzenie\" ab 16 Nidorina\n" );
	fputs(f,	"30  Nidorina h \"Podwojny_Kop\" b Moon_Stone Nidoqueen\n" );
	fputs(f,	"31  Nidoqueen hi \"Atak_Cialem\" h\n" );
	fputs(f,	"32  NidoranM h \"Atak_Rogiem\" ab 16 Nidorino\n" );
	fputs(f,	"33  Nidorino h \"Wkrecajacy_Rog\" b Moon_Stone Nidoking\n" );
	fputs(f,	"34  Nidoking hi \"Sila\" h\n" );
	fputs(f,	"35  Clefairy a \"Propozycja\" ab Moon_Stone Clefable\n" );
	fputs(f,	"36  Clefable a \"Sciagniecie\"\n" );
	fputs(f,	"37  Vulpix b \"Machanie_Ogonem\" ab Fire_Stone Ninetales\n" );
	fputs(f,	"38  Ninetales b \"Niedopalek\"\n" );
	fputs(f,	"39  Jigglypuff a \"Spiew\" ab Moon_Stone Wigglytuff\n" );
	fputs(f,	"40  Wigglytuff a \"Spiew\"\n" );
	fputs(f,	"41  Zubat hj \"Wysysanie_Zycia\" ab 22 Golbat\n" );
	fputs(f,	"42  Golbat hj \"Ugryzienie\"\n" );
	fputs(f,	"43  Oddish eh \"Absorbowanie\" ab 21 Gloom\n" );
	fputs(f,	"44  Gloom eh \"Ogluszajacy_Zarodnik\" b Leaf_Stone Vileplume\n" );
	fputs(f,	"45  Vileplume eh \"Mega_Wysysanie\"\n" );
	fputs(f,	"46  Paras le \"Zarodnik\" ab 24 Parasect\n" );
	fputs(f,	"47  Parasect le \"Rozrost\"\n" );
	fputs(f,	"48  Venonat lh \"Trujacy_Proszek\" ab 30 Venomoth\n" );
	fputs(f,	"49  Venomoth lh \"Usypiajacy_Proszek\"\n" );
	fputs(f,	"50  Diglett i \"Kopanie\" ab 28 Dugtrio\n" );
	fputs(f,	"51  Dugtrio i \"Trzesienie_Ziemi\"\n" );
	fputs(f,	"52  Meowth a \"Wyplata\" abd 28 Persian\n" );
	fputs(f,	"53  Persian a \"Zadrapanie\"\n" );
	fputs(f,	"54  Psyduck c \"Zdezorientowanie\" ab 33 Golduck\n" );
	fputs(f,	"55  Golduck c \"Atak_Furii\"\n" );
	fputs(f,	"56  Mankey g \"Niski_Kopniak\" ab 26 Primeape\n" );
	fputs(f,	"57  Primeape g \"Zniszczenie\"\n" );
	fputs(f,	"58  Growlithe b \"Rryk\" ab Fire_Stone Arcanine\n" );
	fputs(f,	"59  Arcanine b \"Miotacz_Ognia\"\n" );
	fputs(f,	"60  Poliwag c \"Podwojny_Atak\" ab 25 Poliwhirl\n" );
	fputs(f,	"61  Poliwhirl c \"Atak_Cialem\" b Water_Stone Poliwrath\n" );
	fputs(f,	"62  Poliwrath cg \"Uderzenie_Czaszka\" h\n" );
	fputs(f,	"63  Abra k \"Teleport\" ab 16 Kadabra\n" );
	fputs(f,	"64  Kadabra k \"Promien_Psychiczny\" b TRADE Alakazam\n" );
	fputs(f,	"65  Alakazam k \"Odbicie\"\n" );
	fputs(f,	"66  Machop g \"Siekanie\" ab 28 Machoke\n" );
	fputs(f,	"67  Machoke g \"Niski_Kopniak\" b TRADE Machamp\n" );
	fputs(f,	"68  Machamp g \"Seismiczny_Rzut\"\n" );
	fputs(f,	"69  Bellsprout eh \"Winorosla\" ab 21 Weepinbell\n" );
	fputs(f,	"70  Weepinbell eh \"Jad\" b Leaf_Stone Victreebel\n" );
	fputs(f,	"71  Victreebel eh \"Ostry_Lisc\"\n" );
	fputs(f,	"72  Tentacool ch \"Jad\" ab 30 Tentacruel\n" );
	fputs(f,	"73  Tentacruel ch \"Utrudnienie\"\n" );
	fputs(f,	"74  Geodude mi \"Obronne_Skulenie\" ab 25 Graveler\n" );
	fputs(f,	"75  Graveler mi \"Stwardnienie\" b TRADE Golem\n" );
	fputs(f,	"76  Golem mi \"Kamienna_Przejazdzka\" h\n" );
	fputs(f,	"77  Ponyta b \"Stapniecie\" ab 40 Rapidash\n" );
	fputs(f,	"78  Rapidash b \"Zwinnosc\"\n" );
	fputs(f,	"79  Slowpoke ck \"Zdezorientowanie\" ab 37 Slowbro\n" );
	fputs(f,	"80  Slowbro ck \"Amnezia\"\n" );
	fputs(f,	"81  Magnemite d \"Dzwiekowe_Huk\" ab 30 Magneton\n" );
	fputs(f,	"82  Magneton d \"Fala_Piorunow\"\n" );
	fputs(f,	"83  Farfetchd aj \"Spojrzenie\" a\n" );
	fputs(f,	"84  Doduo aj \"Podwojna_Krawedz\" ab 31 Dodrio\n" );
	fputs(f,	"85  Dodrio aj \"Potrojny_Atak\"\n" );
	fputs(f,	"86  Seel c \"Promien_Polarny\" ab 37 Dewgong\n" );
	fputs(f,	"87  Dewgong cf \"Promien_Lodowy\"\n" );
	fputs(f,	"88  Grimer h \"Trujacy_Gaz\" ab 35 Muk\n" );
	fputs(f,	"89  Muk h \"Zbroja_Jadu\"\n" );
	fputs(f,	"90  Shellder c \"Wycofanie\" ab Water_Stone Cloyster\n" );
	fputs(f,	"91  Cloyster cf \"Dzialo_Kolczaste\"\n" );
	fputs(f,	"92  Gastly nh \"Nocny_Cien\" ab 25 Haunter\n" );
	fputs(f,	"93  Haunter nh \"Hipnoza\" b TRADE Gengar\n" );
	fputs(f,	"94  Gengar nh \"Pozeracz_Snow\"\n" );
	fputs(f,	"95  Onix mi \"Rzut_Kamieniem\" a\n" );
	fputs(f,	"96  Drowzee k \"Uszkodzenie\" ab 28 Hypno\n" );
	fputs(f,	"97  Hypno k \"Zdezorientowanie\"\n" );
	fputs(f,	"98  Krabby c \"Uscisk\" ab 28 Kingler\n" );
	fputs(f,	"99  Kingler c \"M³ot\"\n" );
	fputs(f,	"100 Voltorb d \"Samozniszczenie\" ab 33 Electrode\n" );
	fputs(f,	"101 Electrode d \"Eksplozja\"\n" );
	fputs(f,	"102 Exeggcute ek \"Zapora\" ab Leaf_Stone Exeggutor\n" );
	fputs(f,	"103 Exeggutor ek \"Promien_Sloneczny\"\n" );
	fputs(f,	"104 Cubone i \"Kosciomaczuga\" ab 28 Marowak\n" );
	fputs(f,	"105 Marowak i \"Kosciomerang\"\n" );
	fputs(f,	"106 Hitmonlee g \"Mega_Kop\" a\n" );
	fputs(f,	"107 Hitmonchan g \"Mega_Cios\" a\n" );
	fputs(f,	"108 Lickitung a \"Wrzask\" a\n" );
	fputs(f,	"109 Koffing h \"Smog\" ab 35 Weezing\n" );
	fputs(f,	"110 Weezing h \"Toksyny\"\n" );
	fputs(f,	"111 Rhyhorn im \"Atak_Furii\" ab 42 Rhydon\n" );
	fputs(f,	"112 Rhydon im \"Rozerwanie\"\n" );
	fputs(f,	"113 Chansey a \"Bomba_Jajowa\" a\n" );
	fputs(f,	"114 Tangela e \"Absorbowanie\" a\n" );
	fputs(f,	"115 Kangaskhan a \"Odurzajacy_Cios\"\n" );
	fputs(f,	"116 Horsea c \"Babelki\" ab 30 Seadra\n" );
	fputs(f,	"117 Seadra c \"Spojrzenie\"\n" );
	fputs(f,	"118 Goldeen c \"Ponaddzwiekowy\" ab 33 Seaking\n" );
	fputs(f,	"119 Seaking c \"Wodospad\"\n" );
	fputs(f,	"120 Staryu c \"Wyzdrowienie\" ab Water_Stone Starmie\n" );
	fputs(f,	"121 Starmie ck \"Jasny_Ekran\"\n" );
	fputs(f,	"122 MrMime k \"Bariera\" a\n" );
	fputs(f,	"123 Scyther lj \"Podwojna_Druzyna\" a\n" );
	fputs(f,	"124 Jynx fk \"Zamiec\" a\n" );
	fputs(f,	"125 Electabuzz d \"Blysk\" a\n" );
	fputs(f,	"126 Magmar b \"Dymny_Ekran\" a\n" );
	fputs(f,	"127 Pinsir l \"Gilotyna\" a\n" );
	fputs(f,	"128 Tauros a \"Stapniecie\" a\n" );
	fputs(f,	"129 Magikarp c \"Plusk\" ab 20 Gyarados\n" );
	fputs(f,	"130 Gyarados cj \"Serfowanie\"\n" );
	fputs(f,	"131 Lapras cf \"Promien_Dezorientujacy\" a\n" );
	fputs(f,	"132 Ditto a \"Przemiana\" a\n" );
	fputs(f,	"133 Eevee a \"Uderzenie\" ab Water_Stone Vaporeon Thunder_Stone Jolteon Fire_Stone Flareon\n" );
	fputs(f,	"134 Vaporeon c \"Mgla\"\n" );
	fputs(f,	"135 Jolteon d \"Blyskawica\"\n" );
	fputs(f,	"136 Flareon b \"Ognisty_Krag\"\n" );
	fputs(f,	"137 Porygon a \"Konwersja\" a\n" );
	fputs(f,	"138 Omanyte mc \"Wycofanie\" abc 40 Omastar\n" );
	fputs(f,	"139 Omastar mc \"Oczekiwaine\" c\n" );
	fputs(f,	"140 Kabuto mc \"Zadrapanie\" abc 40 Kabutops\n" );
	fputs(f,	"141 Kabutops mc \"Ciecie\" c\n" );
	fputs(f,	"142 Aerodactyl mj \"Zwinnosc\" ac\n" );
	fputs(f,	"143 Snorlax a \"Odpoczynek\" ah\n" );
	fputs(f,	"144 Articuno fj \"Mgla\" acy\n" );
	fputs(f,	"145 Zapdos dj \"Piorun\" acy\n" );
	fputs(f,	"146 Moltres bj \"Atak_Powietrzny\" acy\n" );
	fputs(f,	"147 Dratini o \"Fala_Piorunow\" ab 30 Dragonair\n" );
	fputs(f,	"148 Dragonair o \"Smocza_Furia\" b 55 Dragonite\n" );
	fputs(f,	"149 Dragonite o \"Hyper_Promien\" h\n" );
	fputs(f,	"150 Mewtwo k \"Psycho_Fala\" acy\n" );
	fputs(f,	"151 Mew k \"Medium\" acy\n" );

	fclose(f);
 }
 public ResetSkillInfo()
 {
	new PokeFile[128];
	Poke_FileName( F_Skill, PokeFile);

	if( file_exists(PokeFile) )
		delete_file(PokeFile);

	new f = fopen(PokeFile, "at");

	fputs(f,	"// Note - Do not edit here unless you know what your doing\n" );
	fputs(f,	"// Put skill name then it's type, then delay time, then properties.\n" );
	fputs(f,	"// For types, check types.txt\n" );
	fputs(f,	"// If no time specified, 0.0 will be used.\n" );

	fputs(f,	NEWLINE );
	fputs(f,	"//  Properties:\n" );
	fputs(f,	"//  \"a\" - skill is called when someone attacks someone else\n" );
	fputs(f,	"//  \"b\" - skill is called when someone presses a bind key\n" );
	fputs(f,	"//  \"c\" - skill is called when someone touches something\n" );
	fputs(f,	"//  \"d\" - skill is called when someone is damaged\n" );
	fputs(f,	"//  \"e\" - skill is called every second\n" );
	fputs(f,	"//  \"f\" - skill is called during spawn\n" );
	fputs(f,	"//  \"g\" - skill is called on death\n" );
	fputs(f,	"//  \"h\" - skill is called no matter what\n" );
	fputs(f,	"//  \"i\" - skill ignores delay time\n" );
	fputs(f,	"//  \"j\" - skill is called when someone attacks someone else with a pokeskill\n" );
	fputs(f,	"//  \"k\" - skill is called when someone is damaged with a pokeskill\n" );
	fputs(f,	"//  \"l\" - when someone looks at someone else\n" );
	fputs(f,	"//  \"m\" - when someone changes speed\n" );
	fputs(f,	"//  \"r\" - skill is called when player releases bind key\n" );
	fputs(f,	"//  \"s\" - skill is called when player status changes\n" );
	fputs(f,	"//  \"y\" - skill can only be used by admins\n" );
	fputs(f,	"//  \"z\" - disable default skill\n" );

	fputs(f,	NEWLINE );
	fputs(f,	"// Example:\n" );
	fputs(f,	"//   Leech_Seed e 10 bl\n" );
	//"Function type delay props"

//32 unmade skills
	fputs(f,	NEWLINE );
	fputs(f,	"Absorb e 0 a \"kradnie pancerz od przeciwnikow\"\n" );
	fputs(f,	"Acid h 0 a \"zatruwa przeciwnikow\"\n" );
	fputs(f,	"Acid_Armor h 0 s \"chroni przed trucizna\"\n" );
	fputs(f,	"Agility k 0 m \"zwieksza predkosc\"\n" );
	fputs(f,	"Amnesia k 15 b \"dezorientuje pobliskich przeciwnikow\"\n" );
	fputs(f,	"Aurora_Beam f 15 b \"strzela kolorowym promienim zadajc obrazenia\"\n" );
	fputs(f,	"Barrage a 0 fi \"daje extra granat\"\n" );
	fputs(f,	"Barrier k 5 b \"stawia bariery ktore przyjmuja obrazenia\"\n" );
	fputs(f,	"Bide a 0 a \"zadaje dodatkowe obrazenia zaleznie od twojego zdrowia\"\n" );
//	fputs(f,	"Bind a \"\"\n" );
	fputs(f,	"Bite a 0 c \"kradnie zycie od przeciwnikow\"\n" );
	fputs(f,	"Blizzard f 15 b \"zamraza przeciwnikow dookola ciebie\"\n" );
	fputs(f,	"Body_Slam a 0 c \"rani przeciwnikow i wyrzuca ich\"\n" );
	fputs(f,	"Bone_Club i 0.1 b \"rzut koscia\"\n" );
	fputs(f,	"Bonemerang i 0.1 b \"rzut koscia ktora wraca do ciebie\"\n" );
	fputs(f,	"Bubble c 0 e \"dostarcza dodatkowy tlen w wodzie\"\n" );
	fputs(f,	"Bubble_Beam c 1 b \"strzela promieniem babelkow\"\n" );
//	fputs(f,	"Clamp c \"\"\n" );
//	fputs(f,	"Comet_Punch a \"\"\n" );
	fputs(f,	"Confuse_Ray n 10 b \"Strzela promieniem swiatla ktory dezorientuje wroga\"\n" );
	fputs(f,	"Confusion k 15 b \"dezorientuje pobliskich przeciwnikow\"\n" );
	fputs(f,	"Constrict a 0 a \"paralizuje wrogow\"\n" );
	fputs(f,	"Conversion a 10 br \"wolniej biegasz i trudniej cie zobaczyc\"\n" );
	fputs(f,	"Counter g 0 d \"ranisz przeciwnikow swoja furia\"\n" );
	fputs(f,	"Crabhammer c 5 a \"extra oobrazenia nozem\"\n" );
//	fputs(f,	"Cut a \"\"\n" );
	fputs(f,	"Defense_Curl a 0 d \"dsotajesz pancerz\"\n" );
	fputs(f,	"Dig i 0.5 b \"wkopuje w ziemie i sciany\"\n" );
	fputs(f,	"Disable a 5 b \"opoznia wrogow od uzywania umiejetnosci\"\n" );
	fputs(f,	"Dizzy_Punch a 5 c \"rani i trzesie ekranem\"\n" );
	fputs(f,	"Double_Edge a 0 a \"daje extra amunicje\"\n" );
	fputs(f,	"Double_Kick g 0 b \"skacze ekstremalnie wysoko\"\n" );
	fputs(f,	"Double_Slap a 0 c \"rani wrogow\"\n" );
	fputs(f,	"Double_Team a 15 b \"teleportuje do rannego sojusznika\"\n" );
	fputs(f,	"Dragon_Rage o 5 a \"zawsze zadajesz minimum 40 obrazen\"\n" );
	fputs(f,	"Dream_Eater k 1 bl \"kradnie zycie od spiacych przeciwnikow\"\n" );
	fputs(f,	"Drill_Peck j 0 c \"wielkie obrazenia\"\n" );
	fputs(f,	"Earthquake i 20 b \"trzesie ziemia i rani przeciwnikow\"\n" );
	fputs(f,	"Egg_Bomb a 10 b \"zamienia granat w bombe ktora mozesz wysadzic\"\n" );
	fputs(f,	"Ember b 10 b \"stawia glaz ktory plonie\"\n" );
	fputs(f,	"Explosion a 0 g \"wybucha zadajac ciezkie obrazenia\"\n" );
	fputs(f,	"Fire_Blast b 5 b \"strzela plonacym kamieniem\"\n" );
//	fputs(f,	"Fire_Punch b \"\"\n" );
	fputs(f,	"Fire_Spin b 9 b \"podpala pobliskich przeciwnikow\"\n" );
	fputs(f,	"Fissure i 20 a \"niewielka szansa na natychmiastowe zabicie przeciwnika\"\n" );
	fputs(f,	"Flamethrower b 15 b \"strzela plomieniem ktory podpala przeciwnikow\"\n" );
	fputs(f,	"Flash a 0 a \"oslepia wrogow\"\n" );
	fputs(f,	"Fly a 0 b \"pozwala unosic sie nad ziemia\"\n" );
//	fputs(f,	"Focus_Energy a \"\"\n" );
	fputs(f,	"Fury_Attack a 5 a \"dodatkowe obrazenia nozem zalezne od twojego pancerza\"\n" );
	fputs(f,	"Fury_Swipes a 5 a \"dodatkowe obrazenia nozem zalezne od twojego zdrowia\"\n" );
	fputs(f,	"Glare a 0 bl \"paralizuje wrogow\"\n" );
//	fputs(f,	"Growl a \"\"\n" );
	fputs(f,	"Growth a 0 ei \"skraca czas miedzy umiejetnosciami\"\n" );
	fputs(f,	"Guillotine a 0 a \"szansa na natychmiastowe zabicie z noza\"\n" );
	fputs(f,	"Gust a 10 b \"rani i wyrzuca przeciwnikow w powietrze\"\n" );
	fputs(f,	"Harden a 5 b \"zamienia zycie na pancerz\"\n" );
	fputs(f,	"Haze f 5 s \"Chroni przez zmiana statusuprotects against status effects\"\n" );
//	fputs(f,	"Head_Butt a \"\"\n" );
//	fputs(f,	"Hi-Jump_Kick g \"\"\n" );
	fputs(f,	"Horn_Attack a 1 b \"strzela rogiem\"\n" );
	fputs(f,	"Horn_Drill a 5 b \"strzela poteznym rogiem\"\n" );
	fputs(f,	"Hydro_Pump c 0 b \"strzela dwoma strumieniami wody\"\n" );
	fputs(f,	"Hyper_Beam a 25 b \"strzela poteznym promieniem, paralizujac\"\n" );
	fputs(f,	"Hyper_Fang a 0 d \"extra obrazenia nozem\"\n" );
	fputs(f,	"Hypnosis k 15 b \"usypia przeciwnikow\"\n" );
	fputs(f,	"Ice_Beam f 10 b \"strzela promieniem lodu zamrazajac wrogow\"\n" );
//	fputs(f,	"Ice_Punch f \"\"\n" );
//	fputs(f,	"Jump_Kick g \"\"\n" );
	fputs(f,	"Karate_Chop a 5 c \"rani i omdlewa wrogow\"\n" );
//	fputs(f,	"Kinesis k \"\"\n" );
	fputs(f,	"Leech_Life l 0 c \"kradnie zycie od przeciwnikow\"\n" );
	fputs(f,	"Leech_Seed e 10 bl \"zasadza ziarno ktore zabiera zycie przeciwnikom\"\n" );
	fputs(f,	"Leer a 5 a \"Usuwa caly pancerz z przeciwnikow\"\n" );
//	fputs(f,	"Lick n \"\"\n" );
	fputs(f,	"Light_Screen k 0 k \"leczy 1/2 obrazen\"\n" );
//	fputs(f,	"Lovely_Kiss a \"\"\n" );
	fputs(f,	"Low_Kick g 3 c \"rani wrogow\"\n" );
//	fputs(f,	"Meditate k \"\"\n" );
	fputs(f,	"Mega_Drain e 5 a \"kradnie amunicje od przeciwnikow\"\n" );
	fputs(f,	"Mega_Kick a 0 c \"kopie przeciwnikow w powietrze\"\n" );
	fputs(f,	"Mega_Punch a 0 c \"wybija przeciwnikow z dala od ciebie\"\n" );
//	fputs(f,	"Metronome a \"\"\n" );
//	fputs(f,	"Mimic a \"\"\n" );
//	fputs(f,	"Minimize a \"\"\n" );
//	fputs(f,	"Mirror_Move a \"\"\n" );
	fputs(f,	"Mist f 10 b \"emituje mgle ktora cie leczy\"\n" );
	fputs(f,	"Night_Shade n 0 ei \"czyni cie inewidzialnym zaciemniajac ci ekran\"\n" );
	fputs(f,	"Pay_Day a 0 ahj \"dostajesz extra pieniadze\"\n" );
	fputs(f,	"Peck j 0 c \"rani wrogow\"\n" );
//	fputs(f,	"Petal_Dance e \"\"\n" );
	fputs(f,	"Pin_Missile l 5 b \"strzeal pociskiem ktory odpycha przeciwnikow\"\n" );
	fputs(f,	"Poison_Gas h 0 e \"emituje gaz ktory zatruwa przeciwnikow\"\n" );
	fputs(f,	"Poison_Powder h 10 b \"rozsiewa proszek ktory zatruwa przeciwnikow\"\n" );
	fputs(f,	"Poison_Sting h 0 d \"zatruwa przeciwnikow\"\n" );
//	fputs(f,	"Pound a \"\"\n" );
	fputs(f,	"Psybeam k 10 b \"strzela poteznym kierowanym promieniem\"\n" );
	fputs(f,	"Psychic k 15 b \"rani i ujawnia pobliskich przeciwnikow\"\n" );
	fputs(f,	"Psywave k 0 a \"extra wysokie obrazenia\"\n" );
	fputs(f,	"Quick_Attack a 15 b \"bonus predkosci\"\n" );
	fputs(f,	"Rage a 0 ad \"zadaje dodatkowe obrazenia\"\n" );
	fputs(f,	"Razor_Leaf e 10 b \"strzela liscmi\"\n" );
//	fputs(f,	"Razor_Wind a \"\"\n" );
	fputs(f,	"Recover a 15 b \"przywraca zdrowie\"\n" );
	fputs(f,	"Reflect k 0 d \"odbija obrazenia z granatow\"\n" );
	fputs(f,	"Rest k 0 b \"usypia aby odzyskac zdrowie\"\n" );
	fputs(f,	"Roar a 10 b \"zmniejsza przeciwnikom pociski w magazynku\"\n" );
	fputs(f,	"Rock_Slide m 15 b \"tworzy spadajace glazy\"\n" );
	fputs(f,	"Rock_Throw m 5 b \"strzela glazem\"\n" );
//	fputs(f,	"Rolling_Kick g \"\"\n" );
	fputs(f,	"Sand_Attack a 5 b \"strzela piachem ktory oslepia przeciwnikow\"\n" );
	fputs(f,	"Scratch a 0 d \"paralizuje przeciwnikow\"\n" );
	fputs(f,	"Screech a 10 b \"opoznia pobliskich przeciwnikow\"\n" );
	fputs(f,	"Seismic_Toss g 0 c \"rzuca przeciwnikami na wielkie odleglosci\"\n" );
	fputs(f,	"Self_Destruct a 0 b \"wybucha\"\n" );
//	fputs(f,	"Sharpen a \"\"\n" );
	fputs(f,	"Sing a 10 b \"usypia pobliskich przeciwnikow\"\n" );
	fputs(f,	"Skullbash a 0 c \"rani przeciwnikow i odpycha ich\"\n" );
	fputs(f,	"Sky_Attack j 15 b \"teleportuje w powietrze, a nastepnie za plecy przeciwnika\"\n" );
//	fputs(f,	"Slam a \"\"\n" );
	fputs(f,	"Slash a 3 a \"rani pobliskich przeciwnikow\"\n" );
	fputs(f,	"Sleep_Powder e 10 b \"rozsiewa proszek ktory usypia przeciwnikow\"\n" );
//	fputs(f,	"Sludge h \"\"\n" );
	fputs(f,	"Smog h 0 e \"emituje gaz ktory zaciemnia przeciwnikom ekran\"\n" );
	fputs(f,	"Smokescreen a 15 b \"strzela dymem ktory oslepia przeciwnikow\"\n" );
//	fputs(f,	"Softboiled a \"\"\n" );
	fputs(f,	"Solar_Beam e 15 b \"strzela poteznym promieniem na zewnatrz\"\n" );
	fputs(f,	"Sonic_Boom a 10 b \"rani pobliskich przeciwnikow\"\n" );
	fputs(f,	"Spike_Cannon a 0 b \"strzela malymi kolcami\"\n" );
	fputs(f,	"Splash a 1 b \"zabawa w wodzie\"\n" );
	fputs(f,	"Spore e 10 b \"stawia zarodniki ktore zatruwaja przeciwnika\"\n" );
	fputs(f,	"Stomp a 3 b \"paralizuje pobliskich wrogow\"\n" );
	fputs(f,	"Strength a 0 br \"lapie i porusza rozne rzeczy\"\n" );
	fputs(f,	"String_Shot l 0 a \"spowalnia przeciwnikow\"\n" );
//	fputs(f,	"Struggle a \"\"\n" );
	fputs(f,	"Stun_Spore e 7.5 b \"stawia zarodniki ktore paralizuja przeciwnikow\"\n" );
	fputs(f,	"Submission g 5 c \"paralizuje wrogow\"\n" );
	fputs(f,	"Substitute a 0 b \"teleportuje na respawn\"\n" );
	fputs(f,	"Super_Fang a 0 d \"extra obrazenia nozem\"\n" );
	fputs(f,	"Supersonic a 0 b \"dezorientuje pobliskich wrogow\"\n" );
	fputs(f,	"Surf c 17.5 b \"strzela fala wody\"\n" );
	fputs(f,	"Swift a 10 b \"teleportuje do przeciwnikow\"\n" );
//	fputs(f,	"Swords_Dance a \"\"\n" );
	fputs(f,	"Tackle a 0 b \"bonus skakania\"\n" );
	fputs(f,	"Tail_Whip a 5 b \"odpycha pobliskich przeciwnikow\"\n" );
	fputs(f,	"Take_Down a 5 c \"paralizuje wrogow\"\n" );
	fputs(f,	"Teleport k 10 b \"teleportuje tam gdzie mierzysz\"\n" );
	fputs(f,	"Thrash a 0 c \"rani i trzesie przeciwnikami\"\n" );
	fputs(f,	"Thunder d 15 b \"poraza pobliskich wrogow\"\n" );
	fputs(f,	"Thunder_Wave d 0 d \"paralizuje wrogow\"\n" );
	fputs(f,	"Thunderbolt d 15 b \"poraza przeciwnikow ktorych widzisz\"\n" );
//	fputs(f,	"Thunderpunch d \"\"\n" );
	fputs(f,	"Thundershock d 20 b \"poraza obszar elektrycznoscia\"\n" );
	fputs(f,	"Toxic h 0 e \"emituje gaz ktory zatruwa wrogow\"\n" );
	fputs(f,	"Transform a 5 b \"zmienia wyglad\"\n" );
	fputs(f,	"Tri_Attack a 0 a \"dostajesz extra amunicje\"\n" );
//	fputs(f,	"Twin_Needle l \"\"\n" );
	fputs(f,	"Vice_Grip a 0 a \"paralizuje wrogow\"\n" );
	fputs(f,	"Vine_Whip e 5 bl \"rzuca przeciwnikami w powietrze\"\n" );
	fputs(f,	"Water_Gun c 0 b \"strzela promieniem wody\"\n" );
	fputs(f,	"Waterfall c 15 b \"tworzy wodospad ktory leczy ciebie i sojusznikow\"\n" );
	fputs(f,	"Whirlwind a 10 b \"rani i wyrzuca przeciwnikow w powietrze\"\n" );
//	fputs(f,	"Wing_Attack j \"\"\n" );
	fputs(f,	"Withdraw c 0 d \"dostajesz extra pancerz\"\n" );
	fputs(f,	"Wrap j 0 a \"paralizuje wrogow\"\n" );

	fclose(f);
 }
 public ResetSafari()
 {
	new PokeFile[128];
	Poke_FileName( F_Safari, PokeFile);

	if(file_exists(PokeFile))
		delete_file(PokeFile)

	new f = fopen(PokeFile, "at");

	fputs(f,	"// Note - Do not edit here unless you know what your doing, otherwise use pm_safari\n" );
	fputs(f,	"// Place pokemon name then their level.\n" );
	fputs(f,	"// Level = 0 (No one can use) Level = -# (Only Admin can use)\n" );
	fputs(f,	"// Level = -1000 (Disabled entirely)\n" );

	fputs(f,	"Bulbasaur 1\n" );
	fputs(f,	"Charmander 1\n" );
	fputs(f,	"Squirtle 1\n" );
	fputs(f,	"Pikachu 1\n" );

	fputs(f,	"Articuno 1\n" );
	fputs(f,	"Zapdos 1\n" );
	fputs(f,	"Moltres 1\n" );
	fputs(f,	"Mew 1\n" );
	fputs(f,	"Mewtwo 1\n" );

	fclose(f);
 }

 public ResetMapsConfig()
 {
	new PokeFile[128];
	Poke_FileName( F_PokeMaps, PokeFile);

	if(file_exists(PokeFile))
		delete_file(PokeFile)

	new f = fopen(PokeFile, "at");

	fputs(f,	"// Note - Only add things here if you know what you are doing.\n" );
	fputs(f,	"// When adding map specific configs, do the following:\n" );
	fputs(f,	"//  1. list the map name in brakets\n" );
	fputs(f,	"//  2. list things you want under it\n" );
	fputs(f,	"//  3. do not put comments in the front of the line ( // or ; )\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"// Examples:\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"//[de_dust]\n" );
	fputs(f,	"//-disabled\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"//[as_*]\n" );
	fputs(f,	"//-skills_off\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"//[dod_*]\n" );
	fputs(f,	"//pm_pokemart potion 1\n" );

	fclose(f);
 }
 
 public ResetXPs()
 {
	new PokeFile[128];
	Poke_FileName( F_XPs, PokeFile);

	if(file_exists(PokeFile))
		delete_file(PokeFile)

	new f = fopen(PokeFile, "at");

	fputs(f,	"// Just place the level XPs how you want\n" );
	fputs(f,	"// Note - Even if you don't set it, level 1 will always be 0 xp.\n" );
	fputs(f,	NEWLINE );
	fputs(f,	"0	10	20	30	50	70	100	130	170	210	//1-10\n" );
	fputs(f,	"260	310	370	430	500	570	650	730	820	910	//11-20\n" );
	fputs(f,	"1010	1110	1220	1330	1450	1570	1700	1830	1970	2110	//21-30\n" );
	fputs(f,	"2260	2410	2570	2730	2900	3070	3250	3430	3620	3810	//31-40\n" );
	fputs(f,	"4010	4210	4420	4630	4850	5070	5300	5530	5770	6010	//41-50\n" );
	fputs(f,	"6260	6510	6770	7030	7300	7570	7850	8130	8420	8710	//51-60\n" );
	fputs(f,	"9010	9310	9620	9930	10250	10570	10900	11230	11570	11910	//61-70\n" );
	fputs(f,	"12260	12610	12970	13330	13700	14070	14450	14830	15220	15610	//71-80\n" );
	fputs(f,	"16010	16410	16820	17230	17650	18070	18500	18930	19370	19810	//81-90\n" );
	fputs(f,	"20260	20710	21170	21630	22100	22570	23050	23530	24020		//91-99\n" );

	fclose(f);
 }

 public ReadSkills()
 {
	new PokeFile[128];
	Poke_FileName( F_Skill, PokeFile);
	new Data[256]
	new Left[DESC_LENGTH], Right[151]
	new skill

	SkillsCreated = 0;
	debugMessage(_,2,"Begining to read skills file.");

	new f = fopen(PokeFile, "rt");
	while( !feof(f) )
	{
		if( skill == TOTAL_SKILLS )
			break;

		fgets(f, Data, 255);

		if( ValidData( Data )<2 )
			continue;

		//"Function type delay props"

		//"Function" "type delay props"
		strbreak(Data, Left, NAME_LENGTH-1, Right, 150);
		remove_quotes(Left);

		if( funcidx( Left ) == -1 ){
			poke_error("Invalid Skill '%s'", Left);
			continue;
		}
		copy( SkillName[skill], NAME_LENGTH-1, Left );

		//should be
		//"type" "delay props"
		//but people are stupid, so were going to do a while loop and look randomly
		strbreak(Right, Left, DESC_LENGTH-1, Right, 150);

		while( ValidData(Left) ){
			if( is_str_float(Left) ){
				if( !SkillDelay[skill] )		SkillDelay[skill] = str_to_float(Left);
			}
			else{
				if( !SkillType[skill] )			SkillType[skill] = POKE_TYPE:read_flags(Left);
				else if( !SkillInfo[skill] )	SkillInfo[skill] = read_flags(Left);
				else							copy(SkillDesc[skill], DESC_LENGTH-1, Left);
			}

			strbreak(Right, Left, DESC_LENGTH-1, Right, 150);
		}

		if( !SkillInfo[skill] )
			debugMessage(_,2,"Skill(%s) does not have any call flags", SkillName[skill]);

		SkillsCreated++;
		skill++;
	}
	fclose(f);

	debugMessage(_,2,"Skills loaded (%d total)", SkillsCreated);
 }
 public ReadPokemon( read_data )
 {
	new PokeFile[128];
	Poke_FileName( F_Pokemon, PokeFile);
	new Data[256]
	new Left[NAME_LENGTH], Right[151]
	new poke, evolve_num

	if( read_data ) debugMessage(_,2,"Begining to read pokemon file");

	poke = 1;
	new f = fopen(PokeFile, "rt");
	while( !feof(f) )
	{
		fgets(f, Data, 255);

		if( !ValidData( Data )  )
			continue;

		//"Number Name type attack props evolution"

		//"Number" "Name type attack props evolution"
		strbreak(Data, Left, NAME_LENGTH-1, Right, 150);
		poke = str_to_num(Left);

		if( poke < 1 || poke > TOTAL_POKES )
			continue;
		if( poke > PokesCreated )
			PokesCreated = poke;

		//"Name" "type attack props evolution"
		strbreak(Right, Left, NAME_LENGTH-1, Right, 150);
		remove_quotes(Left);
		copy( POKENAMES[poke], NAME_LENGTH-1, Left );

		if( !read_data )
			continue;

		//"type" "attack props evolution"
		strbreak(Right, Left, NAME_LENGTH-1, Right, 150);
		remove_quotes(Left);
		PokeType[poke] = POKE_TYPE:read_flags(Left);

		if( containi(Right, "\"") != -1 ){
			strbreak(Right, Left, NAME_LENGTH-1, Right, 150);
			remove_quotes(Left);
			PokeSkill[poke] = NameToSkill(Left);

			if( PokeSkill[poke] == -1 )
				poke_error("%s does not have a valid skill (%s)", PokeToName(poke), Left);
		}
		else{
			PokeSkill[poke] = -1;
			poke_error("%s does not have any skill specified.", PokeToName(poke));
		}

		strbreak(Right, Left, NAME_LENGTH-1, Right, 150);
		remove_quotes(Left);
		PokeInfo[poke] = read_flags(Left);

		if( EvoPoke(poke) )
		{
			evolve_num = 0;
			while( ValidData( Right ) ){
				strbreak(Right, Left, NAME_LENGTH-1, Right, 150)
				remove_quotes(Left)
				PokeEvolve[evolve_num][poke] = str_to_num(Left)
				if( !PokeEvolve[evolve_num][poke] ){
					if(equali(Left, "TRADE"))
						PokeEvolve[evolve_num][poke] = TRADE_EVOLVE
					else
						PokeEvolve[evolve_num][poke] = -1*NameToItem(Left,false) // negative so we know it isn't a level
				}
				if( PokeEvolve[evolve_num][poke] ){
					strbreak(Right, Left, NAME_LENGTH-1, Right, 150)
					remove_quotes(Left)
					PokeEvolveTo[evolve_num][poke] = NameToPoke(Left)
					if( PokeEvolveTo[evolve_num][poke] )
						evolve_num++
					else
						PokeEvolve[evolve_num][poke] = 0
				}
			}
		}
	}
	fclose(f);

	copy( POKENAMES[0], NAME_LENGTH-1, "None" );
	PokeSkill[0] = -1;

	if( read_data ) debugMessage(_,2,"Pokemon loaded (%d total)", PokesCreated);
 }

 public ReadXPs()
 {
	new PokeFile[128];
	Poke_FileName( F_XPs, PokeFile);

	if( !file_exists(PokeFile) ){
		poke_error("**WARNING** PokeMod XP Table not found, making default")
		ResetXPs();
	}

	new Data[256];
	new Left[11];
	new last_level;

	new f = fopen(PokeFile, "rt");
	while( !feof(f) )
	{
		fgets(f, Data, 255);
		strbreak(Data, Left, 10, Data, 255);

		while( ValidData(Left) )
		{
			if( last_level >= MAX_LEVELS ){
				debugMessage( _, 1, "More than %d levels in xp table file", MAX_LEVELS);
				//we're going to end the while loop, but we'll need to end the other while loop also
				fseek(f, 0, SEEK_END);
				break;
			}

			PokeLevels[last_level] = str_to_num(Left);
			debugMessage( _, 7, "Level %d = %d xp", last_level, PokeLevels[last_level] );

			if(last_level && PokeLevels[last_level-1] >= PokeLevels[last_level]){

				poke_error( "ERROR in XP File: level %d(%d) >= level %d(%d)",last_level-1,PokeLevels[last_level-1],last_level,PokeLevels[last_level] )

				//we're going to end the while loop, but we'll need to end the other while loop also
				fseek(f, 0, SEEK_END);
				break;

			}
			else
				last_level++

			strbreak(Data, Left, 10, Data, 255);
		}
	}
	fclose(f);

	//set first level to 0 xp
	PokeLevels[0] = 0;
	TotalLevels = last_level;

	debugMessage( _, 1, "Loaded %d levels", last_level);
 }
 
 SearchCvars()
 {
	for(new i=0; i<MAX_CVARS; i++)
		if(get_ppcvar_line(i) == -1)
			set_ppcvar_line(i, cvar_default[i]);
 }
 
