New NPC manager system
Added 2021-10-16 09:42:46 +0000 UTCTesting the new npc manager system, everyone knows how bad is the current npc system on the 5.4, in fact the previous system wasn't meant for a open world game, with that in mind i had to remake it, and i'm pretty happy with the result, now it's perfect for open world games.
It now can have 40 live actors on screen in stress situations and 2x that running on background(can go higher with more optimization), it has many spawn configurations like what type of npc to spawn, the limit of npcs in screen, the distance to spawn, if it's in a city it will spawn closer to player.
It also have restriction based on zones, inside a city npcs will only spawn on specific zones, these zones can have a second layer of configuration, like different zones for the same city, 1 zone will only spawn poor npcs, another zone only rich npcs, in another one only gangsters an so on, this is being set by the inventory, each zone can have a preset of items and general npc features like factions civility gender and so on.
The spawner can also spawn npcs on different floors, since i'm planning interiors for buildings.
Another good thing is persistence, by default when npc spawn if you go 500m of distance from it will go on idle state it will stop moving and enter persistence mode, the way if you get near it again it will resume his schedule, if you go beyond 500m it will despawn completely, but if you talk to the npc the distance will quadruplicate meaning you can talk to an npc, leave the city and when you get back the npc will be there "waiting", when i add combat, i will improve this feature, like if you attack a monster or npc it will have infinite persistence this way if you attack an npc and you can't kill it you can come back later to finish the job.Testing the new npc manager system, everyone knows how bad is the current npc system on the 5.4, in fact the previous system wasn't meant for a open world game, with that in mind i had to remake it, and i'm pretty happy with the result, now it's perfect for open world games.
It now can have 40 live actors on screen in stress situations and 2x that running on background(can go higher with more optimization), it has many spawn configurations like what type of npc to spawn, the limit of npcs in screen, the distance to spawn, if it's in a city it will spawn closer to player.
It also have restriction based on zones, inside a city npcs will only spawn on specific zones, these zones can have a second layer of configuration, like different zones for the same city, 1 zone will only spawn poor npcs, another zone only rich npcs, in another one only gangsters an so on, this is being set by the inventory, each zone can have a preset of items and general npc features like factions civility gender and so on.
The spawner can also spawn npcs on different floors, since i'm planning interiors for buildings.
Another good thing is persistence, by default when npc spawn if you go 500m of distance from it will go on idle state it will stop moving and enter persistence mode, the way if you get near it again it will resume his schedule, if you go beyond 500m it will despawn completely, but if you talk to the npc the distance will quadruplicate meaning you can talk to an npc, leave the city and when you get back the npc will be there "waiting", when i add combat, i will improve this feature, like if you attack a monster or npc it will have infinite persistence this way if you attack an npc and you can't kill it you can come back later to finish the job.
youtube post: Zv5G5l0UaBo