[WIP] Classic RPG / MMO Enemy AI

Hi everyone,

After the recent release of Classic World of Warcraft I started playing around with the idea of creating a classic RPG NPC AI to see how far I could take it. I’d like to share my progress here.

Suggestions and comments very welcome :slight_smile:

Introduction

https://www.youtube.com/watch?v=soavrE-hxpQ

New Weapon System!

https://www.youtube.com/watch?v=0m5FvZ-eTM4

New Magic Spell System!
https://youtube.com/watch?v=WScUHpp7mMc

Spell Showcase
https://youtube.com/watch?v=0vnsdChjfvQ

New Spells Added - Blind and Ethereal Form!
https://youtube.com/watch?v=hoz9EUSaUzM

**Custom Combat Logic **
https://youtube.com/watch?v=5CL_AyUY6VQ

New Threat System
https://youtube.com/watch?v=sW_hGfe64s8

What I have so far:

  • Melee AI that can detect any enemy via tags
  • AI will chase and attack the Player with a variety of attacks
  • Disengage mechanic to prevent “infinite” kiting of mobs
  • Basic leveling system that scales HP, MP, and damage by level!
  • Each melee attack has its own base damage, as well as any number of sound cues that can play
  • Weapon system that gives each weapon base damage and other properties like equip slot
  • Total damage is then calculated by looking at the attack’s base damage + weapon damage * level multiplier
  • AI and player can apply a variety of effects per attack - Knockback, Stun, Snare, Root, Pacify, Fear, Slow, Interrupt, Disarm
  • If NPC is disarmed the attacks will do less damage (no weapon!) and the AI can find and grab a weapon from the floor!

Planned features:

  • Deep magic spell system - ability to create your own spells!
  • Adding ranged attacks
  • Support for hybrid NPCs - Melee / Magic, Melee, Ranged

New Magic Spell System added!

Added:

  • Flexible Spell System created where you can create custom spells in minutes with a wide variety of effects!
  • Spells can be Direct Damage, AoE, Buffs, Debuffs, or Summon Spells
  • Spells can apply status effects like Stun, Fear, Root, Snare, Knockbacks
  • Spells have different categories to allow for custom logic for the AI (Cast Spell X if HP > 50%, else Cast Spell Y)
  • Interface highly inspired by Skyrim’s Creation Kit tool.

Here is a quick showcase video going over all the spells I have created to test the Magic System:

Spells in the video:

  • Blizzard - Area that applies a snare and initial damage
  • Curse of Shadow - Damage Over Time spell. Has a chance to snare on each tick
  • Dispel Magic - removes an attached spell, such as Curse of Shadows
  • Fireball - simple projectile
  • Firenova - Area that applies fire damage every 2 seconds to anyone inside
  • Haste - Doubles the reaction time of target
  • Heal - simple one-time heal
  • Rejuvenation - Heal Over Time. Restores HP over X seconds
  • Restore Mana - Restores X amount of mana
  • Restore Movement - removes any snare or root from target
  • Searing Pain - fire-based Damage Over Time spell
  • Shadowbolt - Shadow-based projectile
  • Shield - Applies an HP shield to target. Shield can absorb any amount of damage desired. Until shield is broken, target’s HP will not be affected
  • Spirit of the Wild - Increases movement speed by 2x permanently (or until dispelled)
  • Pull Target - A more advanced spell - it pulls the target towards caster
  • Summon Boulders - spawns several boulders above target
  • Summon Light Sphere - spawns a light sphere that is attached to the target and provides illumination
  • Summon Trolls - summons X trolls around target
  • Teleport - Teleports self or target to a nearby teleport location
  • Transform - Doe - transforms target into a doe for X seconds. Target loses control until transformed back (polymorph)

New Spells added per request - Blind and Ethereal Form!

New devlog - I go over the new Combat Profiles!

Combat Profiles allows you to add custom logic to your AI in a modular way to create customized encounters very easily.

New Threat System added!