Files
local_machine/scripts/games/diagnose-homm-mouse.sh
ahauimix 1938b7c743 Expand local_machine docs and automation for connectivity, games, and ops.
Add proxy/VPN/telegram launchd and emergency runbooks; reorganize apps docs;
document JA3 CrossOver runbook and Wine troubleshooting; add GOG/HoMM game
scripts, disk cleanup guides, and gitea push-via-proxy helper. Ignore temp/.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-01 08:12:19 +03:00

42 lines
1.9 KiB
Bash
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#!/usr/bin/env bash
# Диагностика «курсор двигается, клики не работают» для HoMM Olden Era в Whisky.
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
# shellcheck source=config.sh
source "${SCRIPT_DIR}/config.sh"
LOG="${BOTTLE_DIR}/drive_c/users/${USER}/AppData/LocalLow/Unfrozen/HeroesOldenEra/Player.log"
LOG_PREV="${BOTTLE_DIR}/drive_c/users/${USER}/AppData/LocalLow/Unfrozen/HeroesOldenEra/Player-prev.log"
echo "Bottle: ${BOTTLE_NAME}"
echo "Player.log: ${LOG}"
echo ""
if [[ ! -f "${LOG}" ]]; then
echo "Нет Player.log — хотя бы один раз запустите игру."
exit 1
fi
if grep -q 'EnableMouseInPointer failed' "${LOG}" 2>/dev/null; then
echo "ДИАГНОЗ: Unity + Wine — заглушка EnableMouseInPointer (WM_POINTER)."
echo "Строка из лога:"
grep -n 'EnableMouseInPointer' "${LOG}" | head -5 || true
echo ""
echo "WineBus / виртуальный desktop / SDL это НЕ лечат."
echo ""
echo "Рабочие пути:"
echo " 1) CrossOver (macOS) + при необходимости патч:"
echo " https://github.com/dabielf/crossover-unity-mouse-fix"
echo " 2) Ждать WhiskyWine/Wine с upstream-фиксом (см. Wine bug #53847)."
echo ""
DOCS="$(cd "${GAMES_DIR}/../.." && pwd)/docs/games/UNITY_POINTER_MOUSE_FIX.md"
echo "Подробности: ${DOCS}"
exit 0
fi
echo "Строка EnableMouseInPointer в текущем Player.log не найдена."
if [[ -f "${LOG_PREV}" ]] && grep -q 'EnableMouseInPointer failed' "${LOG_PREV}" 2>/dev/null; then
echo "(В Player-prev.log она была — перезапустите игру и снова этот скрипт.)"
fi
echo "Если клики всё равно мертвы — пришлите первые 80 строк Player.log в поддержку."