protected static void doWeapon(Weapon I, String name, int val1, String str1, int val2, int val3, int val4, String str4)
	{
		final String[][] weaponTypes={
			{ "exotic","0"},
			{ "sword","1"},
			{ "dagger","9"},
			{ "spear","3"},
			{ "staff","10"},
			{ "mace","4"},
			{ "axe","5"},
			{ "flail","6"},
			{ "whip","7"},
			{ "polearm","8"},
			{ "bow","0"},
			{ "arrow","3"},
			{ "lance","3"}
		};
		str1=str1.toLowerCase().trim();
		if(str1.startsWith("'"))
			str1=str1.substring(1);
		for (final String[] weaponDamageType : weaponTypes)
		{
			if(str1.startsWith(weaponDamageType[0]))
			{
				val1 = CMath.s_int(weaponDamageType[1]);
				break;
			}
		}
		if(val1==0)
		{
			for (final String[] weaponDamageType : weaponTypes)
			{
				if(name.toLowerCase().indexOf(weaponDamageType[0])>=0)
				{
					val1 = CMath.s_int(weaponDamageType[1]);
					break;
				}
			}
		}
		if((name.toUpperCase().endsWith("HAMMER"))&&(val1==4))
			val1=11;
		switch(val1)
		{
		case 0:
			I.setWeaponClassification(Weapon.CLASS_RANGED);
			if (name.toUpperCase().indexOf("BOW") >= 0)
			{
				if (I instanceof AmmunitionWeapon)
				{
					((AmmunitionWeapon) I).setAmmoCapacity(20);
					((AmmunitionWeapon) I).setAmmoRemaining(20);
					((AmmunitionWeapon) I).setAmmunitionType("arrows");
				}
				I.setRanges(1, 3);
				I.setRawLogicalAnd(true);
			}
			break;
		case 1:
			I.setWeaponClassification(Weapon.CLASS_SWORD);
			break;
		case 2:
			I.setWeaponClassification(Weapon.CLASS_EDGED);
			break;
		case 3:
			I.setWeaponClassification(Weapon.CLASS_POLEARM);
			I.setRanges(0, 1);
			I.setRawLogicalAnd(true);
			break;
		case 4:
			I.setWeaponClassification(Weapon.CLASS_BLUNT);
			break;
		case 5:
			I.setWeaponClassification(Weapon.CLASS_AXE);
			break;
		case 6:
			I.setWeaponClassification(Weapon.CLASS_FLAILED);
			I.setRanges(0, 1);
			break;
		case 7:
			I.setWeaponClassification(Weapon.CLASS_FLAILED);
			I.setRanges(0, 1);
			break;
		case 8:
			I.setWeaponClassification(Weapon.CLASS_POLEARM);
			I.setRanges(0, 1);
			I.setRawLogicalAnd(true);
			break;
		case 9:
			I.setWeaponClassification(Weapon.CLASS_DAGGER);
			break;
		case 10:
			I.setWeaponClassification(Weapon.CLASS_STAFF);
			break;
		case 11:
			I.setWeaponClassification(Weapon.CLASS_HAMMER);
			break;
		}
		if(val2>=1)
			I.basePhyStats().setDamage(val2*val3);
		else
			I.basePhyStats().setDamage(val3);
		if((str4.trim().length()>0)&&((Character.isLetter(str4.trim().charAt(0)))||(str4.trim().startsWith("'"))))
		{
			str4=str4.toUpperCase().trim();
			if(str4.startsWith("'"))
			   str4=str4.substring(1);
			if(str4.startsWith("POUND"))
				val4=7;
			else
			if(str4.startsWith("CRUSH"))
				val4=7;
			else
			if(str4.startsWith("SMASH"))
				val4=7;
			else
			if(str4.startsWith("FLAMI"))
				val4=57;
			else
			if(str4.startsWith("SCORC"))
				val4=57;
			else
			if(str4.startsWith("SEARI"))
				val4=57;
			else
			if(str4.startsWith("GOUT"))
				val4=57;
			else
			if(str4.startsWith("SCRATCH"))
				val4=22;
			else
			if(str4.startsWith("CLAW"))
				val4=22;
			else
			if(str4.startsWith("BITE"))
				val4=22;
			else
			if(str4.startsWith("PECK"))
				val4=22;
			else
			if(str4.startsWith("STING"))
				val4=22;
			else
			if(str4.startsWith("BEAT"))
				val4=22;
			else
			if(str4.startsWith("SLAP"))
				val4=22;
			else
			if(str4.startsWith("PUNC"))
				val4=22;
			else
			if(str4.startsWith("WHALL"))
				val4=22;
			else
			if(str4.startsWith("STAB"))
				val4=2;
			else
			if(str4.startsWith("PIERCE"))
				val4=2;
			else
			if(str4.startsWith("CHOP"))
				val4=25;
			else
			if(str4.startsWith("CLEA"))
				val4=25;
			else
			if(str4.startsWith("SLIC"))
				val4=25;
			else
			if(str4.startsWith("SLAS"))
				val4=25;
			else
			if(str4.startsWith("WHIP"))
				val4=25;
		}
		switch(val4)
		{
		case 7:
		case 8:
		case 27:
			I.setWeaponDamageType(Weapon.TYPE_BASHING);
			break;
		case 29:
		case 55:
		case 56:
		case 57:
			I.setWeaponDamageType(Weapon.TYPE_BURNING);
			break;
		case 22:
		case 5:
		case 10:
		case 23:
		case 26:
		case 32:
		case 13:
		case 16:
		case 17:
		case 24:
			I.setWeaponDamageType(Weapon.TYPE_NATURAL);
			break;
		case 2:
		case 11:
			I.setWeaponDamageType(Weapon.TYPE_PIERCING);
			break;
		case 25:
		case 21:
		case 4:
		case 3:
		case 1:
			I.setWeaponDamageType(Weapon.TYPE_SLASHING);
			break;

		default:
			I.setWeaponDamageType(Weapon.TYPE_BURSTING);
			break;
		}
	}