Mob AI behavior
Forum rules
This forum houses many years of development, tracing back to some of the earliest posts that exist on the board.
Its current use is for the continued development of the server and game it has always served: TMW Classic.
Mob AI behavior
I've always found the mob AI in TMW to be pretty dumb.
One of my little side projects involves tweaking the mob AI in the server. I've made a bit of progress in the 'aibehavior' branch, and hope to make a bit more when I have time. Eventually this will be merged with the testing branch, documented in wiki, and go live at some point in the future.
So far I've added a system where mob spawn definitions can include an optional AI behavior flag. There is currently only one flag: guard.
Guard causes mobs to stay within their spawn area. It is possible to lead them astray if a player aggros them, but they will always walk back to their spawn area in the end. This flag will be useful in maps such as the Hurnscald north mines and the graveyard to keep players from putting mobs "in jail" and reducing the difficulty of the maps below what the designers intended.
I have a few ideas for other behaviors, such as 'sticky'. Sticky would make a mob stay aggro at the first player to hit it. Wisps etc do this but it is a side-effect of their flocking behavior. Another flag I'm thinking of is 'random' which causes a mob to aggro at a random player out of those who are attacking it instead of the last one to hit. Flags will be combinable for interesting effects.
Comments/suggestions welcome!
One of my little side projects involves tweaking the mob AI in the server. I've made a bit of progress in the 'aibehavior' branch, and hope to make a bit more when I have time. Eventually this will be merged with the testing branch, documented in wiki, and go live at some point in the future.
So far I've added a system where mob spawn definitions can include an optional AI behavior flag. There is currently only one flag: guard.
Guard causes mobs to stay within their spawn area. It is possible to lead them astray if a player aggros them, but they will always walk back to their spawn area in the end. This flag will be useful in maps such as the Hurnscald north mines and the graveyard to keep players from putting mobs "in jail" and reducing the difficulty of the maps below what the designers intended.
I have a few ideas for other behaviors, such as 'sticky'. Sticky would make a mob stay aggro at the first player to hit it. Wisps etc do this but it is a side-effect of their flocking behavior. Another flag I'm thinking of is 'random' which causes a mob to aggro at a random player out of those who are attacking it instead of the last one to hit. Flags will be combinable for interesting effects.
Comments/suggestions welcome!
Last edited by AnonDuck on 07 Aug 2013, 17:08, edited 1 time in total.
Head of the TMW Illuminati
Re: Mob AI behavior
I can imagine a flag to make the monster go after the weakest player (probably the healer).
Former programmer for the TMWA server.
Re: Mob AI behavior
Or the one with the highest amount of HP/mana.o11c wrote:I can imagine a flag to make the monster go after the weakest player (probably the healer).
I'd like to see monsters that react to certain items - either being provoked from an otherwise non-aggressive state, or ignoring players with the item, but attacking everyone else.
I don't know if that's technically possible, but I think it would be interesting when writing new quests.
Re: Mob AI behavior
Sometimes moving mobs around is just good strategy, especially in places like the graveyard. I'm afraid this would make the gameplay even more "target, hit and wait for the mob to die" than it already is.MadCamel wrote: Guard causes mobs to stay within their spawn area. It is possible to lead them astray if a player aggros them, but they will always walk back to their spawn area in the end. This flag will be useful in maps such as the Hurnscald north mines and the graveyard to keep players from putting mobs "in jail" and reducing the difficulty of the maps below what the designers intended.
Developer: Source of Mana, TMW Classic
SPI Liaison (Donate to The Mana World)
Forum Admin
TMW Team member
Re: Mob AI behavior
You can move them around as much as you want. They just walk back home when they have nothing else to do. In testing it actually makes the gameplay seem more active!.:WildX:. wrote: Sometimes moving mobs around is just good strategy, especially in places like the graveyard. I'm afraid this would make the gameplay even more "target, hit and wait for the mob to die" than it already is.
Head of the TMW Illuminati
Re: Mob AI behavior
I like the idea that a monster "gives up" and stops following, so we can actually run away from a monster that is too powerful rather than fighting it until it or the character dies in order to stay in the general area.MadCamel wrote:You can move them around as much as you want. They just walk back home when they have nothing else to do. In testing it actually makes the gameplay seem more active!.:WildX:. wrote: Sometimes moving mobs around is just good strategy, especially in places like the graveyard. I'm afraid this would make the gameplay even more "target, hit and wait for the mob to die" than it already is.
So like, while we could drag the jacko away in the graveyard now...in the fix I think it would mean we can make attempts to take over the area and if we fail we can run away without having to run all the way to the beginning.
So we can't cheat an area, but we can save ourselves from powerful monsters leaving their space too far and from people creating griefing swarms and dumping them on unsuspecting characters. Am I right about that?
Current character is "Abolish".
Re: Mob AI behavior
That is essentially correct. With guard the mob doesn't "give up" per-se, but if you leave it's aggro range it will start walking back to it's spawn point instead of hanging out where you left it.
Again this behavior and all future AI behaviors are entirely up to the mapper on a per-mob basis.
Again this behavior and all future AI behaviors are entirely up to the mapper on a per-mob basis.
Head of the TMW Illuminati
- wushin
- TMW Adviser
- Posts: 1759
- Joined: 18 Dec 2012, 05:56
- Location: RiverBest, Brew City, Merica
- Contact:
Re: Mob AI behavior
I can round up all most if not all of the terranite cave and park it in front of entrance. Same for Hurnscald mine. So I'm all for this improvement to unstick door mobs and other such stupid like kiting mobs like spiders away.
The secret to getting all the important stuff done is doing nothing.
Re: Mob AI behavior
This sounds like an awesome feature that will add a lot of depth to gameplay!
Is there a server we can try this on?
Also, what about a "wandering monster" flag? This could either be something random, or set some map points that it walks to, in a sort of patrol.
Is there a server we can try this on?
Also, what about a "wandering monster" flag? This could either be something random, or set some map points that it walks to, in a sort of patrol.
You earn respect by how you live, not by what you demand.
-unknown
-unknown
Re: Mob AI behavior
It's definitely an awesome feature and it was real fun to test
Please everyone take care of which mobs you decide to make wander back to their spawn area.
It might sound great to do so with the skulls in the gy but for gameplay this is really annoying.
The graveyard is a place where people level from lvl~50 (some earlier, some later) to lvl99, so they spend most of the time here (and with Yetis).
Archers would be annoyed as hell with all the skulls around because they hardly hit them even with DEX99.
Sure you can say now that they should just get help, but it's not like there's always help around.
Mid- (and also some high-)level warriors often can't be bothered to fight many often them as well.
Please keep in mind that luring mobs away is not just to make the map easier, but also, and I tend to say *mainly*, to make the gameplay more attractive.
Choose wise which mobs should return to their spawn area.
A few examples based on my personal opinion:
-> Skulls in graveyard returning to their home: no
-> Jack O in graveyard returning to its home: yes
-> Spiders in Terranite Cave: no
-> Terranites themselves: yes
-> Clovers Patches: yes
I was also thinking about the skulls in the Northern Mines.
I was thinking that two skulls there shouldn't hurt but it is so damn annoying when you need Iron Ore as beginner and the skulls enjoy hanging around with the Yellow Slimes (yeah I know there are also other places for hunting Yellow Slimes - but beginners don't).
On the other hand when you just leave them they should return to their tiny spawn area north of the slimes.
@MadCamel:
I guess the mobs with one single tile as spawn would be stuck in there then? Just asking cause it looked so weird
(Thinking about the two skulls in the Northern Mines, you could watch them being stuck in their spawn area from the place above where they won't hunt you)
Sorry for the long post ^.^
This is an awesome feature but I just needed to say all of this.
Please everyone take care of which mobs you decide to make wander back to their spawn area.
It might sound great to do so with the skulls in the gy but for gameplay this is really annoying.
The graveyard is a place where people level from lvl~50 (some earlier, some later) to lvl99, so they spend most of the time here (and with Yetis).
Archers would be annoyed as hell with all the skulls around because they hardly hit them even with DEX99.
Sure you can say now that they should just get help, but it's not like there's always help around.
Mid- (and also some high-)level warriors often can't be bothered to fight many often them as well.
Please keep in mind that luring mobs away is not just to make the map easier, but also, and I tend to say *mainly*, to make the gameplay more attractive.
Choose wise which mobs should return to their spawn area.
A few examples based on my personal opinion:
-> Skulls in graveyard returning to their home: no
-> Jack O in graveyard returning to its home: yes
-> Spiders in Terranite Cave: no
-> Terranites themselves: yes
-> Clovers Patches: yes
I was also thinking about the skulls in the Northern Mines.
I was thinking that two skulls there shouldn't hurt but it is so damn annoying when you need Iron Ore as beginner and the skulls enjoy hanging around with the Yellow Slimes (yeah I know there are also other places for hunting Yellow Slimes - but beginners don't).
On the other hand when you just leave them they should return to their tiny spawn area north of the slimes.
@MadCamel:
I guess the mobs with one single tile as spawn would be stuck in there then? Just asking cause it looked so weird
(Thinking about the two skulls in the Northern Mines, you could watch them being stuck in their spawn area from the place above where they won't hunt you)
Sorry for the long post ^.^
This is an awesome feature but I just needed to say all of this.
♡ Main characters:
Lv.94 - Cassy - speedarcher on dark path, bunny-wannabe, would like to ride on a Mouboo once...
Lv.95 - Biqcassy - mage on light path, addicted to her Fluffy Hat, love-hates Fallens, really misses Confused Tree...
Lv.70 - Simca. - dreams of becoming a speedarcher on light path, still has a lot to learn...
❀ Personal development overview | priorities | wiki to-do | wiki profile incl. other characters ✼
[20:24:59] <Cassy> debug npc in crypts!
[20:25:02] <Cassy> just a joke...
[20:25:08] <wushin> DONT DO THAT
[20:25:10] <o11c> !slap Cassy
Lv.94 - Cassy - speedarcher on dark path, bunny-wannabe, would like to ride on a Mouboo once...
Lv.95 - Biqcassy - mage on light path, addicted to her Fluffy Hat, love-hates Fallens, really misses Confused Tree...
Lv.70 - Simca. - dreams of becoming a speedarcher on light path, still has a lot to learn...
❀ Personal development overview | priorities | wiki to-do | wiki profile incl. other characters ✼
[20:24:59] <Cassy> debug npc in crypts!
[20:25:02] <Cassy> just a joke...
[20:25:08] <wushin> DONT DO THAT
[20:25:10] <o11c> !slap Cassy
- ChefChelios
- Novice
- Posts: 210
- Joined: 27 Jul 2010, 05:54
- Location: ...schlaaaand!!
Re: Mob AI behavior
we dont do it this reduce the difficulty of a map... we do it because these Monsters are just annoying!MadCamel wrote:This flag will be useful in maps such as the Hurnscald north mines and the graveyard to keep players from putting mobs "in jail" and reducing the difficulty of the maps below what the designers intended.
why dont ya just reduce the ammount of skulls or change their stats a bit?
pulling mobs to other players or to the entrance of the map is more or less the last kind of fun that i have ingame...
many Players do accept a behavior like this from me as challenge and do fight the Monsters and enjoy it... and some dont xD
a bit off topic and to all devs:
its also annoying to get kicked from the Server just because of doing a dropparty!!! this is spam? seriously, are you kidding me!?
(and yes i know there is a feature at 4144s client to protect me from this Chocolate Cupcake but i want to drop fast and not slow like a snail!)
same with picking up items... i kill a squirrel and it drops several items and i get kicked just because i try to pick up the loot as fast as i can... grrrrrrrrr
sometimes i think it is the job of the devs to make this game more and more annoying!
Re: Mob AI behavior
It does not make sense for a monster to know which player is weak. Going after some items on the outfit (and even color) or weapons seems better, or the amount of carried items.o11c wrote:I can imagine a flag to make the monster go after the weakest player (probably the healer).
You either live long enough to be a GM, or die a Troll Master
Re: Mob AI behavior
Wrong, it makes sense, imagine that you're a mouboo, who would you attack first between a strong worrior with a warrior helmet full of blood and a jean pants and a noob freshly arrived from Tulimshar with a noob hat?pclouds wrote:It does not make sense for a monster to know which player is weak.
"Time is an illusion. Lunchtime doubly so."
-- Ford Prefect
-- Ford Prefect
Re: Mob AI behavior
A flag that causes mobs to not aggro characters that are below a certain level would be nice. They'd still attack if the character starts it, but won't start the attack on their own.
Re: Mob AI behavior
These are all great ideas. I'll see what I can do without making a mess of things!
Head of the TMW Illuminati