Really weird range issue

12/30/2011 16:23 Kiyono#1
I think it's easiest to just use images to show the problem:
[Only registered and activated users can see links. Click Here To Register...]
As you can see, the monsters are hitting me but upon death the server and client suddenly synchronize and I literally get teleported to different coords and it's as if I had been there all the time.
[Only registered and activated users can see links. Click Here To Register...]

It is as if I'm in a different spot serverside, however, this can't be true since I made the console output the X and Y coordinates whenever I moved and they always matched but when using a skill such as fastblade it's get really obvious that server and client side positions don't match. Another example is that when you log in 2 characters and move, on the other client the client will stay in the same place until you teleport away or logout.

I used the Project Manifest source and am currently on patch 5017, just to be clear; I didn't even touch the range system.
12/30/2011 16:32 Korvacs#2
Does it happen if you run around and dont jump and vice versa.
12/30/2011 17:31 Kiyono#3
Quote:
Originally Posted by Korvacs View Post
Does it happen if you run around and dont jump and vice versa.
Ah, just tested a bit and it seems to only affect walking.
I logged in with 2 clients, say A and B.
A and B log in and can see each other.
If you jump with A and then quickly switch to B, you can still see A jumping and it properly updates.
If you walk with A and then quickly check B, you will not see A move.
If you are positioned in such a way that A is 1 pace below B and then move A down with let's say 20 paces using walk. B will not see it. If you then jump somewhere using A and then check B, the client will display A making a huge impossible jump resulting in disconnecting.
This issue also affects monsters, they can move towards you but their position will not update
12/30/2011 18:09 Korvacs#4
Your most likely sending the walk packet back to the client that sent it or not sending it locally or something like that.
12/30/2011 18:14 Kiyono#5
Why would that happen? It worked when it was still on 5135 and I didn't really do anything to it.
12/30/2011 18:19 Korvacs#6
I have no idea why that would happen, maybe you made a mistake somewhere :s
12/30/2011 18:33 Kiyono#7
Well that was stupid, on the packet wiki it says that the values for the walk packet are in this order:
short size
short type
int id
byte direction
bool speed
int timer for higher patches

The 5135 Project Manifest had it like this:
short size
short type
int direction
int id
bool speed
int timer

I only removed the timer and didn't see that they switched around the id and direction values (according to the packet wiki, it's always id first and then direction on all patches so I didn't bother checking it but for some reason 5135 switches them) and for no reason whatsoever changed byte direction to int direction which was apparently giving me the problems.
12/30/2011 18:38 Korvacs#8
Ah well atleast it was a simple fix.