Skip to content

Instantly share code, notes, and snippets.

@ikt32
ikt32 / Gears.cs
Last active March 13, 2017 14:29
Very first attempt at gear locking in GTA V
using System;
using GTA;
using GTA.Native;
public class Gears : Script {
Random random = new Random();
public Gears() {
Tick += OnTick;
Interval = 0;
@ikt32
ikt32 / settings_general.ini
Created March 13, 2017 14:10
Manual Transmission settings I use (v4.2.0-beta1) (Logitech G27)
; Xbox Controller layout, full options
; Toggle: Dpad Right (Hold)
; Shift up: A
; Shift down: X
; Clutch: Left Thumb Down
; Engine: Dpad Right
; Neutral: X (Hold)
; Keyboard without numpad or laptop
@ikt32
ikt32 / Numpad__.kbd.json
Last active October 19, 2017 12:15
Numpad++
[
{
"name": "Numpad++",
"author": "ikt",
"switchMount": "cherry",
"switchBrand": "gateron",
"switchType": "KS-3-White",
"plate": true
},
[
@ikt32
ikt32 / LicencePlateDisplay_Raycast.cs
Last active May 21, 2017 13:36
Shows the licence plate of the car in front
/*
* Raycast version
*/
using System;
using GTA;
using GTA.Math;
using GTA.Native;
public class Raycast : Script
{
@ikt32
ikt32 / WheelData.cs
Last active June 9, 2017 19:04
Accessing wheel data in ScriptHookVDotNet
using System;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Runtime.Remoting.Channels;
using GTA.Math;
using GTA.Native;
namespace GTA.examples
{
public class WheelData : Script
@ikt32
ikt32 / WheelPositions.cs
Created June 10, 2017 15:49
Get absolute wheel coordinates (without GetOffsetInWorldCoords native)
using System;
using System.Collections.Generic;
using System.Runtime.InteropServices;
using System.Runtime.Remoting.Channels;
using GTA.Math;
using GTA.Native;
namespace GTA.examples
{
public class WheelPositions : Script
@ikt32
ikt32 / STLvsLoop.cpp
Last active March 2, 2020 20:46
Compare stl::find_if vs simple search
#include <cstdint>
#include <tuple>
#include <vector>
#include <algorithm>
#include <string>
#include <random>
#include <chrono>
#include <iostream>
typedef uint32_t Hash;
@ikt32
ikt32 / PedHealth.cs
Last active July 18, 2017 18:47
Show ped health on their positions
/*
* Search version
* Due to having multiple entries we can do fancy stuff like fade-in,
* fade-out, depending on distance, and showing multiple boxes.
*/
using System;
using System.CodeDom.Compiler;
using System.Collections.Generic;
using System.Drawing;
@ikt32
ikt32 / nativetest.lua
Created August 9, 2017 19:54
extra natives tests
function drawTxt(x,y ,width,height,scale, text)
SetTextFont(0)
SetTextProportional(0)
SetTextScale(scale, scale)
SetTextColour(255, 255, 255, 255)
SetTextDropShadow(0, 0, 0, 0,255)
SetTextEdge(1, 0, 0, 0, 255)
SetTextDropShadow()
SetTextOutline()
SetTextEntry("STRING")
@ikt32
ikt32 / guide.md
Last active February 25, 2023 13:11
GTA V modding quick start guide