[VB.NET]How to make a GTA 4 script menu

Shout-Out

User Tag List

Results 1 to 5 of 5
  1. #1
    visitor's Avatar Contributor
    Reputation
    174
    Join Date
    Mar 2008
    Posts
    307
    Thanks G/R
    16/15
    Trade Feedback
    1 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [VB.NET]How to make a GTA 4 script

    Hi!

    I know GTA 4 is not popular because of its system requirements but it's cool that with VB I can make custom scripts like: if you press G then Niko sits on the passenger seat of a vehicle. So its kinda cool.

    What you need:
    GTA 4 1.0.2 (not works with 1.0.3 yet )
    An ASI loader ||| Virus scan
    scripthookdotnet ||| Virus scan

    What to do:
    1. Install GTA 4 and patch it to 1.0.2
    2. Copy dsound.dll from IVAsiLoader.rar to the root directory
    3. Copy scripthookdotnet.zip's contents to root directory
    4. Open VisualStudio
    5. Create a Class Library project
    6. Use these settings:


    The scripthookdotnet.dll can be found at GTA's root folder \scripts\for Developers\bin\ folder
    Now here's the code:
    Code:
    Imports System
    Imports System.Windows.Forms
    Imports GTA
    
    Public Class PassengerScript
        Inherits Script
        Private inVehicle As Boolean = False
        Private pedDriver As Ped
        Private veh As Vehicle
    
        Private Sub PassengerScript_KeyUp(ByVal sender As Object, ByVal e As GTA.KeyEventArgs) Handles Me.KeyUp
            If e.Key = Keys.G Then
                If Player.Character.isInVehicle Then inVehicle = True
    
                Select Case inVehicle
                    Case True
                        If Not Player.LastVehicle.GetPedOnSeat(VehicleSeat.Driver) = Player.Character Then
                            Player.Character.Task.LeaveVehicle()
                            inVehicle = False
                        End If
                    Case False
                        If World.GetClosestVehicle(Player.Character.Position, 5.0F) = Nothing Then
                            Game.DisplayText("Get closer to a vehicle")
                        Else
                            veh = World.GetClosestVehicle(Player.Character.Position, 5.0F)
                            If veh.GetPedOnSeat(VehicleSeat.Driver) = Nothing Then
                                Player.Character.Task.EnterVehicle(veh, VehicleSeat.AnyPassengerSeat)
                            Else
                                pedDriver = veh.GetPedOnSeat(VehicleSeat.Driver)
                                pedDriver.ChangeRelationship(RelationshipGroup.Player, Relationship.Respect)
                                Player.Character.Task.EnterVehicle(veh, VehicleSeat.AnyPassengerSeat)
                            End If
                            inVehicle = True
                        End If
                End Select
            End If
        End Sub
    End Class
    Compile it, put the dll in scripts folder and enjoy it
    Last edited by visitor; 04-20-2009 at 11:33 PM.
    Hey I just met you

    [VB.NET]How to make a GTA 4 script
  2. #2
    Mitron's Avatar Contributor
    Reputation
    127
    Join Date
    Jun 2008
    Posts
    1,326
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Pretty cool actually ^^ i dont play GTA 4 but its a fun thing for the players

    ----------------------------------------------------------------

  3. #3
    visitor's Avatar Contributor
    Reputation
    174
    Join Date
    Mar 2008
    Posts
    307
    Thanks G/R
    16/15
    Trade Feedback
    1 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    yes. and you can make all kind of cheats too. and you can spawn bodyguards and every stuff. but it gets boring after a time
    Hey I just met you

  4. #4
    Mitron's Avatar Contributor
    Reputation
    127
    Join Date
    Jun 2008
    Posts
    1,326
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    haha ye too much cheat = too easy ^^ btw do you have msn ??

    ----------------------------------------------------------------

  5. #5
    visitor's Avatar Contributor
    Reputation
    174
    Join Date
    Mar 2008
    Posts
    307
    Thanks G/R
    16/15
    Trade Feedback
    1 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    i completed the story without any cheat, and that was enjoyable. i wanted to make the 100% without cheat(/scrpts ) but its boring and now i make scripts.
    and PM sent
    Hey I just met you

Similar Threads

  1. Vb.net (2008) how to make a keylogger
    By Flame_Warrior in forum Programming
    Replies: 10
    Last Post: 11-22-2013, 08:59 PM
  2. [VB.NET] How to make an anti afk bot
    By Araredon in forum Programming
    Replies: 5
    Last Post: 05-12-2009, 05:47 AM
  3. Replies: 12
    Last Post: 04-07-2009, 06:40 AM
  4. How to make your own Ppather script revamped
    By ~Jagris in forum WoW Bot Maps And Profiles
    Replies: 9
    Last Post: 02-21-2009, 01:57 PM
All times are GMT -5. The time now is 08:42 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search