Lamkefyned´s Graffu Farm
Forum rules
Only post additional bot resources here. Please do not ask unrelated questions.
Only post additional bot resources here. Please do not ask unrelated questions.
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
thank you very much
If you think something is right just because everyone else believes,you're not thinking.
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
Hi, I just need one thing
How to create a menu to jump to tags
How to create a menu to jump to tags
Code: Select all
if you get one that goes to tag BOS1
If you think something is right just because everyone else believes,you're not thinking.
Re: AMBOLIA´s Graffu Farm first,two,three boss
Just print the options, get the user input with io.stdin:read(), then go to the tag selected by the user. Eg.
Code: Select all
print("Here are the options:")
print(" 1. One")
print(" 2. Two")
print(" 3. Three")
printf("Enter a number > ")
local selected = io.stdin:read()
if selected == 1 then
__WPL:setWaypointIndex(__WPL:findWaypointTag("One"))
elseif selected == 2 then
__WPL:setWaypointIndex(__WPL:findWaypointTag("Two"))
elseif selected == 3 then
__WPL:setWaypointIndex(__WPL:findWaypointTag("Three"))
end
- 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
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
this can be done?
Code: Select all
<?xml version="1.0" encoding="utf-8"?><waypoints>
<onLoad>
<!-- ***********************************************************************************************************************************************************************************************************************************************************************************************************************************************************************
*********************************** AMBOLIA SCRPT GRAFFU´S FARM BETA V1
***********************************
*********************************** 05/02/2014
***********************************
***********************************
***********************************
***********************************
***********************************
************************************************************************************************************************************************************************************************************************************************************************************************************************************************************************** -->
<!--************************************************************************************************************ FUNCTION SETWINDOW ************************************************************************************************************ -->
setwindow ("mem")
<!-- *********************************************************************************************************** FUNCTION CHOICE NUMBER RUN ************************************************************************************************* -->
Nbrun = 0
repeat
cprintf(cli.lightgreen,"\n\n\n Welcome On Graffu's farm !\n\n")
print("Choose run's number: ")
print("\nNbrun>")
Nbrun = io.stdin:read()
Nbrun = tonumber(Nbrun)
until Nbrun and Nbrun > 0
cprintf(cli.blue, "\n\n Have nice farm on Graffu V1.0 !\n Create by AMBOLIA !\n\n\n")
if Nbrun > 157
then cprintf(cli.red,"\n\n Sorry, Maximum is 157 ! Because 157*19=2983 ! You can't have more of 2983 Mementos \n\n")
yrest(3000)
loadPaths(__WPL.FileName);
end
SlashCommand("aid easy")
<!-- *********************************************************************************************************** FUNCTION WARDEN_SUMMON_CHIRON_THE_CENTAUR ********************************************************************* -->
function Summon()
player:cast("WARDEN_SUMMON_CHIRON_THE_CENTAUR")
end
<!-- ********************************************************************************************************** FUNCTION TO DEFINE ORIGIN'S WAYPOINT ************************************************************************************* -->
__WPL:setWaypointIndex(__WPL:findWaypointTag("start"))
<!-- ********************************************************************************************************** FUNCTION UNBRIDLED ENTHUSIAM+LUCKY TARGET ************************************************************************** -->
function Buff()
player:update()
if not player:hasBuff("506684")
then inventory:useItem(207200);
end
if (not player:hasBuff("506687"))
then inventory:useItem(207203);
end
end
<!-- *********************************************************************************************************** FUNCTION COUNT SELL ************************************************************************************************************** -->
Mcount = 0
function Mcountround()
Mcount = Mcount+1;
end
<!-- *********************************************************************************************************** FUNCTION COUNT DEAD ************************************************************************************************************** -->
Dcount = 0
function Dcountround()
Dcount = Dcount+1;
end
<!-- *********************************************************************************************************** FUNCTION COUNT BUG **************************************************************************************************************** -->
Bcount = 0
function Bcountround()
Dcount = Bcount+1;
end
<!-- ********************************************************************************************************** FUNCTION COUNT ANCIENT MEMENTO ********************************************************************************************** -->
Acount = 0
function Acountround()
Acount = Count*19;
end
<!-- ********************************************************************************************************** FUNCTION COUNT RUN ******************************************************************************************************************* -->
Count = 0
function Countround()
Count = Count+1;
end
<!-- ********************************************************************************************************** FUNCTION NUMBER RUN & CHECK MEMENTO'S NUMBER ************************************************************************* -->
function number()
End = 0
if ( Nbrun == Count )
then printf("\n\n All run done !\n\n");
End = 1
SlashCommand("ILG destroy")
waitForLoadingScreen()
__WPL:setWaypointIndex(__WPL:findWaypointTag("return"))
end
Mentos = getCurrency("mento")
if ( Mentos == 2983 )
then printf("\n\n Full Ancient Memento !\n\n");
End = 1
SlashCommand("ILG destroy")
waitForLoadingScreen()
__WPL:setWaypointIndex(__WPL:findWaypointTag("return"))
end
end
<!-- *********************************************************************************************************** FUNCTION NUMBER RUN & CHECK MEMENTO'S NUMBER **************************************************************************** -->
function lastrun()
restmentos = 2983 - Mentos;
lrun= restmentos / 19 ;
end
<!-- *********************************************************************************************************** FUNCTION CHECK BAG *********************************************************************************************************************** -->
function bag()
Rightbag = 0
if ( Rightbag == 0 )
then
local bcount = inventory:getItemCount(0)
if( 5 > bcount )
then
SlashCommand("ILG destroy")
waitForLoadingScreen()
SlashCommand("ILG inv")
__WPL:setWaypointIndex(__WPL:findWaypointTag("return"))
end
end
end
<!-- *********************************************************************************************************** FUNCTION GROUP ******************************************************************************************************************************* -->
function ireset()
SlashCommand("ILG destroy")
yrest(500)
SlashCommand("ILG inv")
end
<!-- ********************************************************************************************************** FUNCTION TELEPORT PNJ ********************************************************************************************************************** -->
function tp()
teleportToWP()
end
<!-- ********************************************************************************************************** FUNCTION INFORMATION ************************************************************************************************************************* -->
function Info()
cprintf(cli.pink, "\n\nNbr Round done: %s for %s Mementos win !\n", Count, Acount)
cprintf(cli.pink, "You have %s Mementos ! You chose %s run ! You can do again %s run ! \n",Mentos, Nbrun, lrun)
cprintf(cli.yellow, "Nbr Sell: %s \n", Mcount)
cprintf(cli.red, "Nbr Dead: %s and Nbr Bug: %s\n\n", Dcount, Bcount)
end
</onLoad>
<!-- *********************************************************************************************************** WAYPOINT ENTRAR EN GRUPO Y ENTRAR EN GRAFFU ******************************************************** -->
<!-- # 1 --> <waypoint x="-8472" z="45468" y="758" tag="start" type="TRAVEL"> changeProfileOption("LOOT",false); ireset() </waypoint>
<Onload>
Nbrun = 0
repeat
cprintf(cli.lightgreen,"\n\n\n Welcome On Graffu's farm !\n\n")
print("Choose run's number: ")
print("\nNbrun>")
Nbrun = io.stdin:read()
Nbrun = tonumber(Nbrun)
until Nbrun and Nbrun > 0
cprintf(cli.blue, "\n\n Have nice farm on Graffu V1.0 !\n Create by AMBOLIA !\n\n\n")
if Nbrun > 157
then cprintf(cli.red,"\n\n Sorry, Maximum is 157 ! Because 157*19=2983 ! You can't have more of 2983 Mementos \n\n")
yrest(3000)
loadPaths(__WPL.FileName);
end
SlashCommand("aid easy")
</Onload>
If you think something is right just because everyone else believes,you're not thinking.
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
Because of me this error?
Code: Select all
<?xml version="1.0" encoding="utf-8"?>
<waypoints>
<onLoad>
<!--**********************************************************************************************************************************************************************************************************************-->
<!--*********************************** AMBOLIA SCRPT GRAFFU´S FARM ***********************************-->
<!--*********************************** ***********************************-->
<!--*********************************** Version Stable V1 ***********************************-->
<!--*********************************** ***********************************-->
<!--*********************************** 15/02/2014 ***********************************-->
<!--*********************************** ***********************************-->
<!--*********************************** Support: http://www.solarstrike.net/phpBB3/viewtopic.php?f=27&t=5560 ***********************************-->
<!--*********************************** ***********************************-->
<!--**********************************************************************************************************************************************************************************************************************-->
print("Here are the options:")
print(" 1. One Boss")
print(" 2. Two Boss")
print(" 3. Three Boss")
printf("Enter a number > ")
local selected = io.stdin:read()
if selected == 1 then
loadPaths("Boss1.xml");
elseif selected == 2 then
loadPaths("Boss2.xml");
elseif selected == 3 then
loadPaths("Boss3.xml");
end
</onLoad>
<waypoints>
If you think something is right just because everyone else believes,you're not thinking.
- Bill D Cat
- Posts: 555
- Joined: Sat Aug 10, 2013 8:13 pm
- Location: Deep in the Heart of Texas
Re: AMBOLIA´s Graffu Farm first,two,three boss
Line 5, Position 98 is the apostrophe character that you used in "AMBOLIA SCRPT GRAFFU´S FARM".
Try changing that to another character and see if it helps.
I'm not sure WHY this would cause an error, since it is part of a comment, but it seems to be the case.
Also, as discussed in another thread (http://solarstrike.net/phpBB3/viewtopic.php?f=21&t=5575):
io.stdin:read() will return your input as a string, so you need to quote your results when comparing them.
Try changing that to another character and see if it helps.
I'm not sure WHY this would cause an error, since it is part of a comment, but it seems to be the case.
Also, as discussed in another thread (http://solarstrike.net/phpBB3/viewtopic.php?f=21&t=5575):
io.stdin:read() will return your input as a string, so you need to quote your results when comparing them.
Code: Select all
local selected = io.stdin:read()
if selected == "1" then
loadPaths("Boss1.xml");
elseif selected == "2" then
loadPaths("Boss2.xml");
elseif selected == "3" then
loadPaths("Boss3.xml");
end
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
That's fixed but now I have another lol
Code: Select all
<waypoints>
<onLoad>
<!--**********************************************************************************************************************************************************************************************************************-->
<!--*********************************** AMBOLIA SCRIPT GRAFFU FARM ***********************************-->
<!--*********************************** ***********************************-->
<!--*********************************** Version Stable V1 ***********************************-->
<!--*********************************** ***********************************-->
<!--*********************************** 15/02/2014 ***********************************-->
<!--*********************************** ***********************************-->
<!--*********************************** Support: http://www.solarstrike.net/phpBB3/viewtopic.php?f=27&t=5560 ***********************************-->
<!--*********************************** ***********************************-->
<!--**********************************************************************************************************************************************************************************************************************-->
print("Here are the options:")
print(" 1. One Boss")
print(" 2. Two Boss")
print(" 3. Three Boss")
printf("Enter a number > ")
local selected = io.stdin:read()
if selected == "1" then
loadPaths("Boss1.xml");
elseif selected == "2" then
loadPaths("Boss2.xml");
elseif selected == "3" then
loadPaths("Boss3.xml");
end
</onLoad>
<waypoints>
If you think something is right just because everyone else believes,you're not thinking.
- Bill D Cat
- Posts: 555
- Joined: Sat Aug 10, 2013 8:13 pm
- Location: Deep in the Heart of Texas
Re: AMBOLIA´s Graffu Farm first,two,three boss
Look at your last tag: It is <waypoints> instead of </waypoints>
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
Thanks, as I can put it like this?
Code: Select all
loadPaths("..getFilePath(__WPL.FileName)../Start.xml");
If you think something is right just because everyone else believes,you're not thinking.
- Bill D Cat
- Posts: 555
- Joined: Sat Aug 10, 2013 8:13 pm
- Location: Deep in the Heart of Texas
Re: AMBOLIA´s Graffu Farm first,two,three boss
That looks like it will load the file "start.xml" that is in the same directory as the currently loaded waypoint file.
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
But it gives me error
If you think something is right just because everyone else believes,you're not thinking.
- Bill D Cat
- Posts: 555
- Joined: Sat Aug 10, 2013 8:13 pm
- Location: Deep in the Heart of Texas
Re: AMBOLIA´s Graffu Farm first,two,three boss
You were quoting the whole string so it used it literally. Try it like this.
Code: Select all
loadPaths(getFilePath(__WPL.FileName).."/Start.xml");
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
I will take note of all his contribution to this project
Thanks, now I'm off to bed a 14 year old boy can not go to bed at 5.
Thanks, now I'm off to bed a 14 year old boy can not go to bed at 5.
If you think something is right just because everyone else believes,you're not thinking.
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
I have an error.
when going to attack this error check
SCRIPT 1
when going to attack this error check
SCRIPT 1
If you think something is right just because everyone else believes,you're not thinking.
Re: AMBOLIA´s Graffu Farm first,two,three boss
What version of rombot are you using, the nearest sprintf I can find is at line 1297.
Remember no matter you do in life to always have a little fun while you are at it
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
revision 771
BOT_VERSION = 3.29;
BOT_VERSION = 3.29;
If you think something is right just because everyone else believes,you're not thinking.
Re: AMBOLIA´s Graffu Farm first,two,three boss
There is a cprintf on that line. I believe sprintf refers to the sprintf that is used in the cprintf function. So the nil value is actually the second value used in cprintf. Hm.. or maybe not "language[173]" should exist. Maybe it's the third value.
Anyway, the problem is this lineThe first value should be a string and the boolean value should not be capitalized.
Anyway, the problem is this line
Code: Select all
changeProfileOption(LOOT,False)
Code: Select all
changeProfileOption("LOOT",false)
- 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
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
I have an error.
If you think something is right just because everyone else believes,you're not thinking.
Re: AMBOLIA´s Graffu Farm first,two,three boss
Somewhere you used
__WPL.FileName is a variable that holds the file name of the current waypoint list. When you put quotes around it, it is seen as a string, not a variable. So it tries to load a file literally name "__WPL.FileName" which of course doesn't exist. If you want to use the value held by the variable and reload the current waypoint list then use,
Code: Select all
loadPaths("__WPL.FileName")
Code: Select all
loadPaths(__WPL.FileName)
- 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
- Lamkefyned
- Posts: 348
- Joined: Thu May 23, 2013 11:38 am
- Location: Spain
Re: AMBOLIA´s Graffu Farm first,two,three boss
Thanks, I just missing 3 scripts
If you think something is right just because everyone else believes,you're not thinking.
Who is online
Users browsing this forum: No registered users and 2 guests