Federalist Posted December 12, 2007 Author Posted December 12, 2007 _IELinkClickByText($oIE, "Enter Combat Arena")DaleHm.My code is exactly the same except for _IELinkClickByText($oIE, "Enter Combat Arena",0,0)Were the zeroes causing the issue?I'll test it when I get home.
Federalist Posted December 12, 2007 Author Posted December 12, 2007 Hm.My code is exactly the same except for _IELinkClickByText($oIE, "Enter Combat Arena",0,0)Were the zeroes causing the issue?I'll test it when I get home.Nope, that didn't work.Any other suggestions?It still just hangs after entering, even with _IELinkClickByText($oIE, "Enter Combat Arena")
DaleHohm Posted December 13, 2007 Posted December 13, 2007 I don't recall you saying anything about a hang, but this has plodded along for a while. Use the SciTe debug mode (see my sig) to see what it is doing and post the SciTe output. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
Federalist Posted December 13, 2007 Author Posted December 13, 2007 (edited) Edit. It just stops there, and never progresses. _IELoadWait isn't the problem - it does the same thing with or without it. Edited December 19, 2007 by Federalist
Nevin Posted December 13, 2007 Posted December 13, 2007 For those who don't feel like looking back a page, the next line should be "_IELinkClickByText($oIE,"Enter Combat Arena",0,0)" after that, I think..
Federalist Posted December 13, 2007 Author Posted December 13, 2007 For those who don't feel like looking back a page, the next line should be "_IELinkClickByText($oIE,"Enter Combat Arena",0,0)" after that, I think..Actually, on Drew's advice I changed it to "_IELinkClickByText($oIE,"Enter Combat Arena")"I see no reason for the script just to ... stop moving. I mean, it doesn't even generate any errors, it just stops.
DaleHohm Posted December 13, 2007 Posted December 13, 2007 I see no reason for it to hang there (without the _IELoadWait) upless there is a popup appearing or the showArena(); Javascript function is executing and not returning control to the sctipt. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
Federalist Posted December 13, 2007 Author Posted December 13, 2007 I see no reason for it to hang there (without the _IELoadWait) upless there is a popup appearing or the showArena(); Javascript function is executing and not returning control to the sctipt.DaleNo popups appear - what could cause the showArena to not execute?
DaleHohm Posted December 13, 2007 Posted December 13, 2007 No popups appear - what could cause the showArena to not execute?Not executing wouldn't be the problem - executing and not exiting could. DebugBar will show you the source of the script. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
Federalist Posted December 13, 2007 Author Posted December 13, 2007 (edited) Not executing wouldn't be the problem - executing and not exiting could. DebugBar will show you the source of the script. DaleEDIT If I select the javascript command and click "Run Javascript" , it does bring me to the correct page. Edited December 19, 2007 by Federalist
DaleHohm Posted December 13, 2007 Posted December 13, 2007 Then you can try $oIE.document.parentwindow.eval('showArena();return false;') I admire you tenacity, but I've got to tell you -- I just don't get excited about automating games - especially when they have safeguards that are trying to foil your attempts to do so. If anyone else wants to jump in to assist here, please do. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
Federalist Posted December 13, 2007 Author Posted December 13, 2007 (edited) Then you can try$oIE.document.parentwindow.eval('showArena();return false;')I admire you tenacity, but I've got to tell you -- I just don't get excited about automating games - especially when they have safeguards that are trying to foil your attempts to do so. If anyone else wants to jump in to assist here, please do.DaleSo... like this? _IELinkClickByText($oIE.document.parentwindow.eval('showArena();return false;'), "Enter Combat Arena")Hm, that can't be it..I get an error wwhen running it...Error: Error parsing function call.(For that line.) Edited December 13, 2007 by Federalist
DaleHohm Posted December 13, 2007 Posted December 13, 2007 no, just $oIE.document.parentwindow.eval('showArena();return false;') all by itself. Dale Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
Federalist Posted December 13, 2007 Author Posted December 13, 2007 no, just$oIE.document.parentwindow.eval('showArena();return false;')all by itself.DaleError: The requested action with this object has failed.Hmm. :/I put it right before the line where it was failing.
Federalist Posted December 13, 2007 Author Posted December 13, 2007 When running it in scITE 0030: 0-0: $oIE.document.parentwindow.Eval("showArena();return false;") C:\Documents and Settings\Avery\My Documents\test_DebugIt.au3 (97) : ==> The requested action with this object has failed.: $oIE.document.parentwindow.Eval('showArena();return false;') $oIE.document.parentwindow.Eval('showArena();return false;')^ ERROR
DaleHohm Posted December 13, 2007 Posted December 13, 2007 Try removing the return false; Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model Automate input type=file (Related) Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded Better Better? IE.au3 issues with Vista - Workarounds SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead? Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble
Federalist Posted December 13, 2007 Author Posted December 13, 2007 Try removing the return false;Same error.
Federalist Posted December 13, 2007 Author Posted December 13, 2007 Same error.Anyone else have any ideas? :/
someone Posted December 13, 2007 Posted December 13, 2007 (edited) Hey Federalist... your just trying to click on a character, then click on "Enter Combat Arena" correct? This script works for me... #AutoIt3Wrapper_run_debug_mode=Y #include <IE.au3> Sleep(2000) $charactername = "Someone27" $oIE = _IEAttach("d2jsp") ;While 1 _IELinkClickByText($oIE,$charactername,0,0) _IELoadWait($oIE, 100, 2000) _IELinkClickByText($oIE,"Enter Combat Arena",0,0) ;WEnd Note that the 2 second sleep was just so I could 'see' the page being clicked... also I get a timeout from _IELoadWait, but it does work.... or am I missing something your trying to achieve? Edited December 19, 2007 by someone While ProcessExists('Andrews bad day.exe') BlockInput(1) SoundPlay('Music.wav') SoundSetWaveVolume('Louder') WEnd
Federalist Posted December 13, 2007 Author Posted December 13, 2007 (edited) EDITThat's exactly what I'm trying to do. Let's see if it works.. That worked! I love you. However, it won't go and fight another monster.. edit. Oh, and the random sleeps are to make it take on a semi-'human' appearance. (Rather than that of automation.) Edited December 19, 2007 by Federalist
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now