Announcement: Remember: you are giving away your fantastic ideas for free, and somebody else might even make money from them (or appear to). That's just how the world works! If you're worried about it, maybe you shouldn't post your ideas here.


Caravel Forum : DROD Boards : Feature Requests : A new way to make "smart goblins"
New Topic New Poll Post Reply
Poster Message
Skylancer64
Level: Delver
Rank Points: 62
Registered: 10-25-2003
IP: Logged
icon A new way to make "smart goblins" (0)  
After seeing on the forums the (obvious) bit about having a smarter goblin that will attack when Beethro has his back against the wall, I realized there were more ways to improve goblins. For example, a smarter goblin could avoid being killed in a one square corridor that bends at 90 degrees. For a regular goblin, this would be death.

A smart goblin, in this example, would step as shown if Beethro had his sword North. If Beethro turned his sword to the NE, the goblin could either step W and "hide" in the corner, seeing that the wall to the NW of Beethro blocks the killing step, or it could step E, seeing that the wall again blocks Beethro from thrusting diagonally and killing it.(the former would likely be more appealing to the goblin in most cases, as stepping E would allow Beethro to lead it down a new corridor that could spell its demise, whereas stepping back W would force Beethro to back out of the corner, unable to kill the goblin there.)

X=wall
B=Beethro
| or / or -- =sword
G=goblin
..=filler to line up each row properly (empty space)

XXXXXX
X...G
X.|.XXX
XBX

In all four cases, a regular goblin dies. In a NW corner as shown, the goblin sits in the corner instead of stepping around as in the illustration. Same thing for the NE corner. In the SE corner, a goblin will step out like the smart goblin shown, but if approached with the sword held diagonally SW, it will suicidally attack Beethro, whereafter it can be killed, and in the SW corner, it will step out as in the illustration when Beethro approaches it with a diagonal sword, but then Beethro can take another step forward and kill it.

Another (similar) case:

......XXXX
......XXXX
...G...--B
...............

Here a regular goblin would step forward if Beethro stepped forward (and likely get pushed against a wall and killed later), as in an open space. Perhaps a smarter goblin would step N around the corner instead, as Beethro cannot kill it because of the wall. This would lead to additional problems manipulating the goblins. If the path north into which the goblin stepped were a dead-end corridor (imagine that the top left empty space and the one below it are both X's), this might be exploited as the goblin would be stepping to its doom. Beethro could step SW and cover all three squares of the opening of the corridor, then turn his sword to the NW and force the goblin inside. However, in that case, it is no worse than a regular goblin because the regular goblin could be coerced into entering the corridor just as easily (from the illustration, have Beethro step forward once, then turn his sword to the SW. The goblin will step NE into the space the smart goblin would)

But in a situation like this...

X...XXXX
X...XXXX
...G...--B
XXXXXXX

...the smart goblin would step N as soon as Beethro walks forward, preventing Beethro fron taking another step! Turning the sword to the NW doesn't help! The goblin could apply the same logic as it did in the corner situation (at the top) and step S, realizing that Beethro is unable to step diagonally and kill it due to the wall being there. In this case, Beethro would be unable to progress at all past that point and would have to back out!

There are many more cases in which these same ideas apply and make the goblin more difficult to kill. The basic idea I'm demonstrating here is that a smarter goblin could detect whether Beethro could kill it or not on each space it could step to (based on adjacent obstacles/walls) and combine this with existing goblin logic. This goblin would act no different in open spaces, but as soon as obstacles and narrow spaces come in, it acts a good deal more intelligent.

Essentially, the goblin would detect each "safe space" and then step to the one closest to Beethro. If the closest space is the space it's already on, then it would do nothing. If you look at each of the previous examples I gave, this single rule would result in each those exact moves I had the smart goblin make! (The goblin-attacking-Beethro-when-he-has-his-back-to-the-wall proposal would follow from this rule as well)

I know nothing about how DROD monster AI code works, but perhaps a check could be done where every possible space Beethro's sword could end up on in the next turn is calculated, allowing for walls and force arrows and such to prevent certain movements Beethro could otherwise make. At most there would only be 11 possible "Beethro-moves" to consider --- turning the sword clockwise, counterclockwise, waiting, and stepping in each of the eight directions and the goblin would move to the closest safe spot to Beethro (9 possible moves/safe spots to consider). Ideally, the calculation of the possible squares Beethro's sword could land on would only have to be done once, and all smart goblins could move according to the results.

So, perhaps with these ideas, and maybe some others yet to come, we can get closer to a goblin with enough unique differences from the current one to be added in as a new monster. Phew, that was a mouthful! :)

Questions and comments welcome.

Edit:
A few points of clairification -
-If there are two safe spots equidistant from Beethro, the goblin will choose the one furthest from Beethro's sword.
-If there are no safe spots that the goblin can move to, attack Beethro suidically (pick the space it would have if all the spots were considered safe)

[Edited by Skylancer64 on 01-01-2004 at 03:15 AM GMT]

____________________________
Complexity is the source of Life.
12-31-2003 at 11:40 PM
View Profile Send Private Message to User Show all user's posts Quote Reply
The_Red_Hawk
Level: Smitemaster
Rank Points: 783
Registered: 09-02-2003
IP: Logged
icon Re: A new way to make "smart goblins" (0)  
I really like the idea of smarter goblins. Would it be a different type of goblin altogether, or would it be just a change for regular goblins?

The normal goblins all have shortcomings which are easy to exploit, though a bit harder when they are brained. How about only brained goblins act that way?

____________________________
Slashing, whirling, diving, twirling,
Snapping, turning, rising, swirling,
Screeching, flipping, gliding, sliding,
The red hawk's dance of death.

.....the king of the skies.....
12-31-2003 at 11:45 PM
View Profile Send Private Message to User Send Email to User Show all user's posts This architect's holds Quote Reply
zex20913
Level: Smitemaster
Avatar
Rank Points: 1723
Registered: 02-04-2003
IP: Logged
icon Re: A new way to make "smart goblins" (0)  
And, an addendum, how would brained smart goblins act? I do like the suggestion Red gives, to make the brain add this function, instead of a new goblin rule/type.

____________________________
Click here to view the secret text

01-01-2004 at 12:24 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
Skylancer64
Level: Delver
Rank Points: 62
Registered: 10-25-2003
IP: Logged
icon Re: A new way to make "smart goblins" (0)  
I guess if smart goblins were brained they would just be able to find their way to you better (goblins can go around one-space obstacles, but no more than that currently). Just the same as roaches pretty much.

Actually, roaches do move differently under with a brain, but often that just makes them easier, once you get used to it.

The normal goblins all have shortcomings which are easy to exploit, though a bit harder when they are brained.

I never noticed much difference between them, just that they can get around obstacles like roaches. The only major difference I see is that for brained goblins, they don't stand still when you have your sword pointed at them. I guess this could also be a reason to have brained goblins act smarter. Having them as seperate monsters would be better in some ways because then there could be both kinds in the room at the same time.

Also, another change could be something to take away the ease of forcing a goblin forward just by walking forward. The goblin I posed, although it does that job well, it does so only when obstacles are involved (which is a major shortcoming of current goblins). But you could still simply force it into a wall if you had an open area. I'm leaning towards having it made as a new goblin if there's a way to further differentiate it from standard goblins. If not, then having brained goblins act that way wouldn't be bad.

____________________________
Complexity is the source of Life.
01-01-2004 at 03:09 AM
View Profile Send Private Message to User Show all user's posts Quote Reply
Mattcrampy
Level: Smitemaster
Avatar
Rank Points: 2388
Registered: 05-29-2003
IP: Logged
icon Re: A new way to make "smart goblins" (0)  
We'll probably see a more strategic monster that can order other monsters around (unlike brains) in 1.7. In fact I'd be surprised if we don't as it's a good fit for the story.

We could probably use this behaviour with these monsters.

Matt



____________________________
What do you call an elephant at the North Pole?
Click here to view the secret text

01-02-2004 at 09:38 AM
View Profile Send Private Message to User Send Email to User Show all user's posts Quote Reply
New Topic New Poll Post Reply
Caravel Forum : DROD Boards : Feature Requests : A new way to make "smart goblins"
Surf To:


Forum Rules:
Can I post a new topic? No
Can I reply? No
Can I read? Yes
HTML Enabled? No
UBBC Enabled? Yes
Words Filter Enable? No

Contact Us | CaravelGames.com

Powered by: tForum tForumHacks Edition b0.98.8
Originally created by Toan Huynh (Copyright © 2000)
Enhanced by the tForumHacks team and the Caravel team.