mirror of
https://github.com/csd4ni3l/shatterstack.git
synced 2026-01-01 04:23:48 +01:00
update arcade dependency to development branch, add setting start
settings start category constant
This commit is contained in:
@@ -2,7 +2,7 @@ import copy, pypresence, json, os
|
|||||||
|
|
||||||
import arcade, arcade.gui
|
import arcade, arcade.gui
|
||||||
|
|
||||||
from utils.constants import button_style, dropdown_style, slider_style, settings, discord_presence_id
|
from utils.constants import button_style, dropdown_style, slider_style, settings, discord_presence_id, settings_start_category
|
||||||
from utils.utils import FakePyPresence
|
from utils.utils import FakePyPresence
|
||||||
from utils.preload import button_texture, button_hovered_texture, theme_sound
|
from utils.preload import button_texture, button_hovered_texture, theme_sound
|
||||||
|
|
||||||
@@ -25,7 +25,7 @@ class Settings(arcade.gui.UIView):
|
|||||||
self.on_radiobuttons = {}
|
self.on_radiobuttons = {}
|
||||||
self.off_radiobuttons = {}
|
self.off_radiobuttons = {}
|
||||||
|
|
||||||
self.current_category = "Graphics"
|
self.current_category = settings_start_category
|
||||||
|
|
||||||
self.modified_settings = {}
|
self.modified_settings = {}
|
||||||
|
|
||||||
@@ -54,7 +54,7 @@ class Settings(arcade.gui.UIView):
|
|||||||
|
|
||||||
self.display_categories()
|
self.display_categories()
|
||||||
|
|
||||||
self.display_category("Graphics")
|
self.display_category(settings_start_category)
|
||||||
|
|
||||||
def display_categories(self):
|
def display_categories(self):
|
||||||
for category in settings:
|
for category in settings:
|
||||||
|
|||||||
@@ -7,4 +7,4 @@ requires-python = ">=3.11"
|
|||||||
dependencies = ["arcade", "pypresence>=4.3.0"]
|
dependencies = ["arcade", "pypresence>=4.3.0"]
|
||||||
|
|
||||||
[tool.uv.sources]
|
[tool.uv.sources]
|
||||||
arcade = { git = "https://github.com/pythonarcade/arcade.git", rev = "gui/controller" }
|
arcade = { git = "https://github.com/pythonarcade/arcade.git", rev = "development" }
|
||||||
|
|||||||
@@ -1,3 +1,3 @@
|
|||||||
Pillow
|
Pillow
|
||||||
git+https://github.com/pythonarcade/arcade.git@gui/controller
|
git+https://github.com/pythonarcade/arcade.git@development
|
||||||
pypresence
|
pypresence
|
||||||
|
|||||||
@@ -6,10 +6,41 @@ from arcade.gui.widgets.slider import UISliderStyle
|
|||||||
menu_background_color = (30, 30, 47)
|
menu_background_color = (30, 30, 47)
|
||||||
log_dir = 'logs'
|
log_dir = 'logs'
|
||||||
discord_presence_id = 1360953272843632680
|
discord_presence_id = 1360953272843632680
|
||||||
|
|
||||||
CELL_SIZE = 48
|
CELL_SIZE = 48
|
||||||
ROWS = 14
|
ROWS = 14
|
||||||
COLS = 14
|
COLS = 14
|
||||||
OUTLINE_WIDTH = 2
|
OUTLINE_WIDTH = 2
|
||||||
|
SHAPES = {
|
||||||
|
"I": [(0, 0), (1, 0), (2, 0), (3, 0)],
|
||||||
|
"I_R1": [(0, 0), (0, 1), (0, 2), (0, 3)],
|
||||||
|
"O": [(0, 0), (1, 0), (0, 1), (1, 1)],
|
||||||
|
"T": [(0, 0), (1, 0), (2, 0), (1, 1)],
|
||||||
|
"T_R1": [(1, 0), (1, 1), (1, 2), (0, 1)],
|
||||||
|
"T_R2": [(0, 1), (1, 1), (2, 1), (1, 0)],
|
||||||
|
"T_R3": [(0, 0), (0, 1), (0, 2), (1, 1)],
|
||||||
|
"L": [(0, 0), (0, 1), (0, 2), (1, 2)],
|
||||||
|
"L_R1": [(0, 1), (1, 1), (2, 1), (2, 0)],
|
||||||
|
"L_R2": [(1, 0), (1, 1), (1, 2), (0, 0)],
|
||||||
|
"L_R3": [(0, 0), (1, 0), (2, 0), (0, 1)],
|
||||||
|
"J": [(1, 0), (1, 1), (1, 2), (0, 2)],
|
||||||
|
"J_R1": [(0, 0), (0, 1), (1, 1), (2, 1)],
|
||||||
|
"J_R2": [(0, 0), (1, 0), (0, 1), (0, 2)],
|
||||||
|
"J_R3": [(0, 0), (1, 0), (2, 0), (2, 1)],
|
||||||
|
"LINE1": [(0, 0)],
|
||||||
|
"LINE2": [(0, 0), (1, 0)],
|
||||||
|
"LINE3": [(0, 0), (1, 0), (2, 0)],
|
||||||
|
}
|
||||||
|
|
||||||
|
COLORS = {
|
||||||
|
"red": (255, 90, 90, 255),
|
||||||
|
"blue": (100, 180, 255, 255),
|
||||||
|
"green": (100, 255, 160, 255),
|
||||||
|
"yellow": (255, 230, 100, 255),
|
||||||
|
"purple": (200, 100, 255, 255),
|
||||||
|
"orange": (255, 160, 90, 255),
|
||||||
|
"teal": (100, 255, 255, 255),
|
||||||
|
}
|
||||||
|
|
||||||
button_style = {'normal': UITextureButtonStyle(font_name="Protest Strike", font_color=arcade.color.BLACK), 'hover': UITextureButtonStyle(font_name="Protest Strike", font_color=arcade.color.BLACK),
|
button_style = {'normal': UITextureButtonStyle(font_name="Protest Strike", font_color=arcade.color.BLACK), 'hover': UITextureButtonStyle(font_name="Protest Strike", font_color=arcade.color.BLACK),
|
||||||
'press': UITextureButtonStyle(font_name="Protest Strike", font_color=arcade.color.BLACK), 'disabled': UITextureButtonStyle(font_name="Protest Strike", font_color=arcade.color.BLACK)}
|
'press': UITextureButtonStyle(font_name="Protest Strike", font_color=arcade.color.BLACK), 'disabled': UITextureButtonStyle(font_name="Protest Strike", font_color=arcade.color.BLACK)}
|
||||||
@@ -41,33 +72,4 @@ settings = {
|
|||||||
"Credits": {}
|
"Credits": {}
|
||||||
}
|
}
|
||||||
|
|
||||||
SHAPES = {
|
settings_start_category = "Graphics"
|
||||||
"I": [(0, 0), (1, 0), (2, 0), (3, 0)],
|
|
||||||
"I_R1": [(0, 0), (0, 1), (0, 2), (0, 3)],
|
|
||||||
"O": [(0, 0), (1, 0), (0, 1), (1, 1)],
|
|
||||||
"T": [(0, 0), (1, 0), (2, 0), (1, 1)],
|
|
||||||
"T_R1": [(1, 0), (1, 1), (1, 2), (0, 1)],
|
|
||||||
"T_R2": [(0, 1), (1, 1), (2, 1), (1, 0)],
|
|
||||||
"T_R3": [(0, 0), (0, 1), (0, 2), (1, 1)],
|
|
||||||
"L": [(0, 0), (0, 1), (0, 2), (1, 2)],
|
|
||||||
"L_R1": [(0, 1), (1, 1), (2, 1), (2, 0)],
|
|
||||||
"L_R2": [(1, 0), (1, 1), (1, 2), (0, 0)],
|
|
||||||
"L_R3": [(0, 0), (1, 0), (2, 0), (0, 1)],
|
|
||||||
"J": [(1, 0), (1, 1), (1, 2), (0, 2)],
|
|
||||||
"J_R1": [(0, 0), (0, 1), (1, 1), (2, 1)],
|
|
||||||
"J_R2": [(0, 0), (1, 0), (0, 1), (0, 2)],
|
|
||||||
"J_R3": [(0, 0), (1, 0), (2, 0), (2, 1)],
|
|
||||||
"LINE1": [(0, 0)],
|
|
||||||
"LINE2": [(0, 0), (1, 0)],
|
|
||||||
"LINE3": [(0, 0), (1, 0), (2, 0)],
|
|
||||||
}
|
|
||||||
|
|
||||||
COLORS = {
|
|
||||||
"red": (255, 90, 90, 255),
|
|
||||||
"blue": (100, 180, 255, 255),
|
|
||||||
"green": (100, 255, 160, 255),
|
|
||||||
"yellow": (255, 230, 100, 255),
|
|
||||||
"purple": (200, 100, 255, 255),
|
|
||||||
"orange": (255, 160, 90, 255),
|
|
||||||
"teal": (100, 255, 255, 255),
|
|
||||||
}
|
|
||||||
|
|||||||
4
uv.lock
generated
4
uv.lock
generated
@@ -5,7 +5,7 @@ requires-python = ">=3.11"
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "arcade"
|
name = "arcade"
|
||||||
version = "3.1.0"
|
version = "3.1.0"
|
||||||
source = { git = "https://github.com/pythonarcade/arcade.git?rev=gui%2Fcontroller#2e455be7a75170192a74549517cbdc9bd988780d" }
|
source = { git = "https://github.com/pythonarcade/arcade.git?rev=development#a17e95502bc0c7cd0527445e62bff84a49183c43" }
|
||||||
dependencies = [
|
dependencies = [
|
||||||
{ name = "pillow" },
|
{ name = "pillow" },
|
||||||
{ name = "pyglet" },
|
{ name = "pyglet" },
|
||||||
@@ -202,7 +202,7 @@ dependencies = [
|
|||||||
|
|
||||||
[package.metadata]
|
[package.metadata]
|
||||||
requires-dist = [
|
requires-dist = [
|
||||||
{ name = "arcade", git = "https://github.com/pythonarcade/arcade.git?rev=gui%2Fcontroller" },
|
{ name = "arcade", git = "https://github.com/pythonarcade/arcade.git?rev=development" },
|
||||||
{ name = "pypresence", specifier = ">=4.3.0" },
|
{ name = "pypresence", specifier = ">=4.3.0" },
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user