Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Region ;**** Directives created by AutoIt3Wrapper_GUI ****
- #AutoIt3Wrapper_Icon=D:\Potrzebne\Grafika\Obraz (51).ico
- #AutoIt3Wrapper_Res_Comment=YTMonster Helper by Christopher
- #AutoIt3Wrapper_Res_Description=YTMonster Helper by Christopher
- #AutoIt3Wrapper_Res_Language=1045
- #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
- #include <ButtonConstants.au3>
- #include <EditConstants.au3>
- #include <GUIConstantsEx.au3>
- #include <StaticConstants.au3>
- #include <WindowsConstants.au3>
- #include <IE.au3>
- #include <String.au3>
- #include <Array.au3>
- #include <WinHTTP.au3>
- #Region ### START Koda GUI section ### Form=C:\Users\Krzysztof\Desktop\Like4Like Bot by Christopher.kxf
- $Form2 = GUICreate("YTMonster Helper by Christopher", 314, 242)
- $Group1 = GUICtrlCreateGroup("YTMonster", 16, 16, 281, 161)
- $Input1 = GUICtrlCreateInput("", 96, 56, 121, 21)
- GUICtrlSetData(-1, RegRead("HKEY_CURRENT_USER\Like4Like_BOT\", "Username"))
- $Input2 = GUICtrlCreateInput("", 96, 112, 121, 21, BitOR($ES_PASSWORD, $ES_AUTOHSCROLL))
- GUICtrlSetData(-1, RegRead("HKEY_CURRENT_USER\Like4Like_BOT\", "Password"))
- $Label1 = GUICtrlCreateLabel("Username:", 96, 38, 55, 17, $SS_CENTER)
- $Label2 = GUICtrlCreateLabel("Password:", 96, 92, 53, 17, $SS_CENTER)
- $Save1 = GUICtrlCreateCheckbox("Save", 96, 144, 121, 17, BitOR($GUI_SS_DEFAULT_CHECKBOX, $BS_LEFT))
- GUICtrlSetState(-1, RegRead("HKEY_CURRENT_USER\Like4Like_BOT\", "Save"))
- GUICtrlCreateGroup("", -99, -99, 1, 1)
- $Button1 = GUICtrlCreateButton("Login", 16, 193, 281, 33)
- GUISetState(@SW_SHOW)
- #EndRegion ### END Koda GUI section ###
- ;Zmienne
- $hConnect = 0
- $hSession = 0
- While 1
- $nMsg = GUIGetMsg()
- Switch $nMsg
- Case $GUI_EVENT_CLOSE
- _WinHttpCloseHandle($hConnect)
- _WinHttpCloseHandle($hSession)
- Exit
- Case $Button1
- GUICtrlSetState($Button1, $GUI_DISABLE)
- GUICtrlSetData($Button1, "Logging in...")
- $Login = GUICtrlRead($Input1)
- $Passwd = GUICtrlRead($Input2)
- If GUICtrlRead($Save1) = 1 Then
- RegWrite("HKEY_CURRENT_USER\Like4Like_BOT\", "Username", "REG_SZ", GUICtrlRead($Input1))
- RegWrite("HKEY_CURRENT_USER\Like4Like_BOT\", "Password", "REG_SZ", GUICtrlRead($Input2))
- RegWrite("HKEY_CURRENT_USER\Like4Like_BOT\", "Save", "REG_SZ", 1)
- Else
- RegDelete("HKEY_CURRENT_USER\Like4Like_BOT\", "Username")
- RegDelete("HKEY_CURRENT_USER\Like4Like_BOT\", "Password")
- RegWrite("HKEY_CURRENT_USER\Like4Like_BOT\", "Save", "REG_SZ", 0)
- EndIf
- $hSession = _WinHttpOpen("Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.152 Safari/537.36 OPR/29.0.1795.60")
- $hConnect = _WinHttpConnect($hSession, "www.ytmonster.net")
- $Logowanie = _WinHttpSimpleRequest($hConnect, "POST", "/login?login=ok", "http://www.ytmonster.net/login", "usernames=" & $Login & "&passwords=" & $Passwd & "&submit=")
- GUIDelete($Form2)
- #Region ### START Koda GUI section ### Form=C:\Users\Krzysztof\Desktop\YTMonster Helper.kxf
- $Form1 = GUICreate("YTMonster Helper by Christopher", 538, 410, 192, 124)
- $Input1 = GUICtrlCreateInput("", 128, 12, 393, 21)
- $Label1 = GUICtrlCreateLabel("YouTube Video URL: ", 16, 16, 109, 17)
- $Edit1 = GUICtrlCreateEdit("", 16, 72, 505, 265)
- $Label2 = GUICtrlCreateLabel("Comments:", 16, 52, 56, 17)
- $Checkbox1 = GUICtrlCreateCheckbox("Delay:", 16, 373, 49, 17, BitOR($GUI_SS_DEFAULT_CHECKBOX, $BS_LEFT))
- $Button1 = GUICtrlCreateButton("Add comments", 184, 352, 339, 41)
- $Input2 = GUICtrlCreateInput("", 72, 371, 81, 21)
- GUICtrlSetState(-1, $GUI_DISABLE)
- GUISetState(@SW_SHOW)
- #EndRegion ### END Koda GUI section ###
- While 1
- $nMsg = GUIGetMsg()
- Switch $nMsg
- Case $GUI_EVENT_CLOSE
- _WinHttpCloseHandle($hConnect)
- _WinHttpCloseHandle($hSession)
- Exit
- Case $Button1
- If StringInStr(GUICtrlRead($Edit1), @LF) == 0 Then
- MsgBox(48, "Attention!", "You need to add at least two comments.")
- Else
- GUICtrlSetData($Button1, "Adding comments...")
- GUICtrlSetState($Button1, $GUI_DISABLE)
- $URL = GUICtrlRead($Input1)
- $Comments = StringReplace(GUICtrlRead($Edit1), "ę", "e")
- $Comments = StringReplace($Comments, "ó", "o")
- $Comments = StringReplace($Comments, "ę", "e")
- $Comments = StringReplace($Comments, "ą", "a")
- $Comments = StringReplace($Comments, "ś", "s")
- $Comments = StringReplace($Comments, "ł", "l")
- $Comments = StringReplace($Comments, "ż", "z")
- $Comments = StringReplace($Comments, "ź", "z")
- $Comments = StringReplace($Comments, "ć", "c")
- $Comments = StringReplace($Comments, "ń", "n")
- $Comments = StringReplace($Comments, "Ę", "E")
- $Comments = StringReplace($Comments, "Ó", "O")
- $Comments = StringReplace($Comments, "Ą", "A")
- $Comments = StringReplace($Comments, "Ś", "S")
- $Comments = StringReplace($Comments, "Ł", "L")
- $Comments = StringReplace($Comments, "Ż", "Z")
- $Comments = StringReplace($Comments, "Ź", "Z")
- $Comments = StringReplace($Comments, "Ć", "C")
- $Comments = StringReplace($Comments, "Ń", "N")
- $CommentList = StringSplit($Comments, @LF)
- For $i = 1 To $CommentList[0] Step 2
- If $i + 1 > $CommentList[0] Then
- $CurrentComments = $CommentList[$i] & "%0D%0A" & $CommentList[$i - 1]
- Else
- $CurrentComments = $CommentList[$i] & "%0D%0A" & $CommentList[$i + 1]
- EndIf
- If GUICtrlRead($Checkbox1) = 1 Then
- If StringInStr(GUICtrlRead($Input2), "*") == 0 Then
- Sleep(60000 * GUICtrlRead($Input2))
- Else
- $DelayList = StringSplit(GUICtrlRead($Input2), "*")
- $Delay = 60000
- For $j = 1 To $DelayList[0] Step 1
- $Delay *= $DelayList[$i]
- Next
- Sleep($Delay)
- EndIf
- EndIf
- _WinHttpSimpleRequest($hConnect, "POST", "/add_video?add=comments", "http://www.ytmonster.net/add_video", "url=" & $URL & "&type=comments&length=&amount=&vReferral=2&likes_amount=&subs_amount=&comments=" & $CurrentComments)
- Next
- GUICtrlSetData($Button1, "Dodaj komentarze")
- GUICtrlSetState($Button1, $GUI_ENABLE)
- EndIf
- Case $Checkbox1
- If GUICtrlRead($Checkbox1) = 1 Then
- GUICtrlSetState($Input2, $GUI_ENABLE)
- Else
- GUICtrlSetState($Input2, $GUI_DISABLE)
- EndIf
- EndSwitch
- WEnd
- EndSwitch
- WEnd
Advertisement
Add Comment
Please, Sign In to add comment