Page 16 of 39
Re: Rock5's Mail Mods
Posted: Thu Jan 26, 2012 12:32 pm
by emmanuel04
I use xbar and a Macro
thats also opens it
Re: Rock5's Mail Mods
Posted: Thu Jan 26, 2012 6:59 pm
by lisa
with bot use
and then try using Rock's mail function.
Re: Rock5's Mail Mods
Posted: Thu Feb 02, 2012 10:48 pm
by Rickster
i have a script, which checks for new mail, then does some farming stuff, dealing with quests etc, then returns to the mailbox to check for new mails again. after that it is switching char and doing all over again.
in some rare cases, sometimes at the first mailboxcheck, other times at the second check, sometimes never and othertime at every mailboxcheck i get this error message:
Code: Select all
- ...ts/rom/userfunctions/addon_Rock5s_Mail_Functions.lua:66: The UMM
l interface needs to be open first before using the UMM_TakeMail() function.
the bot exits at this point.
i am using this to open the mailbox
Code: Select all
player:target_Object(112778); yrest(3000); -- mailbox
sendMacro("ChoiceOption(1);"); yrest(1000);
UMM_TakeMail ();
sometimes the mail window opens, other times it does not.
mail mod version is 1.72
any ideas, whats going wrong there?
thanx
ric
Re: Rock5's Mail Mods
Posted: Fri Feb 03, 2012 2:08 am
by rock5
Where does it fail? Does it say that it found the target and will try and open it? Does it open the dialog?
You could try;
Code: Select all
repeat
player:target_Object(112778); yrest(1000); -- mailbox
until RoMScript("SpeakFrame:IsVisible()")
repeat
sendMacro("ChoiceOption(1);"); yrest(1000);
until RoMScript("MailFrame:IsVisible()")
UMM_TakeMail ();
Re: Rock5's Mail Mods
Posted: Fri Feb 03, 2012 5:48 am
by Rickster
It seems, that the mailbox does not get targeted, because the speak frame does not open.
i did not know how to check if some frames/dialogues are visible.
i will give your code a try and report, whats happening

Re: Rock5's Mail Mods
Posted: Fri Feb 03, 2012 9:08 am
by Germangold
you should Set the corresponding waypoint where to aim the Mailbox exactly where it located
i got hung up some times at elven irland > there is a bench right next to the mailbox and my mailing failed and mm quit with a similar error
Re: Rock5's Mail Mods
Posted: Fri Feb 03, 2012 10:29 pm
by Rickster
running rocks
code now works for about one day without any issues when taking mail. it has never done this before
i had this probs at all mailboxes, not a special one, not at special locations.
by now everything is running fine with it

Re: Rock5's Mail Mods
Posted: Sat Feb 25, 2012 12:45 am
by nerf
my micromacro breaks after using this addon
Re: Rock5's Mail Mods
Posted: Sat Feb 25, 2012 6:44 am
by rock5
nerf wrote:my micromacro breaks after using this addon
Really? Interesting.
Re: Rock5's Mail Mods
Posted: Sat Feb 25, 2012 11:04 am
by Rickster
nerf wrote:my micromacro breaks after using this addon
maybe you want to tell us something about the errors you get. that would make it much easier to give some help ... by now it is just ... "interesting"

Re: Rock5's Mail Mods
Posted: Tue Feb 28, 2012 11:25 am
by sdude13
the functions do work nice, however, if a mailbox is full it keeps on wait and retry.
I have some farming bots that send tq to chars.
In the old version when the postbox of a recieving char was full it did send the rest to the next... this does not work anymore
because the addon thinks it's the "to much sent"-time problem.
example mail send function:
Code: Select all
UMM_SendAdvanced("XXXa",nil , 1, 60, 2000)
UMM_SendAdvanced("XXXb",nil , 1, 60, 2000)
Re: Rock5's Mail Mods
Posted: Tue Feb 28, 2012 12:39 pm
by rock5
That's not a problem I've ever had. That's why I didn't factor it in. The question is, how do you tell one from the other? How do you tell if it failed to send because of the "to much sent" problem or the mailbox is full?
Re: Rock5's Mail Mods
Posted: Sun Mar 25, 2012 12:43 pm
by grande
I figured this would be the best place to put this since it mostly deals with mail and uses r5's UMM functions. Please... please... please.. if this is posted somewhere else please let me know. I did some searches and the closest thing I could find didn't really work for what I wanted: send specific items to the next character on the account. So, that's basically what this WP does. I loosely gained some insight from other posts but again... none of them did what I needed. Hope this helps someone:
Code: Select all
<?xml version="1.0" encoding="utf-8"?><waypoints>
<onLoad>
--== User Option ==--
startGMDetect()
CharList = {
{account=11 , chars= {}},}
-- __WPL:setWaypointIndex(1);
</onLoad>
<!-- # 1 --><waypoint x="xxxx" z="xxxx" y="xxx"> </waypoint>
<!-- # 2 --><waypoint x="xxxx" z="xxxx" y="xxx"> </waypoint>
<!-- # 3 --><waypoint x="xxxx" z="xxxx" y="xxx">
RoMScript("EquipItem(4);"); --this is where you unequip specific items
yrest(800);
RoMScript("EquipItem(5);");
yrest(800);
RoMScript("EquipItem(16);");
yrest(800);
RoMScript("EquipItem(17);");
yrest(800);
RoMScript("EquipItem(11);");
yrest(800);
</waypoint>
<!-- # 4 --><waypoint x="-7136" z="-3948" y="138">
nameTable = {"YourToon1","YourToon2","YourToon3","YourToon4","YourToon5","YourToon6","YourToon7","YourToon8",}
repeat
player:target_Object("Mailbox"); yrest(1000); -- mailbox
until RoMScript("SpeakFrame:IsVisible()")
repeat
sendMacro("ChoiceOption(1);"); yrest(1000);
until RoMScript("MailFrame:IsVisible()")
if player.Name == "YourToon1" then player.free_counter1 = player.free_counter1 + 2;
elseif player.Name == "YourToon2" then player.free_counter1 = player.free_counter1 + 3;
elseif player.Name == "YourToon3" then player.free_counter1 = player.free_counter1 + 4;
elseif player.Name == "YourToon4" then player.free_counter1 = player.free_counter1 + 5;
elseif player.Name == "YourToon5" then player.free_counter1 = player.free_counter1 + 6;
elseif player.Name == "YourToon6" then player.free_counter1 = player.free_counter1 + 7;
elseif player.Name == "YourToon7" then player.free_counter1 = player.free_counter1 + 8;
elseif player.Name == "YourToon8" then player.free_counter1 = player.free_counter1 + 1; end
UMM_SendInventoryItem(nameTable[player.free_counter1],inventory:findItem("Name of Your Item goes here"));
yrest(300);
UMM_SendInventoryItem(nameTable[player.free_counter1],inventory:findItem("Name of Your Item goes here"))
yrest(300);
UMM_SendInventoryItem(nameTable[player.free_counter1],inventory:findItem("Name of Your Item goes here"))
yrest(300);
UMM_SendInventoryItem(nameTable[player.free_counter1],inventory:findItem("Name of Your Item goes here"))
yrest(300);
UMM_SendInventoryItem(nameTable[player.free_counter1],inventory:findItem("Name of Your Item goes here"))
yrest(300);
RoMScript("UMMFrame:Hide()");
yrest(300);
</waypoint>
<!-- # 5 --><waypoint x="-7136" z="-3948" y="138">
local dqCount, dqPerDay = RoMScript("Daily_count()");
if dqCount == 10 then
SetCharList(CharList)
yrest(500);
RoMScript("}fastLoginRegSel=math.random(2) a={");
yrest(500);
LoginNextChar()
yrest(500);
loadProfile("Default")
yrest(500);
loadPaths("getmailANDreturntoGrind")
yrest(500);
end
</waypoint>
</waypoints>
Re: Rock5's Mail Mods
Posted: Mon May 28, 2012 1:13 pm
by Andy
Really useful, but why is it waiting before sending? Is it really necessary? (It takes so much time)
Re: Rock5's Mail Mods
Posted: Mon May 28, 2012 1:22 pm
by rock5
I've been meaning to fix that. The reason it does it is because if you send more than 60 mails it starts to fail because there is a limit. It only starts waiting if it fails to send. If you restart the client then you can start sending again. I've been thinking of just making it relog instead of waiting but I just haven't got around to it.
I've been pretty busy on other projects but I'll look into it soon.
Re: Rock5's Mail Mods
Posted: Tue Jun 12, 2012 10:32 am
by sdude13
just changing channel will reset the timer.. nicer than a full relog.
Re: Rock5's Mail Mods
Posted: Tue Jun 12, 2012 3:50 pm
by rock5
sdude13 wrote:just changing channel will reset the timer.. nicer than a full relog.
Ooh, that would be interresting. But then again, it's not a good enough solution. What happens in those locations where changing channel does nothing? Or how about those servers that only have 1 channel?
Re: Rock5's Mail Mods
Posted: Mon Jun 18, 2012 4:15 pm
by dx876234
Nice feature that it handles the mail sending issue but suddenly my distribution bot uses way to much time - is it possible to ask for an argument or global flag to turn it off and just return an error code or ex the number of mails sent? Well, just to turn it off would do wonders
I built a "relog character" around the mail functionality, takes some tens of seconds instead of a constant timeout of 300s per mail, kinda significant when sending 2k mails
regards
DX
Re: Rock5's Mail Mods
Posted: Tue Jun 19, 2012 1:17 am
by rock5
Yeah I've been meaning to fix it. Reloging in with the same character will allow it to continue sending. I've been pretty busy though. At the moment I'm trying to add code that finds the best place to cast clicktocast skills to hit the most mobs.
Actually this should be easy to fix. Where it pauses just make it relog instead. So maybe I'll fix this now. Hm... it would have to close then open the mailbox again. The UMM functions have never had to open the mailbox before. That could be a problem. I could have it just remember the id of the currently targeted object, hopefully it will be the mailbox, and use it to open the mailbox again after reloging. But how about those users who use convenient mailboxes?
This is probably why I never tackled this before. I'll do some thinking on it.
Re: Rock5's Mail Mods
Posted: Tue Jun 19, 2012 3:17 am
by rock5
Well I was thinking that it could check if your current target could be a mailbox. If so then it relogs and tries to open it again, otherwise it just returns false and fails to send if the user is using a convenient mailbox but then I realised that some mailboxes require you to select an option from a dialog before opening. It's starting to get a bit complex.
The easiest solution is to just have the sending fail and allow the user to handle it but that, I think, would require too much programming know-how on the part of the user, especially when trying to send a set number of items and being interupted part way through.
Maybe it is ok to assume, if you have to select an option from a mailbox dialog, it will always be the first? There is the small risk the the object you are targeting is not a mailbox but instead some other npc and you just selected an unintended option but I think the risk is small. You would just have to be careful not to use a convenient mailbox just after talking to an npc.
Users of convenient mailboxes will need to use a bit more code to deal with failed sending but in the end most users use an actual mailbox and that is what these functions were intended for.