Hi this is my first module (more a modification of PlayerScriptsLoader) i’m sharing with the community. It’s a module that allows test players whose id is less than -1 will be controlled by basic AI.
I’m releasing this so people can give feedback and what other types of AI behaviors they want to be implemented (Through you can always edit the code yourself for your own game).
Just do note, this is mostly made for Studio in mind but you could also use it to test out how let’s say pvp would work inside of studio directly.
There currently 3 AI modules, each have their unique behavior:
SimpleWander
Which basically makes the bot wander to a random point on the map (if pathfinding is enabled, it will also calculate a possible path before moving)
SimpleFollow
Makes the bot follow the player with user id of -1, that’s it.
SearchAndDestroy
Makes the bot seek out the nearest target (can be NPC or Player)
As of now, you can simply require() the model with the assetId using Studio’s Command Bar
Just make sure to remove the previous versions
Configuration
You can find configuration module within the model itself.
Known Bugs
SearchAndDestroy seems to not work, looking into it. (Fixed)
Latest Updates
1.0.1
* Fixed an issue with Search and Destroy behavior. Special thanks to @Juicy_Fruit on DevForums!
* Changed how FOV and targetting is handled
* Improved SearchAndDestroy behavior module’s codebase
Sounds like a cool idea! Is it possible to randomly equip tools and activate them via Tool:Activate() and Tool:Deactivate()? It would be a good feature to have for tool integrity checking.
Pretty sure i had the idea of bots equipping a tool if there is one in Backpack and simulate a click using Activate(), i’ve have no idea why it doesn’t work correctly. Will take a look sometime
I know you wanted feedback so just wanted to say that I can’t stress enough how effective and easy to use this module is–to learn from and to apply it to actual npcs, it helped jumpstart my development on a ai gun bot system
while its no where near done, I got a lot done since the last 24 hours from 0 knowledge of AI.