Advertisement
vanheartnet

Portable Valorant

Oct 14th, 2020 (edited)
2,442
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.56 KB | None | 0 0
  1. ;@Ahk2Exe-SetCompanyName VANHEARTNET LTD. INC.
  2. ;@Ahk2Exe-SetCopyright All rights reserved © VANHEARTNET
  3. ;@Ahk2Exe-Set FileDescription, Portable Valorant © VANHEARTNET
  4. ;@Ahk2Exe-Set FileVersion, 1.4.0.0
  5. ;@Ahk2Exe-SetInternalName Valorant Tool
  6. ;@Ahk2Exe-SetName Valorant
  7. ;@Ahk2Exe-SetOrigFileName Valorant Tool
  8. ;@Ahk2Exe-Set ProductName, Portable Valorant-NoBoot
  9. ;@Ahk2Exe-Set ProductVersion, 1.4.0.0
  10. ;@Ahk2Exe-Set Description, Valorant Tool
  11. ;@Ahk2Exe-Set Comments, Software Created by : VANHEARTNET
  12. ;@Ahk2Exe-Obey U_au, = "%A_IsUnicode%" ? 2 : 1 ; Script ANSI or Unicode?
  13. ;@Ahk2Exe-PostExec "BinMod.exe" "%A_WorkFileName%"
  14. ;@Ahk2Exe-Cont "%U_au%2.>AUTOHOTKEY SCRIPT<.01VANHEARTNET "
  15. ;@Ahk2Exe-SetMainIcon icon.ico
  16. ;@Ahk2Exe-AddResource Icon.ico, 160 ; Replaces 'H on blue'
  17. ;@Ahk2Exe-AddResource Icon.ico, 206 ; Replaces 'S on green'
  18. ;@Ahk2Exe-AddResource Icon.ico, 207 ; Replaces 'H on red'
  19. ;@Ahk2Exe-AddResource Icon.ico, 208 ; Replaces 'S on red'
  20.  
  21.  
  22. #SingleInstance,Ignore
  23. #Persistent
  24. #NoEnv
  25. Menu,tray, NoStandard
  26. Menu, Tray, Tip, PORTABLE VALORANT
  27. Menu, Tray, Add, Exit1
  28. SetWorkingDir, %A_ScriptDir%
  29. SetBatchLines, 20ms
  30. #MaxHotkeysPerInterval 99000000
  31. #HotkeyInterval 99000000
  32. #KeyHistory 0
  33. ListLines Off
  34. Process, Priority, , A
  35. SetKeyDelay, -1, -1
  36. SetMouseDelay, -1
  37. SetDefaultMouseSpeed, 0
  38. SetWinDelay, -1
  39. SetControlDelay, -1
  40. DetectHiddenWindows, On
  41. SetTitleMatchMode, 3
  42. SendMode Input
  43.  
  44. if not A_IsAdmin
  45. {
  46. Run, *RunAs "%A_ScriptFullpath%"
  47. ExitApp
  48. }
  49.  
  50. IfNotExist,%A_Temp%\reg
  51. FileCreateDir,%A_Temp%\reg
  52. else
  53. {
  54. FileRemoveDir,%A_Temp%\reg,1
  55. FileCreateDir,%A_Temp%\reg
  56. }
  57. FileSetAttrib,+H,%A_Temp%\reg
  58. FileInstall,logo.png,%A_Temp%\reg\logo.png,1
  59.  
  60. sleep,1000
  61. IfExist,C:\Riot Games
  62. FileRemoveDir,C:\Riot Games,1
  63. IfExist,C:\Users\%A_UserName%\AppData\Local\Riot Games
  64. FileRemoveDir,C:\Users\%A_UserName%\AppData\Local\Riot Games,1
  65. IfExist,C:\Users\%A_UserName%\AppData\Local\VALORANT
  66. FileRemoveDir,C:\Users\%A_UserName%\AppData\Local\VALORANT,1
  67. IfExist,C:\ProgramData\Riot Games
  68. FileRemoveDir,C:\ProgramData\Riot Games,1
  69.  
  70. Gosub,Check_Updates
  71.  
  72. Run *RunAs cmd.exe /c mklink /j "C:\Riot Games" "`%CD`%\Portable Valorant\Riot Games" && mklink /j "C:\Users\%A_UserName%\AppData\Local\Riot Games" "`%CD`%\Portable Valorant\Appdata\Riot Games" && mklink /j "C:\ProgramData\Riot Games" "`%CD`%\Portable Valorant\Programdata\Riot Games",,Hide
  73. sleep 50
  74. FileCreateShortcut,C:\Riot Games\Riot Client\RiotClientServices.exe,%A_Temp%\reg\VALORANT.lnk ,C:/Riot Games/Riot Client, --launch-product=valorant --launch-patchline=live
  75.  
  76. Process,Exist,vgc.exe
  77. {
  78. If(Errorlevel=0)
  79. {
  80. Run, *RunAs cmd.exe /c sc config vgc start= demand,,Hide
  81. Sleep 200
  82. Run, *RunAs cmd.exe /c net start vgc,,Hide
  83. }
  84. }
  85. Process,Exist,vgtray.exe
  86. {
  87. If(Errorlevel=0)
  88. {
  89. IfExist, C:\Program Files\Riot Vanguard\vgtray.exe
  90. Run, *RunAs cmd.exe /c "C:\Program Files\Riot Vanguard\vgtray.exe",,Hide
  91. else IfExist, Vanguard\Riot Vanguard\vgtray.exe
  92. Run, *RunAs cmd.exe /c "Vanguard\Riot Vanguard\vgtray.exe",,Hide
  93. }
  94. }
  95. Sleep 100
  96. Run *RunAs cmd.exe /c "%A_Temp%\reg\VALORANT.lnk",,Hide
  97. Gui,1:+Alwaysontop -Caption
  98. Gui,1:Color,222222
  99. Gui,1:Add,Picture,x1 y2 w600 h200,%A_Temp%\reg\logo.png
  100. Gui,1:+Lastfound
  101. winset,Transcolor,222222
  102. Gui,1:Show,w600 h200,Portable VALORANT
  103. Sleep, 1000
  104. Loop 5
  105. {
  106. SetRegView, 64
  107. RegDelete, HKLM , SOFTWARE\Microsoft\Windows\CurrentVersion\Run , Riot Vanguard
  108. RegDelete, HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run , Riot Vanguard
  109. Sleep 10
  110. SetRegView, 32
  111. RegDelete, HKLM , SOFTWARE\Microsoft\Windows\CurrentVersion\Run , Riot Vanguard
  112. RegDelete, HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run , Riot Vanguard
  113. Sleep 10
  114. SetRegView, Default
  115. RegDelete, HKLM , SOFTWARE\Microsoft\Windows\CurrentVersion\Run , Riot Vanguard
  116. RegDelete, HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Run , Riot Vanguard
  117. Sleep 1000
  118. }
  119. FileRemoveDir,%A_Temp%\reg,1
  120. ExitApp
  121.  
  122. Esc::
  123. Exit1:
  124. FileRemoveDir,%A_Temp%\reg,1
  125. ExitApp
  126.  
  127. Check_Updates:
  128. ;~ =======================================CHECK VERSION=====================================================
  129. V=1.4.0.0
  130. MFlink=https://www.mediafire.com/file/q6debu9d9mfa6wk/Portable+Valorant+-NoBoot.rar/file
  131. pastebin=https://pastebin.com/PSxVqM7B
  132. ;~ ============================================================================================
  133. message=Portable Valorant
  134. message1=`n`nThank You`n`n-VANHEARTNET
  135. message2=Portable Valorant by © VANHEARTNET`n`nLatest version is now available and ready to download`nYou will redirect to a download link.`n`nThank You`n`n-VANHEARTNET
  136. Ytt=https://www.youtube.com/watch?v=o1EtXFr7vkU
  137. URLDownloadToFile,%Ytt%,%A_Temp%\Portable Valorant version2.dat
  138. ;~ ============================================================================================
  139. URLDownloadToFile,%pastebin%,%A_Temp%\Portable Valorant version.dat
  140. if errorlevel=0
  141. {
  142. fileread,version,%A_Temp%\Portable Valorant version.dat
  143. IfNotInString,version,%V%
  144. {
  145. Loop,read,%A_Temp%\Portable Valorant version.dat
  146. {
  147. str := A_LoopReadLine
  148. s:=StrSplit(str,"version=")
  149. Loop,parse,A_LoopReadLine,`n
  150. {
  151. IfNotInString,str,version=
  152. continue
  153. else
  154. {
  155. rar:=StrSplit(s.2,"</div>")
  156. url1:=rar.1
  157. V2:=url1
  158. break 2
  159. }
  160. }
  161. }
  162. if(V2="")
  163. return
  164. MsgBox,262180, Portable Valorant, A new version is Available!`n`nDo you want to download?`t`t`nversion : %V2%,10
  165. IfMsgBox,Yes
  166. Run,%MFlink%
  167. }
  168. }
  169.  
  170. ;~ ==================================================================================================================
  171.  
  172. return
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement