EQ2Interface

EQ2Interface (https://www.eq2interface.com/forums/index.php)
-   Request (https://www.eq2interface.com/forums/forumdisplay.php?f=25)
-   -   Autoattack timer (https://www.eq2interface.com/forums/showthread.php?t=11124)

ananigma 11-14-2008 04:16 PM

Sorry if you already covered this but all it seems that you need to do is...

Create a Progress Bar that starts when an auto attack is triggered whether it lands, misses, etc. Very similar to the progress that bar that starts when you cast a Spell or Combat Art. Then have that progress bar determine it's length based on the delay of your auto attack. If you can create both that should work and you won't have the issues you are discussing such as lag, being out of range, and so on.

So basically...

You autoattack: Progress bar timer starts based on current delay and does not reset until the next autoattack is done. Not an infinite loop which reads your delay because weapon delays will change, auto attacks can be delayed, and lag can cause the timing to be off.

I am not a coder so I have no idea if this can be done or how it would be done. Wish I did because this would be a very helpful addition. However this seems to be the only way to do this and have it still be accurate.

Good Luck. :)

Landiin 11-14-2008 05:17 PM

Quote:

Originally Posted by reins (Post 77226)
Coming from a pvp server where targets move out of range all the time, ya i'm positive that being out of range does not consume the auto attack.

Try it with a bow, move to absolute max range then back out a bit. (You can tell by the shading on the ranged auto attack button). Toggle on ranged auto attack then step into range, it should fire immediately.

I'll try it with a ranged weapon tonight but I know it consume it for melee else I wouldn't of been able to walk up to the mob with AA on and not hit it.

samejima 11-15-2008 02:17 AM

Ranged auto attack and melee auto attack share the same timer bud, for the record hes right being out of range does not consume an auto attack. But you guys could code a UI that thought it did, it would be fun to see :D

Landiin 11-15-2008 02:59 AM

Ranged seems not to consume a AA, every time I would step in range it would shoot. That was not true for melee AA though. when I would see the OOR msg i could go and stand by the mob and back out and get the OOR msg again with out ever hitting the mob with melee. Maybe my timing is just to good in melee but I doubt it.

Drumstix42 11-15-2008 04:42 AM

Sure you're not just missing? :p Just kidding.

Landiin 11-15-2008 10:03 AM

I knew someone would say that, that is why I did these test on mobs 60+ levels below me. :rolleyes:

gm9 11-15-2008 10:39 AM

So either Landiin and Aditu or reins and razieh are auto-attack noobs like me? I guess either way I'm in good company then. Hope you guys figure it out. :)

Landiin 11-15-2008 11:19 AM

<- Noob for life!

dragowulf 11-15-2008 11:30 AM

Quote:

Originally Posted by Landiin (Post 77245)
<- Noob for life!

QFT 123456

samejima 11-15-2008 03:13 PM

Quote:

Originally Posted by gm9 (Post 77242)
So either Landiin and Aditu or reins and razieh are auto-attack noobs like me? I guess either way I'm in good company then. Hope you guys figure it out. :)

Why am I a noob sir!! :( I'm disagreeing with you guys! Yes it does give an out of range message but its easy to tell it doesn't consume the auto attack. Put on a weapon with 5 second delay or more and watch how fast the message spams. Its every half second or so, also you can easily tell that you instnatly swing when you go back into range.

dragowulf 11-15-2008 03:54 PM

Well after discussing with Rothgar, I can only say that I understand the auto attack mechanic much less.

samejima 11-15-2008 04:00 PM

Its not very complex. I don't understand why you would be confused especially if Rothgar explained it to you.

Edit: also I am an ultra cool sea turtle now :D

ananigma 11-15-2008 04:07 PM

There is ONLY one source that tells you exactly when you autoattack. That is your log file. The question is can you create a mod that reads a .txt file?? ACT does so I see no reason why not.

Razieh said:

1. It does not automatically loop in any facet

Of course not but if it is coded for the progress bar to start when an autoattack hits. It would be dumb to make it loop. Clearly this isn't the case because his progress bar doesn't restart until he autoattacks again.

2. It only restarts when an auto attack hits

Your log file tells you exactly when you autoattack. There has to be a way to make a mod that works like ACT's Double attack Plugin only on a UI mod. So instead of hearing "beep", the progress bar restarts.

3. I didn't use your timer codes as a base at all

Clearly not.

As far as being OOR/Stunned, this is completely mute if done right. You don't autoattack if your out of range. Thus the progress bar can not restart. Razieh stated his progress bar starts and doesn't restart unless a autoattack has occured.

So if you can create a Mod that reads your log file (.txt file), then create a regex that states when you autoattack. Your can use that regex to trigger a progress bar that will indicate when your next autoattack is due. To get the right timing for this, you already have DD: /Gamedata.Stats.*_Delay. If you can turn this DD into a timer for the progress bar. You now have a precise progress bar for every single attack regardless of whether your weapon delay changes. You can also use DD:/Gamedata.Self.Autoattack or /Gamedata.Self.Ranged to determine which weapon you are using and calculate the correct delay and bring up the right progress bar.

Damn I wish I was a coder because it can be done.

Drumstix42 11-15-2008 04:15 PM

There's no function in the UI to "read" any kind of file. So... Maybe with external programs like ACT it can be done.

dragowulf 11-15-2008 04:25 PM

Quote:

Originally Posted by samejima (Post 77252)
Its not very complex. I don't understand why you would be confused especially if Rothgar explained it to you.

Edit: also I am an ultra cool sea turtle now :D

It was sarcasm. :p

Oh and I've been a griffon for years.


Quote:

Originally Posted by Drumstix42 (Post 77254)
There's no function in the UI to "read" any kind of file. So... Maybe with external programs like ACT it can be done.

I'm not sure it would require an external program. Maybe. I'm sure it can be done without the use of a log file.

samejima 11-15-2008 04:29 PM

Griffons are lame imo! Zebras are where its at!

ananigma 11-15-2008 04:38 PM

Ok not the UI, a mod or XML file.

But can a XML file read a log (.txt) file?

Drumstix42 11-15-2008 04:58 PM

There are no "Mods" to the game. Anything going on is through the UI. It's written in XML but has many limitations with the game.

ananigma 11-15-2008 05:24 PM

Hmm...

So can an XML (even 3rd party) read your log file and use something in that file to start a time bar (like Mother's countdown timer window) on your EQ2 screen?

If not, what is stopping this?

This is just an idea but i dont understand why it wouldn't work.

*Write a code that reads you log file like ACT does.
*When it sees that you autoattack it sends a trigger to a progress bar (not necessarily EQ2 casting bar but something similar to Mother's or whatever).
*The timer is set using the DD stated above to give an accurate countdown.

Maybe I am not clear in my explanation, I dunno. To me this would work perfectly if this can be done. If not, can you explain what would keep it from working?? :confused:

I don't mean to pyre. I would like to figure this out as well. :)

Drumstix42 11-15-2008 06:48 PM

Far as I know with the functionality of Mother's timer windows is that the UI itself is setting the countdown and starting it.

There's no way to directly communicate with the UI outside of the UI. The only exception to this is displaying webpages in the in-game browser.

So if you wanted to code up some web browser countdown bar... lol. I can't see that being very useful due to lag of the log file being read, and then displayed on screen...

I don't think the log file is a very good way to go. Even 1 second of delay makes it pointless, IMHO.

EQAditu 11-16-2008 04:08 AM

1 Attachment(s)
This piqued my interest, so I thought I would actually test things out. I'm fairly certain that the OOR messages work differently than I remember they did in EoF beta when I did my tests last. Not really doing a study on it, they seemed to trigger 1-3 times a second at irregular intervals. Somewhat strange.

Anyhow, I used a little tool that I already had which was a long abandoned "Swing Meter" plugin for ACT.

Using a 4.0s weapon, it more or less correctly swings each time... though it's oddly early a lot. Could be rounding on the number EQ2 reports plus lag or something... it doesn't matter.

Anyhow, if being out of range fully consumed an auto attack, the purposely late swings would always be late in a multiple of ~4000ms. Clearly that's not the case, but it's strange how often it would be be late around the same amount each time. I certainly didn't attempt to do that. So it would seem that being OOR only partially consumes an auto attack but coming into range is not an instant attack either.

I think I mentioned this somewhere else, but I'll do so again here. A swing meter like the plugin I abandoned long ago has two major drawbacks. To be accurate with haste, the log file would have to be populated with haste or weapon delay pretty often. I suppose you could set up a chat channel that you cannot see to supply this information to ACT, but it's messy no matter what. Secondly and most importantly, ACT cannot tell the difference between two weapons of the same type. This would make it useless for anyone dual wielding with two piercing weapons for instance.

dragowulf 11-16-2008 06:08 AM

I've been thinking. All OOR/Stun/etc things aside. We can make this mod as progress bars by using a similar method as mother's timer window, correct?

If so:

Make it so that when an aa/rangedaa occurs, it takes the delay of the weapon and sets the auto attack progress bar timer.
Ex:
1. Auto-Attack occurs and sets the timer to true
2. The timer uses the 5.3 delay and counts down
3. The auto-attack is turned off and the timer sets to false


We could make it so whenever a CA/spell is used and the casting window is visible, the timer is delayed. Whenever the casting window is no longer visible, it starts the timer again.
Ex:
1. stopautoattacktimer if {mainhud.casting.visible=true}
-Casting window's onshow=parent.stopautoattacktimer=true
2. startautoattacktimer if {mainhud.casting.visible=false}
-Casting window's onhide=parent.startautoattacktimer=true


I'm not sure how this part could work out but..whenever the Out of Range Message occurs, it delays the timer untill the message changes???? EDIT: I'm completely unsure about this one
Ex:
1. OnScreenMessage onshow=if {MessageText.text='out of range'} then stopautoattacktimer=true
2. OnScreenMessage onhide=if {MessageText.text=''} then startautoattacktimer=true


Any thoughts? I'm also unsure of how it would be if you enabled auto attack on an unattackable npc because the timer would start.

EQAditu 11-16-2008 06:25 AM

Quote:

Originally Posted by dragowulf (Post 77295)
I've been thinking. All OOR/Stun/etc things aside. We can make this mod as progress bars by using a similar method as mother's timer window, correct?

It's still obvious that I'm somewhat new at UI modding because I didn't know you could even create timers with a better resolution than whole seconds. I was just using movement effectors though.

Quote:

Originally Posted by dragowulf (Post 77295)
If so:

Make it so that when an aa/rangedaa occurs, it takes the delay of the weapon and sets the auto attack progress bar timer.
Ex:
1. Auto-Attack occurs and sets the timer to true
2. The timer uses the 5.3 delay and counts down
3. The auto-attack is turned off and the timer sets to false

I'd think you would need to recalculate often, so probably as often as the casting bar toggles visibility off. (Before the timer starts)

Quote:

Originally Posted by dragowulf (Post 77295)
We could make it so whenever a CA/spell is used and the casting window is visible, the timer is delayed. Whenever the casting window is no longer visible, it starts the timer again.
Ex:
1. stopautoattacktimer if {mainhud.casting.visible=true}
-Casting window's onshow=parent.stopautoattacktimer=true
2. startautoattacktimer if {mainhud.casting.visible=false}
-Casting window's onhide=parent.startautoattacktimer=true

Quote:

Originally Posted by dragowulf (Post 77295)
I'm not sure how this part could work out but..whenever the Out of Range Message occurs, it delays the timer untill the message changes???? EDIT: I'm completely unsure about this one
Ex:
1. OnScreenMessage onshow=if {MessageText.text='out of range'} then stopautoattacktimer=true
2. OnScreenMessage onhide=if {MessageText.text=''} then startautoattacktimer=true

I don't believe that auto-attacks make use of that UI piece. Casting a spell on an OOR target would, but auto attack doesn't.

Quote:

Originally Posted by dragowulf (Post 77295)
Any thoughts? I'm also unsure of how it would be if you enabled auto attack on an unattackable npc because the timer would start.

That would be a temporary problem as the bar would start too soon and would remain unsynched until the casting of a skill delayed the bar from restarting until the actual auto attack delay had been met.

dragowulf 11-16-2008 08:03 PM

Well I'm sure that this way would work, but I'm not exactly sure if it would be the easiest.

EDIT: Attachment removed, check above^^^^^^^^^^^^

dragowulf 11-17-2008 12:16 AM

1 Attachment(s)
Well it does work, I used movement effectors.
This is pretty much what I've came up with for the movement effectors to work:
Code:

SpeedCalc=350/(Parent.Parent.PrimaryDelayValue.Text)
Parent.Parent.MoveRight.Speed=SpeedCalc ## &apos;,0&apos;
Parent.Parent.ProgressPage.ProgressTimer.Visible=false
Parent.Parent.ProgressPage.ProgressTimer.Visible=true

5.0=PrimaryDelayValue, 350=TimerBarSIZE...
To put the above code in simpler terms: 350 divided by 5.0 = 70.000, which comes out exactly to 5 seconds. (if the weapon delay was actually 5.0, but works with any number)

Only thing I'm unsure of is how to make it continuous. If we get something from Rothgar telling us when an AutoAttack occurs, my code would work almost perfect.

How Raz managed to get around that problem? I have no idea.:confused::confused::confused:


All times are GMT -5. The time now is 05:26 AM.

vBulletin® - Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
© MMOUI