2014-07-07, 14:29
the one that came with the addon i guess , i didn't modify anything
(2014-07-05, 04:41)teeedubb Wrote: Try this one first, I dont get a error when reopening xbmc after this command, although the pc Im using doesnt have web access setup. If this one works well let me know and I will integrate it into the addon, it closes xbmc quickly:
xbmc-pre-steam.sh
Code:#!/bin/bash
kill $(pidof xbmc.bin)
You can replace the 'kill' line above with a xbmc-send command (you need to install xbmc-eventclients-xbmc-send), which uses a inbuilt xbmc function to quit xbmc, although this takes along time to quit xbmc, atleast on my v14 install. Also this command doesnt wait for xbmc to quit. Note you may need to configure the command to suit your system:
Code:xbmc-send --action=Quit
Make sure the script file is marked as executable.
start c:\path\to\your\focus_steam_kodi.exe
;Script to maximise and focus on either Steam BPM and Kodi for a defined period of time
#NoEnv
#SingleInstance force
SetWorkingDir %A_ScriptDir%
;Time to sleep (in milliseconds) between loops:
LoopFrequency = 500
;Time to run loop for (in milliseconds):
LoopTotalTime = 5000
;Uncomment below to force script to wait for Steam BPM before starting focus loop
;WinWait, Steam ahk_class CUIEngineWin32
;;;;;;;;;;
;Uncomment below to force script to wait for Kodi before starting focus loop
;WinWait, Kodi ahk_class Kodi
;;;;;;;;;;
;focus loop
start := A_TickCount
loop
{
;Uncomment below to maximise and force focus on Kodi;;;;;;;;;;;;;;;
; IfWinExist, Kodi ahk_class Kodi
; {
; WinMaximize, Kodi ahk_class Kodi
; WinActivate, Kodi ahk_class Kodi
; }
;;;;;;;;;;
;The following is to maximise and force focus on Steam BPM;;;;;;;;;
IfWinExist, Steam ahk_class CUIEngineWin32
{
WinMaximize, Steam ahk_class CUIEngineWin32
WinActivate, Steam ahk_class CUIEngineWin32
}
;;;;;;;;;;
sleep, %LoopFrequency%
now := A_TickCount-start
if now > %LoopTotalTime%
break
}
return
ExitApp
1.2.2
Basic support for Android added. This simply launches the Steam app. Only options that work are 'busy dialog timeouts'. Closing XBMC requires root rights (at least using 'kill' via adb), and anyway, is there any point to closing XBMC on Android?
Script files attempt to close xbmc gracefully, then in the background wait 1 second and if xbmc still exists it will be closed forcefully.
1.9.4
New settings layout - only OS specific settings are shown.
Steam-launch.sh is made executable automatically when necessary and the option do so is removed.
Rewrote default.py - added extra logging and trimmed it down and cleaned it up a bit, should work better now.
New locking mechanism to try and prevent xbmc restarting multiple instances on linux if addon run multiple times
Changes to included scripts
1.9.6
fixed error notifications
cleaned up launching commands
addon check if checks if pre/post steam scripts exist, if not disables them.
small fixes