I'm doing a reformatting of
More specifically, I noticed that pretty much everything in this function assumes that you actually were in the corresponding choice adventure when you sent the request.
(for example, it assumes that you were in choice adventure 1000 if it sees the URL
Heck, it doesn't even check if you actually supplied your password hash, only looking at the fact that KoL returned the code 200 ("OK") (which it will always do if you were NOT in a choice adventure to begin with)
So, there's definitely "an issue" with
Again, what I am doing is a REFORMATTING of this file. This means that if you see this post and come up with a solution to this problem, discuss it here instead of taking any initiative, to make sure your work is not wasted by what I'll have done on my side.
ChoiceManager.java
, and while doing so, noticed the preChoice()
function.More specifically, I noticed that pretty much everything in this function assumes that you actually were in the corresponding choice adventure when you sent the request.
(for example, it assumes that you were in choice adventure 1000 if it sees the URL
choice.php?whichchoice=1000&option=1
)Heck, it doesn't even check if you actually supplied your password hash, only looking at the fact that KoL returned the code 200 ("OK") (which it will always do if you were NOT in a choice adventure to begin with)
responseText
is also not being looked at at all at this point.So, there's definitely "an issue" with
preChoice()
. My question here is where to go to solve this issue.- Is anything in
preChoice()
really necessary, this early? Would it be possible to move all of this topostChoice0( String, GenericRequest )
instead, or do those really all need to be done before the registering of the adventure by AdventureRequest? - If the latter, should the code in this section start looking at
responseText
? - If not possible, should handling be done to make sure you're actually in a choice adventure, before this function?
Again, what I am doing is a REFORMATTING of this file. This means that if you see this post and come up with a solution to this problem, discuss it here instead of taking any initiative, to make sure your work is not wasted by what I'll have done on my side.