Shells, interiors not loaded when players connect

Hello,
I’ve been making a property system lately and I’ve used some shells for the houses’ interior made by K4MB1
But I’ve faced a problem when players log in after logging out from game inside their houses, they fall into the ground without any interiors or shells loaded up.
Can anyone suggest a fix or something that can make these shells load not only when they enter the house. I think something has to do with instance too? the housing system uses it.

Hi,

You need to recreate the instance upon connection. Therefore you’ll need to store whether or not the player disconnected in an instance, and then create the instance when the player connects. (Freeze the player first and wait for the interior to load, so that the player doesn’t fall through the floor until the interior is fully loaded.)

for now, I’m just creating the instance when the player enters a house and deleting it when he exits it. Shall I add the check if player is inside house in the playerDropped event? even if that’s a client event?

You should do that server-side. Store the information into a database, then upon connection, load the data and recreate the instance.

I’m already doing it server-side. So, you think Database is the right way to go?
Can you show me some code snippets on how to detect if player disconnected server-side, what to use for detecting if player inside house? variables ( set them to TRUE when he enters and vice-versa ) or detect if player in range of the instance x,y,z?

Unfortunately, I’m not at my computer right now but the easiest way to do it would probably be updating the user’s last instance in the enter event, then removing the user’s identifier from the instance’s data when exiting the instance. If the player’s identifier is found in the table when connecting, (that means he hasn’t left the instance before disconnecting) create the according instance.

Alright. Thanks, I’ll try my best!