Australia in Australia strat.

This commit is contained in:
Casper V. Kristensen 2019-04-07 03:04:26 +02:00
parent 4560ecfb63
commit 7d1b4d4537
Signed by: caspervk
GPG key ID: 289CA03790535054

View file

@ -35,12 +35,20 @@ def australiaStrat(context : Context) -> Prediction:
hour = t.hour hour = t.hour
p = Prediction() p = Prediction()
if hour > 22 or hour < 6: if context.in_australia:
p.probability = 0.0 if hour > 22 or hour < 6:
p.reasons.append('It\'s night-time in Australia, so it must be day-time here.') p.probability = 1.0
p.reasons.append('It\'s night-time in Australia, and that\'s where we\'re at.')
else:
p.probability = 0.0
p.reasons.append('It\'s day-time in Australia, and that\'s where we\'re at.')
else: else:
p.probability = 1.0 if hour > 22 or hour < 6:
p.reasons.append('It\'s day-time in Australia, so it must be night-time here.') p.probability = 0.0
p.reasons.append('It\'s night-time in Australia, so it must be day-time here.')
else:
p.probability = 1.0
p.reasons.append('It\'s day-time in Australia, so it must be night-time here.')
return p return p