Ancient Treasures waypoint
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.
Re: Ancient Treasures waypoint
it doesn't have any more args?
Generally when I see a function that returns icon first there is usally a few more args after it.
Generally when I see a function that returns icon first there is usally a few more args after it.
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
Re: Ancient Treasures waypoint
While testing the chest code that Lisa gave me (which it seems I didn't put in right, got a "failed to compile" error) I ran across an aggro issue. While checking for the candle in the center room today, I got to the 3rd location, located the candle and dropped to collect it. This seems to be a very narrow window for aggro spot it seems. Guess I'll have to do a little more fine tuning on coordinates to avoid this problem. I'll update when I can get it fixed.
Scout/Knight/Rogue 70/66/66
Re: Ancient Treasures waypoint
Doesn't this effectively disable all skills? You could just disable them all in the waypoint onload. That way a user doesn't need to set anything up.rock5 wrote:]if settings.profile.options.DISMOUNT == false and zoneid == 355 then return false end --- NEW LINE
Code: Select all
for k,v in pairs(settings.profile.skills) do
v.AutoUse = false
end
Re: Ancient Treasures waypoint
You obviously need it for something else because the healing skills don't work in this minigame.cufRet8e wrote:How to disable all skills except healing ones? Or disable particular skill from mage.
To disable all skills except healing skill then use this
Code: Select all
for k,v in pairs(settings.profile.skills) do
if v.Type ~= STYPE_HEAL and v.Type ~= STYPE_HOT then
v.AutoUse = false
end
end
changeProfileSkill(_skill, _option, _value)
Eg.
Code: Select all
changeProfileSkill("ROGUE_SHADOWSTAB", "AutoUse", true)
- 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: Ancient Treasures waypoint
Thank you:)
Yes, it's for something else - running with mount. My character just cast buffs (like MAGE_INTENSIFICATION) when got aggro, even with TRAVEL waypoints (I think), and continue running (dismounted already) with those useless buffs.
You can move this message as it's unrelated to Ancient Treasures, sorry:)
Yes, it's for something else - running with mount. My character just cast buffs (like MAGE_INTENSIFICATION) when got aggro, even with TRAVEL waypoints (I think), and continue running (dismounted already) with those useless buffs.
You can move this message as it's unrelated to Ancient Treasures, sorry:)
Re: Ancient Treasures waypoint
Actually I think that is a bug that needs to be fixed. I'll have a look.cufRet8e wrote:running with mount. My character just cast buffs (like MAGE_INTENSIFICATION) when got aggro, even with TRAVEL waypoints (I think), and continue running (dismounted already) with those useless buffs.
- 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: Ancient Treasures waypoint
Ok, there is only one reference to the checkskills function in the player:moveTo.
So basically what I think I will do is, skip these if mounted and in travel mode or if mounted and in run mode and not battling. So
How does that sound?
Code: Select all
-- while moving without target: check potions / friendly skills
if( self:checkPotions() or self:checkSkills(ONLY_FRIENDLY) ) then -- only cast friendly spells to ourselfe
Code: Select all
-- while moving without target: check potions / friendly skills
if not (player.Mounted and __WPL.Type == WPT_TRAVEL) and not (player.Mounted and __WPL.Type == WPL_RUN and not player.Battling) then
if( self:checkPotions() or self:checkSkills(ONLY_FRIENDLY) ) then -- only cast friendly spells to ourselfe
- 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: Ancient Treasures waypoint
So many "not"
ok let me see if I understand it properly
So only if both are not at the same time.
so not mounted and wp type isn't travel
so player battling since double nengative?
so not mounted and also not wp type run and also player battling (in combat).
I am thinking it should be an or between them
Little confusing with so many not but it should do the trick.
ok let me see if I understand it properly
Code: Select all
not (player.Mounted and __WPL.Type == WPT_TRAVEL)
so not mounted and wp type isn't travel
Code: Select all
not (player.Mounted and __WPL.Type == WPL_RUN and not player.Battling)
so not mounted and also not wp type run and also player battling (in combat).
I am thinking it should be an or between them
Code: Select all
if not (player.Mounted and __WPL.Type == WPT_TRAVEL) or not (player.Mounted and __WPL.Type == WPL_RUN and not player.Battling) then
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
Re: Ancient Treasures waypoint
Yeh basically, if its type travel and mounted we don't want to cast. So we do want to cast if "not (type travel and mounted)". Also we dont want it to cast if type is run and mounted but only if not in combat, so we do want it to cast if "not (type is run and mount and not in combat)".
Finally, if either of those are true then we dont want to cast. But we do want to cast if "not (type travel and mounted) and not (type is run and mount and not in combat)". Because if either of those is true then we wouldn't want it to cast.
I think that's right. I can get confused too. It probably would have been easier to write
Problem is I don't really want to test it. Anyone want to test it? cufRet8e do you want to test it?
Finally, if either of those are true then we dont want to cast. But we do want to cast if "not (type travel and mounted) and not (type is run and mount and not in combat)". Because if either of those is true then we wouldn't want it to cast.
I think that's right. I can get confused too. It probably would have been easier to write
Code: Select all
if (type travel and mounted) or (type is run and mount and not in combat) then
nothing
else
check skills and potions.
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
Re: Ancient Treasures waypoint
Of course:)
What exactly you wan't me to paste between my waypoints, or which files to modify?
What exactly you wan't me to paste between my waypoints, or which files to modify?
Re: Ancient Treasures waypoint
Just had a thought, you wouldn't want to cast skills when mounted even if the type = normal. So it may be as simple as
I just did a little test. It still dismounts and it;s not because the logic is wrong. I think this might be harder than we thought because checkskills is run in a few different places.
Is there any reason we can't put the check for mounted right in the skill:canUse function? Then we could just add somewhere.
Ok cufRet8e, try this. In "skill.lua" at around line 172, just before
add the code just above.
Code: Select all
if not player.Mounted or (__WPL.Type ~= WPT_TRAVEL and player.Battling) then
check skills and potions
end
Is there any reason we can't put the check for mounted right in the skill:canUse function? Then we could just add somewhere.
Code: Select all
-- Is player mounted
if player.Mounted then
if __WPL.Type == WPL_TRAVEL or not player.Battling then
return false
end
end
Code: Select all
-- Is player level more than or equal to aslevel
- 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: Ancient Treasures waypoint
Tested. Not working at the moment.
I inserted code as you said, to 172 line of classes\skill.lua:
Loaded rombot with Default profile, I created simple waypoint file with about 20 WPs, and this code in one of them:
So characted get mounted and start running in TRAVEL mode.
I inserted code as you said, to 172 line of classes\skill.lua:
Code: Select all
-- Is player mounted
if player.Mounted then
if __WPL.Type == WPL_TRAVEL or not player.Battling then
return false
end
end
Code: Select all
__WPL:setForcedWaypointType("TRAVEL")
useGoodie(***); <-- rock5, is any better way to get char mounted? :) I'm using mount ID atm. -->
yrest(5000);
Code: Select all
Loading profile Default.xml
Testing 'ingamefunctions' macro. If it gets stuck here, please update the 'ingamefunctions
' by copying the 'ingamefunctions' folder from 'rom/devtools' to the games 'interface/addo
ns' folder.
MACRO Test: ok
Ranged skill found: MAGE_FLAME
[DEBUG] CPU Frequency 3135.537
Waypoint files from X:/Programs/micromacro/scripts/rom:
Enter the number of the path you want to use and press Enter > 51
You chose 51
Loaded waypoint path test.xml
Waypoint #18 is closer then #1. Hence we start with waypoint #18.
No return path with default naming test_return.xml found.
We use the normal waypoint path test.xml now.
Moving to waypoint #24, (-16160, 6766)
Moving to waypoint #1, (-16080, 6720)
Moving to waypoint #2, (-16069, 6648)
Moving to waypoint #3, (-16061, 6580)
Moving to waypoint #4, (-16056, 6523)
Forced waypoint type 'TRAVEL' set by user.
Used 201928.
Clearing target.
Moving to waypoint #5, (-16085, 6471)
Moving to waypoint #6, (-16087, 6432)
Moving to waypoint #7, (-16035, 6444)
Waypoint type TRAVEL, we won't stop and won't fight back
Moving to waypoint #8, (-15989, 6435)
Use MACRO: MAGE_ELEMENTAL_CATAL=> Skorpion ┼╗─ůdl─ůcy (4386/4386)
Use MACRO: MAGE_ENERGY_INFLUX => Skorpion ┼╗─ůdl─ůcy (4386/4386)
Use MACRO: MAGE_ENERGY_WELL => Skorpion ┼╗─ůdl─ůcy (4386/4386)
Waypoint type TRAVEL, we won't stop and won't fight back
Moving to waypoint #9, (-15993, 6472)
Waypoint type TRAVEL, we won't stop and won't fight back
Moving to waypoint #10, (-15944, 6487)
Last edited by cufRet8e on Wed Dec 28, 2011 8:25 am, edited 1 time in total.
Re: Ancient Treasures waypoint
That's annoying. setForcedWaypointType doesn't change the Type it only changes the ForcedType of the waypoints. Let me have a look at 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
Re: Ancient Treasures waypoint
No it's ok. When it finds the next waypoint it changes the Type to equal the Forced Type.
I see the problem. You can always count on me to include a typo. It should be "WPT_TRAVEL" not "WPL_TRAVEL". Change That and see if it works.
I see the problem. You can always count on me to include a typo. It should be "WPT_TRAVEL" not "WPL_TRAVEL". Change That and see if it works.
- 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: Ancient Treasures waypoint
So the code I put in to player:checkskills isn't working?
just have
in your profile and it shouldn't use skills while mounted.
Code: Select all
if settings.profile.options.DISMOUNT == false and player.Mounted then return false end
Code: Select all
<option name="DISMOUNT" value="false" />
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
Re: Ancient Treasures waypoint
I see them as being 2 different things. I think by default that it shouldn't try to use skills when mounted if you've set the waypoint type to travel. And if it isn't waypoint type travel then it should not dismount to cast skills unless aggroed. I don't think users should have to set a setting when it should behave this way.
With these default behaviours most people wont need to use your setting. I think it would mainly be useful if users want to override the default waypoint type behavior, ie. if the user wants it not to dismount regardless of waypoint type.
With these default behaviours most people wont need to use your setting. I think it would mainly be useful if users want to override the default waypoint type behavior, ie. if the user wants it not to dismount regardless of waypoint type.
- 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: Ancient Treasures waypoint
Changed in skill.lua:rock5 wrote:No it's ok. When it finds the next waypoint it changes the Type to equal the Forced Type.
I see the problem. You can always count on me to include a typo. It should be "WPT_TRAVEL" not "WPL_TRAVEL". Change That and see if it works.
Code: Select all
if __WPL.Type == WPT_TRAVEL or not player.Battling then
Because it have no difference, in situation like this (I wrote in again, just to clarify):
- running mounted, TRAVEL mode
got aggro from mob
cast MAGE_INTENSIFICATION etc.
got dismounted because of casting
said in terminal window, that it's not going to fight because of TRAVEL mode
continue walking without harm enemies
Re: Ancient Treasures waypoint
Where I should put this code with "if"? Because simply adding DISMOUNT to false does not change anything.lisa wrote:So the code I put in to player:checkskills isn't working?
just haveCode: Select all
if settings.profile.options.DISMOUNT == false and player.Mounted then return false end
in your profile and it shouldn't use skills while mounted.Code: Select all
<option name="DISMOUNT" value="false" />
Code: Select all
We use the normal waypoint path test.xml now.
We changed the option 'DISMOUNT' from 'true' to 'false'.
Moving to waypoint #24, (-16160, 6766)
Moving to waypoint #1, (-16080, 6720)
Moving to waypoint #2, (-16069, 6648)
Moving to waypoint #3, (-16061, 6580)
Moving to waypoint #4, (-16056, 6523)
Forced waypoint type 'TRAVEL' set by user.
Used 201928.
Clearing target.
Moving to waypoint #5, (-16085, 6471)
Moving to waypoint #6, (-16087, 6432)
Waypoint type TRAVEL, we won't stop and won't fight back
Moving to waypoint #7, (-16035, 6444)
Use MACRO: MAGE_ELEMENTAL_CATAL=> Skorpion ┼╗─ůdl─ůcy (4539/4539)
Use MACRO: MAGE_ENERGY_INFLUX => Skorpion ┼╗─ůdl─ůcy (4539/4539)
Use MACRO: MAGE_ENERGY_WELL => Skorpion ┼╗─ůdl─ůcy (4539/4539)
Waypoint type TRAVEL, we won't stop and won't fight back
Moving to waypoint #8, (-15989, 6435)
Re: Ancient Treasures waypoint
Is it possible you have intensification in your onPreSkillCast section of your waypoint?
- 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: Ancient Treasures waypoint
it still used the skill while mounted and profile option DISMOUNT was set to false??
That isn't right.
There must be something else casting those buffs and not the usual bot checking skills.
That isn't right.
There must be something else casting those buffs and not the usual bot checking 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

wiki here http://www.solarstrike.net/wiki/index.php?title=Manual
Who is online
Users browsing this forum: No registered users and 2 guests