ProjectHax

ProjectHax (https://projecthax.com/index.php)
-   Downloads (https://projecthax.com/forumdisplay.php?f=6)
-   -   phBot Comand Line Manager (https://projecthax.com/showthread.php?t=2077)

PainQuate 10-02-2011 05:03 PM

phBot Comand Line Manager
 
1 Attachment(s)
Hi everybody,
I had a suggestion. I wanted to save the access data of the Silkroad to phBot. One member showed me the command line post and I had the idea to transform the set into a program. And that has come out.

The phBot Command Line Manager
http://www8.pic-upload.de/02.10.11/wexrj3j9eoyq.jpg

Itīs very simple. You put the access data of your characters in and push "Create it !" .
It create a .bat file in your phBot folder with the access data. You can run this files and it will run phBot where the access data will directly put in the phBot.

So easy. : D
Itīs written in AutoIT.
The Souce :

PHP Code:

#include <ButtonConstants.au3>
#include <ComboConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <GuiIPAddress.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <File.au3>
#Region ### START Koda GUI section ### Form=
$Form1 GUICreate("phBot Comand Line Manager"475359192124)
GUISetBkColor(0xFFFBF0)
$Label1 GUICtrlCreateLabel("Username :"16245817)
$Input1 GUICtrlCreateInput(""962215321)
$Label2 GUICtrlCreateLabel("Password :"16565617)
$Input2 GUICtrlCreateInput(""965615321,BitOR($GUI_SS_DEFAULT_INPUT,$ES_PASSWORD))
$Label3 GUICtrlCreateLabel("Charakter"16885017)
$Input3 GUICtrlCreateInput(""968815321)
$Label4 GUICtrlCreateLabel("Server :"161204117)
$Combo1 GUICtrlCreateInput(""9612015321)
$Label5 GUICtrlCreateLabel("Loginport :"161525417)
$Combo2 GUICtrlCreateCombo("26"9615215325BitOR($CBS_DROPDOWN,$CBS_AUTOHSCROLL))
GUICtrlSetData(-1"27|28|29|30|Random")
$Radio1 GUICtrlCreateRadio("None"264248917)
GUICtrlSetState(-1$GUI_CHECKED)
$Radio2 GUICtrlCreateRadio("Bind IP"264566517)
$IPAddress1 GUICtrlCreateInput (""3365413021)
$Radio3 GUICtrlCreateRadio("Proxy v4"264887317)
$Radio4 GUICtrlCreateRadio("Proxy v5"2641127317)
$Input4 GUICtrlCreateInput("Proxy IP"3368612921)
$Input5 GUICtrlCreateInput("Proxy Port"33611212921)

$Input6 GUICtrlCreateInput("Proxy Username"26413620121)

$Input7 GUICtrlCreateInput("Proxy Password"26416020121)

$Group1 GUICtrlCreateGroup("Options"818445773)
$Checkbox1 GUICtrlCreateCheckbox("Start Bot on Login"2420810517)
$Checkbox2 GUICtrlCreateCheckbox("Return to Town on Login"2422414517)
$Checkbox3 GUICtrlCreateCheckbox("Relog On Disconncet"24020816117)
$Checkbox4 GUICtrlCreateCheckbox("Minimize phBot directly"24022413717)
GUICtrlCreateGroup("", -99, -9911)
$Button1 GUICtrlCreateButton("Locate phBot Folder"826422725)
$Checkbox5 GUICtrlCreateCheckbox("Create Shortcut on Desktop"24826621717)
$Button2 GUICtrlCreateButton("Create it !"829645925)
$Button3 GUICtrlCreateButton("About"832045925)
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

If FileExists(@ScriptDir "\Confing.ini") = true Then
    $read 
IniRead(@ScriptDir "\Confing.ini","phBot","phBot Folder","")
    
GUICtrlSetColor($Button1,0x00FF00)
Else
    
GUICtrlSetColor($Button1,0xFF0000)
EndIf

While 
1
    $nMsg 
GUIGetMsg()
    Switch 
$nMsg
        
Case $GUI_EVENT_CLOSE
            
Exit
        Case 
$Button3
            MsgBox
(0,"About","Created by PainQuate for phBot")
        Case 
$Button1
            $read
=FileSelectFolder("Locate phBot Folder","")
            
IniWrite("Confing.ini","phBot","phBot Folder",$read)
        Case 
$Button2
            Create
()
    EndSwitch
WEnd

Func Create
()
    
$usernameGuictrlread($Input1)
    
$passwordGuictrlread($Input2)
    
$charakterGUICtrlRead($Input3)
    
$serverGUICtrlRead($Combo1)
    
$loginportGUICtrlRead($Combo2)
    if 
$loginport "Random" Then
        $loginport 
Random(26,30,1)
    Endif
    
$cmdBefehl "@ECHO off" & @CRLF " start phBot.exe --locale isro --username " $username " --password " $password " --server " $server " --character " $charakter " --loginserver " $loginport
    
if GUICtrlRead($Radio2) =1 Then
        $BindIP
=GUICtrlRead($IPAddress1)
        
$cmdBefehl $cmdBefehl " --bindip " $BindIP
    
EndIf
    If 
GUICtrlRead($Radio3) = 1 Then
        $ProxyVersion 
4
        $ProxyIP 
GUICtrlRead($Input4)
        
$ProxyPort GUICtrlRead($Input5)
        
$ProxyUser GUICtrlRead($Input6)
        
$ProxyPass GUICtrlRead($Input7)
        
$cmdBefehl $cmdBefehl " --proxyip " $ProxyIP " --proxyport " $ProxyPort " --proxyuser " $ProxyUser " --proxypass " $ProxyPass " --proxyversion " $ProxyVersion
    
EndIf
    If 
GUICtrlRead($Radio4) = 1 Then
        $ProxyVersion 
5
        $ProxyIP 
GUICtrlRead($Input4)
        
$ProxyPort GUICtrlRead($Input5)
        
$ProxyUser GUICtrlRead($Input6)
        
$ProxyPass GUICtrlRead($Input7)
        
$cmdBefehl $cmdBefehl " --proxyip " $ProxyIP " --proxyport " $ProxyPort " --proxyuser " $ProxyUser " --proxypass " $ProxyPass " --proxyversion " $ProxyVersion
    
EndIf
    If 
GUICtrlRead($Checkbox1) = 1 Then
        $cmdBefehl 
$cmdBefehl " --startbot"
    
EndIf
    If 
GUICtrlRead($Checkbox2) = 1 Then
        $cmdBefehl 
$cmdBefehl " --returntotown"
    
EndIf
    If 
GUICtrlRead($Checkbox3) = 1 Then
        $cmdBefehl 
$cmdBefehl " --relogdc"
    
EndIf
    If 
GUICtrlRead($Checkbox4) = 1 Then
        $cmdBefehl 
$cmdBefehl " --minimize"
    
EndIf
    if 
FileExists($read "\" & $charakter & ".bat") = true Then
        
$xyz=MsgBox ( 48+4, "Attention", "This file already exists, do you want to overwrite it ?" )
        If 
$xyz = 6 Then
            _FileCreate(
$charakter & ".txt")
            FileWrite(
$charakter & ".txt",$cmdBefehl)
            _FileCreate(
$read & "\" & $charakter & ".bat")
            FileCopy(@Scriptdir & "
\" & $charakter & ".txt" , $read & "\" & $charakter & ".bat", 1)
            if GUICtrlRead(
$Checkbox5) = 1 Then
                FileCreateShortcut(
$read & "\" & $charakter & ".bat", @DesktopDir & "\" & $charakter & ".lnk",$read,"","",@ScriptDir & "\icon.bmp")
            EndIf
            MsgBox(0,"
Success","The file was successfully created !")
        ElseIf 
$xyz=7 Then

        EndIf
    Else
        _FileCreate(
$charakter & ".txt")
        FileWrite(
$charakter & ".txt",$cmdBefehl)
        _FileCreate(
$read & "\" & $charakter & ".bat")
        FileCopy(@Scriptdir & "
\" & $charakter & ".txt" , $read & "\" & $charakter & ".bat", 1)
        if GUICtrlRead(
$Checkbox5) = 1 Then
            FileCreateShortcut(
$read & "\" & $charakter & ".bat", @DesktopDir & "\" & $charakter & ".lnk",$read,"","",@ScriptDir & "\icon.bmp")
        EndIf
    EndIf
EndFunc 

if there some Bugs please report.
There will come updates

gm55 10-02-2011 05:34 PM

scan?

projoman 10-03-2011 09:50 AM

Really cool ^^
Maybe in the next version, you can add a function to put all bat files together, I mean all comand lines in the same bat file.... (with pause XXXX between each line ofc)

PainQuate 10-03-2011 10:22 AM

Iīm not at home to night I will post a scan.

PainQuate 10-03-2011 12:32 PM

http://www.virustotal.com/file-scan/...057-1317645602

Virus scan

Halon2 10-03-2011 02:24 PM

Can i have the source ? ^_^
Just want to look how you made it ect, btw, add the scan to your thread not in a post :p

PainQuate 10-03-2011 08:57 PM

The souce is in the first post

Tete1990 03-01-2012 01:10 PM

wow very nice , you have other programs like this with autoit source ?

.z3ro 03-01-2012 07:37 PM

Nice

Flint 06-07-2012 07:26 PM

Pretty usefull, Thanks :)


All times are GMT. The time now is 08:13 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2018, vBulletin Solutions Inc.