Updating actors on different levels

In many older games, if you enter a building, a new level with its interior will be loaded.
I will base my question on the game: “Harvest Moon”, where such a mechanic was implemented. A new day always starts and ends inside the main house.

Now, how can you for example update the plants growing outside the building? Doing all the calculations inside a GameInstance seems a little bit weird… Is there any better way to achieve this? I thought about level streaming, but the interior and exterior dimensions of the house do not match…

Screenshots of the levels:

if using two separate levels where one is loaded and the other is unloaded, the issue is that the unloaded level ceases to exist when unloaded. this leads me to two possible solutions. first though some assumptions, im assuming that the situation is something like you plant some plants and after each day they are meant to grow a bit.

ok so for the first possible solution you could create a array which contains the pertinent information about each plant (location, growth stage int, class, etc). then you dont really need to worry about the level being unloaded you could instead just spawn the plants back into the level on begin play.

the second solution would be to use level streaming. in this case however you would not have the house level actually in the house mesh you would place it elsewhere such as below the terrain and just teleport the character there. this would allow you to not unload the level which eliminates the issue.

Well, there is a problem with the first solution… It’s unfortunately a bit more complex and requires more than adding a number to the growth stage…

At the beginning, the field is only sown and there is no plant actor.

In this state, there is a small chance of weed appearing on the field, which will prevent the plant from spawning.

Furthermore, the time between growth stages can be reduced by watering the field (by player or rain).

Is it possible to store inside a GameInstance some sort of manager that would handle updates of field and plant data?

Thank you very much ThompsonN13. I followed your advice and I implemented it based on structures and UObjects. Technically, it works, but I don’t know whether my solution is correct/reasonable or not…

The general hierarchy of actors looks like this: a GridActor has an array of FieldActors which have a PlantActor. The data structures are created in the same way: GridInfo has an array of FieldInfos and each FieldInfo stores a PlantInfo (each struct has some more variables).

After each day the GameInstance creates a temporary GridUpdater (UObject) which is responsible for updating the field data. It takes the whole GridInfo structure as parameter. The GridUpdater creates then a temporary FieldUpdater (UObject) and passes each FieldInfo (one by one) to its update function. Finally the plant data is updated after creating a temporary PlantUpdater (UObject) inside the FieldUpdater and executing its update function with the PlantInfo structure as parameter.

My problem is now as follows: I have no idea when (and where) should I write the code to save the structures into my GameInstance. Would the EndPlay function of the FieldGrid be an appropriate place to do this?

He has a very good response to this, I would’ve handled it by using a function that takes in the time passed and simulated the various events taking place, then updating the level with the output from the simulation.