BEGIN {
	ERRORLEVEL = ARGV[1]
	ARGV[1] = "-"
	FS = "[-.]"
}
{
	if(ERRORLEVEL) {
		print "TEXTURE_(" toupper($1) ")"
	} else {
		print "TEXTURE_RESOURCE_(" toupper($1) ",\"" gensub(/\.bmp$/, ".pgd", "g") "\")"
	}
}
