Schnabulation Posted December 16, 2014 Posted December 16, 2014 (edited) Hello all I am new here and signed up to ask this question. The internet and this forum has already been searched by me to this time but sadly it did not solve my problem. I wrote a hotkey script that writes a rather long text with the push of a button. The script is working as intended on every application except the one that I need it to. Which is the game: MechWarrior Online I am fairly aware that game automation is not supported within this forum so I want to say this is not about automation (see my code below). What I have come to so far: - The script works in every application but MechWarrior Online. MechWarrior Online is a fullscreen application. So when the game is running and I hit the hotkey it just does not do anything. - I compiled the script to an .exe and run it with admin privileges. Did not change anything. - I added #RequireAdmin which did not change anything. - I exchanged "send" with "ControlSend" and the window title which solved the problem partly: The hotkey still does not work when the game has focus. When I alt-tab out of the game (still running in the background but no focus) and hit the hotkey the text is written into MechWarrior Online perfectly. But I always have to alt-tab out of the game to use the hotkey which is not bearable. So I would be really glad if you guys can point out what the problem is. Please see the code below: #RequireAdmin HotKeySet("{F1}","f1") While 1 Sleep(50) WEnd Func f1() Sleep(50) ControlSend("MechWarrior Online","","","Hello teammates, bla bla bla...") FuncEnd Thank you very much and have a nice day! Steve Edited December 16, 2014 by Schnabulation
Moderators Melba23 Posted December 16, 2014 Moderators Posted December 16, 2014 Schnabulation,Welcome to the AutoIt forum. I am fairly aware that game automation is not supported within this forumBut not aware enough it seems. > hit the hotkey the text is written into MechWarrior OnlineThat still falls under the prohibition of: Launching, automation or script interaction with games or game servers, regardless of the gameSo this thread will now be locked. M23 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
Recommended Posts