WarcraftReamls.com
  FAQFAQ    SearchSearch    MemberlistMemberlist    UsergroupsUsergroups   RegisterRegister 
  ProfileProfile    Log in to check your private messagesLog in to check your private messages    Log inLog in 
MountFiend.. Remount->Catchup->Charge - Could this be

 
Post new topic   Reply to topic    WarcraftRealms.com Forum Index -> Other Mods
View previous topic :: View next topic  
Author Message
Stom



Joined: 06 Sep 2005
Posts: 3

WR Updates: 0
Stom WR Profile

PostPosted: Tue Sep 06, 2005 12:26 am    Post subject: MountFiend.. Remount->Catchup->Charge - Could this be Reply with quote

First of all, hello to everyone on the forum..

Second of all, THANKYOU Rollie for the mod that I spent the last hmm.. 2 weeks searching for! quite why this isnt a better known mod in the community I will never ever know - absolutely brilliant!

Now onto my question..
Like everyone, when you get exactly what you want in a mod (i.e Dismount-Charge in my case) you then think hmm.. hmm.. wouldnt it be cool if it could do this too..

Basically the mod is perfect as it is so I dont know if it needs this, but I would find it handy i suppose (especially against faster on foot characters than me that are out of charge range!)

At the moment when I target an enemy and I am dismounted it casts my 'charge' ability so long as the target is in range. What I am wondering is that would it be possible to add a check of some sort to see how far the target is away from your character, if the target is say 30ft (I am unsure how distance measurements work in WoW) then instead of it trying to cast the 'charge' ability it will remount again instead so that I can 'run' after the target and 'dismountcharge' again once in range.. (obviously, this would be over ridden in battle by just moving if you wanted to go after the target on foot)

Any ideas if this is possible? I guess it depends purely if range checking is available, and then of course the know how to put it together! Thanks for the GREAT mod and I hope to hear from someone with the knowledge.. Wink
_________________
'Hack' on Turalyon Euro Server - For the Horde!
Back to top
View user's profile Send private message
Rollie
Site Admin


Joined: 28 Nov 2004
Posts: 5374
Location: Austin, TX
WR Updates: 480,131
Rollie WR Profile

PostPosted: Tue Sep 06, 2005 8:38 am    Post subject: Reply with quote

Range is not available in the API anymore. You can however determine if you are in range for an ability or spell to work. If you wanted to set it so if you hit the button it will either charge your target if within range for charge, or mount, it could be done, but would require quite a few changes.
Back to top
View user's profile Send private message Visit poster's website
Stom



Joined: 06 Sep 2005
Posts: 3

WR Updates: 0
Stom WR Profile

PostPosted: Tue Sep 06, 2005 9:25 am    Post subject: Reply with quote

Rollie wrote:
Range is not available in the API anymore. You can however determine if you are in range for an ability or spell to work. If you wanted to set it so if you hit the button it will either charge your target if within range for charge, or mount, it could be done, but would require quite a few changes.


Ok, thanks very much for the reply anyway Smile shame that the range function isnt availlable anymore as that would have made it ideal for doing what I was after - makes it seem a bit pointless doing it though if the target is only just out of range for the charge and it starts it trying to mount up...

How would i code something like that to happen though? I guess that the Charge 'spell' (or whichever ability) gives a error back which could be passed to a 'then' command to start the mount proceedure? (infact, could this in-effect be used to remount again when out of combat?)

I hate asking this, but if you have any ideas how to code this into your addon would you be able to tell me what to put and where? other than looking through other peoples addons (and yourselfs) I dont have a clue where to start coding :/ (is it really that hard for a total noob to work it out? I get what some of the commands mean)

I suppose that if you are casting an ability like charge, getting it to remount on fail would be pretty useful anyway (after all, pressing forward would cancel the mount attempt I think)
_________________
'Hack' on Turalyon Euro Server - For the Horde!
Back to top
View user's profile Send private message
Rollie
Site Admin


Joined: 28 Nov 2004
Posts: 5374
Location: Austin, TX
WR Updates: 480,131
Rollie WR Profile

PostPosted: Tue Sep 06, 2005 10:10 am    Post subject: Reply with quote

I am not sure of the exact syntax, I just know that people have been able to determine if an ability can be used. I'll have to do some poking around if I get time and I'll get back with you. You might post in the UI forum on the WOW boards and someone more in the know will probably be able to answer your question rather quickly.
Back to top
View user's profile Send private message Visit poster's website
Stom



Joined: 06 Sep 2005
Posts: 3

WR Updates: 0
Stom WR Profile

PostPosted: Tue Sep 06, 2005 12:16 pm    Post subject: Update No.3 Reply with quote

Ok then, thanks for that Rollie...

Just to check that I am looking at the correct section of the MFiend.lua file is this where I should be adding the information as what to do if the ability can not be used?
Code:
      --  first let's check to see if we are in combat

SNIP      

      elseif( g_AbilityID ~= -1 ) then
         CastSpell( g_AbilityID, 1 )
      end   
   end   
end


(the Castspell bit)

I know that an ability can not be used if has just been used and has a countdown before you 'fire' it again (charge has a 15sec cooldown time) which would stop it working. So long as I am not targeting any enemy the 'charge' fails with 'Nothing to Attack' so I guess that I need catch that to do it perhaps?

I will post onthe WoW (euro) forums about this and see if anyone can come to my help.

Other than that, thanks for the help so far (I still dont have a clue how these commands work, although I am getting a slightly clearer picture by comparing your commands to the ones on wowwiki)

Cheers, if by soome miracle I manage to get it to (look out for flying pigs when that happens! Wink ) I will post the LUA I edited up here for others to see and perhaps use..


edit...
Just thinking again and suddenly thought it might be easier than this - IF I have no target selected would it be possible to make it skip straight past the charge part and back to the remounting bit again?

i.e Press once, demounts, press again charges enemy, kill enemy, get out of combat and have no target selected, press the button again and it checks to see if I have a target selected, If I have no target start remounting (of course, if i have another enemy target selected it carries on and charges that one)

Would this be easier to do you think, basically adding some sort of thing to say are you targetting? if not remount?

It would be great by the way if you could let me know which bitof the Lua I should be looking at to add this into...

Edit 3
Ok, I have got it working in a 'bodge' kind of way at the moment purely by making a macro in WoW which has

Code:
/mfiend
/script UseContainerItem(4,8)



in it, so that if I have a hostile selected and I am dismounted it will charge, if its a friendly it will refuse to charge (and use the container item for my mount) and the same if I have no target selected..

Not the prettiest way of doing it, but it works Smile (and well... that poor alliance NE couldnt run way fast enough once I got my mount out and charged him using this Wink )
_________________
'Hack' on Turalyon Euro Server - For the Horde!
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    WarcraftRealms.com Forum Index -> Other Mods All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
WarcraftRealms.com  


Powered by phpBB © 2001, 2005 phpBB Group