Page 3 of 4

Re: Rev 577 Changelog

Posted: Sat Feb 26, 2011 6:13 am
by rock5
Alkaiser wrote:SCOUT_CONCENTRATE is missing from skills_local.xml
Is that the one that is instant cast, cooldown 5m and focus regeneration speed is increased by 100%?

And I guess it should only be used in battle.

Edit: Sorry, found it. It was misnamed. I'll add the correct name and add it to skills_local. Should I add 'inbattle=true' so it only uses it in battle or should I leave it to the user.

Re: Rev 577 Changelog

Posted: Sat Feb 26, 2011 12:28 pm
by Alkaiser
rock5 wrote:
Alkaiser wrote:SCOUT_CONCENTRATE is missing from skills_local.xml
Is that the one that is instant cast, cooldown 5m and focus regeneration speed is increased by 100%?

And I guess it should only be used in battle.

Edit: Sorry, found it. It was misnamed. I'll add the correct name and add it to skills_local. Should I add 'inbattle=true' so it only uses it in battle or should I leave it to the user.
That sounds good. It would be wasted outside of battle anyway.

Re: Rev 577 Changelog

Posted: Sat Feb 26, 2011 7:42 pm
by rock5
Actually, what would be good is if you could check to see if your focus was below a certain point before using. Unfortunately there is no check for that.

I'll just add the inbattle=false.

Re: Rev 577 Changelog

Posted: Mon Mar 07, 2011 6:25 pm
by Alkaiser
Is there some reason WARRIOR_BLASTING_CYCLONE has a casttime? It always shows "failed to cast" in the console... I assume because there is no cast bar for this skill.

Re: Rev 577 Changelog

Posted: Mon Mar 07, 2011 10:20 pm
by rock5
Alkaiser wrote:Is there some reason WARRIOR_BLASTING_CYCLONE has a casttime? It always shows "failed to cast" in the console... I assume because there is no cast bar for this skill.
If you have the skill can you confirm the details? Does it use 35 or 50 rage? Does it have a cooldown of 12 or 30 seconds? Is it 2s cast time or instant?

Re: Rev 577 Changelog

Posted: Wed Mar 09, 2011 12:46 am
by Alkaiser
It uses 35 rage and has a 12 sec cooldown. As far as I know, it is instant cast.

Re: Rev 577 Changelog

Posted: Thu Mar 10, 2011 2:11 am
by rock5
It probably changed since it was first added. I'll change it in my next commit.

Re: Rev 577 Changelog

Posted: Thu Mar 10, 2011 3:40 am
by lisa
functions.lua has
"function levelupSkill"
which levels up skills that are in database/skills.xml
There are however passive skills that still require lvling up and since they arn't in skills.xml anymore it gets an error.

Simple solution is to just add skills to the skills.xml such as

Code: Select all

	<skill name="SCOUT_RANGED_WEAPON_MASTERY" />
It doesn't need anymore information then that for it to work.
A longer solution would be to rewrite the function to work even if the skill isn't in skills.xml

Re: Rev 577 Changelog

Posted: Thu Mar 10, 2011 5:52 pm
by rock5
That's a good point Lisa. I believe it would also need the aslevel, skilltab and skillnum values to work with the current code.

The 2 main problems I see are;
  • it would be a big job to add them all to the skills database
  • it would require the passive to be added to the skills list in the profile which is confusing because they are supposed to be the skills you 'use' but passives are not 'used'.
Maybe what we need is another function that bypasses the skills list and can be used to level up a skill directly eg.

Code: Select all

levelupSkillManually(_skillname, _times)
It could use the 'GetSkillDetail' function in-game to find the skill then level it. Users could add it in their 'onLevelup' section to level their favourite passives.

What do you think.

Re: Rev 577 Changelog

Posted: Fri Mar 11, 2011 10:03 pm
by lisa
Yeah I agree adding them all to the skills DB would take a while and it's not really necessary. I would guess less then 25% of users may concider getting bot to lvl their skills, I just happen to be one of them lol

From what I can tell so far you would need the tab and number for each skill anyway. "GetSkillDetail" uses them to get name and such but I didn't come across any functions to get the numbers from the name.

I see 2 ways about it,

1. make up a passive skills DB and add a new lvlpassiveskill function to match
2. people use the in game function "SetSpellPoint" and add the tab and number themselves. sendMacro("SetSpellPoint(4, 2);");

Would also need to make sure the current function doesn't try to lvl the passive skills anymore.
The best option is probably 1 but would involve a bit of time doing it. I am stretched pretty thin at the moment for time =(

Option 3 is of course leave the functions as is and just add the passive skills to the bottom of skills.xml lol

Re: Rev 577 Changelog

Posted: Fri Mar 11, 2011 11:09 pm
by lisa
As it is the existing function only lvles up 1 passive skill, adding this to skills.xml would be fine for now as no other passives are lvled by the function.

Code: Select all

	<skill name="SCOUT_RANGED_WEAPON_MASTERY" aslevel="6" skilltab="4" skillnum="4" />

Re: Rev 577 Changelog

Posted: Sat Mar 12, 2011 12:48 am
by rock5
lisa wrote:From what I can tell so far you would need the tab and number for each skill anyway. "GetSkillDetail" uses them to get name and such but I didn't come across any functions to get the numbers from the name.
Actually I envisioned it would do a search for the name eg.

Code: Select all

function levelupSkillManually(_skillname, _times)
   for tab = 1, 4 do
      slot = 0
      repeat
         local name, _, icon, _, rank, type, upgradeCost, isSkillable, isAvailable = RoMScript("GetSkillDetail("..tab..","..slot..")")
         if name == _skillname then
            -- take steps to level up the required number of times
            return
         end
      until name == nil
   end
end
Of course that's really rough but you get the idea. I'd get the skill details in batches to reduce the number of RoMScripts so it wouldn't take too long. I've gotten good at that.

Re: Rev 577 Changelog

Posted: Sat Mar 12, 2011 3:50 am
by lisa
Trouble is you would need to use the ingame names for skills.

"Flame" and not "MAGE_FLAME"
"Electrostatic Charge" and not "MAGE_ELECTROSTATIC_CHARGE"

Which might confuse some people and not sure how it would work for different languages.
I can't help but feel if people can name the skill then they can also just use the tab, num.

Code: Select all

function levelupSkillManually(_skilltab, _skillnum, _times)
local times = 0
if _times == nil then _times = 1 end
repeat
sendMacro("SetSpellPoint(".._skilltab..", ".._skillnum..");");
times = times + 1
repeat until times = _times
end 

I can't help but feel I am still overthinking things lol

Re: Rev 577 Changelog

Posted: Sat Mar 12, 2011 8:08 am
by rock5
I don't really think it's a problem that, for this function, the users would have to use the real name. It is, in effect, a 'bypass' function after all, so I'd think it's logical that it wouldn't use the bots skill names. Language shouldn't be an issue as long as they use the name as they see it in-game(not sure about special characters).

But you're probably right. It would be just about as easy to just use the tab and number. I just thought it might be that little bit more convenient to use the name and more reliablely level the right skill.

Re: Rev 577 Changelog

Posted: Sat Mar 12, 2011 3:07 pm
by Giram
I think it was after this update when i started getting this error:

Sat Mar 12 21:59:02 2011 : ...Runes of Magic/micromacro/scripts/classes/player.lua:1260: Error in your profile: onLeaveCombat error: ...t/Runes of Magic/micromacro/scripts/classes/pawn.lua:536: bad argument #1 to 'gmatch' (string expected, got nil)

I think it's related to the housemaid buff userfunction in my case. This happened after killing mob and didn't have some buffs on. When i just took those potions it's working again and won't give that error next time it needs to take potion or food. And there are also times that i don't get this error.

Re: Rev 577 Changelog

Posted: Sat Mar 12, 2011 9:50 pm
by rock5
Giram wrote:I think it was after this update when i started getting this error:

Sat Mar 12 21:59:02 2011 : ...Runes of Magic/micromacro/scripts/classes/player.lua:1260: Error in your profile: onLeaveCombat error: ...t/Runes of Magic/micromacro/scripts/classes/pawn.lua:536: bad argument #1 to 'gmatch' (string expected, got nil)

I think it's related to the housemaid buff userfunction in my case. This happened after killing mob and didn't have some buffs on. When i just took those potions it's working again and won't give that error next time it needs to take potion or food. And there are also times that i don't get this error.
You're probably right as I changed the buff functions to get their data from memory in that revision although I tried to make it backward compatible.

What version of the bot are you running at the moment? What is in your 'onLeaveCombat' section? Have you updated to the latest housemaid userfunction?

Re: Rev 577 Changelog

Posted: Sun Mar 13, 2011 11:02 am
by Giram
Rombot version 3.29 rev 580

Here is one onleave but it's happening with all that have useGoodie. Sometimes it works and sometimes it gives me error.

Code: Select all

	<onLeaveCombat><![CDATA[
		-- Additional Lua code to execute after killing an enemy
	]]>
	useGoodie("speed");
	useGoodie("luck");
	useGoodie("patt3");

	catchCavy();
	lootBodies();
	player.free_flag1 = false;
	</onLeaveCombat>
The userfunction i am using now is posted on here http://www.solarstrike.net/phpBB3/viewt ... 949#p18949. It was updated to use id of the buff.

Re: Rev 577 Changelog

Posted: Sun Mar 13, 2011 10:31 pm
by rock5
I think the problem is with the useGoodies function. If I print the value for GetIdName(506679), I get nothing(that's the patt3 item name). It looks like none of the foods work. Maybe they are the wrong id numbers.

I got some food from my house maid and they weren't called 'Smoked Bacon with Herbs' and 'Salted Fish with Sauce' but 'Housekeeper Special Smoked Bacon with Herbs' and 'Housekeeper Special Salted Fish with Sauce' . The ids for those are 207210 and 207209 respectively. I suspect a review of the food ids is in order.

Re: Rev 577 Changelog

Posted: Fri Mar 18, 2011 8:22 pm
by Alkaiser
Missing from skills_local.xml

Code: Select all

<ROGUE_LIONS_PROTECTION en="Lion\'s Protection" />

Re: Rev 577 Changelog

Posted: Fri Mar 18, 2011 10:27 pm
by rock5
Alkaiser wrote:Missing from skills_local.xml

Code: Select all

<ROGUE_LIONS_PROTECTION en="Lion\'s Protection" />
I'll add it to the next commit.