Jump to content
Sign in to follow this  
NizonRox

Bug/error Or just misscoded

Recommended Posts

NizonRox

I made the code Look for the words Shiny, Dark, Mysitc and Ancient... And if it was found then it would stop script and bring up a msg box. But that error accurs

   MouseClick ( "LEFT", 1017, 176, 1, 1)
   Sleep(500)
   Local $shiny = WinGetText("[ACTIVE]", "Shiny")
   if $shiny > "Shiny" Then Exit MsgBox ( 0, "Shiny Pokemon Found!", "You Have found a Shiny Pokemon")
   Local $dark = WinGetText("[ACTIVE]", "Dark")
   if $dark > "Dark" Then Exit MsgBox ( 0, "Dark Pokemon Found!", "You Have found a Dark Pokemon")
   Local $mystic  = WinGetText("[ACTIVE]", "Mystic")
   If $mystic > "Mystic" Then Exit MsgBox ( 0, "Mystic Pokemon Found!", "You Have found a Mystic Pokemon")
   Local $ancient  = WinGetText("[ACTIVE]", "Ancient")
   If $ancient > "Ancient" Then Exit MsgBox ( 0, "Ancient Pokemon Found!", "You Have found a Ancient Pokemon")

Error :Variable Used Without Being delared.

Edited by NizonRox

Share this post


Link to post
Share on other sites
corgano

If it's for or about gaming, it is (sadly :( )against the rules to discuss

But as a tip, in SciTE -> tools there is autoit window info. It will show you info about windows / controls, and will also show you what text autoit can see with the WinGetText function (in the visible text tab). The page you're looking at in the chrome window aren't simple controls like labels and inputs, but a lot of complicated stuff rendered from the HTML by the browser, and is hard to get at.

This is why the _IE functions were made. _IEBodyReadHTML() will get you the html of the page, and you can use stringregexp() to find patterns in it. Consult the help file! The examples are awesome and will help you a lot

Edited by corgano

0x616e2069646561206973206c696b652061206d616e20776974686f7574206120626f64792c20746f206669676874206f6e6520697320746f206e657665722077696e2e2e2e2e

Share this post


Link to post
Share on other sites
NizonRox

So, how do i make it look for thouse 4 words?

Edited by NizonRox

Share this post


Link to post
Share on other sites
kaotkbliss

sigh, nearly every line in that code is wrong, especially the one about rule #1 bullet point 4. Best go read it.


010101000110100001101001011100110010000001101001011100110010000

001101101011110010010000001110011011010010110011100100001

My Android cat and mouse game
https://play.google.com/store/apps/details?id=com.KaosVisions.WhiskersNSqueek

We're gonna need another Timmy!

Share this post


Link to post
Share on other sites
NizonRox

sigh, nearly every line in that code is wrong, especially the one about rule #1 bullet point 4. Best go read it.

I dont understand, but if you can get me a link to this rule then id like to read it :)

Share this post


Link to post
Share on other sites
Melba23

NizonRox,

Welcome to the AutoIt forum. :)

The Forum rules are here - there is also a link at bottom right of each page. Please read them now - 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:

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  

×