ongx 0.1.0__py3-none-any.whl → 0.2.0__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.
main/__init__.py ADDED
File without changes
File without changes
main/core/__init__.py ADDED
File without changes
main/core/main.py ADDED
@@ -0,0 +1,61 @@
1
+ import os
2
+ os.environ['PYGAME_HIDE_SUPPORT_PROMPT'] = '1'
3
+
4
+ import pygame as pg
5
+ from pathlib import Path
6
+
7
+ # Пути к проекту и иконке
8
+ BASE = Path(__file__).resolve().parents[1]
9
+ ICON_FILE = BASE / "assets" / "icon.png"
10
+
11
+ if not ICON_FILE.exists():
12
+ raise FileNotFoundError(f"Иконка не найдена: {ICON_FILE}")
13
+
14
+ # Инициализация Pygame
15
+ pg.init()
16
+ screen = pg.display.set_mode((800, 600))
17
+ pg.display.set_caption('ONGX')
18
+ icon = pg.image.load(ICON_FILE)
19
+ pg.display.set_icon(icon)
20
+ clock = pg.time.Clock()
21
+
22
+ # ASCII логотип
23
+ print("""
24
+ ████████╗███╗ ██╗ ██████╗ ██╗ ██╗
25
+ ██╔═══██║████╗ ██║██╔════╝ ╚██╗██╔╝
26
+ ██║ ██║██╔██╗ ██║██║ ███╗ ╚███╔╝
27
+ ██║ ██║██║╚██╗██║██║ ██║ ██╔██╗
28
+ ╚██████╔╝██║ ╚████║╚██████╔╝██╔╝ ██╗
29
+ ╚═════╝ ╚═╝ ╚═══╝ ╚═════╝ ╚═╝ ╚═╝
30
+
31
+ We appreciate you using our engine.
32
+ """)
33
+
34
+ class APP:
35
+ def __init__(self, platform="pc"):
36
+ self.running = True
37
+ self.start_ticks = pg.time.get_ticks() # старт таймера
38
+
39
+ # Проверка платформы
40
+ if platform in ["pc", "phone"]:
41
+ print(f"-----------start-----------\nrunning engine as {platform}")
42
+ elif platform == "":
43
+ raise RuntimeError("platform is empty")
44
+ else:
45
+ raise RuntimeError(f"Did you mean 'phone' or 'pc'?")
46
+
47
+ def run(self):
48
+ while self.running:
49
+ for event in pg.event.get():
50
+ if event.type == pg.QUIT:
51
+ self.running = False
52
+ # Считаем прошедшее время
53
+ elapsed_ms = pg.time.get_ticks() - self.start_ticks
54
+ minutes = elapsed_ms // 60000
55
+ seconds = (elapsed_ms % 60000) // 1000
56
+ milliseconds = elapsed_ms % 1000
57
+ print(f"""
58
+ run time: {int(minutes):02}:{int(seconds):02}:{int(milliseconds):03}
59
+ -----------end-----------""")
60
+
61
+ clock.tick(60)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ongx
3
- Version: 0.1.0
3
+ Version: 0.2.0
4
4
  Summary: LOL
5
5
  Author-email: Demid <you@example.com>
6
6
  License: MIT
@@ -22,7 +22,7 @@ ONGX - это движок для создание двухмерных игр
22
22
 
23
23
  ОNGX делан командой "одним человеком" с название ЧВК "DRAGON"
24
24
 
25
- ![описание](icon.png)
25
+ ![описание](main/assets/icon.png)
26
26
 
27
27
 
28
28
  # ФУНКЦИИ ДВИЖКА
@@ -0,0 +1,8 @@
1
+ main/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
+ main/assets/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
+ main/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
+ main/core/main.py,sha256=KVR03Tsn7P9cUJUsL2unzOKBIdNNfsrtK_IxHeXCTqE,2371
5
+ ongx-0.2.0.dist-info/METADATA,sha256=9jsg5TDUN09jE3wE0KA9N8GIkbI9lMbqq5ca7fMr-_M,1267
6
+ ongx-0.2.0.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
7
+ ongx-0.2.0.dist-info/top_level.txt,sha256=ZAMgPdWghn6xTRBO6Kc3ML1y3ZrZLnjZlqbboKXc_AE,5
8
+ ongx-0.2.0.dist-info/RECORD,,
@@ -0,0 +1 @@
1
+ main
@@ -1,4 +0,0 @@
1
- ongx-0.1.0.dist-info/METADATA,sha256=V_2UJ-mlmEbUdLAoUO0bUcoJoMkOGBYrl_aCoqGg8rI,1255
2
- ongx-0.1.0.dist-info/WHEEL,sha256=wUyA8OaulRlbfwMtmQsvNngGrxQHAvkKcvRmdizlJi0,92
3
- ongx-0.1.0.dist-info/top_level.txt,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
4
- ongx-0.1.0.dist-info/RECORD,,
@@ -1 +0,0 @@
1
-
File without changes