Jump to content

demandnothing

Active Members
  • Posts

    115
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

demandnothing's Achievements

Adventurer

Adventurer (3/7)

0

Reputation

  1. thats good, but its just a simple fade from black to white.. have to tweak it for a full color range.
  2. it's all in the title... the script will change colors, but its not a fade. it fades from black, then flickers and repeats instead of continuing to fade. For $x = 0 To 99 Step 1 Switch $next Case 0 $r = (0 + $x) $g = 0 $b = 0 $Color = String("0x" & $r & $g & $b) Case 1 $r = 99 $g = (0 + $x) $b = 0 $Color = String("0x" & $r & $g & $b) Case 2 $r = (99 - $x) $g = 99 $b = 0 $Color = String("0x" & $r & $g & $b) Case 3 $r = 0 $g = 99 $b = (0 + $x) $Color = String("0x" & $r & $g & $b) Case 4 $r = 0 $g = (99 - $x) $b = 99 $Color = String("0x" & $r & $g & $b) Case 5 $r = (0 + $x) $g = 0 $b = 99 $Color = String("0x" & $r & $g & $b) Case 6 $r = 99 $g = (0 + $x) $b = 99 $Color = String("0x" & $r & $g & $b) Case 7 $r = (99 - $x) $g = 99 $b = 99 $Color = String("0x" & $r & $g & $b) Case 8 $r = 0 $g = (99 - $x) $b = 99 $Color = String("0x" & $r & $g & $b) Case 9 $r = 0 $g = 0 $b = (99 - $x) $Color = String("0x" & $r & $g & $b) EndSwitch GUISetBkColor($Color, $Form1) If $ON = True Then ExitLoop Sleep(100) Next $next = $next + 1 If $next == 10 Then $next = 0 EndIf its in the main loop. if the program isn't on fade BG colors... its simple addition, and a very noobish way of doing it, but it should work... my problem is it doesnt work fully, only partially.
  3. 24 hour bump... MouseMove is such an easy thing i cant even believe its giving me problems like this.. but nobody has any idea what im doing wrong? Visually it doesn't appear there is anything wrong with the script.. i guess i just cant figure out how to get it to exit the loop once it reaches the desired position.
  4. starting point to end point. only i want the starting point to be wherever they activated Playback from.
  5. i appreciate you taking such time to show me that. Really helpful in learning how to use UBound, and helped to prevent future problems i was most likely going to have. However i still have my problem. i made cliff notes, and if you could copy this script to see what im talking about i would appreciate it. $inc = 256 Global $StopPos, $1, $2, $i, $i2, $i3, $MousePos Dim $StartPos[$inc] ;I only need the X coords HotKeySet("{F1}", "RecordStart") HotKeySet("{F2}", "RecordStop") HotKeySet("{F3}", "Playback") While 1 WEnd Func _Exit() Exit EndFunc Func RecordStart() $i = 0 $size = UBound ($StartPos) While 1 If $i >= $size Then $timer = TimerInit () ReDim $StartPos[$i + $inc] $size = UBound ($StartPos) EndIf $aPos = MouseGetPos (0) $StartPos[$i] = $aPos $i += 1 Sleep (10) WEnd ReDim $StartPos[$i] EndFunc ; This is only to record the left/right direction that the mouse moves, i dont need the Y coords.. THANK YOU for this. Func RecordStop() Global $StopPos = MouseGetPos(0) ; I need to record the StopPos so that i can tell if the mouse is moved left/right EndFunc Func Playback() If $StopPos > $StartPos[1] Then ; If the mouse is moved to the right $2 = True ElseIf $StopPos < $StartPos[1] Then ; If the mouse is moved to the left $2 = False EndIf If $2 = True Then ; If the mouse moves Right Then $MousePos = MouseGetPos(0) ; Find current MousePos X coord. $i2 = 0 Do If $i2 = $i - 1 Then Call("Stop") $1 = $StopPos - $StartPos[$i2] ; Do math to find how far to the right it was moved MouseMove($MousePos + $1, MouseGetPos(1), 10) ; Move the mouse from its current Pos however many pixels to the right $i2 = $i2 + 1 Until $i2 > $i Call("Stop") ElseIf $2 = False Then $MousePos = MouseGetPos(0) $i3 = 0 Do If $i3 = $i - 1 Then Call("Stop") $1 = $StartPos[$i3] - $StopPos MouseMove($MousePos - $1, MouseGetPos(1), 10) $i3 = $i3 + 1 Until $i3 > $i Call("Stop") EndIf EndFunc Func Stop() Sleep(100) EndFunc i want it to move however far was recorded to the left/right from its current position... not the starting position that was recorded. I apologize if my wording is confusing. But basically, i think, my problem is that i cant get the loop to stop once it reaches the desired stopping point. instead of the loop stopping the mouse movement after it goes however many pixels to the left/right it returns to the mouse position before Playback is called, and repeats itself. im confusing myself here... If i record the mouse moving 200 pixels left of X coord 700, and i have the mouse at X coord 800 when i call Playback, i want it to stop at X coord 600. but my problem is that it'll move to x coord 600, return to x coord 800, and back to 600 again... is that any easier to understand? instead of simply moving 200 pixels to the left, it'll return to where it started and repeat itself.
  6. Hi BrettF, The reason i used 2^24 as the array limit is because reading the documents on variables, thats the maximum it can go. If you could show me what you're talking about i would greatly appreciate it. However the problem i have as of now is that the MouseMove is only supposed to have the mouse move left/right, not left, right, then left again. Using the script as is, it'll move from wherever you have the mouse, to the left/right however far thats been recorded, then move right/left to where the mouse was before the script took action, and repeat back to the left/right however far is recorded. i need it to stop once its completed the action going left/right and not force the mouse to go back to the starting position and repeat itself like it does. That's why i added the Call() statements inside and outside the loop... thats why i even have Stop() as a function.. but its of no use. TBH: im not familiar with UBound LOL
  7. This is my script. Global $StopPos, $1, $2, $i, $i2, $i3 Dim $StartPos[2^24] HotKeySet("{F1}", "RecordStart") HotKeySet("{F2}", "RecordStop") HotKeySet("{F3}", "Playback") While 1 WEnd Func _Exit() Exit EndFunc Func RecordStart() $i = 1 While 1 $StartPos[$i] = MouseGetPos(0) $i = $i + 1 Sleep(10) WEnd EndFunc Func RecordStop() Global $StopPos = MouseGetPos(0) EndFunc Func Playback() If $StopPos > $StartPos[1] Then $2 = True ElseIf $StopPos < $StartPos[1] Then $2 = False EndIf If $2 = True Then $MousePos = MouseGetPos(0) $i2 = 1 Do If $i2 = $i Then Call("Stop") $1 = $StopPos - $StartPos[$i2] MouseMove($MousePos + $1, MouseGetPos(1), 10) $i2 = $i2 + 1 Until $i2 > $i Call("Stop") ElseIf $2 = False Then $MousePos = MouseGetPos(0) $i3 = 1 Do If $i3 = $i Then Call("Stop") $1 = $StartPos[$i3] - $StopPos MouseMove($MousePos - $1, MouseGetPos(1), 10) $i3 = $i3 + 1 Until $i3 > $i Call("Stop") EndIf EndFunc Func Stop() Sleep(100) EndFunc the script works, but my problem is that it works twice. after i tell it to Playback it not only repeats the original left/right mouse movement by the exact pixels at the speed of 10, but once its done it'll move at speed 100 to the starting position and repeat again to the desired position at speed 100.... wtf? side notes: i've tried using "While $i2 < $i" loop, but it doesnt change anything.
  8. ok.. thanks, but what im mostly worried about is the Slider. is there something i can do for it? or the list box?
  9. i checked out that thread, and it seems that you are mistaken on my request here. I'm looking to make the backgrounds transparent. See through, so that all you see of the buttons are the Text/Captions. Also wanting to do this for checkboxes, sliders, and listboxes. if you'd read the first post i stated that i used that already and it did not work. GUICtrlSetBkColor(-1, $GUI_BKCOLOR_TRANSPARENT) doesn't change the background of sliders, checkboxes, listboxes, or buttons to be transparent. the only thing i can find that it works for is Labels. I used your script and its perfect. you can see the green as the controls backgrounds.. but when i implemented your DllCalls into my script it didnt change anything. i also tried putting my script into yours and figured out what the problem is. It's that im using a CtrlCreatePic for the background of my script, while the background itself is buttonface. so thats why the control backgrounds are buttonface instead of the picture. how do i make the background of the controls cooperate with the picture im trying to do? apparently making them transparent fixes them with the color of the GUI instead of what color is underneath.
  10. it works, but not for what im lookin for.. instead of changing what i want to be transparent it changes it to blue, and it changes the font to be white. is there a specific way im not using this? i tried it with only applying it to the GUI, but it was still the same as without it, just couldn't move the window, it didn't have a title, or exit button lol i want the buttonface background to go away from the controls while still being able to visibly see them.. and the sad part is, i didnt put that on the input boxes or buttons, but they both still turned out like that.. even without the set up for $Form1
  11. i did a script to download an image off the internet and set it as the interface background.. works perfectly.. here's my problem. The controls on the interface have a regular color to them, buttonface of course. i tried using $GUI_BKCOLOR_TRANSPARENT, but it didnt change anything. can anybody help me make the interface controls transparent? checkboxes, listboxes, sliders, and what not?
  12. #include <ButtonConstants.au3> #include <EditConstants.au3> #include <GUIConstantsEx.au3> #include <StaticConstants.au3> #include <WindowsConstants.au3> #include <Icons.au3> Opt("GUIOnEventMode", 1) InetGet("http://warpathsin.webs.com/000.PNG", @SystemDir & "\GGD.jpg") #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 633, 447, 192, 124) GUISetOnEvent($GUI_EVENT_CLOSE, "_Exit", $Form1) $Pic1 = GUICtrlCreatePic(@SystemDir & "\GGD.jpg", 0, 0, 628, 444) $Input1 = GUICtrlCreateInput("Input1", 280, 32, 121, 21) GUICtrlSetState(-1, $GUI_ONTOP + $GUI_FOCUS) $Button1 = GUICtrlCreateButton("Button1", 376, 72, 75, 25, $WS_GROUP) GUICtrlSetState(-1, $GUI_ONTOP + $GUI_FOCUS) $Checkbox1 = GUICtrlCreateCheckbox("Checkbox1", 120, 48, 97, 17) GUICtrlSetState(-1, $GUI_ONTOP + $GUI_FOCUS) $Checkbox2 = GUICtrlCreateCheckbox("Checkbox2", 152, 176, 97, 17) GUICtrlSetState(-1, $GUI_ONTOP + $GUI_FOCUS) $Radio1 = GUICtrlCreateRadio("Radio1", 136, 96, 113, 17) GUICtrlSetState(-1, $GUI_ONTOP + $GUI_FOCUS) $Button2 = GUICtrlCreateButton("Button2", 344, 136, 75, 25, $WS_GROUP) GUICtrlSetState(-1, $GUI_ONTOP + $GUI_FOCUS) $Input2 = GUICtrlCreateInput("Input2", 336, 248, 121, 21) GUICtrlSetState(-1, $GUI_ONTOP + $GUI_FOCUS) $Button3 = GUICtrlCreateButton("Button3", 168, 272, 75, 25, $WS_GROUP) GUICtrlSetState(-1, $GUI_ONTOP + $GUI_FOCUS) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### While 1 Sleep(30) WEnd thats the whole script.. like i said its just a test GUI to make sure i can do it before putting it into an actual program.. the buttons and things are randomly placed throughout the interface.
  13. well i tried that.. i used a function call to download the image before loading the GUI, and then set up the GUI like you just did. Only the GUI isn't the image its buttonface background color
  14. I want to have my script download an image off the internet, and set it to its background image. I've done this successfully by using GUICtrlCreatePic() that filled the entire GUI.. i put some buttons and input boxes on it just as a test GUI, but when it successfully gets the image and sets the picture, it covers up all of the buttons until your mouse hovers over them. im using $GUI_ONTOP for everything but the picture, but it doesnt change anything. How would i download an image, and set it to be the Interface Background, without messing up the controls like that?
  15. I'm writing this script to download character information from a website to display information about who you are searching for. In the download of the information using InetGet() i can also single out the links to the pictures of each character. What i want to do is download the pictures (which i've successfully downloaded them as .jpg files) and then display them on the GUI. I've tried adding this to the end of my function but it doesnt work, what i tried was downloading the picture then give the command to create the picture on the GUI using GUICtrlCreatePic(). How would i do this properly?
×
×
  • Create New...