Results 1 to 5 of 5

Thread: RTST Batch File

  1. #1

    RTST Batch File

    I've noticed I often forget to start RTST when I play Planetside so I came up with a solution. It's a combination of batch file and python file. The batch file handles monitoring and the python file is a work around for notifying the user if RTST is being started.

    The batch file is as follows:
    Code:
    @echo off
    
    tasklist /fi "imagename eq RTST.exe" | find ":" > nul
    	if errorlevel 1 (
    		echo "RTST is running..."
    		exit
    	)
    
    tasklist /fi "imagename eq LaunchPad.exe" | find ":" > nul
    	if errorlevel 1 (
    		echo "LaunchPad is running..."
    		start beep.py
    		start /d "C:\Program Files (x86)\Recursion\RealTimeStatTracker" RTST
    	)
    
    exit
    and the python file:
    Code:
    import winsound
    winsound.Beep(750,300)
    winsound.Beep(750,300)
    winsound.Beep(750,300)
    If you don't care about the beeps, you can remove the "start beep.py" from the batch file. Because it's a batch file, you can set it to run on a schedule (aka every minutes, etc.) It basically just monitors your processes and if it detects the LaunchPad is started and RTST is not, it will start RTST automatically (and notify you with beeps if you choose.)

  2. #2
    Cancer Man
    Stat Tracker Development Team
    Recursion Council
    Recursion Officer
    Exploding Fist's Avatar
    Join Date
    Feb 2014
    Location
    Toronto, Canada
    Posts
    1,512
    Awesome, thanks for sharing that. One thing we still need to code in is the option to auto start sessions when your last monitored character is online. With something like this then you'd never have to push any buttons!

    I will say that having the tracker open BEFORE Planetside is launched will become very important soon. Looping this with a one second sleep "timeout /t 1" at the end of the batch file would be good enough to catch it though.
    Last edited by Exploding Fist; 03-24-2014 at 08:00 AM.


  3. #3
    Quote Originally Posted by Exploding Fist View Post
    Awesome, thanks for sharing that. One thing we still need to code in is the option to auto start sessions when your last monitored character is online. With something like this then you'd never have to push any buttons!

    I will say that having the tracker open BEFORE Planetside is launched will become very important soon. Looping this with a one second sleep "timeout /t 1" at the end of the batch file would be good enough to catch it though.
    Yeah, I didn't include a loop in the file itself because I wasn't sure how I wanted to handle the looping. But, it's probably the best method. You could potentially bundle it with the installer as an optional install and then it could be passed through as a service to windows on start-up.

  4. #4
    Cancer Man
    Stat Tracker Development Team
    Recursion Council
    Recursion Officer
    Exploding Fist's Avatar
    Join Date
    Feb 2014
    Location
    Toronto, Canada
    Posts
    1,512
    If anything at some point we'd look into putting in the option to autostart to system tray on Windows login. That'd be the proper way to implement this.

    Until then, a scripted hack job is a good solution


  5. #5
    That's true. the only reason I like the script setup is that it's dependent on starting planetside. As it stands if you never start planetside, the tracker never launches. Granted the tracker requires nearly no memory, but it's something. I look forward to a more automated start-up in the future though.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •