vPhaseReport.addElement(r); vPhaseReport.addAll(
addReport(r); addReport(
    private void resolveThrashAttack( PhysicalResult pr,                                        int lastEntityId ) {        final ThrashAttackAction taa = (ThrashAttackAction)pr.aaa;        final Entity ae = game.getEntity(taa.getEntityId());        // get damage, ToHitData and roll from the PhysicalResult        int hits = pr.damage;        final ToHitData toHit = pr.toHit;        int roll = pr.roll;        final boolean glancing = (game.getOptions().booleanOption("maxtech_glancing_blows") && (roll == toHit.getValue()));        // PLEASE NOTE: buildings are *never* the target of a "thrash".        final Entity te = game.getEntity(taa.getTargetId());        Report r;        if (lastEntityId != taa.getEntityId()) {            //who is making the attacks            r = new Report(4005);            r.subject = ae.getId();            r.addDesc(ae);            vPhaseReport.addElement(r);        }        r = new Report(4110);        r.subject = ae.getId();        r.indent();        r.addDesc(te);        r.newlines = 0;        vPhaseReport.addElement(r);        if (toHit.getValue() == ToHitData.IMPOSSIBLE) {            r = new Report(4115);            r.subject = ae.getId();            r.add(toHit.getDesc());            vPhaseReport.addElement(r);            return;        }        // Thrash attack may hit automatically        if ( toHit.getValue() == ToHitData.AUTOMATIC_SUCCESS ) {            r = new Report(4120);            r.subject = ae.getId();            r.newlines = 0;            vPhaseReport.addElement(r);        } else {            // report the roll            r = new Report(4025);            r.subject = ae.getId();            r.add(toHit.getValue());            r.add(roll);            r.newlines = 0;            vPhaseReport.addElement(r);            // do we hit?            if (roll < toHit.getValue()) {                //miss                r = new Report(4035);                r.subject = ae.getId();                vPhaseReport.addElement(r);                return;            }            r = new Report(4125);            r.subject = ae.getId();            r.newlines = 0;            vPhaseReport.addElement(r);        }        // Standard damage loop in 5 point clusters.        if (glancing) {            hits = (int)Math.floor(hits/2.0);        }        r = new Report(4130);        r.subject = ae.getId();        r.add(hits);        r.newlines = 0;        vPhaseReport.addElement(r);        if (glancing) {            r = new Report(4030);            r.subject = ae.getId();            r.newlines = 0;            vPhaseReport.addElement(r);        }        while ( hits > 0 ) {            int damage = Math.min(5, hits);            hits -= damage;            HitData hit = te.rollHitLocation( toHit.getHitTable(),                                              toHit.getSideTable() );            r = new Report(4135);            r.subject = ae.getId();            r.add(te.getLocationAbbr(hit));            r.newlines = 0;            vPhaseReport.addElement(r);            vPhaseReport.addAll(                                  damageEntity(te, hit, damage));        }        Report.addNewline(vPhaseReport);        // Thrash attacks cause PSRs.  Failed PSRs cause falling damage.        // This fall damage applies even though the Thrashing Mek is prone.        PilotingRollData rollData = ae.getBasePilotingRoll();        ae.addPilotingModifierForTerrain(rollData);        rollData.addModifier( 0, "thrashing at infantry" );        r = new Report(4140);        r.subject = ae.getId();        r.addDesc(ae);        vPhaseReport.addElement(r);        final int diceRoll = Compute.d6(2);        r = new Report(2190);        r.subject = ae.getId();        r.addDesc(ae);        r.add(rollData.getValueAsString());        r.add(rollData.getDesc());        r.add(diceRoll);        if (diceRoll < rollData.getValue()) {            r.choose(false);            vPhaseReport.addElement(r);            doEntityFall( ae, rollData );        } else {            r.choose(true);            vPhaseReport.addElement(r);        }    }