The MatriX
  • Welcome To Ghbsys
  • Combat Arms Classic Public is released
  • CS GO Streaming Version is released. Have fun streaming while cheating!
  • Have a Payment Issue? Send us a Support ticket.
  • Make a thread if you need support or join our discord for live support.
  • Have Suggestions? Make a thread and you'll earn Ghbsys Points for implemented suggestions.
  • Join our discord to stay well connected! Don't forget to integrate your discord to the site

Welcome to [GHB] - GAmEhAcKbAsTaRdS Forum

Welcome to [GHB] - GAmEhAcKbAsTaRdS Forum, like most online communities you must register to view or post in our community, but don't worry this is a simple free process that requires minimal information for you to signup. Be apart of [GHB] - GAmEhAcKbAsTaRdS Forum by signing in or creating an account.
  • Start new topics and reply to others
  • Subscribe to topics and forums to get email updates
  • Get your own profile page and make new friends
  • Send personal messages to other members.

Sign in to follow this  
NeoIII

Visual Basic6 Tutorial

Recommended Posts

Im assuming you have vb6,ok lets get started.

im not going to get in depth of the properties.(color,clip controls,etc.)

 

Open vb6,hit make new Standard.exe,now we have are basic form page.

 

1.We need to rename this,notice on the righthand side.You will see project1 properties.

if you notice caption is highlighted,in our properties box.thats the name of our forum.go ahead and rename it.My Trainer V1.0 or w/e.

 

2.ok you need this module,for warrock

too add this module,at the top left of vb6 by the file,and edit,under it is a pic

untitledbr3.gif

click this and add new module(copy and paste this code in)

 

Public Const PROCESS_ALL_ACCESS = &H1F0FFF
Dim f1holder As Integer
Dim timer_pos As Long

'API Declaration
Public Declare Function GetWindowThreadProcessId Lib "user32" (ByVal hwnd As Long, lpdwProcessId As Long) As Long
Public Declare Function OpenProcess Lib "kernel32" (ByVal dwDesiredAccess As Long, ByVal bInheritHandle As Long, ByVal dwProcessId As Long) As Long
Public Declare Function WriteProcessMemory Lib "kernel32" (ByVal hProcess As Long, ByVal lpBaseAddress As Any, lpBuffer As Any, ByVal nSize As Long, lpNumberOfBytesWritten As Long) As Long
Public Declare Function CloseHandle Lib "kernel32" (ByVal hObject As Long) As Long
Public Declare Function FindWindow Lib "user32" Alias "FindWindowA" (ByVal Classname As String, ByVal WindowName As String) As Long
Public Declare Function GetKeyPress Lib "user32" Alias "GetAsyncKeyState" (ByVal key As Long) As Integer
Public Declare Function ReadProcessMem Lib "kernel32" Alias "ReadProcessMemory" (ByVal hProcess As Long, ByVal lpBaseAddress As Any, ByRef lpBuffer As Any, ByVal nSize As Long, lpNumberOfBytesWritten As Long) As Long

Public Function WriteAByte(gamewindowtext As String, address As Long, value As Byte)
Dim hwnd As Long
Dim pid As Long
Dim phandle As Long
hwnd = FindWindow(vbNullString, gamewindowtext)
If (hwnd = 0) Then
MsgBox "The Game Is Not Working", vbCritical, "Error"
End
Exit Function
End If
GetWindowThreadProcessId hwnd, pid
phandle = OpenProcess(PROCESS_ALL_ACCESS, False, pid)
If (phandle = 0) Then
MsgBox "Can't get ProcessId", vbCritical, "Error"
Exit Function
End If
WriteProcessMemory phandle, address, value, 1, 0&
CloseHandle hProcess
End Function

Public Function WriteAnInt(gamewindowtext As String, address As Long, value As Integer)
Dim hwnd As Long
Dim pid As Long
Dim phandle As Long
hwnd = FindWindow(vbNullString, gamewindowtext)
If (hwnd = 0) Then
MsgBox "The Game Is Not Working", vbCritical, "Error"
End
End If
GetWindowThreadProcessId hwnd, pid
phandle = OpenProcess(PROCESS_ALL_ACCESS, False, pid)
If (phandle = 0) Then
MsgBox "Can't get ProcessId", vbCritical, "Error"
Exit Function
End If
WriteProcessMemory phandle, address, value, 2, 0&
CloseHandle hProcess
End Function

Public Function WriteALong(gamewindowtext As String, address As Long, value As Long)
Dim hwnd As Long
Dim pid As Long
Dim phandle As Long
hwnd = FindWindow(vbNullString, gamewindowtext)
If (hwnd = 0) Then
MsgBox "The Game Is Not Working", vbCritical, "Error"
End
Exit Function
End If
GetWindowThreadProcessId hwnd, pid
phandle = OpenProcess(PROCESS_ALL_ACCESS, False, pid)
If (phandle = 0) Then
MsgBox "Can't get ProcessId", vbCritical, "Error"
Exit Function
End If
WriteProcessMemory phandle, address, value, 4, 0&
CloseHandle hProcess
End Function

Public Function ReadAByte(gamewindowtext As String, address As Long, valbuffer As Byte)
Dim hwnd As Long
Dim pid As Long
Dim phandle As Long
hwnd = FindWindow(vbNullString, gamewindowtext)
If (hwnd = 0) Then
MsgBox "The Game Is Not Working", vbCritical, "Error"
End
Exit Function
End If
GetWindowThreadProcessId hwnd, pid
phandle = OpenProcess(PROCESS_ALL_ACCESS, False, pid)
If (phandle = 0) Then
MsgBox "Can't get ProcessId", vbCritical, "Error"
Exit Function
End If
ReadProcessMem phandle, address, valbuffer, 1, 0&
CloseHandle hProcess
End Function

Public Function ReadAnInt(gamewindowtext As String, address As Long, valbuffer As Integer)
Dim hwnd As Long
Dim pid As Long
Dim phandle As Long
hwnd = FindWindow(vbNullString, gamewindowtext)
If (hwnd = 0) Then
MsgBox "The Game Is Not Working", vbCritical, "Error"
End
Exit Function
End If
GetWindowThreadProcessId hwnd, pid
phandle = OpenProcess(PROCESS_ALL_ACCESS, False, pid)
If (phandle = 0) Then
MsgBox "Can't get ProcessId", vbCritical, "Error"
Exit Function
End If
ReadProcessMem phandle, address, valbuffer, 2, 0&
CloseHandle hProcess
End Function

Public Function ReadALong(gamewindowtext As String, address As Long, valbuffer As Long)
Dim hwnd As Long
Dim pid As Long
Dim phandle As Long
hwnd = FindWindow(vbNullString, gamewindowtext)
If (hwnd = 0) Then
MsgBox "The Game Is Not Working", vbCritical, "Error"
End
Exit Function
End If
GetWindowThreadProcessId hwnd, pid
phandle = OpenProcess(PROCESS_ALL_ACCESS, False, pid)
If (phandle = 0) Then
MsgBox "Can't get ProcessId", vbCritical, "Error"
Exit Function
End If
ReadProcessMem phandle, address, valbuffer, 4, 0&
CloseHandle hProcess
End Function

Public Function ReadAFloat(gamewindowtext As String, address As Long, valbuffer As Single) 
Dim hWnd As Long 
Dim pid As Long 
Dim phandle As Long 
hWnd = FindWindow(vbNullString, gamewindowtext) 
If (hWnd = 0) Then 
MsgBox "The Game Is Not Working", vbCritical, "Error" 
End 
Exit Function 
End If 

GetWindowThreadProcessId hWnd, pid 
phandle = OpenProcess(PROCESS_ALL_ACCESS, False, pid) 
If (phandle = 0) Then 
MsgBox "Can't get ProcessId", vbCritical, "Error" 
Exit Function 
End If 

ReadProcessMem phandle, address, valbuffer, 4, 0& 
CloseHandle hProcess 
End Function 



Public Function WriteAFloat(gamewindowtext As String, address As Long, value As Single) 
Dim hWnd As Long 
Dim pid As Long 
Dim phandle As Long 

hWnd = FindWindow(vbNullString, gamewindowtext) 
If (hWnd = 0) Then 
MsgBox "The Game Is Not Working", vbCritical, "Error" 
End 
Exit Function 
End If 

GetWindowThreadProcessId hWnd, pid 
phandle = OpenProcess(PROCESS_ALL_ACCESS, False, pid) 
If (phandle = 0) Then 
MsgBox "Can't get ProcessId", vbCritical, "Error" 
Exit Function 
End If 

WriteProcessMemory phandle, address, value, 4, 0& 
CloseHandle hProcess 
End Function

 

ok now we have our module,were ready to build our trainer

now heres how to do a button and hotkeys

 

3.now to add a button,go to the lefthand side,to the toolbar,double click a button,now you have a button on your form,click it to put were you want it.Notice you can resize it and whatnot.ok now

 

4.rename this button,look into the properties box again,now your in the properties of this button,scroll threw it,look for caption(and rename it)

 

5.Adding a code to this button,double click the button,now your in the coding part of the button/trainer.this is what you should see

Private Sub Command1_Click()

End Sub

 

ok,we want to put in our addie like so.ill do gps

Private Sub Command1_Click()
Call WriteAlong("WarRock", &H90DC84 , 1)
End Sub

 

Notice its Writing along our addie we use in uce with &H infront(vb code &H)with a value of 1 for on.To do the Off code it would be in another button of course and a value of 0,like so

 

Private Sub Command2_Click()
Call WriteAlong("WarRock", &H90DC84 , 0)
End Sub

 

ok,moving on

 

6.hotkeys,You need two timers for this

you need to Add A Timer,In the toolbox with the button

ok now goto the properties of the timer,Righthand side(when you add something into your trainer or form it will automaticlly be in the properties for that timer or button.in properties look for the interval set it to 1.

now double click on that timer to add in our code(this timer is for the hotkey.

If GetKeyPress (VbKeyNumpad0)then
If Timer2.Interval = 0 Then Timer2.Interval = 1
Else: Timer2.Interval = 0
End If

 

now if you notice GetKeyPress(VBkey) is our hotkey command

heres a few for pointers

VBKeyNumpad0-9

VbKeyShift

VbKeyP

ok and the rest of the code

If Timer2.Interval = 0 Then Timer2.Interval = 1

Else: Timer2.Interval = 0,

this will tell our trainer to turn on the timer we want,by changeing the interval

 

7.now add the second timer,(leave the interval as 0)and add our code for the cheat,again i will use gps

Call WriteALong("WarRock", &H90DC84 ,1)

 

hopefully You get my point to a hotkey,If you dont understand start with buttons first.

 

now we have a gps hack with buttons and a hotkey.lets test our trainer before saving.go to the play button at the top.

p.s you must have warrock opened up for your trainer to work.

 

if everything tested out fine and worked then we are ready to save our trainer.exe

 

8.go to file and save your trainer,change the names to what you want,then go back to file and look for make project1.exe or w/e u named it.exe and your done find your trainer inside C:\Program Files\Microsoft Visual Studio\VB98

 

and thats it.woot woot

 

soon i will post how to add more hotkeys to the same timer,and change the looks of your trainer,even how to add your own icons.etc.

Share this post


Link to post
Share on other sites

wow. nice tutorial. im new to vb6 and making hacks so i have a few questions. do you ever need to change the module if you're making diferent hacks? i also don't understand what do hot keys do. Also don't the warrock adresses change? and if they do whare do you get them? i'm guessing google. o and i also heard that punkbuster detects vb6 hacks, is that true? thanks in advance!!!!

Share this post


Link to post
Share on other sites
very ns tut Neo, i have a better tut on how to make it gps a bypass everytime u make the gps hack!!

 

 

In my opinion it's a very good ex gratia payment of Neo I.I.I to post such a tut. He needn't do it, but he does it. He also can only make the hacks and load them up at this page, but he makes tuts or everyone so each person can understand the codes and make his own hacks. Don't say anything against Neo, he is a very sympathic person.

 

Greets Pascha649

Share this post


Link to post
Share on other sites

wow,my tut gets around.i am cjg333 from *Zensored* lol if you look at the top it says quotecjg333,lol idc glad to see it helps ppl

Edited by cobra

Share this post


Link to post
Share on other sites

i have an question when u use an undetected module when u spell ex: Call WriteAlong("WarRock", &H90DC84 , 1) it dont work =\ for me can anyone say me why ? and what should i change sorry for my english ^^ its not so good

Share this post


Link to post
Share on other sites

WriteAlong("WarRock", &H90DC84 , 1) i believe you should be changing the thing in green(the adress), but i am not sure.... i think you leave the &H and change only the other part,,, sorry i can't be much more helpfull

Share this post


Link to post
Share on other sites
WriteAlong("WarRock", &H90DC84 , 1) i believe you should be changing the thing in green(the adress), but i am not sure.... i think you leave the &H and change only the other part,,, sorry i can't be much more helpfull

 

 

no problem xD

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.