1
0
Fork 0
mirror of https://github.com/aclist/dztui.git synced 2024-12-29 13:52:03 +01:00

feat: GTK bindings

This commit is contained in:
aclist 2024-01-31 18:36:08 +09:00
parent b16e613094
commit ebe54d812c
6 changed files with 3843 additions and 2016 deletions

View file

@ -1,5 +1,31 @@
# Changelog # Changelog
## [5.0.0] 2024-01-31
### Added
- Context switching: navigate to different pages using side buttons
- Dynamic statusbar: updates metadata and server distance when selecting rows
- Show server-side modlist and allow jumping to Steam Workshop pages to browse, and list whether mod is currently installed
- Print debug logs in-app (Help > Show debug log)
- Functionality to change API keys in-app (used when revoking old API keys)
- Print atomic mod sizes when listing installed mods
- Dialogs show direct links to API key management URLs when changing API keys
- Toggle dry-run mode directly from server browser
- Extensive keybindings for fully controlling the application without the mouse
- Extensive pre-boot sanity checks
- Keybinding help dialog in main menu
- Right-click context menus in server browsers/mod list: add/remove from favorites, show server-side mods, delete mod, copy server IP to clipboard
### Changed
- Utilize GTK bindings and MVC paradigm for UI creation and data flow
- Filter servers dynamically from within server browser
- Performance and security improvements to DZGUI helper files
### Fixed
- First-time setup dialogs respawning repeatedly in certain scenarios
- Issues with Steam client switching to the wrong page when using auto-mod install
- Set text input module correctly when launching on Steam Deck
- Separate current/total player count and use proper integer sort method in table
## [4.1.1] 2023-12-18 ## [4.1.1] 2023-12-18
### Fixed ### Fixed

2622
dzgui.sh

File diff suppressed because it is too large Load diff

1355
helpers/funcs Executable file

File diff suppressed because it is too large Load diff

75
helpers/query_v2.py Normal file
View file

@ -0,0 +1,75 @@
import sys
import a2s
import math
import json
from a2s import dayzquery
sys.path.append('a2s')
def get_info(ip, qport):
try:
info = a2s.info((ip, int(qport)))
name = info.server_name
map = info.map_name
address = ip + ":" + qport
gameport = str(info.port)
players = info.player_count
max_players = info.max_players
keywords = info.keywords
ping = (info.ping*1000)
ping = math.floor(ping)
res = {}
res['name'] = name
res['map'] = map
res['gametype'] = keywords
res['players'] = players
res['max_players'] = max_players
res['addr'] = address
res['gameport'] = gameport
res['stat'] = "online"
res['qport'] = qport
res['ping'] = str(ping) + "ms"
j = json.dumps([res])
print(j)
except:
sys.exit(1)
def get_rules(ip, qport):
try:
mods = dayzquery.dayz_rules((ip, int(qport))).mods
for k in mods:
print(k.workshop_id)
except:
sys.exit(1)
def get_names(ip, qport):
try:
mods = dayzquery.dayz_rules((ip, int(qport))).mods
ids = []
names = []
for mod in mods:
names.append(mod.name)
ids.append(mod.workshop_id)
res = {}
res['names'] = names
res['ids'] = ids
j = json.dumps(res)
print(j)
except:
sys.exit(1)
ip = sys.argv[1]
qport = sys.argv[2]
mode = sys.argv[3]
match mode:
case "info":
get_info(ip, qport)
case "rules":
get_rules(ip, qport)
case "names":
get_names(ip, qport)

1665
helpers/ui.py Normal file

File diff suppressed because it is too large Load diff

0
news
View file