smemhack 5.9__py3-none-any.whl → 5.11__py3-none-any.whl

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.
smemhack/__init__.py CHANGED
@@ -1,2 +1,2 @@
1
1
  from .main import *
2
- __version__="5.9"
2
+ __version__="5.11"
smemhack/main.py CHANGED
@@ -7,6 +7,7 @@ import keyboard
7
7
  import os
8
8
  from fuzzywuzzy import process
9
9
  from threading import Thread
10
+ import pkg_resources
10
11
  import tensorflow as tf
11
12
  from tensorflow.keras.models import Sequential
12
13
  from tensorflow.keras.layers import Dense,LSTM,Embedding
@@ -21,13 +22,29 @@ def hack(number):
21
22
  def hexit():
22
23
  keyboard.add_hotkey("esc",exit)
23
24
  keyboard.wait()
24
- os.system("pip install --upgrade smemhack")
25
- os.system("py -m pip install --upgrade smemhack")
25
+ def restart():
26
+ os.system(f"pyt(hon {os.path.abspath(__file__)}")
27
+ exit()
28
+ def package_version():
29
+ current_ver=pkg_resources.get_distribution("smemhack").version
30
+ if current_ver != 5.11:
31
+ os.system("pip install --upgrade smemhack")
32
+ os.system("py -m pip install --upgrade smemhack")
33
+ restart()
34
+ package_version()
26
35
  t=Thread(target=hexit)
27
36
  t.start()
28
- sox,soy=1366,768
29
- x,y=py.size()
30
- nx,ny=x/sox,y/soy
37
+ try:
38
+ exercise=py.locateCenterOnScreen("exercise.png",grayscale=False)
39
+ py.click(exercise)
40
+ time.sleep(0.5)
41
+ question=py.locateCenterOnScreen("question.png",grayscale=False)
42
+ question=question[0]+100
43
+ qnext=py.locateCenterOnScreen("next.png",grayscale=False)
44
+ qexit=py.locateCenterOnScreen("exit.png",grayscale=False)
45
+ except:
46
+ print("can't locate")
47
+ os._exit(0)
31
48
  py.keyDown("alt") # Simulate pressing down the Alt key
32
49
  time.sleep(1) # Wait for 1 second to ensure the key press is registered
33
50
  py.press("tab") # Simulate pressing the Tab key to switch between applications/windows
@@ -39,7 +56,7 @@ def hack(number):
39
56
  def get_w():
40
57
  py.press("enter")
41
58
  time.sleep(0.5)
42
- py.click(971*nx,106*ny)
59
+ py.click(question)
43
60
  py.click()
44
61
  py.mouseDown()
45
62
  py.keyDown("ctrl")
@@ -51,15 +68,15 @@ def hack(number):
51
68
  first=first.split(" ")
52
69
  first="".join(first)
53
70
  if "_" in first:
54
- py.click(1315*nx,41*ny)
71
+ py.click(qexit)
55
72
  time.sleep(0.5)
56
- py.click(1053*nx,317*ny)
73
+ py.click(exercise)
57
74
  get_w()
58
75
  time.sleep(1)
59
76
  time.sleep(0.5)
60
- py.click(773*nx,157*ny)
77
+ py.click(qnext)
61
78
  time.sleep(0.5)
62
- py.click(115*nx,604*ny)
79
+ py.click(115,604)
63
80
  time.sleep(0.5)
64
81
  py.keyDown("ctrl")
65
82
  py.press("a")
@@ -68,7 +85,7 @@ def hack(number):
68
85
  py.click()
69
86
  time.sleep(0.5)
70
87
  first_g=pycopy.paste()
71
- py.click(971*nx,106*ny)
88
+ py.click(question)
72
89
  time.sleep(0.5)
73
90
  py.typewrite(first)
74
91
  time.sleep(0.5)
@@ -79,7 +96,7 @@ def hack(number):
79
96
  while True:
80
97
  py.press("enter")
81
98
  time.sleep(0.5)
82
- py.click(971*nx,106*ny)
99
+ py.click(question)
83
100
  py.click()
84
101
  py.mouseDown()
85
102
  time.sleep(0.5)
@@ -89,21 +106,21 @@ def hack(number):
89
106
  py.mouseUp()
90
107
  py.click()
91
108
  time.sleep(0.5)
92
- py.click(797*nx,156*ny)
109
+ py.click(qnext)
93
110
  n=pycopy.paste()
94
111
  n=n.split(" ")
95
112
  n="".join(n)
96
113
  if "_" in n:
97
- py.click(1315*nx,41*ny)
114
+ py.click(qexit)
98
115
  time.sleep(0.5)
99
- py.click(1053*nx,317*ny)
116
+ py.click(exercise)
100
117
  get_w()
101
118
  if n== first:
102
119
  break
103
120
  else:
104
121
  data.append(n)
105
122
  time.sleep(0.5)
106
- py.click(115*nx,604*ny)
123
+ py.click(115,604)
107
124
  time.sleep(0.5)
108
125
  py.keyDown("ctrl")
109
126
  py.press("a")
@@ -113,14 +130,14 @@ def hack(number):
113
130
  time.sleep(0.5)
114
131
  nn=pycopy.paste()
115
132
  get.append(nn)
116
- py.click(971*nx,106*ny)
133
+ py.click(question)
117
134
  time.sleep(0.5)
118
135
  py.typewrite(n)
119
136
  time.sleep(0.5)
120
137
  py.press("enter")
121
138
  time.sleep(0.5)
122
139
  time.sleep(0.5)
123
- py.click(1315*nx,41*ny)
140
+ py.click(qexit)
124
141
  get_w()
125
142
  py.keyDown("alt") # Simulate pressing down the Alt key
126
143
  time.sleep(1) # Wait for 1 second to ensure the key press is registered
@@ -148,7 +165,7 @@ def hack(number):
148
165
  py.press("tab") # Simulate pressing the Tab key to switch between applications/windows
149
166
  time.sleep(1) # Wait for 1 second to allow the switch to complete
150
167
  py.keyUp("alt")
151
- py.click(1053*nx,317*ny)
168
+ py.click(exercise)
152
169
  time.sleep(1)
153
170
  lw=""
154
171
  def normal_w(ggget,data):
@@ -159,7 +176,7 @@ def hack(number):
159
176
  gget="\n".join(gget)
160
177
  xget.append(gget)
161
178
  for _ in range(0,len(data)+number):
162
- py.click(115*nx,604*ny)
179
+ py.click(115,604)
163
180
  py.keyDown("ctrl")
164
181
  py.press("a")
165
182
  py.press("c")
@@ -171,13 +188,13 @@ def hack(number):
171
188
  w=w[2:]
172
189
  w="\n".join(w)
173
190
  word,_=process.extractOne(w,xget)
174
- py.click(971*nx,106*ny)
191
+ py.click(question)
175
192
  time.sleep(0.5)
176
193
  py.typewrite(data[xget.index(word)])
177
194
  py.press("enter")
178
195
  time.sleep(1)
179
196
  for _ in range(0,len(data)+number):
180
- py.click(115*nx,604*ny)
197
+ py.click(115,604)
181
198
  py.keyDown("ctrl")
182
199
  py.press("a")
183
200
  py.press("c")
@@ -186,9 +203,9 @@ def hack(number):
186
203
  time.sleep(0.5)
187
204
  gg=pycopy.paste()
188
205
  if gg== lw:
189
- py.click(1315*nx,41*ny)
206
+ py.click(qexit)
190
207
  time.sleep(0.5)
191
- py.click(1053*nx,317*ny)
208
+ py.click(exercise)
192
209
  normal_w(get,data)
193
210
  break
194
211
  else:
@@ -198,7 +215,7 @@ def hack(number):
198
215
  gg=pad_sequences(gg,maxlen=5)
199
216
  prediction=model.predict(gg)
200
217
  pd=np.argmax(prediction)
201
- py.click(971*nx,106*ny)
218
+ py.click(question)
202
219
  time.sleep(0.5)
203
220
  py.typewrite(data[pd])
204
221
  py.press("enter")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: smemhack
3
- Version: 5.9
3
+ Version: 5.11
4
4
  Summary: A Python library to automate online homework tasks with AI and system control.
5
5
  Author: Dickily
6
6
  Author-email: dickilyyiu@gmail.com
@@ -19,6 +19,7 @@ Requires-Dist: numpy>=1.20.0
19
19
  Requires-Dist: keyboard>=0.13.5
20
20
  Requires-Dist: fuzzywuzzy>=0.18.0
21
21
  Requires-Dist: python-Levenshtein>=0.12.2
22
+ Requires-Dist: Pillow>=8.0.0
22
23
 
23
24
  # smemhack
24
25
  **smemhack** is a Python library designed to automate online homework tasks with AI and system control.
@@ -50,15 +51,19 @@ Now you can't enter number below 0 or larger than 5
50
51
 
51
52
  Upgraded the backup compare system
52
53
 
53
- # What is new in version 5.9
54
+ **What is new in version 5.9**
54
55
 
55
56
  Now it will auto upgrade the program
56
57
 
58
+ # What is new in version 5.10
59
+
60
+ Updated the code so that it will fit everybody's computer
61
+
57
62
  **How to Use it:**
58
63
 
59
64
  copy the code i give in the last of this discription and change the new_word_number to the number of new word you have entered
60
65
 
61
- 1.Prepare a started solidmemory page(exercise page)
66
+ 1.Prepare a not started solidmemory page(exercise page)
62
67
 
63
68
  2.Run the code
64
69
  ## Usage
@@ -0,0 +1,7 @@
1
+ smemhack/__init__.py,sha256=c_gChICwX_VLZWp3GHQzlNfcH3KbWG8ps4S3f-zr2IE,39
2
+ smemhack/main.py,sha256=JOgAuDBKCp3L2cNkMRkSUnoGvrPTEPW06-lQNNR8dEc,8131
3
+ smemhack-5.11.dist-info/LICENSE.txt,sha256=RJahtv1H4Hjtstu6FLflvTF63-bB_QahD7q_vLWCVus,906
4
+ smemhack-5.11.dist-info/METADATA,sha256=xexuw0t2dlwx4JLhl6Hp7N0X0X29imWNHrRZcHvMvxU,2099
5
+ smemhack-5.11.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
6
+ smemhack-5.11.dist-info/top_level.txt,sha256=xNcFNsBkAsQ7cvrsNoZurwu9SXFyvBe6PxS-zt5MuG8,9
7
+ smemhack-5.11.dist-info/RECORD,,
@@ -1,7 +0,0 @@
1
- smemhack/__init__.py,sha256=CoE-hhuinGX29iBvRvVhBxodc4lQWzP6tluAD2nYcAY,38
2
- smemhack/main.py,sha256=I2R9yiq080G9RAXIXQ5ecI5_6vPMo-kb6_iYR0PpRww,7565
3
- smemhack-5.9.dist-info/LICENSE.txt,sha256=RJahtv1H4Hjtstu6FLflvTF63-bB_QahD7q_vLWCVus,906
4
- smemhack-5.9.dist-info/METADATA,sha256=77YALvMQNf5OLjpjiKExtcEvhXRGeFrxQqrtwsTjJxY,1968
5
- smemhack-5.9.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
6
- smemhack-5.9.dist-info/top_level.txt,sha256=xNcFNsBkAsQ7cvrsNoZurwu9SXFyvBe6PxS-zt5MuG8,9
7
- smemhack-5.9.dist-info/RECORD,,