Page 13 of 46
Re: rock5's "fastLogin Revisited"
Posted: Mon Jan 02, 2012 8:19 pm
by lisa
Germangold wrote:1:21am - scripts\rom\bot.lua:465: onLoad error: D:\e\micromacro\lib\lib.lua:472:
stack overflow
Stack overflow generally means you are reading memory in an infinate loop.
So if that is all of the onload code then I would be looking to see if there is an issue with the function SetCharList or maybe it's usage in thise case?
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 9:11 am
by Alleexx
I need some help now...
I first run Malatinas survival with one of my chars. Then I load a waypoint named "dias" that will go to Cedric to buy dias. After that it returns to Malatina. After all chars have finished the dia script I want to load cot_tele but I don't understand how to do that.
Right now it looks like this:
Code: Select all
<?xml version="1.0" encoding="utf-8"?><waypoints>
<onLoad>
<![CDATA[
__WPL:setWaypointIndex(1)
]]>
CharList = {
{account=1,chars={2}},
{account=2,chars={2}},
{account=3,chars={2}},
}
</onLoad>
<!-- # 1 --><waypoint x="4882" z="-1867" y="103"> </waypoint>
<!-- # 2 --><waypoint x="5198" z="-2129" y="103"> </waypoint>
<!-- # 3 --><waypoint x="5278" z="-2118" y="121"> player:target_NPC("Cedric");
sendMacro("ChoiceOption(1);");
player:target_NPC("Cedric");
sendMacro("ChoiceOption(1);");
player:target_NPC("Cedric");
sendMacro("ChoiceOption(1);");
</waypoint>
<!-- # 8 --><waypoint x="4930" z="-1876" y="103"> </waypoint>
<!-- # 9 --><waypoint x="4886" z="-1903" y="109">
SetCharList(CharList)
LoginNextChar()
waitForLoadingScreen ();
loadPaths("cot_tele") </waypoint>
</waypoints>
The userfunction log out before it comes to
loadPaths("cot_tele"). How do I make it load cot_tele when all chars is finished with "dias"?
Also I don't want it to log out when it's finished with cot_tele as I want to stay on the last char in the list.
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 9:40 am
by lisa
In rock's userfunction this part is what happens when you have finished all characters.
line 123
Code: Select all
if nextAcc == nil then
-- Last character
print("Last player finished.")
player:logout()
end
I think it might be an idea for rock to add an argument to the function and if the argument exists then load it as a waypoint file.
line 77
line 123
Code: Select all
if nextAcc == nil then
if _waypoint then
loadPaths(_waypoint);
end
-- Last character
print("Last player finished.")
player:logout()
end
Something like that will probably do the trick.
So in the example of cot_tele you could do this
around line 77
so when all chars are finished cot then it will start the wapoint daily.
Since you are on the last character of the charlist though you might need to have that as the first character of the next charlist.
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 10:50 am
by rock5
lisa wrote:I think it might be an idea for rock to add an argument to the function and if the argument exists then load it as a waypoint file.
I don't like the idea that it looks misleading. It looks like it's going to load a character called "daily".
But it's not a bad idea. It's even an alternative to using my survivalnext script. You could instead use
in survival and in survival you could use something else. Of course it's probably better to do all your scripts with one character at a time to reduce loading screens but it does provide an alternative.
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 10:57 am
by Shogun
Do we have a safety problem here?
Try
Code: Select all
/script msg = CheckSecondaryPass(); DEFAULT_CHAT_FRAME:AddMessage("sec:"..msg);
after login.
Every addon can read that.
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 11:01 am
by lisa
rock5 wrote:I don't like the idea that it looks misleading. It looks like it's going to load a character called "daily".
You know how bad I am with naming things lol
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 11:03 am
by lisa
Shogun wrote:Do we have a safety problem here?
Try
Code: Select all
/script msg = CheckSecondaryPass(); DEFAULT_CHAT_FRAME:AddMessage("sec:"..msg);
after login.
Every addon can read that.
line 522 can be made local and still work fine
Code: Select all
local function CheckSecondaryPass()
and probably should be local.
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 11:09 am
by Shogun
line 522 can be made local and still work fine
That was the first I tried, but does not work. You can not enter with your char.
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 11:18 am
by rock5
Good catch.
I don't think anyone who worked on it was an expert on security.
It was my first idea, too, to make it a local function but it looks like it's interfering with changing character.
If anybody has any ideas let us know.
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 11:26 am
by rock5
This seems to work, if anyone would like to confirm it.
Move the whole CheckSecondaryPass() function to the top of the "LoginDialog_Show" function. Inside the function and make sure it's local. So...
Code: Select all
function LoginDialog_Show(which, text, data)
local function CheckSecondaryPass()
for i = 1, 18 do
if CustomSecondaryPass["Account"..i].ID == LogID then return CustomSecondaryPass["Account"..i].SecondaryPassword end
end
return
end
etc...
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 11:47 am
by Shogun
OK, good work rock!
Re: rock5's "fastLogin Revisited"
Posted: Wed Jan 04, 2012 11:49 am
by lisa
works for me and doesn't print password in game anymore.
Re: rock5's "fastLogin Revisited"
Posted: Thu Jan 05, 2012 7:13 am
by Alleexx
rock5 wrote:Of course it's probably better to do all your scripts with one character at a time to reduce loading screens but it does provide an alternative.
But I have to start them all manually if I do them one at a time?
Re: rock5's "fastLogin Revisited"
Posted: Thu Jan 05, 2012 9:16 am
by Alleexx
lisa wrote:
line 77
line 123
Code: Select all
if nextAcc == nil then
if _waypoint then
loadPaths(_waypoint);
end
-- Last character
print("Last player finished.")
player:logout()
end
Something like that will probably do the trick.
So in the example of cot_tele you could do this
around line 77
so when all chars are finished cot then it will start the wapoint daily.
Since you are on the last character of the charlist though you might need to have that as the first character of the next charlist.
Didn't work.
Code: Select all
<?xml version="1.0" encoding="utf-8"?><waypoints>
<onLoad>
<![CDATA[
__WPL:setWaypointIndex(1)
]]>
CharList = {
{account=1,chars={2}},
{account=2,chars={2}},
{account=3,chars={2}},
}
</onLoad>
<!-- # 1 --><waypoint x="4882" z="-1867" y="103"> </waypoint>
<!-- # 2 --><waypoint x="5198" z="-2129" y="103"> </waypoint>
<!-- # 3 --><waypoint x="5278" z="-2118" y="121"> player:target_NPC("Cedric");
sendMacro("ChoiceOption(1);");
player:target_NPC("Cedric");
sendMacro("ChoiceOption(1);");
player:target_NPC("Cedric");
sendMacro("ChoiceOption(1);");
</waypoint>
<!-- # 8 --><waypoint x="4930" z="-1876" y="103"> </waypoint>
<!-- # 9 --><waypoint x="4886" z="-1903" y="109">
SetCharList(CharList)
LoginNextChar("cot_tele")
waitForLoadingScreen (); </waypoint>
</waypoints>
1: Every time it changes char it stops after loadingscreen dissappear and nothing happens.
2: It successfully loaded cot_tele when all was done with dias. The problem is that after it entered malatina it said "Last player finnished.
Auto-Logging out"
before it had even started.
Re: rock5's "fastLogin Revisited"
Posted: Thu Jan 05, 2012 9:31 am
by rock5
Alleexx wrote:But I have to start them all manually if I do them one at a time?
No, by "one at a time" I mean do one character do a string of connected waypoints such as "survivalR5", "Cot_tele", your own daily script perhaps, Ancient Treasure maybe. Then end with Survivalnext which loads the next character and then loads survivalr5 again. It will go through all the characters in your list.
If I implement this idea then it would go through all your characters doing survivalr5. Then when it reaches the last character, it starts with the first character again but with the next file, in this example, cot_tele. This would involve a lot more changing characters as it would go through the whole list of characters for each file.
BTW, I liked the idea of teleporting to do dailies from cot_tele so I've changed my sequence. Now I do survivalr5, cot_tele, dailies, clearbag. It always bugged me that clearbag wasn't at the end. I'm much more happier with this.
Re: rock5's "fastLogin Revisited"
Posted: Thu Jan 05, 2012 10:22 am
by Alleexx
Ah didn't know how to use that script.
Thanks for the help!
Re: rock5's "fastLogin Revisited"
Posted: Fri Jan 06, 2012 7:17 am
by Germangold
It works for me like a charm
but after the 12th char (3. Account 1. Char) most of the time the clients starts failing > critical error.
so only up to 12 chars in a row for me
but its fine anyway!
Re: rock5's "fastLogin Revisited"
Posted: Sun Jan 08, 2012 2:00 pm
by grande
Is this the correct sequence or does the random region select part go someplace else? Also, would a ; be requied after these lines? TIA
Code: Select all
SetCharList(CharList)
LoginNextChar()
fastLoginReqSel=math.random(2)
G
Re: rock5's "fastLogin Revisited"
Posted: Sun Jan 08, 2012 9:29 pm
by rock5
You have to change the region
before loging in the next character. And its an in game value so you need to use RoMScript. And you spelt "fastLoginRegSel" wrong.
Code: Select all
SetCharList(CharList)
RoMScript("}fastLoginRegSel=math.random(2) a={");
LoginNextChar()
Re: rock5's "fastLogin Revisited"
Posted: Sun Jan 08, 2012 10:28 pm
by grande
Thank you