Jump to content

Recommended Posts

Posted (edited)

EDIT: God I'm an idiot. Still got the problem, but _IsPressed doesn't seem to work. Oh well the principle is the same :D

Hi all,

So I'm having a slight problem with the MouseUp function. Here's the example code I'm working with:

#include <Misc.au3>

HotKeySet("{ESC}","quit")

while(1)

$input1=_IsPressed(11)

if $input1=1 then

mousedown("right")

elseif $input1=0 then

mouseup("right")

EndIf

WEnd

func quit()

Exit

EndFunc

(Forgot the html code to put it in special tags:()

I'd be careful running that though; for me it constantly right clicks regardless of whether 'W' is pressed or not. Had the same problem using any input by the way, just put that in for ease of use.

I want it to work like the Send() function when you hold down a key, i.e, while this button is being held down, hold down the mouse button, then release...you get the idea.

(I know this looks pointless at the mo, but I'm trying to convert pulling the trigger on a game controller to holding down the right mouse button. NOT GAME AUTOMATION :D just using a controller with a game that doesn't support one)

Thanks for reading

-CptSpike

Edited by CptSpike
  • Moderators
Posted

CptSpike,

pulling the trigger on a game controller to holding down the right mouse button. [...] just using a controller with a game that doesn't support one

NOT GAME AUTOMATION

You might not be "automating" the game, but by your own admission you are certainly "interacting" with one. Please read the Forum Rules carefully before you post again. Thread locked. :naughty:

M23

Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png 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 columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...