mail recall belt

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
Supergala
Posts: 504
Joined: Mon May 17, 2010 3:40 pm
Location: Poland

mail recall belt

#1 Post by Supergala » Fri May 22, 2015 9:42 pm

hi guys i try to buy recall belt from wailing fjord and try to send to all my alt for make fusion.i use this script but mm say me "error to compile lua"...anyone can help me pls?the problem arrive when i add line where i try to send item by mail and try to compile nametable....ty

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints>
<onLoad> 

nameTable =
{
"char1","char2" etc
};
counter = 1;

</onLoad>
	<!-- #  1 --><waypoint x="-10294" z="2230" y="43">
			player:target_NPC(123010) -- Didide Spiderfoot
                        	store:buyItem(228959, 15);
	yrest(1000)
	</waypoint>
	<!-- #  2 --><waypoint x="-10258" z="2236" y="50">	</waypoint>
	<!-- #  3 --><waypoint x="-10155" z="2235" y="47">	</waypoint>
	<!-- #  4 --><waypoint x="-10072" z="2255" y="48">	</waypoint>
	<!-- #  5 --><waypoint x="-9992" z="2265" y="50">	</waypoint>
	<!-- #  6 --><waypoint x="-9912" z="2270" y="49">
			player:target_NPC(123006) -- Mailbox
UMM_SendByNameOrId(nameTable[counter],228959, 15);
yrest(500);
counter = counter  + 1;
    end

	</waypoint>
</waypoints>

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: mail recall belt

#2 Post by rock5 » Fri May 22, 2015 9:48 pm

Supergala wrote:nameTable =
{
"char1","char2" etc
};
Firstly, I assume you don't have "etc" in your file?
Supergala wrote: <!-- # 6 --><waypoint x="-9912" z="2270" y="49">
player:target_NPC(123006) -- Mailbox
UMM_SendByNameOrId(nameTable[counter],228959, 15);
yrest(500);
counter = counter + 1;
end

</waypoint>
That "end" doesn't end anything.

That's all I see.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

Supergala
Posts: 504
Joined: Mon May 17, 2010 3:40 pm
Location: Poland

Re: mail recall belt

#3 Post by Supergala » Sat May 23, 2015 7:45 am

y rock i don't have etc,i try to cancel "end" and check if work,another question,if mailbox crash your function is configured for regoll automatically?ty

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: mail recall belt

#4 Post by rock5 » Sat May 23, 2015 9:17 am

If you reach your send limit then it logs off then back in again to clear the send limit. Then it continues where it left off.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

Supergala
Posts: 504
Joined: Mon May 17, 2010 3:40 pm
Location: Poland

Re: mail recall belt

#5 Post by Supergala » Tue May 26, 2015 8:10 pm

mm say me there is a problem in on load event...i cut end as your suggest but don't wrk.i don't understand why....:(

Supergala
Posts: 504
Joined: Mon May 17, 2010 3:40 pm
Location: Poland

Re: mail recall belt

#6 Post by Supergala » Tue May 26, 2015 8:48 pm

rock i find the problem....how many name can add in name table?i have around 40 names in nametable,i try to add only 2 and it's work,can you answer me pls?if can't add 40 names how can i compile script for send belt to all?ty

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: mail recall belt

#7 Post by rock5 » Tue May 26, 2015 8:59 pm

I can't see anything wrong with your onload.

I see you found the problem. For future reference you can use a trick we have mentioned before on the forums to find errors in onload. Copy the contents of the onload into another file, eg. tmpOnLoad.lua, and place it in the rom folder
  • tmpOnLoad.lua

Code: Select all

nameTable =
{
"char1","char2" etc
};
counter = 1;
Then change the onload of your waypoint file to point to that file

Code: Select all

<onLoad>
include("tmpOnLoad.lua")
</onLoad>
Then when you get an onload error it will tell you what line it's on and a better error description.
Supergala wrote:rock i find the problem....how many name can add in name table?i have around 40 names in nametable,i try to add only 2 and it's work,can you answer me pls?if can't add 40 names how can i compile script for send belt to all?ty
There is no limit to how many names you can add. You probably just made a mistake adding them. If you can't see what you are doing wrong then just add a few at a time until it fails. Then see what's wrong with what you just added.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

Supergala
Posts: 504
Joined: Mon May 17, 2010 3:40 pm
Location: Poland

Re: mail recall belt

#8 Post by Supergala » Tue May 26, 2015 9:11 pm

if i add name after jacala mm say me an error to compile lua.if i use this script i don't have relog if when i send item stuck.why?

Code: Select all

<?xml version="1.0" encoding="utf-8"?><waypoints>
<onLoad>

nameTable =
{
"char 1","char2","char3" etc
};
counter = 1;

<!-- Function to Buy Belts Wailing Fjord -->
function buyBelts_Fjord()
player:openStore("Didide Spiderfoot")
store:buyItem(228959, 20);
yrest(1000);
end



</onLoad>
   <!-- #  1 --><waypoint x="-10294" z="2230" y="43">
         player:target_NPC("Didide Spiderfoot") 
   store:buyItem(228959, 15);
   yrest(1000)
   </waypoint>
   <!-- #  2 --><waypoint x="-10258" z="2236" y="50">   </waypoint>
   <!-- #  3 --><waypoint x="-10155" z="2235" y="47">   </waypoint>
   <!-- #  4 --><waypoint x="-10072" z="2255" y="48">   </waypoint>
   <!-- #  5 --><waypoint x="-9992" z="2265" y="50">   </waypoint>
   <!-- #  6 --><waypoint x="-9912" z="2270" y="49">
         player:target_NPC(123006) -- Mailbox
UMM_SendByNameOrId(nameTable[counter],228959, 15);
yrest(500);
counter = counter  + 1;
loadpaths(buybelt2)
end
	</waypoint>
</waypoints>
Last edited by Supergala on Thu May 28, 2015 4:59 pm, edited 1 time in total.

User avatar
Bill D Cat
Posts: 555
Joined: Sat Aug 10, 2013 8:13 pm
Location: Deep in the Heart of Texas

Re: mail recall belt

#9 Post by Bill D Cat » Thu May 28, 2015 12:32 pm

I really hope those are not your actual character names, lest someone stumble across this thread and you end up getting banned. Might be a good idea to edit the post to change the names to some type of placeholder names instead.

noobbotter
Posts: 527
Joined: Fri Aug 31, 2012 1:15 pm

Re: mail recall belt

#10 Post by noobbotter » Thu May 28, 2015 2:14 pm

Yes, edit your post and remove those names.

As for why you can't add any names, keep in mind when you have items in the nameTable, every item should have a comma after it except for the last item in the table. If you are adding more names, make sure all of them have a comma except the last item.

What I'm confused about is the variable "counter" which is established in the onLoad section:

Code: Select all

counter = 1;
Then in waypoint 6, you send 15 belts to the first name in the table. Then it increases the counter by 1. Then it loads a different waypoint. How will it ever send to other characters?

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: mail recall belt

#11 Post by rock5 » Thu May 28, 2015 2:24 pm

The copy he sent me via pm had some quote marks missing so I think he was just adding them wrong.

I think the point with the loadPaths is that he doesn't know how to add it. I added a check to see if it's reached the end of the list.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

noobbotter
Posts: 527
Joined: Fri Aug 31, 2012 1:15 pm

Re: mail recall belt

#12 Post by noobbotter » Thu May 28, 2015 2:38 pm

Ok, Rock. So I assume you showed him how to build a loop to iterate through the table and you fixed his loadpath statement. Also, if he's sending 15 belts to each person, it will need to relog after 4 people so hopefully he has set up what he needs for that to happen properly.

Supergala
Posts: 504
Joined: Mon May 17, 2010 3:40 pm
Location: Poland

Re: mail recall belt

#13 Post by Supergala » Thu May 28, 2015 5:11 pm

thk's for now.i check and try..ty to all

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: mail recall belt

#14 Post by rock5 » Thu May 28, 2015 7:09 pm

noobbotter wrote:Also, if he's sending 15 belts to each person, it will need to relog after 4 people
Well.... The mail functions should handle that.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

Supergala
Posts: 504
Joined: Mon May 17, 2010 3:40 pm
Location: Poland

Re: mail recall belt

#15 Post by Supergala » Thu May 28, 2015 7:12 pm

rock check my pm pls

User avatar
rock5
Posts: 12173
Joined: Tue Jan 05, 2010 3:30 am
Location: Australia

Re: mail recall belt

#16 Post by rock5 » Thu May 28, 2015 7:17 pm

Already done it.

You don't have to tell me to check my PMs. I do it automatically. :) But like my signature says, I always read posts first. That's why I answered the post first.
  • Please consider making a small donation to me to support my continued contributions to the bot and this forum. Thank you. Donate
  • I check all posts before reading PMs. So if you want a fast reply, don't PM me but post a topic instead. PM me for private or personal topics only.
  • How to: copy and paste in micromacro
    ________________________
    Quote:
    • “They say hard work never hurt anybody, but I figure, why take the chance.”
          • Ronald Reagan

Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 2 guests