Justice, the awesome NPC system

Sweet system, although i do have a question. How do you remove the dots indicating where the NPC will be going to?

I do plan on implementing this into my game and i just wanted to know how to remove the pathfinding dots.

Thanks! :slight_smile:

EDIT: I just set the transparency to 1 where you make the pathfinding marker instances.

The dots are only gonna be showing when you’re in the studio.

2 Likes

Quick question, why are my NPCs stuck like this?


Any help would be wonderful. Thanks @apoaddda

I think running many npcs without debug mode could actually have better performance anyway. That should be it?

Sadly it doesn’t run in studio or the Roblox Client. Here’s the settings:

---------------------------
-- Justice Configuration -- 
---------------------------

return {
	count = 20, -- The amount of NPCs you want to generate
	movementTimeout = 3, -- How long the NPCs can be stuck for before they give up and go to another target
	maxDawdlingTime = 5,  -- How long the NPCs will dawdle in an area before they select a new target
	canCollideWithNPCs = false, -- If NPCs can collide with each other
	canCollideWithPlayers = false, -- If NPCs can collide with players
	discriminators = { "male", "female" }, -- How NPCs will be unique (e.g. gender, race, etc.)
	origin = CFrame.new(25.63, 279.603, 132.32), -- The spawnpoint of the NPCs
	logging = true, -- If logging should be enabled.
	nameGenerator = function(i) -- The function used to generate names for the NPCs.
		return "Intern " .. i
	end,
}

Did I do something wrong? I haven’t messed with anything else.

Hey there! I also use the same NPC system for the last couple of months, and from my experience, whenever NPC’s are just frozen its either you don’t have any destination for them to go to or that you probably messed something up from the main script.

Would a bunch of meshparts and parts spread across multiple floors break the system?

If you haven’t tagged them it might be screwing up the pathfinding.

No I sized up a couple of parts and tagged them using the tag editor plugin… does it matter if can collide/touch is on/off?

This is great, I am using it in my team’s upcoming game since I don’t want to script a whole another library for this task.

This seems amazing, is it possible though to spawn a mass amount of npcs with each being in a random location?

Definitely gonna use this in some new projects! Really cool stuff!

also that drawing at the top is really good!

Why are my NPC’s bugging like this?

1 Like

I’m not sure, I only have a flat floor and designated area for them to walk around to, and from what I found out, they need to have at least ~20 studs wide of a hallway in order for them to go to a destination.

It is possible to spawn a bunch of NPC’s at random locations, however you would need to script it yourself.

I would consider using this but I’ll wait till a official model comes out.

@lewisakura Would there be any reason why the module would be bugging in such a way? The part for the NPC’s to move in is 200x800x20. Would there be any reason why the cannot move?

That looks like they can’t pathfind beyond that area. Do you have any invisible barriers or whatnot?

There are some invisible walls, nothing confining them to that area though. Most of the map is made from mesh parts if that would cause any issues, thanks in advance, apoaddda.

Works great for me. Just tested it with 700 NPC’s. The only thing bugging me is figuring out how to hide the dummy template. Everywhere I stash him, the script breaks.

2 Likes