Dear AHK members,
i hope someone to help me to get a script for the whiteboard in yoville, i found some sites have a free simples, but it's limited on the pix at this site, and it's hard to make my own pix, and i found it easy to be done with AHK, plz if anyone can help me i'll be so happy for that, also for Yoville players i can give 20k in return for it but i need it an open resource cause im actualy trying to learn AHK
Regards,
[Moderator's note: Moved topic from Wish List to Ask for Help.]
Yoville WhiteBoard Drawing Script
Started by
egstar
, Jul 03 2010 09:58 PM
1 reply to this topic
#1
-
Posted 03 July 2010 - 09:58 PM
After some search i got the script for the drawing, and i used it with a ready drawing code it's working gr8!!
now im just in need to fix a scan script to allow me to scan pix
hope u can help me ppl
sry for annoying u
but i hope i get a good result ;(
thats the scan script which i collect most of it from alot of topics, but i put info about each part, to tell me if it's right or wrong, as im a newbie
btw, it's worked with the flag of germany, at the AHK languages bar, but when i used my own image it's gave no results in all colors text,
Issues :
- Scanning The Flag Of the AHK Languages bar, but not Scanning any thing else.
- it's takes about 40minute for scanning that size i put in the code
- it's generat a mouse clicks, but im in need for mouse drags,
To-Do :
- Make the script allows me to scan all pix idunno if i have to get the BGR colors of each image i use ? or there's must be some thing makes it fixed in scanning,
- Wanna make the output code in 1 txt file not 8 files, as it's gonna be so bad art if it drew each color alone
- It's output must be " Mouse Click Drag " not a " Mouse click "so, i can be allowed to draw on boards
Example:
hope someone helping ^^
Regards [/code]
now im just in need to fix a scan script to allow me to scan pix
hope u can help me ppl
sry for annoying u
but i hope i get a good result ;(
CoordMode, ToolTip, screen CoordMode, Mouse, screen CoordMode, Pixel, screen pz:=0 ; simple variable to allow pausing the script, see hotkey at end of listing settitlematchmode 2 Iwidth:=221 Iheight=140 ;============== The color Codes in BGR format ====== black=0x000000 blue=0xFF0000 yellow=0x00FFFF green=0x00FF00 magenta=0xFF00FF red=0x0000FF brown=0x00AFFF white=0xFFFFFF msgbox, , , Starting Scannin, `n press OK to continue `n(You can press ALT-CTRL-P to pause script) ;============== GUI Picture Viewer ================= image=1.png Gui, -Caption ; this hides the typical frame of gui window gui, margin, 0, 0 ; this hides the typical margin between picture control and gui window gui, add, picture, ,%image% ypos:=a_screenheight/4 ; arbitrary location, just _not behind_ the MsgBox gui, show,y%ypos%, %image% ;============== Image Scanning Position as the GUI Viewer Appears OutputVarX:= 529 OutputVarY:= 200 ;== i think i used the OutPut vars of the GUI viewer so no need for image === ;======== so next is disabled ; ImageSearch, OutputVarX, OutputVarY, 0, 0, A_ScreenWidth, A_ScreenHeight, %image% OutputVarX-- OutputVarY-- ;======== the Starting Point After How Many Columns ============= demo_column:=1 ;============ Starting Text at The Output Colors Lists ========== black_list=Black_List `n red_list=Red_List `n yellow_list=Yellow_List `n green_list=Green_List `n magenta_list=Magenta_List `n brown_list=Brown_List `n blue_list=Blue_List `n white_list=White_List `n ;================= only 'pixel_list' is currently used pixel_list:=" X Y Color `n" loop, %iwidth% { x:=a_index x:=x+demo_column loop, %Iheight% { y:=a_index xx:=OutputVarX+x yy:=OutputVarY+y pixelgetcolor, color, xx,yy mousemove, xx, yy if (pz=1) { msgbox Paused by user, press OK to continue pz:=0 } sleep, 1 pixel_list:= pixel_list . xx . " ". yy . " ". color . "`n" if(color= red) { red_list:= red_list . "MouseClick, L, " . xx . ", ". yy . " ". ";". color . "`n" } if(color= black) { black_list:= black_list . "MouseClick, L, " . xx . ", ". yy . " ". ";". color . "`n" } if(color= yellow) { yellow_list:= yellow_list . "MouseClick, L, " . xx . ", ". yy . " ". ";". color . "`n" } if(color= green) { green_list:= green_list . "MouseClick, L, " . xx . ", ". yy . " ". ";". color . "`n" } if(color= brown) { brown_list:= brown_list . "MouseClick, L, " . xx . ", ". yy . " ". ";". color . "`n" } if(color= magenta) { magenta_list:= magenta_list . "MouseClick, L, " . xx . ", ". yy . " ". ";". color . "`n" } if(color= blue) { blue_list:= blue_list . "MouseClick, L, " . xx . ", ". yy . " ". ";". color . "`n" } if(color= white) { blue_list:= white_list . "MouseClick, L, " . xx . ", ". yy . " ". ";". color . "`n" } } pixel_list:= pixel_list . "end of column " . x . "`n" } msgbox Scan Proccess Complete, Press OK to Quit. ;=============== FileAppend, use the working directory ============================ FileAppend, %black_list% , C:\Documents and Settings\XPPRESP3\Desktop\pix\results\black.txt FileAppend, %red_list% , C:\Documents and Settings\XPPRESP3\Desktop\pix\results\red.txt FileAppend, %yellow_list%, C:\Documents and Settings\XPPRESP3\Desktop\pix\results\yellow.txt FileAppend, %green_list%, C:\Documents and Settings\XPPRESP3\Desktop\pix\results\green.txt FileAppend, %blue_list%, C:\Documents and Settings\XPPRESP3\Desktop\pix\results\blue.txt FileAppend, %brown_list%, C:\Documents and Settings\XPPRESP3\Desktop\pix\results\brown.txt FileAppend, %magenta_list%, C:\Documents and Settings\XPPRESP3\Desktop\pix\results\magenta.txt FileAppend, %white_list%, C:\Documents and Settings\XPPRESP3\Desktop\pix\results\white.txt exitapp ; simple variable to allow pausing the script !^p:: pz:=1 return
thats the scan script which i collect most of it from alot of topics, but i put info about each part, to tell me if it's right or wrong, as im a newbie
btw, it's worked with the flag of germany, at the AHK languages bar, but when i used my own image it's gave no results in all colors text,
Issues :
- Scanning The Flag Of the AHK Languages bar, but not Scanning any thing else.
- it's takes about 40minute for scanning that size i put in the code
- it's generat a mouse clicks, but im in need for mouse drags,
To-Do :
- Make the script allows me to scan all pix idunno if i have to get the BGR colors of each image i use ? or there's must be some thing makes it fixed in scanning,
- Wanna make the output code in 1 txt file not 8 files, as it's gonna be so bad art if it drew each color alone
- It's output must be " Mouse Click Drag " not a " Mouse click "so, i can be allowed to draw on boards
Example:
MouseClick, L, 13+%OutputVarX%, 168+%OuputVarY% MouseClickDrag, L, 0+OutputVarX, 0+OutputVarY, 0+OutputVarX, 123+OutputVarY ;0x000000
hope someone helping ^^
Regards [/code]
#2
-
Posted 06 July 2010 - 09:44 PM