Enhanced Functionality!
Re: Enhanced Functionality!
Just checked. Looks like it is in fact a function, list_waypoint_files(). Just have to see if I understand how to add an option to the paused state.
- 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
Re: Enhanced Functionality!
rock5 wrote:Code: Select all
Paused. (DEL) to continue, (CTRL+L) exit to shell, (CTRL+C) quit (CTRL+W) load new waypoint file
Exactly THAT's What I meant! and where I was saying interrupt i meant like you do with pause! So yes, BINGO!
Thanks for reading! 
Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates
Re: Enhanced Functionality!
I've added it to my todo list but I'll have to ask Administrator about how to add a key to the list as I don't quite follow it.jduartedj wrote:rock5 wrote:Code: Select all
Paused. (DEL) to continue, (CTRL+L) exit to shell, (CTRL+C) quit (CTRL+W) load new waypoint file
Exactly THAT's What I meant! and where I was saying interrupt i meant like you do with pause! So yes, BINGO!

- 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
Re: Enhanced Functionality!
rock5 wrote:I've added it to my todo list but I'll have to ask Administrator about how to add a key to the list as I don't quite follow it.jduartedj wrote:rock5 wrote:Code: Select all
Paused. (DEL) to continue, (CTRL+L) exit to shell, (CTRL+C) quit (CTRL+W) load new waypoint file
Exactly THAT's What I meant! and where I was saying interrupt i meant like you do with pause! So yes, BINGO!
I'm pretty sure I've seen a function that does this... it captures the keys if they are CTRL+L etc... not sure where ... if in bot or MM.
Thanks for reading! 
Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates
- Administrator
- Site Admin
- Posts: 5330
- Joined: Sat Jan 05, 2008 4:21 pm
Re: Enhanced Functionality!
It is currently hard-coded into lib.lua. I'll work on modifying the code to allow scripts to dynamically insert global hotkeys.
Re: Enhanced Functionality!
Here Rock5 it must be something like this:
at the end function pauseCallback use:
this is what MM uses for keytesting/pausing.... and pauseCallback is the function that is called (on rom-bot) on pause so....
I havent tested it anyway, I'm just hinting a shot at this.
(Could this work?)
at the end function pauseCallback use:
Code: Select all
while(true) do
yrest(10);
if( keyPressed(key.VK_CONTROL) and keyPressed(key.VK_W) ) then
(code to go back)
end
end
I havent tested it anyway, I'm just hinting a shot at this.
(Could this work?)
Thanks for reading! 
Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates
Re: Enhanced Functionality!
OOPSS this disables PAUSE (CTRL+L) need to break it or maybe call [EDIT:]exit on CTRL+Ljduartedj wrote:Code: Select all
while(true) do yrest(10); if( keyPressed(key.VK_CONTROL) and keyPressed(key.VK_W) ) then (code to go back) end end
EDIT2: FIXED but resume isn't working either .... - this does it as CTRL+C doesn't need to be specified
Code: Select all
while(true) do
yrest(10);
if( keyPressed(key.VK_CONTROL) and keyPressed(key.VK_W) ) then
printf("Code to execute\n");
end
if( keyPressed(key.VK_CONTROL) and keyPressed(key.VK_L) ) then
exitCallback();
break;
end
end
Code: Select all
if( keyPressed(settings.hotkeys.START_BOT.key) ) then --Settings is Is always loaded here
printf("Press DEL again.\n");
break;
end
Basically I'm doing MM's work for it! this evaluation is supposed to be done in MM like Admin said.
Also this code requires pressing DEL twice and only works after the settings are loaded (which makes sense btw).
This code is very sloppy because it generates useless trash (duplicates) and I can't bypass that....
Thanks for reading! 
Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates
Re: Enhanced Functionality!
This is getting over the head for me but I'm sure Administrator will work it out.
- 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
Re: Enhanced Functionality!
After a way-too-big amount of effort I was able to workaround and do sucessfully make the bot return to the waypoint list and start another waypoint file.
But like admin said this change has to be done at MM level.
This workaround is very sloppy and messy.
first I used:
at the end on function pauseCallback() in functions.lua file
then I had to put this:
at the beggining of in the bot.lua file
and finally add: after
and put: at the end of main().
Works but not so great... so I DON''T advise ppl to use it!
But like admin said this change has to be done at MM level.
This workaround is very sloppy and messy.
first I used:
Code: Select all
while(true) do
yrest(10);
if( keyPressed(key.VK_CONTROL) and keyPressed(key.VK_W)) then
printf("Press DEL twice, flag set to %s\n", player.free_flag1);
player.free_flag1 = true
return;
end
if( keyPressed(key.VK_CONTROL) and keyPressed(key.VK_L)) then
exitCallback();
return;
end
if( keyPressed(settings.hotkeys.START_BOT.key) ) then
printf("Press DEL again.\n");
return;
end
end
then I had to put this:
Code: Select all
if player.free_flag1 == true then --my code
__WPL=nil;
printf("Restarting... %s\n", player.free_flag1);
player.free_flag1 = false;
return botting(); --tail call
end
Code: Select all
while(true) do
and finally add:
Code: Select all
function botting()
Code: Select all
-- end of local function list_waypoint_files()
Code: Select all
end --end of botting
botting();
Works but not so great... so I DON''T advise ppl to use it!
Thanks for reading! 
Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates
Re: Enhanced Functionality!
By including this:2 - Include the Waypoint path file in the title bar!
Code: Select all
if (__WPL) then --test if not nil use "and option==true" to set it optional
if (__WPL.FileName) then --test if not nil either in case of wander
waypoint = "<"..__WPL.FileName.."> ";
end
end
Code: Select all
local waypoint=" "
EDIT:
use this instead it's better, but if you use wander then it'll show <<NONE>>:
Code: Select all
if (__WPL) then --not nil use "and option =true" to set it optional
waypoint = "<"..__WPL:getFileName().."> ";
end
Thanks for reading! 
Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates
Who is online
Users browsing this forum: Bing [Bot] and 1 guest