for (Enumeration e = getEntity().getWeapons(); e.hasMoreElements(); ) { Mounted m = (Mounted) e.nextElement();
for (Mounted m : getEntity().getWeaponList()) {
    public float getWeightWeapon()    {        float weight = 0.0f;        for (Enumeration e = getEntity().getWeapons(); e.hasMoreElements(); )        {            Mounted m = (Mounted) e.nextElement();            WeaponType mt = (WeaponType) m.getType();            weight += mt.getTonnage(getEntity());        }        return weight;    }