Nong 0 Posted January 13, 2022 Share Posted January 13, 2022 this is my first post, so before we going any further I need to let you that I'm a beginner to creating a script so that I might not be able to understand straight away so please take time with me and you will need to example me in more detail if you can please, so now let me introduce you to what I'm trying to do here is that I'm try to do the auto pressing key in different colour but I don't know to to make it read correctly and do I do any wrong or I could do a different way please let me know in this pic you can tell that there are different colour on the W Func w() ; White if PixelGetColor(905, 119) = 0xECEDF0 then ;Top middle sleep(10) if PixelGetColor(896, 119) = 0xECEDF0 then ;Top left sleep(10) if PixelGetColor(910, 132) = 0xECEDF0 then ;Down right sleep(10) if PixelGetColor(900, 131) = 0xECEDF0 then ;Down left sleep(10) send("{w down}") sleep(100) send("{w up}") Func w() ; Green if PixelGetColor(905, 119) = 0x008000 then ; Top middle sleep(10) if PixelGetColor(896, 119) = 0x008000 then ; Top left sleep(10) if PixelGetColor(910, 132) = 0x008000 then ; Down right sleep(10) if PixelGetColor(900, 131) = 0x008000 then ; Down left sleep(10) send("{w down}") sleep(100) send("{w up}") I has use this to selected the key in different colour but it still doesn't pick up the colour or the key and do nothing thanks a lot sorry for my bad writing Link to post Share on other sites
spudw2k 276 Posted January 14, 2022 Share Posted January 14, 2022 Hello @Nong. Welcome to the forum. Unfortunately, it looks like what you are trying to script is for a game. Game automation discussion and support is not allowed on the forum and this post will likely be locked; sorry. Please refer to the forum rules. Also, take note of rule #7 (not making a new topic/post by rewording a locked topic). Spoiler Things I've Made: Always On Top Tool ◊ AU History ◊ Deck of Cards ◊ HideIt ◊ ICU ◊ Icon Freezer ◊ Ipod Ejector ◊ Link Downloader ◊ MD5 Folder Enumerator ◊ PassGen ◊ Ping Tool ◊ Quick NIC ◊ Read OCR ◊ RemoteIT ◊ SchTasksGui ◊ SpyCam ◊ System Scan Report Tool ◊ System UpTime ◊ Transparency Machine ◊ VMWare ESX BuilderMisc Code Snippets: ADODB Example ◊ CheckHover ◊ Detect SafeMode ◊ DynEnumArray ◊ GetNetStatData ◊ HashArray ◊ IsBetweenDates ◊ Local Admins ◊ Make Choice ◊ Recursive File List ◊ Remove Sizebox Style ◊ Retrieve PNPDeviceID ◊ Retreive SysListView32 Contents ◊ Set IE Homepage ◊ Tickle Expired Password ◊ Transpose ArrayProjects: Drive Space Usage GUI ◊ LEDkIT ◊ Plasma_kIt ◊ Scan Engine Builder ◊ SpeeDBurner ◊ SubnetCalcCool Stuff: AutoItObject UDF ◊ Extract Icon From Proc ◊ GuiCtrlFontRotate ◊ Hex Edit Funcs ◊ Run binary ◊ Service_UDF Link to post Share on other sites
Moderators Melba23 3,799 Posted January 14, 2022 Moderators Share Posted January 14, 2022 Welcome to the AutoIt forum. Unfortunately you appear to have missed the Forum rules on your way in. Please read them now - particularly the bit about not discussing game automation - and then you will understand why you will get no help and this thread will now be locked. See you soon with a legitimate question I hope. The Moderation team Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area Link to post Share on other sites
Recommended Posts