The following warnings occurred:
Warning [2] Use of undefined constant SAPI_NAME - assumed 'SAPI_NAME' (this will throw an Error in a future version of PHP) - Line: 3388 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3388 errorHandler->error
/showthread.php 116 build_archive_link
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/inc/functions.php 3324 build_forum_breadcrumb
/showthread.php 195 build_forum_breadcrumb
Warning [2] Use of undefined constant IN_ARCHIVE - assumed 'IN_ARCHIVE' (this will throw an Error in a future version of PHP) - Line: 3331 - File: inc/functions.php PHP 7.4.33-nmm7 (Linux)
File Line Function
/inc/functions.php 3331 errorHandler->error
/showthread.php 195 build_forum_breadcrumb






Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
NPC AI Sphere vs RunUO
Author Message
Anarch Cassius
Master
**

Posts: 273
Likes Given: 19
Likes Received: 10 in 9 posts
Joined: Mar 2012
Reputation: 2



Post: #6
RE: NPC AI Sphere vs RunUO
Well I'm really liking groups. One of my favorite moments from the time I played WoW was having defeated a bunch of Orcs in a dungeon room and while we were still healing a warparty of NPC Orcs charged in for revenge. They wiped us but it felt more interesting than frustrating since I'd not seen NPCs move in to attack as a group rather than spawning one by one and getting picked offed.

The basic structure I'm using (and stole most of from a previous system) is that NPCs get a rank and faction. On sight they can recruit lower ranking NPCs. Once in a group the leader's home distance multiplies and the members of the groups update their home to a short range from the leader periodically.

When combat occurs the leader's memory gets updated with the enemy involved. It periodically orders the group to attack the target. As more enemies get involved in the fight they get checked against the current target and if deemed more dangerous they replace it.

The leader also tracks calls for help from wounded members. Not much good unless you have a mage right now since I don't have NPCs bandaging others working yet. However if you do the leader will likewise store the most hurt group member and periodically direct the mages to heal and buff him.

The leader has a leader memory that stores this target information for the group. The group members have a memory with their leader. The leader doesn't track his followers individually but can easily spot them on a FORCHAR check by looking at the memory item.

If the leader dies the group disbands. The memories have a fail safe to destroy themselves if they loose the leader. In this case a high ranking member of the group may recruit the others in to a new group and/or they head back to their original home points. They won't just run back in the middle of a fight but you'll disrupt coordination and those who kill their current targets may wander off.

I use a much simpler effect for things like mongbats, rats and headlesses which fight as a pack but hardly have the coordination of groups or factions. So to save processing the simply cry out with a FORCHAR and any nearby creature who has their kind in its desires and isn't a pet or currently fighting will come help. If the creatures are the same kind they will have their own attack trigger set off and call out as well, increasing the possible range. On the other hand I also use this on for example the Dread Spider. All spiders, even non-aggressive ones, have this creature in their desires and it has the event. In the presence of the Dread Spider they will fight whatever it fights.

Current Projects: Necromancy SCP overhaul. Custom Faction AI/System. Imbuing.
07-31-2012 06:37 PM
Find all posts by this user Like Post Quote this message in a reply
Post Reply 


Messages In This Thread
NPC AI Sphere vs RunUO - WRWR - 07-28-2012, 08:41 PM
RE: NPC AI Sphere vs RunUO - Shaklaban - 07-28-2012, 09:32 PM
RE: NPC AI Sphere vs RunUO - darksun84 - 07-29-2012, 12:59 AM
RE: NPC AI Sphere vs RunUO - WRWR - 07-29-2012, 02:09 AM
RE: NPC AI Sphere vs RunUO - ShiryuX - 07-31-2012, 01:21 PM
RE: NPC AI Sphere vs RunUO - Anarch Cassius - 07-31-2012 06:37 PM
RE: NPC AI Sphere vs RunUO - Barnabus - 10-02-2012, 12:22 AM
RE: NPC AI Sphere vs RunUO - JeBu - 10-02-2012, 02:43 AM
RE: NPC AI Sphere vs RunUO - Mordaunt - 10-02-2012, 03:27 AM
RE: NPC AI Sphere vs RunUO - gokku - 10-02-2012, 05:44 AM
RE: NPC AI Sphere vs RunUO - Extreme - 10-02-2012, 07:01 AM
RE: NPC AI Sphere vs RunUO - Shaklaban - 10-02-2012, 07:09 AM
RE: NPC AI Sphere vs RunUO - Extreme - 10-02-2012, 07:23 AM
RE: NPC AI Sphere vs RunUO - Shaklaban - 10-03-2012, 01:42 AM
RE: NPC AI Sphere vs RunUO - Barnabus - 10-02-2012, 07:26 AM
RE: NPC AI Sphere vs RunUO - Barnabus - 10-02-2012, 09:52 AM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)