HitsparkInteractive / NinOnline

Public Nin Online Repository for Bug Tracking
GNU General Public License v3.0
1 stars 3 forks source link

Invisible walls randomly in world #71

Closed Su5hicz closed 2 years ago

Su5hicz commented 2 years ago

Problem description

There are invisible walls appearing randomly all over the world map, which seems to be connected to instance housing, not confirmed. This wasn't a problem before but on the clip ill post it blocked off the entire part of the map for many players.

https://user-images.githubusercontent.com/57494027/132516548-2f42c761-e021-4d2d-9126-f21ad78eb51b.mp4

Steps to reproduce the issue

Probably something with instance housing, not confirmed but I'm reporting it anyways since it became a bigger issue.

Observed result

Not being able to pass through tiles.

Expected result

Passing through.

More details

Affected Client Version:

INOCHI CLIENT

First noticed:

After instanced houses became a thing.

Error Logs

View details PASTE HERE
RorySoh commented 2 years ago

Was running into some kind of invisible wall I recorded a few minutes of it before I got past it. https://www.youtube.com/watch?v=Pic5eWaD0Ag

RorySoh commented 2 years ago

We're currently looking into this and hoping players come forward with more information on what causes it. While we have heavy suspicions it has something to do with furniture, we've yet to be able to replicate it reliably, which is the first step to us being able to fix it.

gripzyyy commented 2 years ago

Hi! First of all, I'd like saying that the game is not open source so it is incredibly hard for me to make a guess. Luckily, I have some knowledge about the client, so my guess could me quite accurate.

The client works like this: You press the key to move. The client sends a packet with: direction, x, y, moving bool (probably for moving and running animation?) The client handles the packet, making a prediction based on the dir. If the prediction is right, nothing happens, if it is not, the client will take you to the legal position and S would appear near you.

The movement is actually dir based, not x y based.

From my testing, the S appears when the server and the client are not syncronised regarding the XY of the player. The server inforcing his rules, will actually bring back the player to the legal server position (I guess to stop TP hacks). The S also appears when an illegal movement is made, the server won't process you forcefully sending a movement packet in a dir where a non walkable tile is. The client will predict the movement but it will be quickly corrected the S appearing near you.

So, how can you reproduce this? As I said, moving to an non-walkable tile will make the effect seen in the video. So, to reproduce this effect, I have an idea.

  1. Create an empty map
  2. Mark some tiles as non-walkable on the server (blocked).
  3. Do not send them to the client, so the client will think they're walkable
  4. Move to the tile. The same effect will take place

You can force this effect by also moving the character to a blocked tile (or any tile if you're just manipulating the x and y) using cheat engine or an external tool, then moving legally using your keyboard in game.

So, what are my solutions? There is for sure a desync regarding walkable tiles between the client and the server. Next time this happens, look into all the modTypes.Map.Tile[i, j] and check the i and j tile type for the tiles that have this effect, then check what's on the server regarding their tile type. It can be from map caching or a lot of other stuff. Maybe the server is sending incorrect data about some maps. Maybe the server is making somewhere a mistake at the check for illegal type inside the server. I can not comment on how the server works, I can only make guesses regarding what happens on the client-side. A lot of debugging is needed to see where the mistake is and to pinpoit if there's a desync between modTypes.Map and the server.