Jump to content
Sign in to follow this  
cash

[Help]How to join this 7 script

Recommended Posts

cash

hi all,

i just learn how to use autoit

so i made scripts for facebook flashgame using imagesearch and pixelsearch

i dont know hot to put only in 1 file

this is example of few script

Script 1

#include <ImageSearch.au3>
 
HotKeySet("+1", "Start")
HotKeySet("!1", "_Exit")
 
$X = 0
$Y = 0
 
While 1
   Sleep(4000)
WEnd
 
Func Start()
   Sleep(4000)
   While 1
 $Search = _ImageSearch('cast.png', 0, $X, $Y, 0)
If $Search = 1 Then
MouseMove($X, $Y, 10)
Sleep(4000)
MouseClick("Left")
MouseMove(10, 200, 1)
Sleep(4000)
EndIf
   WEnd
   Sleep(4000)
EndFunc
Sleep(4000)
 
Func _Exit()
   Exit
EndFunc
 

 
Script 2

#include <ImageSearch.au3>
 
HotKeySet("+2", "Start")
HotKeySet("!2", "_Exit")
 
$X1 = 0
$Y1 = 0
 
While 1
   Sleep(3000)
WEnd
 
Func Start()
   While 1
 $Search1 = _ImageSearch('strike.png', 0, $X1, $Y1, 0)
If $Search1 = 1 Then
MouseMove($X1, $Y1, 10)
MouseClick("Left")
MouseMove(10, 200, 10)
EndIf
   WEnd
EndFunc
 
Func _Exit()
   Exit
EndFunc
 

 
Script 3

#include <ImageSearch.au3>
 
HotKeySet("+6", "Start")
HotKeySet("!6", "_Exit")
 
While 1
   Sleep(100)
WEnd
 
Func Start()
   Sleep(100)
   While 1
 $Search5 = PixelSearch(0, 0, 1440, 900, 0x3A9B28)
If IsArray($Search5) = True Then
MouseMove($Search5[0], $Search5[1], 10)
Sleep(100)
MouseClick("Left")
MouseMove(10, 200, 10)
Sleep(100)
EndIf
   WEnd
   Sleep(100)
EndFunc
Sleep(100)
 
Func _Exit()
   Exit
EndFunc

 

so how to join them in 1 script

when i run all 7 script at flash game it got lag because use big memory

thx alot

Share this post


Link to post
Share on other sites
TheSaint

Welcome to the forum cash.

You need to read the rules, especially about Game Automation, which is not allowed in any variation what-so-ever.

Hope to see you around with questions unrelated to this.

This topic has been reported and will no doubt be locked by a MOD shortly.

Cheers.  :)


AutoIt.4.Life Clubrooms - Life is like a Donut (secret key)

Make sure brain is in gear before opening mouth!
Remember, what is not said, can be just as important as what is said.

Spoiler

What is the Secret Key? Life is like a Donut

If I put effort into communication, I expect you to read properly & fully, or just not comment.
Ignoring those who try to divert conversation with irrelevancies.
If I'm intent on insulting you or being rude, I will be obvious, not ambiguous about it.
I'm only big and bad, to those who have an over-active imagination.

I may have the Artistic Liesense ;) to disagree with you. TheSaint's Toolbox (be advised many downloads are not working due to ISP screwup with my storage)

userbar.png

Share this post


Link to post
Share on other sites
Melba23

cash,

Welcome to the AutoIt forum. :)

Unfortunately you appear to have missed the Forum rules on your way in. Please read them now (there is also a link at bottom right of each page) - 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. :naughty:

See you soon with a legitimate question I hope. :)

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

 

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×