Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Imports System ' basic imports
- Imports GTA ' basic imports
- Imports System.Windows.Forms ' needed to have access to "keys" enumeration, for example
- Imports System.Drawing ' needed to handle colors referencing the color name, ex: myCar.color = System.Drawing.Color.Black
- Public Class BasicScript
- Inherits Script
- private myCam as camera = nothing
- Public Sub New()
- Me.interval = 10
- myCam = new camera
- End Sub
- private sub msg(sMsg as string, time as int32)
- Native.Function.Call("PRINT_STRING_WITH_LITERAL_STRING_NOW", "STRING", sMsg, time, 1)
- end sub
- Private Sub keyDown(ByVal sender As Object, ByVal e As GTA.KeyEventArgs) Handles MyBase.KeyDown
- if (e.key = keys.d1) then
- myCam.position = game.currentcamera.position
- myCam.rotation = game.currentcamera.rotation
- myCam.activate
- end if
- if (e.key = keys.d2) then
- myCam.deactivate
- end if
- if e.key = keys.d0 then
- player.character.weapons.MP5.ammo = 50
- player.character.weapons.RocketLauncher.ammo = 50
- player.character.weapons.RocketLauncher.select
- end if
- if e.key = keys.d9 then
- dim aSet as AnimationSet
- aSet = new AnimationSet("jump_std")
- player.character.animation.play(aSet, "jump_land_roll", 1.0, AnimationFlags.Unknown01)
- wait(100)
- while player.character.animation.isPlaying(aSet, "jump_land_roll")
- msg(player.character.animation.GetCurrentAnimationTime(aSet, "jump_land_roll").tostring, 100)
- if player.character.animation.GetCurrentAnimationTime(aSet, "jump_land_roll") > 0.2 then player.character.task.clearallimmediately
- wait(10)
- end while
- end if
- End Sub
- Private Sub keyUp(ByVal sender As Object, ByVal e As GTA.KeyEventArgs) Handles MyBase.KeyUp
- end sub
- Private Sub general_tick(ByVal sender As Object, ByVal e As EventArgs) Handles MyBase.Tick
- if myCam.isactive then
- myCam.rotation = game.defaultcamera.rotation
- if game.iskeypressed(keys.numpad8) then
- myCam.position += myCam.direction
- elseif game.iskeypressed(keys.numpad2) then
- myCam.position -= myCam.direction
- end if
- end if
- end sub
- End Class
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement