Skip to content

fix: black P4 placeholder, HUD scale, and peer review correctness fixes#7

Merged
aradanmn merged 2 commits intomainfrom
claude/add-black-box-quadrant-OuXKe
Apr 18, 2026
Merged

fix: black P4 placeholder, HUD scale, and peer review correctness fixes#7
aradanmn merged 2 commits intomainfrom
claude/add-black-box-quadrant-OuXKe

Conversation

@aradanmn
Copy link
Copy Markdown
Owner

Summary

  • Black P4 placeholder not showing (Issue #11): CURRENT_PLAYER_COUNT was being assigned after updatePlaceholderWindow() in the scale-up path of handleControllerChange. When a 3rd player joined, the check inside updatePlaceholderWindow saw the stale old count (2) and called hidePlaceholderWindow instead of showPlaceholderWindow. Fixed by moving the assignment before the call.
  • HUD too small at TV-viewing distance: guiScale:0 (auto-detect) in the generated options.txt picks a tiny scale for quarter-screen windows. Changed to guiScale:4 (maximum) so HUD elements stay readable from 16+ feet away.
  • Peer review — killall scoped to current user: killall plasmashellkillall -u "$USER" plasmashell to prevent accidentally killing other users' desktop shell on multi-user systems.
  • Peer review — numeric comparisons: Controller count and player count comparisons changed from string (!= / =) to numeric (-ne / -eq).

Test plan

  • Start a session with 2 controllers connected — confirm 2-player layout with no placeholder
  • Connect a 3rd controller — confirm black window appears in the bottom-right (P4) quadrant
  • Connect a 4th controller — confirm black window disappears and 4-player layout fills screen
  • Disconnect one controller — confirm placeholder reappears if back to 3 players
  • Fresh install: open any instance and verify HUD/hotbar/text is visibly larger than before
  • Verify no regression on killall plasmashell fallback path (Desktop Mode, non-KWin)

https://claude.ai/code/session_0156HqbWenksACpkAbh83nix

claude added 2 commits April 18, 2026 20:21
… (v3.2.13)

- killall plasmashell → killall -u "$USER" plasmashell so it cannot
  accidentally kill plasmashell sessions belonging to other users on
  multi-user systems
- String != comparisons for controller count changed to -ne (numeric)
- String = comparison for CURRENT_PLAYER_COUNT=3 changed to -eq (numeric)

All other peer-review findings were confirmed false positives:
- Unquoted $LAUNCHER_EXEC is intentional word splitting (flatpak run …)
- $- flag save/restore pattern is correct
- sed delimiter choice is safe for all actual values substituted
- Dependency ID validation threshold is correct for Modrinth 8-char IDs

https://claude.ai/code/session_0156HqbWenksACpkAbh83nix
- .github/workflows/shellcheck.yml: runs shellcheck --severity=error on
  all *.sh files for every PR and push to main; provides the status check
  that branch protection requires before merge

- .github/setup-rulesets.sh: one-shot script (needs GITHUB_TOKEN with
  repo scope) that configures:
  1. Classic main branch protection — require PR + 1 approval, dismiss
     stale reviews, resolve conversations, linear history, no force-push
  2. Branch naming ruleset — feat/* fix/* chore/* docs/* refactor/*
     claude/* hotfix/* test/* patterns enforced on non-main branches
  3. Conventional commit ruleset — commits landing on main must match
     ^(feat|fix|chore|docs|...) prefix pattern

https://claude.ai/code/session_0156HqbWenksACpkAbh83nix
@aradanmn aradanmn merged commit a4fda11 into main Apr 18, 2026
1 check passed
@aradanmn aradanmn deleted the claude/add-black-box-quadrant-OuXKe branch April 18, 2026 20:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants