Hostile / Enemy system

My laptop is currently away for repairs at the moment so this is primarily conceptualised.

My current project: OuterOcean is a game set in space with multiple Planets // locations that are visit-able.

My issue is, the locations are heavily Client-Based. Meaning the location // area only loads if needed by the specific Player…

I’m working on ways to implement a hostile system into these locally generated areas that can be effective.

Currently a method I’ve trialed is:
Server-sided system that detects when a Player is close to a spawner; if so, then an NPC will spawn and the :SetNetworkOwner is set to the nearest Player.

Explanation

This is incase a Player leaves the game or area. This method also prevents the NPC from falling through the client generated area.

The issue with this is, Players outside the areas will undoubtedly be able to see a hovering NPC.

Does anyone have suggestions or methods they use for similar games?

Thank you!

Have it so the sever links the npcs with the player and if they leave just despawn em

1 Like

Thanks, but is this not a similar method to the one I already use?

despawning them will well it will despawn them no hovering duder

Sorry - I don’t quite understand.

My method works using Magnitude to detect whether or not a Player is nearby prior to spawning.

delete the mobs if to far away.