EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Support::Windows Servers (https://www.eqemulator.org/forums/forumdisplay.php?f=587)
-   -   Synchronizing packet updates (https://www.eqemulator.org/forums/showthread.php?t=39731)

Coenxai 06-05-2015 11:20 PM

Synchronizing packet updates
 
Has anyone successfully synchronized character vitals? I'm sick of the server and the client fighting. When does the client begin to tic? Is it when the character successfully connects to the zone? Would it be possible to start our timers then?

image 06-06-2015 09:03 AM

This seems to be two problems
1) the timing of client/server with the HP
2) the server having the correct amount of HP

item #1 I still see fluctuation in my hp up and down, #2 I don't have, but originally there was a bug around this (Don't know if eqemu main source is fixed either).

To add in regards to when the timer starts I would assume it would be around either the end of client loading or when the screen begins rendering (client does send an opcode, but eqemu doesnt track it). This would probably require disassembling the client to be sure.


Pretty easy to test #2 just buff yourself, add equipment and watch #showstats, make sure you arent off by a few hp here and there (ignore the fluctuations of the HP just make sure the #'s are right).

Coenxai 06-06-2015 12:52 PM

Problem #2 isn't really an issue because we can easily modify the client's BaseData to match the server. Unfortunately, they seemingly hard-coded the assumed regeneration. I have it updating virtually seamless now (RoF2). It's still pushing values onto the client, but it's a lot more logical now. I'd still be interested in a more efficient approach if anyone has any information.

demonstar55 06-06-2015 01:58 PM

I think it's spamming too many HP updates (If I remove the sending HP to self in SendHPUpdate my HP stays correct)

demonstar55 06-06-2015 05:58 PM

I pushed some stuff to try to cut down on spam of useless HP updates and also prevent sending it to the client when it will use the OP_Damage packet to update it's own HP.

Still need to get HP regen right though :/

Coenxai 06-06-2015 06:48 PM

Code:

                        SendHPUpdate(!iBuffTic); // the OP_Damage actually updates the client in these cases, so we skill them
        }        //end `if damage was done`

        //send damage packet...
        if(!iBuffTic) { //buff ticks do not send damage, instead they just call SendHPUpdate(), which is done below

?

demonstar55 06-06-2015 07:05 PM

The comment on line 3700 isn't really true, the SendHPUpdate is done above, the message is done below. I also didn't proof read my comments added to 3696, oh well. Should read skip not skill.

But other than that, what are you confused about?

Coenxai 06-06-2015 07:20 PM

The commenting was confusing. Also, how would damage over time spells update? Are they not sent through CommonDamage?

demonstar55 06-06-2015 07:47 PM

That's what the comments say. I haven't checked live.


All times are GMT -4. The time now is 09:55 AM.

Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.