Paint a WAE station by the traffic left with it, as N1MM does

N1MM has four colours for a station in WAE rather than the usual three, and
the manual and the RTTY tutorial both spell them out. Red is a new
multiplier, as everywhere else. Green is a new station with QTC traffic
still to exchange, which takes the more-than-one-multiplier colour because
WAE has no second multiplier to use it. Black is a station already worked
that still has traffic left — worth working for the QTC points alone — and
it is a colour of its own, N1MM's "Color of a QTC callsign in the WAE
contest". Grey is a dupe with nothing left, the same as in other contests.

The verdict carries how much traffic is left with the station, so the
callsign box, the check window, the bandmap and everything else that colours
a station say the same thing. The contest works the number out: ten with a
station on the other side of the contest, none with one on our own
continent, and none once the ten have gone. Every other contest answers
nought. The log counts the QTC rows per station as they are indexed rather
than counting them again for each station judged, because the bandmap judges
every spot it holds on every pass.

The verdict line says it in words as well, so a dupe reads `dupe · 7 QTCs
left` rather than `dupe`.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0157i7PiZyqBkquxS9A6FTdQ
This commit is contained in:
2026-09-10 20:03:32 +00:00
co-authored by Claude Opus 5
parent f24cab0ae5
commit 2079bf3f59
8 changed files with 136 additions and 8 deletions
+65
View File
@@ -171,6 +171,71 @@ public class WaeTests
Assert.Equal(2, log.Tally.TotalMultipliers);
}
/// N1MM paints a station by what is left to exchange with it as well as by
/// what it scores, so the verdict carries how much traffic is left: ten
/// with a station on the other side of the contest, none with one on our
/// own, and none once the ten have gone.
[Fact]
public void TheVerdictSaysHowMuchTrafficIsLeft()
{
ContestLog log = LogFor(Cw, TestLog.Germany);
Assert.Equal(10, log.Judge(On("JA1XYZ", 14_025)).TrafficLeft);
Assert.Equal(0, log.Judge(On("OM5M", 14_025)).TrafficLeft);
}
[Fact]
public void TrafficRunsOutAfterTenLines()
{
ContestLog log = LogFor(Cw, TestLog.Germany);
log.Add(On("JA1XYZ", 14_025));
for (int line = 1; line <= 10; line++)
{
log.Add(new WaeQtc(
Callsign.Parse("JA1XYZ"), IsSent: false, 1, 10, "1435", Callsign.Parse("W1AW"), line)
.ApplyTo(On("JA1XYZ", 14_025)));
}
Verdict verdict = log.Judge(On("JA1XYZ", 14_025));
Assert.True(verdict.IsDupe);
Assert.Equal(0, verdict.TrafficLeft);
}
/// A station already worked is still worth working while it has traffic
/// left, which is the state N1MM paints in a colour of its own.
[Fact]
public void ADupeWithTrafficLeftSaysSo()
{
ContestLog log = LogFor(Cw, TestLog.Germany);
log.Add(On("JA1XYZ", 14_025));
Verdict verdict = log.Judge(On("JA1XYZ", 14_025));
Assert.True(verdict.IsDupe);
Assert.Equal(10, verdict.TrafficLeft);
}
/// On RTTY the line is between continents rather than between Europe and
/// the rest, so two European stations still cannot exchange traffic.
[Fact]
public void OnRttyTrafficNeedsTwoContinents()
{
ContestLog log = LogFor(Rtty, TestLog.Germany);
Assert.Equal(10, log.Judge(On("JA1XYZ", 14_080, Modes.Rtty)).TrafficLeft);
Assert.Equal(0, log.Judge(On("OM5M", 14_080, Modes.Rtty)).TrafficLeft);
}
/// Every other contest has no traffic at all.
[Fact]
public void AContestWithoutTrafficLeavesTheNumberAtNought()
{
ContestLog log = new(new CqWorldWide(ModeCategory.Cw), TestLog.Germany, TestLog.CountryFile);
Assert.Equal(0, log.Judge(TestLog.Contact("JA1XYZ", zone: 25)).TrafficLeft);
}
/// ADIF has no QTC record, so the export writes contacts alone. N1MM says
/// the same in its manual: "the ADIF file will not contain QTCs, only
/// QSOs".