scratch-syntax 0.7.2__tar.gz → 0.7.3__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.
- {scratch_syntax-0.7.2/src/scratch_syntax.egg-info → scratch_syntax-0.7.3}/PKG-INFO +27 -2
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/README.md +26 -1
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/pyproject.toml +1 -1
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/src/scratch_syntax/core.py +2 -3
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3/src/scratch_syntax.egg-info}/PKG-INFO +27 -2
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/LICENSE +0 -0
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/setup.cfg +0 -0
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/src/scratch_syntax/__init__.py +0 -0
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/src/scratch_syntax.egg-info/SOURCES.txt +0 -0
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/src/scratch_syntax.egg-info/dependency_links.txt +0 -0
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/src/scratch_syntax.egg-info/requires.txt +0 -0
- {scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/src/scratch_syntax.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scratch_syntax
|
|
3
|
-
Version: 0.7.
|
|
3
|
+
Version: 0.7.3
|
|
4
4
|
Summary: A syntax library designed to help scratch users transition to python
|
|
5
5
|
Author-email: Cade <cadey.matignas@gmail.com>
|
|
6
6
|
Project-URL: Homepage, https://github.com/cadeymatignas-source/scratch_syntax
|
|
@@ -15,7 +15,7 @@ Dynamic: license-file
|
|
|
15
15
|
|
|
16
16
|
# Scratch_Syntax
|
|
17
17
|
|
|
18
|
-
## This is a custom Python library designed make python syntax more like scratch.
|
|
18
|
+
## This is a custom Python library designed to make python syntax more like scratch.
|
|
19
19
|
|
|
20
20
|
# Installation
|
|
21
21
|
|
|
@@ -74,6 +74,10 @@ Also btw don't forget to put from scratch_syntax import * so the functions run c
|
|
|
74
74
|
## Update 0.7.2 note:
|
|
75
75
|
* I changed the wait_until function a bit so now it goes ```wait_until(condition) ``` instead of ```wait_until(action, condition)```
|
|
76
76
|
|
|
77
|
+
## Update 0.7.3:
|
|
78
|
+
* Made the ```when_key_pressed()``` and ```wait_until()``` functions faster
|
|
79
|
+
|
|
80
|
+
|
|
77
81
|
|
|
78
82
|
# All Functions
|
|
79
83
|
|
|
@@ -81,3 +85,24 @@ Also btw don't forget to put from scratch_syntax import * so the functions run c
|
|
|
81
85
|
say(), ask(), wait(), pick_random_number_from(), stop_all(), add_to_list(), insert_in_list(), delete_from_list(), delete_all_from_list(), replace_from_list(), answer(), say_for_seconds(), wait_until(), repeat(), forever(), repeat_until(), when_key_pressed()
|
|
82
86
|
|
|
83
87
|
```
|
|
88
|
+
Also heres an example code
|
|
89
|
+
```python
|
|
90
|
+
from scratch_syntax import *
|
|
91
|
+
|
|
92
|
+
say("welcome to this beautiful thing!")
|
|
93
|
+
ask("hmm what do you think? answer yes please ")
|
|
94
|
+
wait_until(answer() == "yes")
|
|
95
|
+
say("hahaha no way you said it!!!")
|
|
96
|
+
repeat_until(
|
|
97
|
+
lambda: (
|
|
98
|
+
say_for_seconds("hello guys!", 1),
|
|
99
|
+
ask("stop running?"),
|
|
100
|
+
),
|
|
101
|
+
lambda: answer() == "yes",
|
|
102
|
+
)
|
|
103
|
+
say("done!")
|
|
104
|
+
say("now it is time for us to part!")
|
|
105
|
+
repeat_until(lambda: ask("would you like to leave?"), lambda: answer() == "yes")
|
|
106
|
+
wait(1)
|
|
107
|
+
stop_all()
|
|
108
|
+
```
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Scratch_Syntax
|
|
2
2
|
|
|
3
|
-
## This is a custom Python library designed make python syntax more like scratch.
|
|
3
|
+
## This is a custom Python library designed to make python syntax more like scratch.
|
|
4
4
|
|
|
5
5
|
# Installation
|
|
6
6
|
|
|
@@ -59,6 +59,10 @@ Also btw don't forget to put from scratch_syntax import * so the functions run c
|
|
|
59
59
|
## Update 0.7.2 note:
|
|
60
60
|
* I changed the wait_until function a bit so now it goes ```wait_until(condition) ``` instead of ```wait_until(action, condition)```
|
|
61
61
|
|
|
62
|
+
## Update 0.7.3:
|
|
63
|
+
* Made the ```when_key_pressed()``` and ```wait_until()``` functions faster
|
|
64
|
+
|
|
65
|
+
|
|
62
66
|
|
|
63
67
|
# All Functions
|
|
64
68
|
|
|
@@ -66,3 +70,24 @@ Also btw don't forget to put from scratch_syntax import * so the functions run c
|
|
|
66
70
|
say(), ask(), wait(), pick_random_number_from(), stop_all(), add_to_list(), insert_in_list(), delete_from_list(), delete_all_from_list(), replace_from_list(), answer(), say_for_seconds(), wait_until(), repeat(), forever(), repeat_until(), when_key_pressed()
|
|
67
71
|
|
|
68
72
|
```
|
|
73
|
+
Also heres an example code
|
|
74
|
+
```python
|
|
75
|
+
from scratch_syntax import *
|
|
76
|
+
|
|
77
|
+
say("welcome to this beautiful thing!")
|
|
78
|
+
ask("hmm what do you think? answer yes please ")
|
|
79
|
+
wait_until(answer() == "yes")
|
|
80
|
+
say("hahaha no way you said it!!!")
|
|
81
|
+
repeat_until(
|
|
82
|
+
lambda: (
|
|
83
|
+
say_for_seconds("hello guys!", 1),
|
|
84
|
+
ask("stop running?"),
|
|
85
|
+
),
|
|
86
|
+
lambda: answer() == "yes",
|
|
87
|
+
)
|
|
88
|
+
say("done!")
|
|
89
|
+
say("now it is time for us to part!")
|
|
90
|
+
repeat_until(lambda: ask("would you like to leave?"), lambda: answer() == "yes")
|
|
91
|
+
wait(1)
|
|
92
|
+
stop_all()
|
|
93
|
+
```
|
|
@@ -66,7 +66,7 @@ def replace_in_list(listname, index, item):
|
|
|
66
66
|
|
|
67
67
|
def wait_until(condit):
|
|
68
68
|
while not condit:
|
|
69
|
-
sleep(
|
|
69
|
+
sleep(0.01)
|
|
70
70
|
|
|
71
71
|
|
|
72
72
|
def repeat(action, timy):
|
|
@@ -90,7 +90,6 @@ def repeat_until(actionon, condition):
|
|
|
90
90
|
def when_key_pressed(key):
|
|
91
91
|
"""This function checks when key is pressed"""
|
|
92
92
|
if is_pressed(key):
|
|
93
|
-
|
|
94
|
-
sleep(0.1)
|
|
93
|
+
sleep(0.01)
|
|
95
94
|
return True
|
|
96
95
|
return False
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: scratch_syntax
|
|
3
|
-
Version: 0.7.
|
|
3
|
+
Version: 0.7.3
|
|
4
4
|
Summary: A syntax library designed to help scratch users transition to python
|
|
5
5
|
Author-email: Cade <cadey.matignas@gmail.com>
|
|
6
6
|
Project-URL: Homepage, https://github.com/cadeymatignas-source/scratch_syntax
|
|
@@ -15,7 +15,7 @@ Dynamic: license-file
|
|
|
15
15
|
|
|
16
16
|
# Scratch_Syntax
|
|
17
17
|
|
|
18
|
-
## This is a custom Python library designed make python syntax more like scratch.
|
|
18
|
+
## This is a custom Python library designed to make python syntax more like scratch.
|
|
19
19
|
|
|
20
20
|
# Installation
|
|
21
21
|
|
|
@@ -74,6 +74,10 @@ Also btw don't forget to put from scratch_syntax import * so the functions run c
|
|
|
74
74
|
## Update 0.7.2 note:
|
|
75
75
|
* I changed the wait_until function a bit so now it goes ```wait_until(condition) ``` instead of ```wait_until(action, condition)```
|
|
76
76
|
|
|
77
|
+
## Update 0.7.3:
|
|
78
|
+
* Made the ```when_key_pressed()``` and ```wait_until()``` functions faster
|
|
79
|
+
|
|
80
|
+
|
|
77
81
|
|
|
78
82
|
# All Functions
|
|
79
83
|
|
|
@@ -81,3 +85,24 @@ Also btw don't forget to put from scratch_syntax import * so the functions run c
|
|
|
81
85
|
say(), ask(), wait(), pick_random_number_from(), stop_all(), add_to_list(), insert_in_list(), delete_from_list(), delete_all_from_list(), replace_from_list(), answer(), say_for_seconds(), wait_until(), repeat(), forever(), repeat_until(), when_key_pressed()
|
|
82
86
|
|
|
83
87
|
```
|
|
88
|
+
Also heres an example code
|
|
89
|
+
```python
|
|
90
|
+
from scratch_syntax import *
|
|
91
|
+
|
|
92
|
+
say("welcome to this beautiful thing!")
|
|
93
|
+
ask("hmm what do you think? answer yes please ")
|
|
94
|
+
wait_until(answer() == "yes")
|
|
95
|
+
say("hahaha no way you said it!!!")
|
|
96
|
+
repeat_until(
|
|
97
|
+
lambda: (
|
|
98
|
+
say_for_seconds("hello guys!", 1),
|
|
99
|
+
ask("stop running?"),
|
|
100
|
+
),
|
|
101
|
+
lambda: answer() == "yes",
|
|
102
|
+
)
|
|
103
|
+
say("done!")
|
|
104
|
+
say("now it is time for us to part!")
|
|
105
|
+
repeat_until(lambda: ask("would you like to leave?"), lambda: answer() == "yes")
|
|
106
|
+
wait(1)
|
|
107
|
+
stop_all()
|
|
108
|
+
```
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{scratch_syntax-0.7.2 → scratch_syntax-0.7.3}/src/scratch_syntax.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|