[Bug Report] NPC/vehicle issues when using virtual worlds
#1

EDIT: this post has been edited in order to explain better what's going on.

Okay, basically there is a streaming fail when using virtual worlds. I could reproduce this bug with two different ways. Before anything, assume all objects have been downloaded and we're relying on the cache.

Method #1 (usually happens when reconnecting to a server)
A real player reconnects, we set his virtual world to 1 in OnPlayerConnect and we set the spectate mode for him in OnPlayerRequestClass (called after OnPlayerFinishedDownloading).

Now, in virtual world 0, we connect a NPC and when it spawns we create a vehicle in order to put the NPC as driver.

Alright, if now we set NPC's and vehicle's virtual world to 1, they don't stream for the real player! Notice how in the next video OnPlayerFinishedDownloading isn't called when the player connects.

Method #1 video here.


Method #2 (happens always)
This method is very similar to the first one, but changing a little bit the order. So we connect the real player, we set the virtual world to 1 and we put him into the spectate mode.

Now we connect the NPC and we set its virtual to 1, it should stream for the player (sometimes if you're just reconnecting without leaving the game it doesn't). We create a vehicle, but surprise: it doesn't stream for the NPC, but just for the real player!

So there is no way to put the NPC in the vehicle.

Method #2 video here.


CONCLUSION
Seems that OnPlayerFinishedDownloading is not being called sometimes when reconnecting, maybe that's what causes these bugs, Kalcor said once: "players won't stream anything until after OnPlayerFinishedDownloading is called". Alright, that might explain the bug, but OnPlayerFinishedDownloading is being called when using the 2nd method to reproduce it.
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)