TinyKeep is an upcoming action roguelike game with procedurally generated dungeons, emergent monsters, deadly traps and mysterious secrets.

Post news Report content RSS feed TinyKeep's AI System (Part 2 of 5)

Learn how TinyKeep's AI handles monster retreat and defensive behaviours! Also a brief mention on the minor improvements over Part 1 - thanks to community feedback.

Posted by on

Before I crack on to Part 2 (Retreat and defense) I would like to quickly cover the minor improvements we made since Part 1 of this AI series. Thanks to community feedback we've added a few more features, removed others and hopefully will have created more realistic behaviour.

In short, the changes are:

1. If the Skeleton loses sight (raycasting towards hero) and smell (raycasting towards dropped breadcrumbs), he will still continue to head towards the location where the hero was last detected and investigate further.

2. If the Skeleton still cannot find the hero, it will make a best guess where it thinks he has gone and will set a patrol route to the nearest waypoint. Given these changes, we've removed the alert level as we've found this feature has become redundant and offers no extra intelligence. The "smell trails" have been reduced to balance the extra added behaviour - this also seems to help limit cheating in the AI.

Ok, let's bring on the fun stuff!

AI Explained - Part 2 of 5: Retreating and Defense, featuring TinyKeep's Fire Imp Monster!


Fire Imps (and other monsters marked with the "Shy" personality flag) will run away from the player if he gets too close. Put him in this level of distress for too long, and he'll breathe fire on you.

The interactive demo is here on the TinyKeep website along with all of the previous demos:
Tinykeep.com

As with all of these AI behaviours, what you see on the video and demo are the default settings for each of the personality flags (Aggressive, Cautious, Shy, Lumbering etc...). However we've designed our AI editor to be a lot more flexible than that - so our game designer Ben can choose from a multitude of variables to customize his monsters:

  • Enable/disable line of sight (blind monsters)
  • Smell/sound sensitivity (monsters with amazing sense of smell)
  • Roaming speed, chasing speed, fleeing speed
  • Enable/disable wall avoidance (in case some monsters can walk through walls!)
  • Distance threshold before alerted
  • Require line of sight before alerted
  • ...and many more!

We know that this will give us the ability to create really unique and varied monsters, and part of the fun of the game is figuring out the behaviours of each one.

Hope you enjoyed the post, and let us know if you have any questions about the AI!

Comments
Arkanium
Arkanium

Interesting. Have you considered adding flocking behaviour to the fire imps so that a group which are friends will tend to flee in a similar direction? Or would this make catching them too hard if they are all breathing fire?

Reply Good karma Bad karma+1 vote
Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.

Icon
TinyKeep
Platforms
Windows, Mac, Linux
Creator
phi6
Engine
Unity
Contact
Send Message
Homepage
Tinykeep.com
Release date
Game watch
Start tracking
News
Browse
News
New
Post news
Share
Related Games
TinyKeep
TinyKeep Roguelike
Related Engines
Unity
Unity Commercial