Turning Off Buffing When On A Mount

Runes of Magic/Radiant Arcana (http://www.runesofmagic.com)
Post Reply
Message
Author
agentken007
Posts: 2
Joined: Sun Jan 30, 2011 12:20 pm

Turning Off Buffing When On A Mount

#1 Post by agentken007 » Sun Jan 30, 2011 1:05 pm

Hi there, as the title says im curious if there is a way to set it so that the bot doesn't cast buffs when it is mounted? I want to avoid casting a buff when traveling through some aggro mobs to cost me a death >.<

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Turning Off Buffing When On A Mount

#2 Post by lisa » Sun Jan 30, 2011 9:29 pm

Administrator wrote:Makes sense. For some reason, it was set to only be used outside of combat. Not sure why. I've changed it and it will be included in my next commit.
Admin said he would make it so bot would only buff while in combat, I think he has been pretty busy lately though, i believe that would be best way to stop this.

http://www.solarstrike.net/phpBB3/viewt ... 21&p=17243
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

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Turning Off Buffing When On A Mount

#3 Post by lisa » Sun Jan 30, 2011 10:19 pm

in the mean time I guess we could come up with something to stop the bot from casting any spells at all.

Do you use skill autouse in any of your WP or profiles if not then try this.

This is very crude and it's deffinately not the best solution but it will get you by until admin gets the time to change the buffs.

you will need to add this code to the beginning of pretty much any WP you use. It will call the function attached which will disable ALL skills if WP type="TRAVEL" and enable ALL skills if type isn't TRAVEL.

Like I said it is very crude and brute force, not the best option but it will do what you want for now.

Code: Select all

	<onLoad><![CDATA[
		_travel();
	]]></onLoad>
Added V1.01 that only disables the skills with type ="buff" in the database/skills.lua, so can now be used even if you disable other skills in your normal bot usage.
Attachments
userfunction_travelskills.lua
V 1.01 Only disables buffs.
(428 Bytes) Downloaded 90 times
userfunction_travelskills.lua
add to your userfunctions folder
(289 Bytes) Downloaded 81 times
Last edited by lisa on Mon Jan 31, 2011 1:47 am, edited 1 time in total.
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

agentken007
Posts: 2
Joined: Sun Jan 30, 2011 12:20 pm

Re: Turning Off Buffing When On A Mount

#4 Post by agentken007 » Mon Jan 31, 2011 12:32 am

This is great! It works like a charm =D thanks a lot for the help lisa and taking some of your time to help a stranger >.<

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Turning Off Buffing When On A Mount

#5 Post by lisa » Mon Jan 31, 2011 12:43 am

Adjusting it to only disable skills with type="buff", having little trouble implementing it though lol
Atleast then if you do use the autouse on other skills in profiles or userfunctions then they will still function as normal as only buffs will be affected by it.

I can see rock5 shaking their head at my implementation lol
If I reduce it to just affect buff's then it's not so brute force anymore ;)

I have this atm

Code: Select all

function _travel()

for k,v in pairs(settings.profile.skills) do
 
 	if __WPL.Type == WPT_TRAVEL and	settings.profile.skills[k].Type == STYPE_BUFF then
		settings.profile.skills[k].AutoUse = false
		printf("buffs off");
		end
 	
	if __WPL.Type ~= WPT_TRAVEL and	settings.profile.skills[k].Type == STYPE_BUFF then
		settings.profile.skills[k].AutoUse = true
		printf("buffs on");
		end
	end
end
It is printing the correct number of skills that are buffs but it isn't disabling them, I tried to use

Code: Select all

settings.profile.skills[k].Type == "buff"
but it didn't get the skills that were type buff.
I'm guessing I am missing something simple as usual.

LMAO yup I was missing something simple, I had another function in the profile on load enabling the skills, so it disabled and then enabled them lol
I'll edit the post with the userfunction to have the new one that only disables the buff skills.
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

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

Re: Turning Off Buffing When On A Mount

#6 Post by rock5 » Mon Jan 31, 2011 1:49 am

I think it's a reasonable thing to expect the bot not to buff while mounted. That could be implemented easily enough I think, just include a check to see if you are mounted before casting a buff while out of combat.

Would anyone have any issues if I implemented this?
  • 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

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Turning Off Buffing When On A Mount

#7 Post by lisa » Mon Jan 31, 2011 1:53 am

A while ago I actually asked if buffs could be made in combat only, admin said he would implement it but it doesn't seem to have been done. I'd say he has been busy.

I think anytime you use mount or waypoints type="TRAVEL" buffs should be dissabled.

Actually, I'd say only if you use mount. If you are set on travel and not mounted using a buff wouldn't affect the bot, it would use up some mana at most.

Might need to rethink the out of combat though, If set on TRAVEL and you have agro then it will still use the buff.
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

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Turning Off Buffing When On A Mount

#8 Post by lisa » Mon Jan 31, 2011 2:07 am

Maybe do it in 2 parts.
1. While mounted and out of combat then don't use "buff"
2. While mounted and TRAVEL then don't use "buff"
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

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

Re: Turning Off Buffing When On A Mount

#9 Post by rock5 » Mon Jan 31, 2011 2:56 am

I never did like the blanket statement that buffs should be in combat only. It should only be those buffs that are designed for combat only and have cooldowns. Other long buffs should be cast out of combat. I don't know if there is an easy way to separate the 2 groups though.

The travel idea needs more thought. If you are going to be casting buffs then should you also heal yourself if hurt? By the way, does it currently cast any skills while traveling? Also, of course, you wont be able to cast skills that take time because you are moving.
  • 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

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Turning Off Buffing When On A Mount

#10 Post by lisa » Mon Jan 31, 2011 3:20 am

While in TRAVEL it casts "buff" but that is all, it won't fight back, might do a HoT but I'd need to test.

line 520 of bot.lua deals with while TRAVEL, from what I can tell it stops rombot from battling while in TRAVEL, so theoretically it will still heal and buff.

I guess you would want it to still heal if your health got real low but if you stop to heal while your at 80% then you increase the chance of the mob killing you.

I find if your mounted and in TRAVEL then you don't die so easy as you out run them, unless feared.


Maybe we can use

Code: Select all

player.Battling == true
for buffs that you want to use during battle??
and obviously the ~= equivalent for buffs out of combat.
Would mean having another tag in skills though to seperate the 2 types.



Actually there is already a tag for inbattle.

Code: Select all

self.InBattle = nil
Could add the tag to the buffs that we only want used in combat. That would only involve changing the skill database.
This won't change the TRAVEL using buff issue though.
Might be as simple as adding in a while mounted don't use buff?

Me personally I would change all buffs to be inbattle but I can see how you might want to have some buffs before starting combat and then not use up a few seconds buffing up after entering combat.
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

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Turning Off Buffing When On A Mount

#11 Post by lisa » Mon Jan 31, 2011 3:49 am

Sorry about the long post, editing as I think of new ideas lol

Ok I think best way to go would be to make the buffs you want to use in combat only with the tag inbattle="true" and not include that tag into the buff's you want to be used both in and out of combat.

Now add in a profile option along the lines of

Code: Select all

<option name="BUFF_ONLY_IN_COMBAT" value="true" /> -- true/false true means all buffs will only be used while in combat, false means they will be used by default settings.
Add in some code to say if that option = true then all "buff" inbattle ="true" else just leave them as is.

That means default will be the way you like it and people have the option of making it only buff in battle if they wish ;)

Still need the if mounted don't use buffs.
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

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

Re: Turning Off Buffing When On A Mount

#12 Post by rock5 » Mon Jan 31, 2011 6:29 am

If I understand the 'InBattle' value properly, if no value is set then it will cast in and out of battle. If it's set to 'true' then it casts only in battle. If it's set to 'false' then it casts only out of battle.

So if you want your buffs to only cast in battle, all you need to do is add the "InBattle=true" option. There's no extra programming needed. It might be a good idea to add "InBattle=true" to the skills database for buffs that are obviously for battle only but the rest can be left to the user to add to their profile if they want.

And, yes, we still need to stop buffing while mounted.
  • 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

User avatar
lisa
Posts: 8332
Joined: Tue Nov 09, 2010 11:46 pm
Location: Australia

Re: Turning Off Buffing When On A Mount

#13 Post by lisa » Mon Jan 31, 2011 6:43 am

Without going through all the skills I'd just have a guess anything with cooldown <= 5 mins should be inbattle, anything longer then 5 mins should be both in or out of battle.

People could post if they wanted skills changed from true to false or vice versa, I don't know all the skills and their best usage.

Then just a matter of the while mounted issue.


The thing about TRAVEL though is it sets to not in battle, so any skills with inbattle = "true" wouldn't be used while in a WP with TRAVEL. I would still like to stop all buffs while mounted though regardless of WP type.
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

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

Re: Turning Off Buffing When On A Mount

#14 Post by rock5 » Mon Jan 31, 2011 7:24 am

lisa wrote:The thing about TRAVEL though is it sets to not in battle, so any skills with inbattle = "true" wouldn't be used while in a WP with TRAVEL.
That sounds like the way it should work.
lisa wrote:I would still like to stop all buffs while mounted though regardless of WP type.
Ah we are back to the topic. I'll look into it.
  • 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

User avatar
jduartedj
Posts: 599
Joined: Sat Dec 19, 2009 12:18 am
Location: Lisbon
Contact:

Re: Turning Off Buffing When On A Mount

#15 Post by jduartedj » Mon Jan 31, 2011 7:21 pm

actually I just use: (in my profile)

Code: Select all

	<onPreSkillCast>
		if (__WPL.Type == (WPT_TRAVEL or WPT_RUN)) and (player.Mounted) then
			return false;
		end
	</onPreSkillCast>
EDIT:if you want it to be regardless of the waypoint type then use:

Code: Select all

	<onPreSkillCast>
		if player.Mounted then
			return false;
		end
	</onPreSkillCast>
Thanks for reading! :D

Some of you might find this useful: RoM-bot Wiki
User Functions Repository (and other useful files): Addon Repo
Latest SVN updates: SVN updates

Post Reply

Who is online

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