dashcode 1.0.3__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.
- {dashcode-1.0.3 → dashcode-1.1.0}/PKG-INFO +3 -1
- {dashcode-1.0.3 → dashcode-1.1.0}/dashcode/core.py +37 -2
- {dashcode-1.0.3 → dashcode-1.1.0}/dashcode.egg-info/PKG-INFO +3 -1
- {dashcode-1.0.3 → dashcode-1.1.0}/setup.py +2 -1
- {dashcode-1.0.3 → dashcode-1.1.0}/README.md +0 -0
- {dashcode-1.0.3 → dashcode-1.1.0}/dashcode/__init__.py +0 -0
- {dashcode-1.0.3 → dashcode-1.1.0}/dashcode.egg-info/SOURCES.txt +0 -0
- {dashcode-1.0.3 → dashcode-1.1.0}/dashcode.egg-info/dependency_links.txt +0 -0
- {dashcode-1.0.3 → dashcode-1.1.0}/dashcode.egg-info/top_level.txt +0 -0
- {dashcode-1.0.3 → dashcode-1.1.0}/setup.cfg +0 -0
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dashcode
|
|
3
|
-
Version: 1.0
|
|
3
|
+
Version: 1.1.0
|
|
4
4
|
Summary: A library for Geometry Dash level generation using .gmd files
|
|
5
5
|
Author: IWiterI
|
|
6
6
|
Project-URL: Homepage, https://github.com/ISviterI/dashcode
|
|
7
7
|
Project-URL: Wiki, https://github.com/ISviterI/dashcode/wiki
|
|
8
8
|
Project-URL: Documentation, https://github.com/ISviterI/dashcode/wiki/Documentation
|
|
9
|
+
Keywords: geometry dash,gd,level-generator,automation,2.2,python,dash,dashcode,code
|
|
9
10
|
Classifier: Programming Language :: Python :: 3
|
|
10
11
|
Classifier: License :: OSI Approved :: MIT License
|
|
11
12
|
Classifier: Operating System :: OS Independent
|
|
@@ -15,6 +16,7 @@ Dynamic: author
|
|
|
15
16
|
Dynamic: classifier
|
|
16
17
|
Dynamic: description
|
|
17
18
|
Dynamic: description-content-type
|
|
19
|
+
Dynamic: keywords
|
|
18
20
|
Dynamic: project-url
|
|
19
21
|
Dynamic: requires-python
|
|
20
22
|
Dynamic: summary
|
|
@@ -12,12 +12,12 @@ class Dashcode:
|
|
|
12
12
|
global objects
|
|
13
13
|
self.params = {
|
|
14
14
|
"NoTouch": 13,
|
|
15
|
-
"Hide":
|
|
15
|
+
"Hide": 12,
|
|
16
16
|
"Group": 57,
|
|
17
17
|
"TGroup": 51,
|
|
18
18
|
"Duration": 10,
|
|
19
19
|
"Alpha": 11,
|
|
20
|
-
"TouchTrigger": 11,
|
|
20
|
+
"TouchTrigger": 11,
|
|
21
21
|
"ActivateGroup": 56,
|
|
22
22
|
"ScaleX": 128,
|
|
23
23
|
"ScaleY": 129,
|
|
@@ -37,6 +37,11 @@ class Dashcode:
|
|
|
37
37
|
"p_cube": 12, "p_ship": 13, "p_ball": 47, "p_ufo": 111,
|
|
38
38
|
"p_wave": 660, "p_robot": 745, "p_spider": 1331, "p_swing": 1933
|
|
39
39
|
}
|
|
40
|
+
self.prefabs = {
|
|
41
|
+
"wall": {"Y":0},
|
|
42
|
+
"platform": {"X":0},
|
|
43
|
+
"square": {"X":0, "Y":0},
|
|
44
|
+
}
|
|
40
45
|
|
|
41
46
|
def setobjects(self, objs:dict):
|
|
42
47
|
self.objects = objs
|
|
@@ -45,6 +50,9 @@ class Dashcode:
|
|
|
45
50
|
self.params = params
|
|
46
51
|
|
|
47
52
|
def addobject(self, obj: str, params: dict):
|
|
53
|
+
if len(objects) <= 0:
|
|
54
|
+
objects.append(
|
|
55
|
+
f"1,1,2,{str(-10 * 30)},3,{str(-10 * 30)},12,1,13,1")
|
|
48
56
|
extraparams = ""
|
|
49
57
|
for param, value in params.items():
|
|
50
58
|
if self.params.get(param) is not None:
|
|
@@ -61,6 +69,33 @@ class Dashcode:
|
|
|
61
69
|
objects.append(
|
|
62
70
|
f"1,{str(obj)},2,{str(params.get('X') * 30 + 15)},3,{str(params.get('Y') * 30 + 15)}{extraparams}")
|
|
63
71
|
|
|
72
|
+
def addprefab(self, obj:str, params:dict, prefab:str):
|
|
73
|
+
extraparams = ""
|
|
74
|
+
for param, value in params.items():
|
|
75
|
+
if self.params.get(param) is not None:
|
|
76
|
+
pid = self.params[param]
|
|
77
|
+
extraparams += f",{str(pid)},{value}"
|
|
78
|
+
else:
|
|
79
|
+
extraparams += f",{str(param)},{value}"
|
|
80
|
+
|
|
81
|
+
oid = self.objects.get(obj, 1)
|
|
82
|
+
if prefab:
|
|
83
|
+
#print("1")
|
|
84
|
+
fab = self.prefabs.get(prefab)
|
|
85
|
+
if fab:
|
|
86
|
+
#print(fab)
|
|
87
|
+
#print("2")
|
|
88
|
+
if fab.get("X") == 0:
|
|
89
|
+
#print("3")
|
|
90
|
+
for i in range(params.get('EX')):
|
|
91
|
+
objects.append(
|
|
92
|
+
f"1,{str(oid)},2,{str(params.get('X') * 30 + 15 + (i * 30))},3,{str(params.get('Y') * 30 + 15)}{extraparams}")
|
|
93
|
+
if fab.get("Y") == 0:
|
|
94
|
+
#print("3")
|
|
95
|
+
for i in range(params.get('EY')):
|
|
96
|
+
objects.append(
|
|
97
|
+
f"1,{str(oid)},2,{str(params.get('X') * 30 + 15)},3,{str(params.get('Y') * 30 + 15 + (i * 30))}{extraparams}")
|
|
98
|
+
|
|
64
99
|
def create_gmd_file(self, level_name, author_name, objects_string):
|
|
65
100
|
global lvlname
|
|
66
101
|
lvlname = level_name
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dashcode
|
|
3
|
-
Version: 1.0
|
|
3
|
+
Version: 1.1.0
|
|
4
4
|
Summary: A library for Geometry Dash level generation using .gmd files
|
|
5
5
|
Author: IWiterI
|
|
6
6
|
Project-URL: Homepage, https://github.com/ISviterI/dashcode
|
|
7
7
|
Project-URL: Wiki, https://github.com/ISviterI/dashcode/wiki
|
|
8
8
|
Project-URL: Documentation, https://github.com/ISviterI/dashcode/wiki/Documentation
|
|
9
|
+
Keywords: geometry dash,gd,level-generator,automation,2.2,python,dash,dashcode,code
|
|
9
10
|
Classifier: Programming Language :: Python :: 3
|
|
10
11
|
Classifier: License :: OSI Approved :: MIT License
|
|
11
12
|
Classifier: Operating System :: OS Independent
|
|
@@ -15,6 +16,7 @@ Dynamic: author
|
|
|
15
16
|
Dynamic: classifier
|
|
16
17
|
Dynamic: description
|
|
17
18
|
Dynamic: description-content-type
|
|
19
|
+
Dynamic: keywords
|
|
18
20
|
Dynamic: project-url
|
|
19
21
|
Dynamic: requires-python
|
|
20
22
|
Dynamic: summary
|
|
@@ -8,7 +8,7 @@ if os.path.exists("README.md"):
|
|
|
8
8
|
|
|
9
9
|
setup(
|
|
10
10
|
name="dashcode",
|
|
11
|
-
version="1.0
|
|
11
|
+
version="1.1.0",
|
|
12
12
|
packages=find_packages(),
|
|
13
13
|
author="IWiterI",
|
|
14
14
|
description="A library for Geometry Dash level generation using .gmd files",
|
|
@@ -25,4 +25,5 @@ setup(
|
|
|
25
25
|
"License :: OSI Approved :: MIT License",
|
|
26
26
|
"Operating System :: OS Independent",
|
|
27
27
|
],
|
|
28
|
+
keywords='geometry dash, gd, level-generator, automation, 2.2, python, dash, dashcode, code',
|
|
28
29
|
)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|