diff --git a/js-web/KubeInvaders/archive/archive_files.json b/js-web/KubeInvaders/archive/archive_files.json index d9d460b..9e7f2ea 100644 --- a/js-web/KubeInvaders/archive/archive_files.json +++ b/js-web/KubeInvaders/archive/archive_files.json @@ -1 +1 @@ -{"content":[{"name":"game.projectc","size":2335,"pieces":[{"name":"game.projectc0","offset":0}]},{"name":"game.arci","size":5488,"pieces":[{"name":"game.arci0","offset":0}]},{"name":"game.arcd","size":290224,"pieces":[{"name":"game.arcd0","offset":0}]},{"name":"game.dmanifest","size":9710,"pieces":[{"name":"game.dmanifest0","offset":0}]},{"name":"game.public.der","size":162,"pieces":[{"name":"game.public.der0","offset":0}]}]} \ No newline at end of file +{"content":[{"name":"game.projectc","size":2335,"pieces":[{"name":"game.projectc0","offset":0}]},{"name":"game.arci","size":5488,"pieces":[{"name":"game.arci0","offset":0}]},{"name":"game.arcd","size":290100,"pieces":[{"name":"game.arcd0","offset":0}]},{"name":"game.dmanifest","size":9710,"pieces":[{"name":"game.dmanifest0","offset":0}]},{"name":"game.public.der","size":162,"pieces":[{"name":"game.public.der0","offset":0}]}]} \ No newline at end of file diff --git a/js-web/KubeInvaders/archive/game.arcd0 b/js-web/KubeInvaders/archive/game.arcd0 index 3d1d479..1ce8ecf 100644 Binary files a/js-web/KubeInvaders/archive/game.arcd0 and b/js-web/KubeInvaders/archive/game.arcd0 differ diff --git a/js-web/KubeInvaders/archive/game.arci0 b/js-web/KubeInvaders/archive/game.arci0 index ac9ec51..ba82557 100644 Binary files a/js-web/KubeInvaders/archive/game.arci0 and b/js-web/KubeInvaders/archive/game.arci0 differ diff --git a/js-web/KubeInvaders/archive/game.dmanifest0 b/js-web/KubeInvaders/archive/game.dmanifest0 index 6a2b9c9..2db4a93 100644 Binary files a/js-web/KubeInvaders/archive/game.dmanifest0 and b/js-web/KubeInvaders/archive/game.dmanifest0 differ diff --git a/js-web/KubeInvaders/archive/game.public.der0 b/js-web/KubeInvaders/archive/game.public.der0 index 50f84ee..a3287e4 100644 Binary files a/js-web/KubeInvaders/archive/game.public.der0 and b/js-web/KubeInvaders/archive/game.public.der0 differ diff --git a/main/spaceship.script b/main/spaceship.script index 6ceee52..393a1a8 100644 --- a/main/spaceship.script +++ b/main/spaceship.script @@ -139,7 +139,7 @@ end function http_update_pod_result(self, _, response) kubernetes_pods = {} - msg.post("ui#gui", "error",{ errormessage = alien_proximity_factor .. " " .. hit_cpu_time_rate_limit .. " " .. os.getenv("ALIENPROXIMITY") .." " .. os.getenv("HITSLIMIT") .. " k8s status code request: " .. response.status }) + msg.post("ui#gui", "error",{ errormessage = alien_proximity_factor .. " " .. hit_cpu_time_rate_limit .. " " .. os.getenv("ALIENPROXIMITY") .." " .. os.getenv("HITSLIMIT") .. " " .. os.clock() .. " ".. response.status }) if response.status == 0 then msg.post("ui#gui", "error",{ errormessage = "Error connecting to " .. conf['endpoint'] }) end @@ -309,27 +309,13 @@ function init(self) local contents = file:read( "*a" ) conf = json.decode(contents); io.close(file) - - if conf['ALIENPROXIMITY'] ~= nil then - alien_proximity_factor = conf['ALIENPROXIMITY'] - end - - if conf['HITSLIMIT'] ~= nil then - hit_cpu_time_rate_limit = conf['HITSLIMIT'] - end - else conf["token"] = os.getenv("TOKEN") conf["endpoint"] = os.getenv("ENDPOINT") conf["namespace"] = os.getenv("NAMESPACE") - if os.getenv("ALIENPROXIMITY") ~= nil then - alien_proximity_factor = os.getenv("ALIENPROXIMITY") - end - - if os.getenv("HITSLIMIT") ~= nil then - hit_cpu_time_rate_limit = os.getenv("HITSLIMIT") - end + alien_proximity_factor = os.getenv("ALIENPROXIMITY") + hit_cpu_time_rate_limit = os.getenv("HITSLIMIT") end @@ -449,7 +435,7 @@ function on_input(self, action_id, action) current_hit_time = os.clock() if automatic == false then shot = true - if (hit_cpu_time_rate_limit ~= nil) and (current_hit_time - last_hit_time < hit_cpu_time_rate_limit) then + if ((current_hit_time - last_hit_time) < hit_cpu_time_rate_limit) then shot = false end if shot == true then