Browse Source

Just commit everything

JoostSijm 3 years ago
parent
commit
a20ea86182
7 changed files with 36 additions and 27 deletions
  1. 19 11
      building_calculator.py
  2. 7 0
      deep_expo.py
  3. 2 5
      deep_expo_percentage.py
  4. 2 2
      donations/donations.py
  5. 2 5
      factories/factories.py
  6. 1 1
      productivity/productivity.py
  7. 3 3
      regions.py

+ 19 - 11
building_calculator.py

@@ -4,9 +4,9 @@ from rival_regions_calc import ConstructionCosts, Building
 
 PRICES = {
     'cash': 0.7,
-    'gold': 0.45,
+    'gold': 0.35,
     'oil': 250,
-    'ore': 230,
+    'ore': 220,
     'diamond': 1700000,
     'uranium': 2100
 }
@@ -39,14 +39,22 @@ def main():
 #        'power plant': 1461,
 #        'spaceport': 201,
 #        'airport': 3750,
+# oost-nl
+        'hospital': 2546,
+        'military base': 1692,
+        'school': 1605,
+        'missile system': 4550,
+        'power plant': 1461,
+        'spaceport': 201,
+        'airport': 3750,
 # noord-nl
-        'hospital': 2474,
-        'military base': 1645,
-        'school': 1564,
-        'missile system': 1200,
-        'power plant': 2570,
-        'spaceport': 4,
-        'airport': 2305
+#        'hospital': 2474,
+#        'military base': 1645,
+#        'school': 1564,
+#        'missile system': 1200,
+#        'power plant': 2570,
+#        'spaceport': 4,
+#        'airport': 2305
     }
     build_buildings = {
         'hospital': 0,
@@ -59,8 +67,8 @@ def main():
     }
 
     total_buildings = sum(item for item in buildings.values())
-    # building_goal = 36581 #5
-    building_goal = 61300 #1
+    # building_goal = 37520 #5
+    building_goal = 60500 #1
     total_price = 0
     required_buildings = building_goal - total_buildings
     power_surplus = 6198

+ 7 - 0
deep_expo.py

@@ -29,3 +29,10 @@ if __name__ == "__main__":
     calc_resource(2, 25, 0.75)
     print("lux")
     calc_resource(267, 89, 0.65)
+    print("oil zuid")
+    calc_resource(296, 75, 0.65)
+    print("gold maldiven")
+    calc_resource(198, 439, 0.4)
+
+    print("25 uranium")
+    calc_resource(25, 26, 0.75)

+ 2 - 5
deep_expo_percentage.py

@@ -9,12 +9,9 @@ def nth_root(num, root):
 def calc_resource_factor(resource_limit, koef_factor):
     """Calculate resource factor based on limit"""
     return pow(resource_limit * koef_factor / 10, 0.8)
-    # a = (resource_limit * koef_factor / 10)**0.8
-    # a = (m * n / c) ** d
 
 def calc_required_limit(koef, koef_factor):
     """Calculate amount of deep exploration points"""
-    # m = (c * nth_root(a, d)) / n
     return (10 * nth_root(koef, 0.8)) / koef_factor
 
 def calc_deep_exploration(resource_limit, percentage, koef_factor, max_limit):
@@ -41,8 +38,8 @@ if __name__ == "__main__":
     print('Oost-Nederland')
     calc_deep_exploration(359, 50, 0.4, 637)
     print('West-Nederland')
-    calc_deep_exploration(372, 20, 0.4, 637)
+    calc_deep_exploration(372, 50, 0.4, 637)
     print('Zuid-Nederland')
-    calc_deep_exploration(366, 25, 0.4, 637)
+    calc_deep_exploration(366, 50, 0.4, 637)
     print('Amsterdam')
     calc_deep_exploration(418, 45, 0.4, 637)

+ 2 - 2
donations/donations.py

@@ -55,13 +55,13 @@ def calc_reward(resources):
     reward = {
         'bbl':    130,
         'kg':     120,
-        'g':     1120,
+        # 'g':     1120,
         'pcs': 840000,
     }
     resource_koef = {
         'bbl': 1000000000,
         'kg':  1105000000,
-        'g':    100000000,
+        # 'g':    100000000,
         'pcs':     150000,
     }
     player_reward = {}

+ 2 - 5
factories/factories.py

@@ -21,12 +21,9 @@ RESOURCES = None
 with open('factories.json') as file:
     RESOURCES = json.load(file)
 
-
 WP = WorkProduction()
-WP.user_level = 73
-WP.work_exp = 80000 + 200 * 176
-WP.profit_share = 75
-
+WP.user_level = 60
+WP.work_exp = 80000 + 200 * 30
 
 def calculate_wage(resource_name, factory):
     """Calculate production"""

+ 1 - 1
productivity/productivity.py

@@ -114,7 +114,7 @@ def main():
 
         RESOURCES[resource_name][factory_id]['wage'] = calculate_wage(resource_name, factory)
 
-        for i in range(factory['level'], 221, 5):
+        for i in range(factory['level'], 221, 1):
             new_factory_id = int(factory_id) + i - 150
             new_factory = copy.copy(factory)
             new_factory['level'] = i

+ 3 - 3
regions.py

@@ -2,11 +2,11 @@
 
 from rival_regions_calc import Item, DeepExploration, ResourceCoefficient
 
-TOTAL_COSTS = True 
-PRINT_AVERAGE = False 
+TOTAL_COSTS = True
+PRINT_AVERAGE = False
 GOLD_PRICE = 0.15
 #DIAMOND_PRICE = 1600690
-DIAMOND_PRICE = 1720000
+DIAMOND_PRICE = 1684000
 REGIONS = {
     '4001': {
         'name': 'Northern Netherlands',