Overprotective NPCs

G

Guest

Guest
Archived from groups: rec.games.roguelike.development (More info?)

I playtested Dweller yesterday and found a small curiosity that I didn't
mean to happen when I wrote the code:

In Dweller I have an item, Book of Charms, that can be used to pacify a
nearby monster and make it friendly. If the monster is charmed and
becomes friendly it's AI is changed so that it always tries to stay in a
map cell adjacent to the player. If the monster starts it's turn in a
cell adjacent to the player it will start defending the player from
other nearby monsters. It will attack any monster that is adjacent to
the player. The thing is that if the charmed monster is the only monster
adjacent to the player it will start attacking itself, committing
suicide in order to protect the player from itself.... talk about
overprotective!

Weird/fun/bug/feature... I don't know, but I guess I'll have to change
it for the next release :)

Happy coding everyone!

BR,
Björn Bergström
roguelike development [http://roguelikedevelopment.org]
dweller - cellphone roguelike [http://roguelikedevelopment.org/dweller]
 
G

Guest

Guest
Archived from groups: rec.games.roguelike.development (More info?)

On Thu, 30 Jun 2005 08:04:21 +0200, Björn Bergström wrote:

>I playtested Dweller yesterday and found a small curiosity that I didn't
>mean to happen when I wrote the code:
>
>In Dweller I have an item, Book of Charms, that can be used to pacify a
>nearby monster and make it friendly. If the monster is charmed and
>becomes friendly it's AI is changed so that it always tries to stay in a
> map cell adjacent to the player. If the monster starts it's turn in a
>cell adjacent to the player it will start defending the player from
>other nearby monsters. It will attack any monster that is adjacent to
>the player. The thing is that if the charmed monster is the only monster
>adjacent to the player it will start attacking itself, committing
>suicide in order to protect the player from itself.... talk about
>overprotective!
>
>Weird/fun/bug/feature... I don't know, but I guess I'll have to change
>it for the next release :)
>
>Happy coding everyone!

What if you have two charmed monsters - will they fight to the death?
--
auric underscore underscore at hotmail dot com
*****
Someday we gotta learn how to swear.
 
G

Guest

Guest
Archived from groups: rec.games.roguelike.development (More info?)

Auric__ wrote:
> On Thu, 30 Jun 2005 08:04:21 +0200, Björn Bergström wrote:
>
>
>>I playtested Dweller yesterday and found a small curiosity that I didn't
>>mean to happen when I wrote the code:
>>
>>In Dweller I have an item, Book of Charms, that can be used to pacify a
>>nearby monster and make it friendly. If the monster is charmed and
>>becomes friendly it's AI is changed so that it always tries to stay in a
>> map cell adjacent to the player. If the monster starts it's turn in a
>>cell adjacent to the player it will start defending the player from
>>other nearby monsters. It will attack any monster that is adjacent to
>>the player. The thing is that if the charmed monster is the only monster
>>adjacent to the player it will start attacking itself, committing
>>suicide in order to protect the player from itself.... talk about
>>overprotective!
>>
>>Weird/fun/bug/feature... I don't know, but I guess I'll have to change
>>it for the next release :)
>>
>>Happy coding everyone!
>
>
> What if you have two charmed monsters - will they fight to the death?

They'll choose targets randomly, so yes, they might fight to the death
or just stand still and commit suicide...

--
Björn Bergström
roguelike development [http://roguelikedevelopment.org]
dweller - cellphone roguelike [http://roguelikedevelopment.org/dweller]
 
G

Guest

Guest
Archived from groups: rec.games.roguelike.development (More info?)

On Thu, 30 Jun 2005 16:39:41 +0200, Björn Bergström wrote:

>Auric__ wrote:
>> On Thu, 30 Jun 2005 08:04:21 +0200, Björn Bergström wrote:
>>
>>
>>>I playtested Dweller yesterday and found a small curiosity that I didn't
>>>mean to happen when I wrote the code:
>>>
>>>In Dweller I have an item, Book of Charms, that can be used to pacify a
>>>nearby monster and make it friendly. If the monster is charmed and
>>>becomes friendly it's AI is changed so that it always tries to stay in a
>>> map cell adjacent to the player. If the monster starts it's turn in a
>>>cell adjacent to the player it will start defending the player from
>>>other nearby monsters. It will attack any monster that is adjacent to
>>>the player. The thing is that if the charmed monster is the only monster
>>>adjacent to the player it will start attacking itself, committing
>>>suicide in order to protect the player from itself.... talk about
>>>overprotective!
>>>
>>>Weird/fun/bug/feature... I don't know, but I guess I'll have to change
>>>it for the next release :)
>>>
>>>Happy coding everyone!
>>
>>
>> What if you have two charmed monsters - will they fight to the death?
>
>They'll choose targets randomly, so yes, they might fight to the death
>or just stand still and commit suicide...

Make it intentional - the monsters should be fighting to decide who's
"best" to guard the PC. <g>
--
auric underscore underscore at hotmail dot com
*****
Mr. Notlob, there's nothing wrong with you that an expensive operation
can't prolong.
 
G

Guest

Guest
Archived from groups: rec.games.roguelike.development (More info?)

It's an interesting and logical way to balance charms and deal with the
player who tries to form an army of charmies, anyway; you can just say
that the 'charm' spell makes them ultrasensitive to any threat to their
owner (or just ultra-jealous), to the point where they'd attack anyone
just standing nearby. Players could still try for the army of charmed
creatures if they want, but keeping them from killing each other would
be quite a task.
 
G

Guest

Guest
Archived from groups: rec.games.roguelike.development (More info?)

On 3 Jul 2005 02:17:24 -0700, Aquillion wrote:

>It's an interesting and logical way to balance charms and deal with the
>player who tries to form an army of charmies, anyway; you can just say
>that the 'charm' spell makes them ultrasensitive to any threat to their
>owner (or just ultra-jealous), to the point where they'd attack anyone
>just standing nearby. Players could still try for the army of charmed
>creatures if they want, but keeping them from killing each other would
>be quite a task.

Be interesting to see that implemented in a multiplayer game.
- You've charmed the [monster].
- The [monster] perceives that [teammate] is a threat to you.
- The [monster] attacks [teammate]! You can't stop it!
<g>
--
auric underscore underscore at hotmail dot com
*****
No, I never read the documentation - why do you ask?
 
G

Guest

Guest
Archived from groups: rec.games.roguelike.development (More info?)

>Be interesting to see that implemented in a multiplayer game.
>- You've charmed the [monster].
>- The [monster] perceives that [teammate] is a threat to you.
>- The [monster] attacks [teammate]! You can't stop it!

Hmm. In a game that has them, you could also make it dependant on the
player's leadership/charisma ability. A player with high interpersonal
skills could manage a large group of fanatically-charmed monsters
without having them kill each other, while a player without such skills
would have trouble keeping even two of them from each other's throats.