Hallo,
ich habe folgende Idee. (Einen Teil davon von youtube übernommen)
Und zwar macht man sich ein Script oder Programm. Allerdings muss man vorher die Models von den Gegnern z.B. CT (also CSS) vorher so geändert haben, dass die Köpfe ein unatürliche Farbe haben. Zum Beispiel türkis.
So jetzt lässt man mit einem Script den Destop absuchen, kommt diese Farbe zielt er auf die Koordinate (also dass der kopf dann in der mitte ist) und schießt. ( headshot xD).
So mit Autoit lässt sich das ja ungefähr so verwirklichen:
Code:
; pixel search bot example
; include the misc UDF library
; UDF = user defined Function
#include <Misc.au3>
;----- set the hotkeys ------;
HotKeySet("{f3}", "chosecolor")
; set the escape button to
; the exit function
HotKeySet("{esc}", "_exit")
HotKeySet("{f5}", "start")
HotKeySet("{f6}", "stop")
; declare the variable color to be
; used globaly
Global $color
; declare ON globaly and set it
; to false(off)
Global $ON = False
While 1
Sleep(15); dont fuck the CPU
; if the on is set to true
If $ON = True Then
; this is the pixel search function
; the last parameter (40) is the
; shade variation
; the other parameters are the
; pixel search area
; change them so they fits your needs :)
$coord = PixelSearch(0, 0, @DesktopWidth, @DesktopHeight, $color, 80)
; if the return of coord is an array
; which means a pixel was found
If IsArray($coord) = 1 Then
; left click on the pixel
MouseMove($coord[0],$coord[1])
MouseClick("left",$coord[0],$coord[1])
EndIf
EndIf
WEnd
; chose color function
Func chosecolor()
; this will display a color chose window
; the chosen color will be stored in the
; variable $color
$color = _ChooseColor(2, 0x00FFFF, 2, "")
MsgBox(0,'',$color)
EndFunc ;==>chosecolor
; func extit
Func _exit()
; simply exits the script
Exit
EndFunc ;==>_exit
;start func
Func start()
; set the variable to true
$ON = True
EndFunc ;==>start
;start func
Func stop()
; set the variable false
$ON = False
EndFunc ;==>stop
Allerdings funktioniert das im Spiel nicht... Aber auf dem Destop nicht. Was ist daran falsch? Bzw. wie würdet ihr das mit C++ machen?
Ich habe das jetzt einfach hier rein gepostet, da es kein autoit forum gibt.
könnt ihr mir helfen?
gruß