Skip to content
MPGHThe Dark Arts
/
RegisterLog in
Forum
Community
What's NewLatest posts across the boardTrendingHottest threads right nowSubscribedThreads you follow
Discussion
GeneralIntroductionsEntertainmentDebate FortFlaming & Rage
Board
News & AnnouncementsMPGH TimesSuggestions & HelpGiveaways
More Sections
Art & Graphic DesignProgrammingHackingCryptocurrency
Hacks & Cheats
Games
ValorantCS2 / CS:GOCall of Duty / WarzoneFortniteApex LegendsEscape From Tarkov
+14 moreLeague of LegendsGTA VMinecraftRustROTMGBattlefieldTroveBattleOnCombat ArmsCrossFireBlackshotRuneScapeDayZDead by Daylight
Resources
Game Hacking TutorialsReverse EngineeringGeneral Game HackingAnti-CheatConsole Game Hacking
Tools
Game Hacking ToolsTrainers & CheatsHack/Release NewsNew
Submit a release →Share your cheat, tool, or config with the community.
AINEW
AI Tools
General & DiscussionPrompt EngineeringLLM JailbreaksHotAI Agents & AutomationLocal / Open Models
AI × Gaming
AI Aimbots & VisionML Anti-CheatGame Bots & Automation
Create
AI Coding / Vibe CodingAI Art & MediaAI Voice & TTS
The AI frontier →Where game hacking meets modern machine learning. Jump in.
Marketplace
Buy & Sell
SellingBuyingTradingUser Services
Trust & Safety
Middleman LoungeMarketplace TalkVouch Copy Profiles
Money
Cryptocurrency TalkCurrency ExchangeWork & Job Offers
Start selling →List accounts, services, and goods. Use the middleman to trade safe.
MPGH The Dark Arts

A community for offensive security research, reverse engineering, and AI.

Community

ForumMarketplaceSearch

Account

RegisterLog in

Legal

Privacy PolicyForum RulesHelp & FAQ
© 2026 MPGH · All rights reserved.Built by the community, for the community. For educational purposes onlyContent is shared for security research and education — we don't condone illegal use. You're responsible for complying with applicable laws. Use at your own risk.
Home › Forum › Programming › Visual Basic Programming › AFK Bot for Crossfire.

AFK Bot for Crossfire.

Posts 1–6 of 6 · Page 1 of 1
LA
Lachesis09
[Help] AFK Bot for Crossfire.
Hey all.

For 1 week now, i am farming at Crossfire. And i am already gettin tired by moving my char to dont get kicked for being afk.

So i downloaded Visual Basic again, i tried to create kind of a "Anti-AFK Bot".
But it doesnt worked so far. And i have no idea, how to go on.

I dont know whether Crossfire or Xtrap, but something is blocking every keystroke my app sends.

i already tried SendKeys, the keybd_event function via KeyPush.dll & the SendInput function via user32.dll. I got all of them sending keystrokes to the notepad, but when i try them in Crossfire.. nothing happens.

Is there any1, who can give me a helping hand? If i get the bot working for Crossfire, i am going to release it in the crossfire hack section.

Thank you,

Paul

Here, my try with SendInput: But it doesnt worked for crossfire...

[php]Imports System****ntime.InteropServices

Public Class Form1
Private Sub DoKeyBoard(ByVal flags As NativeMethods.KEYEVENTF, ByVal key As Keys)
Dim input As New NativeMethods.INPUT
Dim ki As New NativeMethods.KEYBDINPUT
input.dwType = NativeMethods.InputType.Keyboard
input.ki = ki
input.ki.wVk = Convert.ToInt16(key)
input.ki.wScan = 0
input.ki.time = 0
input.ki.dwFlags = flags
input.ki.dwExtraInfo = IntPtr.Zero
Dim cbSize As Integer = Marshal.SizeOf(GetType(NativeMethods.INPUT))
Dim result As Integer = NativeMethods.SendInput(1, input, cbSize)
If result = 0 Then Debug.WriteLine(Marshal.GetLastWin32Error)
End Sub
Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
DoKeyBoard(4, Keys.A)
DoKeyBoard(4, Keys.D)
End Sub

Private Sub startBtn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles startBtn.Click
Timer1.Enabled = True
stopBtn.Enabled = True
startBtn.Enabled = False
End Sub

Private Sub stopBtn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles stopBtn.Click
Timer1.Enabled = False
startBtn.Enabled = True
stopBtn.Enabled = False
End Sub
End Class

Public Class NativeMethods

<DllImport("user32.dll", SetLastError:=True)> _
Friend Shared Function SendInput(ByVal cInputs As Int32, ByRef pInputs As INPUT, ByVal cbSize As Int32) As Int32
End Function

<StructLayout(LayoutKind.Explicit, pack:=1, Size:=28)> _
Friend Structure INPUT
<FieldOffset(0)> Public dwType As InputType
<FieldOffset(4)> Public mi As MOUSEINPUT
<FieldOffset(4)> Public ki As KEYBDINPUT
<FieldOffset(4)> Public hi As HARDWAREINPUT
End Structure

<StructLayout(LayoutKind.Sequential, pack:=1)> _
Friend Structure MOUSEINPUT
Public dx As Int32
Public dy As Int32
Public mouseData As Int32
Public dwFlags As MOUSEEVENTF
Public time As Int32
Public dwExtraInfo As IntPtr
End Structure

<StructLayout(LayoutKind.Sequential, pack:=1)> _
Friend Structure KEYBDINPUT
Public wVk As Int16
Public wScan As Int16
Public dwFlags As KEYEVENTF
Public time As Int32
Public dwExtraInfo As IntPtr
End Structure

<StructLayout(LayoutKind.Sequential, pack:=1)> _
Friend Structure HARDWAREINPUT
Public uMsg As Int32
Public wParamL As Int16
Public wParamH As Int16
End Structure

Friend Enum InputType As Integer
Mouse = 0
Keyboard = 1
Hardware = 2
End Enum

<Flags()> _
Friend Enum MOUSEEVENTF As Integer
MOVE = &H1
LEFTDOWN = &H2
LEFTUP = &H4
RIGHTDOWN = &H8
RIGHTUP = &H10
MIDDLEDOWN = &H20
MIDDLEUP = &H40
XDOWN = &H80
XUP = &H100
VIRTUALDESK = &H400
WHEEL = &H800
ABSOLUTE = &H8000
End Enum

<Flags()> _
Friend Enum KEYEVENTF As Integer
EXTENDEDKEY = 1
KEYUP = 2
[UNICODE] = 4
SCANCODE = 8
End Enum
End Class[/php]
#1 · edited 15y ago · 15y ago
/B
/b/oss
senkeys.send?

ZZ
#2 · 15y ago
Blubb1337
Blubb1337
Quote Originally Posted by m_t_h View Post
senkeys.send?

ZZ
Does not work in 99% off the directx games
#3 · 15y ago
/B
/b/oss
Quote Originally Posted by Blubb1337 View Post
Does not work in 99% off the directx games
didnt kno cf is ded.
zzz
#4 · 15y ago
Jason
Jason
Quote Originally Posted by m_t_h View Post
senkeys.send?

ZZ
I please you to read the first post.

Quote Originally Posted by Lachesis09
i already tried SendKeys, the keybd_event function via KeyPush.dll & the SendInput function via user32.dll.
#5 · 15y ago
/B
/b/oss
Quote Originally Posted by Jason View Post


I please you to read the first post.

srry im on phone fmm
#6 · 15y ago
Posts 1–6 of 6 · Page 1 of 1

Post a Reply

Tags for this Thread

None