Skip to content
This repository was archived by the owner on Mar 11, 2022. It is now read-only.

Commit d121691

Browse files
fixes
1 parent 394f984 commit d121691

File tree

5 files changed

+15
-7
lines changed

5 files changed

+15
-7
lines changed

Basic/login.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import __init__
12
from Help_functions.login import *
23

34
# This should help to run __main__ files.

Fight/login.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import __init__
12
from Help_functions.login import *
23
# This should help to run __main__ files.
34
# Original File: Help_functions.login

Fight/motivates.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,11 @@ async def send_motivates(server, Type="all"):
5555
newCitizens_tree = await get_content(URL + 'newCitizens.html?countryId=0')
5656
start_food = int(newCitizens_tree.xpath('//*[@id="foodLimit2"]')[0].text)
5757
citizenId = int(newCitizens_tree.xpath("//tr[2]//td[1]/a/@href")[0].split("=")[1])
58+
checking = list()
5859
for _ in range(200): # newest 200 players
5960
try:
61+
if len(checking) >= 5:
62+
break
6063
tree = await get_content(f'{URL}profile.html?id={citizenId}')
6164
current_food = int(tree.xpath('//*[@id="foodLimit2"]')[0].text)
6265
if current_food - start_food == 5:
@@ -76,8 +79,9 @@ async def send_motivates(server, Type="all"):
7679
if tree.xpath('//*[@id="motivateCitizenButton"]'):
7780
for num in storage:
7881
payload = {'type': num, "submit": "Motivate", "id": citizenId}
79-
_, send = await get_content(f"{URL}motivateCitizen.html?id={citizenId}", data=payload)
82+
send = await get_content(f"{URL}motivateCitizen.html?id={citizenId}", data=payload)
8083
if "&actionStatus=SUCCESFULLY_MOTIVATED" in str(send):
84+
checking.append(str(send))
8185
print(send)
8286
break
8387
citizenId -= 1

README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
- Discord bot (control each of your trusted group accounts via commands)
2525
- And much more!
2626
---
27-
Currently there are 2 available versions of these scripts, which both of them does the same thing, but the lastest version is using **Asyncio** and **AIOHTTP** Library which is a non-blocking version of previous release for Discord bot usage, you can access both versions from this Link : [**Releases**](https://github.com/e-sim-python/scripts/releases)
27+
Currently, there are 2 available versions of these scripts, which both of them does the same thing, but the latest version is using **Asyncio** and **AIOHTTP** Library which is a non-blocking version of previous release for Discord bot usage, you can access both versions from this Link : [**Releases**](https://github.com/e-sim-python/scripts/releases)
2828

2929
As far as we know, no one has ever been punished for using these scripts. However, the use is at your own risk, of course.
3030

@@ -51,25 +51,26 @@ If you still think there is a suspicious line, you can [ask us about it, and war
5151
5252
4. Install **Pydroid repository plugin** from Google Play Store.
5353
54-
5. Open **Pydroid 3**, from top left side of app, click on menu, there are a few options, such as Get premium, interpreter, Terminal, etc. Now you should choose **Pip**.
54+
5. Open **Pydroid 3**, from top left side of app, click on the menu, there are a few options, such as Get premium, interpreter, Terminal, etc. Now you should choose **Pip**.
5555
5656
6. In **Library name** field, first type **lxml** (its LXML not ixmi) and click on install, after its finished, enter **Requests** in that field and go ahead and click install. (you can do this for any missing module in future if you needed it)
5757
5858
7. Now, just go back in main menu and click on folder icon in top right side of the app (near light bulb icon) and choose open, find your desired script in your phone file manager and open it.
5959

6060
8. Once you opened it, there should be a **Run yellowish play button** in left bottom of screen, go ahead and run it.
61+
6162
9. Now after you ran the script in your phone, on top right side of the screen, there is a menu. In that menu, choose **Take wakelock** and **Take wifilock**, Now it should be able to run as long as you don't close the app from your phone's app manager. [Screenshot](http://prntscr.com/uo9dxh)
6263

6364

6465
- ### Few Notes:
6566
- You can edit the scripts by right click on it -> edit with IDLE, or click "Fork" at the top of this page.
6667
- Everything written after the pound (#) in the same line, is a note that can help you understand the code, or for the developers.
67-
- Every line with `input` can be replaces (instead of typing the same choice every time you run the script). For example: `server = input("Server: ")` can be replaced into `server = "alpha"`.
68+
- Every line with `input` can be replaced (instead of typing the same choice every time you run the script). For example: `server = input("Server: ")` can be replaced into `server = "alpha"`.
6869
- Those scripts (Basic folder mainly) are mostly raw, and they can be used in many other ways.
69-
- in [Discord bot](https://github.com/e-sim-python/scripts/blob/master/bot.py), if you want to run command in a specific server, **Channel name should be the same as the server you want to run the command on**. (Ex: if it you wish to run command in alpha server, name of channel should be `alpha` [screenshot](http://prntscr.com/wmscov))
70+
- in [Discord bot](https://github.com/e-sim-python/scripts/blob/master/bot.py), if you want to run command in a specific server, **Channel name should be the same as the server you want to run the command on**. (Ex: if you wish to run command in alpha server, name of channel should be `alpha` [screenshot](http://prntscr.com/wmscov))
7071
- ### Customization and Advanced usage:
7172
- **Beginner idea:**
72-
- Add `await asyncio.sleep(time_in_sconds)` at the beginning of the script to do action with a delay (For example: Bid auctions just before it's end, propose a law while you are sleeping etc.)
73+
- Add `await asyncio.sleep(time_in_sconds)` at the beginning of the script to do action with a delay (For example: Bid auctions just before it ends, propose a law while you are sleeping etc.)
7374

7475
- **Advanced idea:**
7576
- Run the [discord bot](https://github.com/e-sim-python/scripts/blob/master/bot.py) in each of your trusted group devices, and let everyone do specific actions in each other accounts (fight, vote laws etc.) (you should have `discord.py` installed already, but if not - install it)
@@ -82,7 +83,7 @@ If you still think there is a suspicious line, you can [ask us about it, and war
8283
- For example: `ImportError: No module named aiohttp` -> [google search](https://www.google.com/search?q=No+module+named+aiohttp) will tell you how to install package (via pip). In that specific error you can also run [install_package.py](https://github.com/e-sim-python/scripts/blob/master/Help_functions/install_packets.py)
8384
- Sometimes all you need is to login via script again, because your cookies are too old (Run `Help/login`, or delete `Help/cookies.txt`).
8485
- See if there are updates in the source code. (`pip install -U eSim`)
85-
- If you believes that the error is made by us, you can describe it [here](https://github.com/e-sim-python/scripts/issues) and we will try to fix. This is also the place for suggestions and any contact.
86+
- If you believe that the error is made by us, you can describe it [here](https://github.com/e-sim-python/scripts/issues) and we will try to fix. This is also the place for suggestions and any contact.
8687

8788

8889
# Good luck & have fun!

Time_saver/login.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import __init__
12
from Help_functions.login import *
23
# This should help to run __main__ files.
34
# Original File: Help_functions.login

0 commit comments

Comments
 (0)