pyscreeps-arena 0.5.7b0__py3-none-any.whl → 0.5.7.2__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.
- pyscreeps_arena/__init__.py +35 -3
- pyscreeps_arena/core/const.py +1 -1
- pyscreeps_arena/project.7z +0 -0
- pyscreeps_arena/ui/__init__.py +3 -1
- pyscreeps_arena/ui/map_render.py +705 -0
- pyscreeps_arena/ui/mapviewer.py +14 -0
- pyscreeps_arena/ui/qcreeplogic/qcreeplogic.py +82 -21
- pyscreeps_arena/ui/qmapv/__init__.py +3 -0
- pyscreeps_arena/ui/qmapv/qcinfo.py +567 -0
- pyscreeps_arena/ui/qmapv/qco.py +441 -0
- pyscreeps_arena/ui/qmapv/qmapv.py +728 -0
- pyscreeps_arena/ui/qmapv/test_array_drag.py +191 -0
- pyscreeps_arena/ui/qmapv/test_drag.py +107 -0
- pyscreeps_arena/ui/qmapv/test_qcinfo.py +169 -0
- pyscreeps_arena/ui/qmapv/test_qco_drag.py +7 -0
- pyscreeps_arena/ui/qmapv/test_qmapv.py +224 -0
- pyscreeps_arena/ui/qmapv/test_simple_array.py +303 -0
- {pyscreeps_arena-0.5.7b0.dist-info → pyscreeps_arena-0.5.7.2.dist-info}/METADATA +1 -1
- pyscreeps_arena-0.5.7.2.dist-info/RECORD +40 -0
- pyscreeps_arena-0.5.7b0.dist-info/RECORD +0 -28
- {pyscreeps_arena-0.5.7b0.dist-info → pyscreeps_arena-0.5.7.2.dist-info}/WHEEL +0 -0
- {pyscreeps_arena-0.5.7b0.dist-info → pyscreeps_arena-0.5.7.2.dist-info}/entry_points.txt +0 -0
- {pyscreeps_arena-0.5.7b0.dist-info → pyscreeps_arena-0.5.7.2.dist-info}/top_level.txt +0 -0
pyscreeps_arena/__init__.py
CHANGED
|
@@ -27,7 +27,10 @@ def CMD_NewProject():
|
|
|
27
27
|
def CMD_OpenUI():
|
|
28
28
|
"""
|
|
29
29
|
cmd:
|
|
30
|
-
psaui
|
|
30
|
+
psaui 无参数,启用project ui
|
|
31
|
+
psaui -c/-e 启用creeplogic edit
|
|
32
|
+
psaui -m [-c/-e] 启用mapviewer. 默认cn,可以指定-c/-e
|
|
33
|
+
psaui -h 显示帮助信息
|
|
31
34
|
|
|
32
35
|
* 打开UI界面
|
|
33
36
|
|
|
@@ -35,10 +38,39 @@ def CMD_OpenUI():
|
|
|
35
38
|
|
|
36
39
|
"""
|
|
37
40
|
try:
|
|
38
|
-
#
|
|
39
|
-
if len(sys.argv) > 1 and sys.argv[1] == '-
|
|
41
|
+
# 显示帮助信息
|
|
42
|
+
if len(sys.argv) > 1 and sys.argv[1] == '-h':
|
|
43
|
+
print("Usage:")
|
|
44
|
+
print(" psaui 启用project ui")
|
|
45
|
+
print(" psaui -c/-e 启用creeplogic edit (-c: 中文, -e: 英文)")
|
|
46
|
+
print(" psaui -m [-c/-e] 启用mapviewer (-c: 中文, -e: 英文, 默认: 中文)")
|
|
47
|
+
print(" psaui -h 显示帮助信息")
|
|
48
|
+
print(" --------------------------------------------------------------")
|
|
49
|
+
print(" psaui run `project ui`")
|
|
50
|
+
print(" psaui -c/-e run `creeplogic edit` (-c: chinese, -e: english)")
|
|
51
|
+
print(" psaui -m [-c/-e] run `mapviewer` (-c: chinese, -e: english, default: chinese)")
|
|
52
|
+
print(" psaui -h Show this help message")
|
|
53
|
+
|
|
54
|
+
return
|
|
55
|
+
|
|
56
|
+
# 检查是否使用mapviewer
|
|
57
|
+
if len(sys.argv) > 1 and sys.argv[1] == '-m':
|
|
58
|
+
from pyscreeps_arena.ui.mapviewer import run_mapviewer
|
|
59
|
+
# 检查语言参数
|
|
60
|
+
if len(sys.argv) > 2 and sys.argv[2] == '-e':
|
|
61
|
+
from pyscreeps_arena.core import config
|
|
62
|
+
config.language = 'en'
|
|
63
|
+
run_mapviewer()
|
|
64
|
+
# 检查是否使用creeplogic edit
|
|
65
|
+
elif len(sys.argv) > 1 and sys.argv[1] == '-c':
|
|
66
|
+
from pyscreeps_arena.ui.creeplogic_edit import run_creeplogic_edit
|
|
67
|
+
run_creeplogic_edit()
|
|
68
|
+
elif len(sys.argv) > 1 and sys.argv[1] == '-e':
|
|
40
69
|
from pyscreeps_arena.ui.creeplogic_edit import run_creeplogic_edit
|
|
70
|
+
from pyscreeps_arena.core import config
|
|
71
|
+
config.language = 'en'
|
|
41
72
|
run_creeplogic_edit()
|
|
73
|
+
# 默认启用project ui
|
|
42
74
|
else:
|
|
43
75
|
from pyscreeps_arena.ui.project_ui import run_project_creator
|
|
44
76
|
run_project_creator()
|
pyscreeps_arena/core/const.py
CHANGED
pyscreeps_arena/project.7z
CHANGED
|
Binary file
|
pyscreeps_arena/ui/__init__.py
CHANGED
|
@@ -6,5 +6,7 @@ PyScreeps Arena UI模块
|
|
|
6
6
|
from .rs_icon import get_icon, get_pixmap
|
|
7
7
|
from .project_ui import ProjectCreatorUI, run_project_creator
|
|
8
8
|
from .P2PY import png_to_py
|
|
9
|
+
from .qmapv import QPSAMapViewer, CellInfo
|
|
9
10
|
|
|
10
|
-
__all__ = ['get_icon', 'get_pixmap', 'ProjectCreatorUI', 'run_project_creator',
|
|
11
|
+
__all__ = ['get_icon', 'get_pixmap', 'ProjectCreatorUI', 'run_project_creator',
|
|
12
|
+
'png_to_py', 'QPSAMapViewer', 'CellInfo']
|