From a7d1981d7147be8eaa10b116d63287a4f7513f23 Mon Sep 17 00:00:00 2001 From: Thefeli73 Date: Thu, 8 Oct 2020 02:49:39 +0200 Subject: [PATCH] ema length --- main.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index af97689..b9c8cf9 100644 --- a/main.py +++ b/main.py @@ -34,6 +34,7 @@ def main(): # global vars rounds_between_energy = 5 EMA_temp = None + ema_length = 16 building_under_construction = None available_tiles = [] queue_timeout = 1 @@ -50,7 +51,7 @@ def main(): try: if EMA_temp is None: EMA_temp = state.current_temp - ema_k_value = (2/(rounds_between_energy+1)) + ema_k_value = (2/(ema_length+1)) EMA_temp = state.current_temp * ema_k_value + EMA_temp*(1-ema_k_value) take_turn() except Exception: