int mPlayerTurn = mMatch.getPlayerTurn();
Weighting.resetAllWeightings();
Weighting weightingUsed = Weighting.DEFAULT;
if (mPlayer instanceof MatchComputerPlayer)
{
MatchComputerPlayer cp = (MatchComputerPlayer) mPlayer;
AIPlayer aip = cp.getAIPlayer();
if (!aip.isScriptedAI())
{
EAIConfigurationData eaiConfig = aip.getEAIConfig();
if (eaiConfig != null)
{
String wName = eaiConfig.getActiveWeightingCollection();
weightingUsed = Weighting.buildWeighting(wName);
}
}
}
if (mVMatch == null)
{
mPlayerTurn = mMatch.getPlayerTurn();
weightingUsed.buildScore(mMatch, mPlayerTurn, false);
weightingUsed.buildScore(mMatch, (mPlayerTurn+1)%2, false);
}
else
{
mPlayerTurn = mPlayerNo;
weightingUsed.buildScore(mVMatch, mPlayerTurn, false);
weightingUsed.buildScore(mVMatch, (mPlayerTurn+1)%2, false);
}
WeightingPanel panel = new WeightingPanel(mPlayerTurn, weightingUsed);
mMatch.getMainDisplay().showPanelModal(panel, "Weighting player: " +mPlayerTurn, 750, 400);
}//GEN-LAST:event_jButton3ActionPerformed