appropriate racial type. I'd prefer it if there was a chance involved but IMHO a given trap should shoot the same (racial) type of ammo, so this is now always the case in these two branches, for all of needle, arrow, bolt, spear and axe traps.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@2395 c06c8d41-db1a-0410-9941-cceddc491573
LGBOBJZ37D3LFSP62KD4IUA37O5ON4UDP724JHE7HZRTBSB27JZQC
bool branchtype = false;
if (trap_category(trt) == DNGN_TRAP_MECHANICAL && trt != TRAP_NET
&& trt != TRAP_BLADE)
{
if (you.where_are_you == BRANCH_ORCISH_MINES)
{
beam.name = "n orcish";
branchtype = true;
}
else if (you.where_are_you == BRANCH_ELVEN_HALLS)
{
beam.name = "n elven";
branchtype = true;
}
else
beam.name = "";
}
// give appropriate racial flag for Orcish Mines and Elven Halls
// should we ever allow properties of dungeon features, we could use that
if ( item.sub_type != MI_THROWING_NET )
{
if (you.where_are_you == BRANCH_ORCISH_MINES)
set_equip_race( item, ISFLAG_ORCISH );
else if (you.where_are_you == BRANCH_ELVEN_HALLS)
set_equip_race( item, ISFLAG_ELVEN );
}