foxapi 1.0.7__tar.gz → 1.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,13 +1,13 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: foxapi
3
- Version: 1.0.7
3
+ Version: 1.1.0
4
4
  Summary: A wrapper for the foxhole API
5
5
  Home-page: https://github.com/ThePhoenix78/FoxAPI
6
6
  Download-URL: https://github.com/ThePhoenix78/FoxAPI/tarball/master
7
7
  Author: ThePhoenix78
8
8
  Author-email: thephoenix788@gmail.com
9
9
  License: MIT
10
- Keywords: foxhole,foxapi
10
+ Keywords: foxhole,foxapi,foxhole-game
11
11
  Classifier: Programming Language :: Python :: 3
12
12
  Classifier: License :: OSI Approved :: MIT License
13
13
  Classifier: Operating System :: OS Independent
@@ -54,7 +54,7 @@ Also, if you work with discord.py or any asynchronous API, this tool might be us
54
54
  ## Wrapper
55
55
 
56
56
  ```python
57
- class FoxAPI(image_dir: str = None, safe_mode: bool = True)
57
+ class FoxAPI(shard: str = "", image_dir: str = None, safe_mode: bool = True)
58
58
  ```
59
59
 
60
60
 
@@ -162,7 +162,9 @@ from foxapi import FoxAPI
162
162
  # api calls and hexagons name into valid ones
163
163
  # Ex: deadlands -> DeadLandsHex (Yes, I am *that* lazy)
164
164
 
165
- fox = FoxAPI()
165
+ # don't forget to download the image folder https://github.com/ThePhoenix78/FoxAPI/tree/main/foxapi
166
+
167
+ fox = FoxAPI(shard="2", image_dir="Images")
166
168
 
167
169
  hexagon: str = "DeadLandsHex"
168
170
 
@@ -36,7 +36,7 @@ Also, if you work with discord.py or any asynchronous API, this tool might be us
36
36
  ## Wrapper
37
37
 
38
38
  ```python
39
- class FoxAPI(image_dir: str = None, safe_mode: bool = True)
39
+ class FoxAPI(shard: str = "", image_dir: str = None, safe_mode: bool = True)
40
40
  ```
41
41
 
42
42
 
@@ -144,7 +144,9 @@ from foxapi import FoxAPI
144
144
  # api calls and hexagons name into valid ones
145
145
  # Ex: deadlands -> DeadLandsHex (Yes, I am *that* lazy)
146
146
 
147
- fox = FoxAPI()
147
+ # don't forget to download the image folder https://github.com/ThePhoenix78/FoxAPI/tree/main/foxapi
148
+
149
+ fox = FoxAPI(shard="2", image_dir="Images")
148
150
 
149
151
  hexagon: str = "DeadLandsHex"
150
152
 
@@ -21,8 +21,17 @@ import os
21
21
 
22
22
 
23
23
  class FoxAPI():
24
- def __init__(self, image_dir: str = None, safe_mode: bool = True):
25
- self.base_api: str = "https://war-service-live.foxholeservices.com/api/worldconquest"
24
+ def __init__(self, shard: str = "", image_dir: str = None, safe_mode: bool = True):
25
+ if shard in [1, "1"]:
26
+ shard: str = ""
27
+
28
+ elif shard in [2, "2", "-2"]:
29
+ shard: str = "-2"
30
+
31
+ elif shard in [3, "3", "-3"]:
32
+ shard: str = "-3"
33
+
34
+ self.base_api: str = f"https://war-service-live{shard}.foxholeservices.com/api/worldconquest"
26
35
  self.session: requests.Session = requests.Session()
27
36
 
28
37
  if image_dir is not None:
@@ -1,13 +1,13 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: foxapi
3
- Version: 1.0.7
3
+ Version: 1.1.0
4
4
  Summary: A wrapper for the foxhole API
5
5
  Home-page: https://github.com/ThePhoenix78/FoxAPI
6
6
  Download-URL: https://github.com/ThePhoenix78/FoxAPI/tarball/master
7
7
  Author: ThePhoenix78
8
8
  Author-email: thephoenix788@gmail.com
9
9
  License: MIT
10
- Keywords: foxhole,foxapi
10
+ Keywords: foxhole,foxapi,foxhole-game
11
11
  Classifier: Programming Language :: Python :: 3
12
12
  Classifier: License :: OSI Approved :: MIT License
13
13
  Classifier: Operating System :: OS Independent
@@ -54,7 +54,7 @@ Also, if you work with discord.py or any asynchronous API, this tool might be us
54
54
  ## Wrapper
55
55
 
56
56
  ```python
57
- class FoxAPI(image_dir: str = None, safe_mode: bool = True)
57
+ class FoxAPI(shard: str = "", image_dir: str = None, safe_mode: bool = True)
58
58
  ```
59
59
 
60
60
 
@@ -162,7 +162,9 @@ from foxapi import FoxAPI
162
162
  # api calls and hexagons name into valid ones
163
163
  # Ex: deadlands -> DeadLandsHex (Yes, I am *that* lazy)
164
164
 
165
- fox = FoxAPI()
165
+ # don't forget to download the image folder https://github.com/ThePhoenix78/FoxAPI/tree/main/foxapi
166
+
167
+ fox = FoxAPI(shard="2", image_dir="Images")
166
168
 
167
169
  hexagon: str = "DeadLandsHex"
168
170
 
@@ -1,12 +1,12 @@
1
1
  from setuptools import setup, find_packages
2
- # from BotAmino.__init__ import __version__
2
+
3
3
 
4
4
  with open("README.md", "r") as stream:
5
5
  long_description = stream.read()
6
6
 
7
7
  setup(
8
8
  name='foxapi',
9
- version="1.0.7",
9
+ version="1.1.0",
10
10
  url='https://github.com/ThePhoenix78/FoxAPI',
11
11
  download_url='https://github.com/ThePhoenix78/FoxAPI/tarball/master',
12
12
  license='MIT',
@@ -17,7 +17,8 @@ setup(
17
17
  long_description_content_type='text/markdown',
18
18
  keywords=[
19
19
  'foxhole',
20
- 'foxapi'
20
+ 'foxapi',
21
+ 'foxhole-game'
21
22
  ],
22
23
  install_requires=[
23
24
  'requests',
File without changes
File without changes
File without changes
File without changes