From 15586a7bc1cdf06b39101bb93a469adff34b58b1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl?= <54442375+satepestage@users.noreply.github.com> Date: Thu, 19 Oct 2023 16:14:00 +0200 Subject: [PATCH 1/4] Limite des foreuses MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Les foreuses sont limitées à 50% de bonus. Début de prise en charge --- production.php | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/production.php b/production.php index 6346e4d..913d391 100644 --- a/production.php +++ b/production.php @@ -468,19 +468,16 @@ function calcul () { if(ratio_conso > 1) ratio_conso = 1; } if(ratio_conso > 0){ + BonusMaxForeuse = 0.5; if (class_collect.value == "1") { - F_prod_M = Math.round(CofM * ratio_conso * nb_F_1 * 0.0003 * donnee['rap_FO'][i] / 100 * Math.floor(speed * 30 * donnee['M'][i] * Math.pow(1.1,donnee['M'][i]) * (1))); - F_prod_C = Math.round(CofC * ratio_conso * nb_F_1 * 0.0003 * donnee['rap_FO'][i] / 100 * Math.floor(speed * 20 * donnee['C'][i] * Math.pow(1.1,donnee['C'][i]) * (1))); - F_prod_D = Math.round(CofD * ratio_conso * nb_F_1 * 0.0003 * donnee['rap_FO'][i] / 100 * Math.floor(speed * 10 * donnee['D'][i] * Math.pow(1.1,donnee['D'][i]) * (1.44 - 0.004 * temperature_max_1 ) * (1))); + BonusForeuse = Math.min(nb_F_1 * 0.0003 * donnee['rap_FO'][i] / 100, BonusMaxForeuse); } else { - - - F_prod_M = Math.round(CofM * ratio_conso * nb_F_1 * 0.0002 * donnee['rap_FO'][i] / 100 * Math.floor(speed * 30 * donnee['M'][i] * Math.pow(1.1,donnee['M'][i]) * (1))); - F_prod_C = Math.round(CofC * ratio_conso * nb_F_1 * 0.0002 * donnee['rap_FO'][i] / 100 * Math.floor(speed * 20 * donnee['C'][i] * Math.pow(1.1,donnee['C'][i]) * (1))); - F_prod_D = Math.round(CofD * ratio_conso * nb_F_1 * 0.0002 * donnee['rap_FO'][i] / 100 * Math.floor(speed * 10 * donnee['D'][i] * Math.pow(1.1,donnee['D'][i]) * (1.44 - 0.004 * temperature_max_1 ) * (1))); + BonusForeuse = Math.min(nb_F_1 * 0.0002 * donnee['rap_FO'][i] / 100, BonusMaxForeuse); } - + F_prod_M = Math.round(CofM * ratio_conso * BonusForeuse * Math.floor(speed * 30 * donnee['M'][i] * Math.pow(1.1,donnee['M'][i]) * (1))); + F_prod_C = Math.round(CofC * ratio_conso * BonusForeuse * Math.floor(speed * 20 * donnee['C'][i] * Math.pow(1.1,donnee['C'][i]) * (1))); + F_prod_D = Math.round(CofD * ratio_conso * BonusForeuse * Math.floor(speed * 10 * donnee['D'][i] * Math.pow(1.1,donnee['D'][i]) * (1.44 - 0.004 * temperature_max_1 ) * (1))); M_1_prod[i] = Math.round(CofM * ratio_conso * production("M", donnee['M'][i], temperature_max_1, NRJ, Plasma) * donnee['rap_M'][i] / 100) + F_prod_M; C_1_prod[i] = Math.round(CofC * ratio_conso * production("C", donnee['C'][i], temperature_max_1, NRJ, Plasma) * donnee['rap_C'][i] / 100) + F_prod_C; From 5a0011f71306592ac615ceb62d0efa5deabaee82 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl?= <54442375+satepestage@users.noreply.github.com> Date: Thu, 21 Dec 2023 15:39:37 +0100 Subject: [PATCH 2/4] Update Readme.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pour préparation version 1.5.9 --- Readme.md | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Readme.md b/Readme.md index a20f2c3..a847098 100644 --- a/Readme.md +++ b/Readme.md @@ -63,8 +63,9 @@ IV/ Versions 1.5.4 [2017-04-15]= La fonction requiert un user_id 1.5.5 [2018-10-23]= Version OGSpy Minimale 1.5.6 [2019-09-18]= Nouveau fichier de gestion -1.5.7 [2020-03-16]= Nouveau fichier de gestion -1.5.8 [2020-xx-xx]= Nouveau fichier de gestion +1.5.7 [2020-03-16]= Prise en charge technologie Plasma +1.5.8 [2020-04-14]= Prise en charge foreuses et classe +1.5.9 [2023-12-21]= Prise en charge limite de bonus des foreuses V/ Informations et liens Les bugs seront renseignés sur github (https://github.com/OGSteam/mod-production/issues/new) ou sur le forum avec comme objet : @@ -73,6 +74,6 @@ Les bugs seront renseignés sur github (https://github.com/OGSteam/mod-productio Bitbucket : https://github.com/OGSteam/mod-production Signalement de bugs : https://github.com/OGSteam/mod-production/issues/new Téléchargement : https://github.com/OGSteam/mod-production/archive/master.zip -Wiki OGSteam : http://wiki.ogsteam.fr/doku.php?id=ogspy:liste_mods#production +Wiki OGSteam : http://wiki.ogsteam.eu/doku.php?id=ogspy:liste_mods Responsable du mod : Pitch314 From 71935393803e69e7ccde90f953aeb0c4c431f474 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl?= <54442375+satepestage@users.noreply.github.com> Date: Thu, 21 Dec 2023 15:40:39 +0100 Subject: [PATCH 3/4] Update composer.json Pour version 1.5.9 --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 2f82e0b..9a3ebd8 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name" : "ogsteam/mod-production", "description" : "OGSpy Module calculating the mineral production", - "version": "1.5.8", + "version": "1.5.9", "type" : "ogspy-mod", "keywords" : [ "ogspy" ], "license" : "GPL-2.0-only", From cb5aa48db1b7ce6dedf4f84b4513dc8537876788 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C3=ABl?= <54442375+satepestage@users.noreply.github.com> Date: Thu, 21 Dec 2023 15:42:22 +0100 Subject: [PATCH 4/4] Update version.txt Version 1.5.9 du mod Production Informations prises en compte : Technologie Plasma, Energie Foreuses Classe Officiers Positions des colonies --- version.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/version.txt b/version.txt index 50ba93d..d61dedd 100644 --- a/version.txt +++ b/version.txt @@ -1,4 +1,4 @@ Production -1.5.8 +1.5.9 production,production,production,production,production.php,1,0 3.3.7