Jump to content
Sign in to follow this  

IniRead Var in Run()

Recommended Posts


So I'm writing a launcher for a video game and I'm trying to make my launcher read certain variables from a .ini file which is fine, I've done it before but never in Run()

The script isn't even executing the .exe so I'm guessing its failing at the iniread section or the Run() section.

Here's a test script I wrote to demonstrate what I'm talking about. ( Because the actual launcher script is annoying and has a patching system / status check that would be annoying to sort through )

#include <GUIConstants.au3>
#include <File.au3>

GUICreate ( "Launcher", 600, 480,(@DesktopWidth-600)/2, (@DesktopHeight-480)/2 )
Opt("GUIOnEventMode", 1)
GUISetOnEvent($GUI_EVENT_CLOSE, "_Quit")

$Launch = GUICtrlCreateButton("Start Game", 5, 420, 100, 33, 0)
$Fcon = @ScriptDir & "\FConfig.ini"
$con = IniRead("FConfig.ini", "SERVER", "SIP", "NotFound")


While 1
    $msg = GuiGetMsg()
    Case $msg = $Launch
        Run('TRose.exe @TRIGGER_SOFT@ _server' & $con)

Func _Quit()

If anyone could point out where its not working ( I'm thinking its failing in Run() ) or point me in the right direction I would be very grateful.

I've tried it several different ways but it doesn't want to work.



Edited by Portwolf

Share this post

Link to post
Share on other sites

RUN works in one directory.. try changin it.. or specifying the workingdir to the folder its located in

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this