As you level up your Roblox development skills, you’ll eventually reach a point where you need your NPCs, mobs, or AI-driven characters to do more than just wander around or follow simple patterns. That’s when structured AI systems like Finite State Machines (FSM), Behavior Trees, and Goal-Oriented Action Planning (GOAP) come into play.
This guide is meant to demystify those systems and help you make informed, professional decisions about how to architect AI in your Roblox games. We'll also touch on non-structured AI, and clarify some common misconceptions in the Roblox community around what an "NPC" or "mob" actually is.
In short: there isn’t much of a difference.
💡 Whether you're coding a shopkeeper or a boss enemy, you're still writing AI for an NPC — even if the model doesn’t look humanoid.
We'll cover four major AI styles:
A Finite State Machine is one of the simplest and most widely used AI architectures — especially in Roblox.