Author Topic: Repetitive inane phrases from NPCs in long games  (Read 4172 times)

Offline Cobra951

  • Gold Member
  • *
  • Posts: 8,934
Repetitive inane phrases from NPCs in long games
« on: Friday, August 12, 2016, 06:01:36 AM »
Don't we all hate them?  Why do they still happen?  What makes me hate them all the more is knowing how simple it is to prevent the repetitions within any reasonable time frame.  (The quality and quantity of the phrases, we programmers can't help at all.)

There is more than one way to approach randomness.  I don't mean the RNG (random-number generator), which is the truly involved element to develop properly.  I mean there are multiple ways to apply a hopefully competent RNG.  The obvious method is to select something from a list at random.  And that's what even the best games seem to do.  That's the problem.  That's wrong, because it can lead to irritatingly frequent repetition of the same phrase, or a few phrases, and skipping over others for long periods of time.

The correct method is akin to a deck of cards.  After shuffling the deck, dealing from the top produces a random series of values, but each value will appear exactly once until the deck is exhausted.  Shuffling a list of items requires an algorithm, and it can arguably produce a lengthy or resource-intensive calculating process.  With today's hardware, I doubt it, but let's say for the sake of argument that it is.  Fortunately, there is a great shortcut.

Instead of shuffling and dealing from the top, we can deal from random places in an unshuffled deck.  The only trick to this approach is removing each dealt card from the deck, and reducing the range of the RNG-generated index by one, after each card is dealt.  This can be handled by a 1.79 MEGA-Hz 8-bit 6502 CPU without breaking stride.  I know that for a fact, because I did it in a Cribbage game I programmed in the early 80s.

To this, I'd add a timestamp to each utterance of a phrase.  If a certain amount of time hasn't elapsed since it was last heard, I'd discard it altogether.  Silence is preferable to hearing the same crap over and over.

Rant comes courtesy of my increasing irritation with The Witcher 3 and Fallout 4, because of this wholly unnecessary issue.  If I was responsible for the ambient dialog in these games, I'd hang my head in shame.

Offline K-man

  • Post-aholic
  • *****
  • Posts: 2,967
  • HOW'S IT FEEEEEL IDOL
Re: Repetitive inane phrases from NPCs in long games
« Reply #1 on: Friday, August 12, 2016, 06:44:39 AM »
It is why the first 5-10 hours of most any Bethesda game are the best.  There's a tipping point in all of them where the illusion of a fully realized world begins to crumble. 

But man, those first few glorious hours.

Offline Cobra951

  • Gold Member
  • *
  • Posts: 8,934
Re: Repetitive inane phrases from NPCs in long games
« Reply #2 on: Friday, August 12, 2016, 12:11:05 PM »
Yeah, the facades start tipping over after a couple of dozen hours.  But in TW3's Blood & Wine, it's more like a dozen minutes.  Some characters get stuck saying the same thing repeatedly, and some of the new phrases are idiotic or otherwise grating right from the start.  I dread hearing "that Gwent will be the end of me; I've lost a game" one more time.  (Oh, really?  A whole game, huh?  That's rough.)

Offline Quemaqua

  • 古い塩
  • Administrator
  • Forum god
  • *
  • Posts: 16,498
  • パンダは触るな。
    • Bookruptcy
Re: Repetitive inane phrases from NPCs in long games
« Reply #3 on: Friday, August 12, 2016, 12:26:15 PM »
I have long felt exactly the way you do about this. Like come on guys, we have the capability to make this so much better than it is! It shouldn't even be THAT difficult in the grand scheme of things!

天才的な閃きと平均以下のテクニックやな。 課長有野

Offline idolminds

  • ZOMG!
  • Administrator
  • Forum god
  • *
  • Posts: 11,939
Re: Repetitive inane phrases from NPCs in long games
« Reply #4 on: Friday, August 12, 2016, 11:22:38 PM »
It does seem like the solution is fairly obvious and simple to implement. Really weird that it just keeps happening so often in games.

Offline K-man

  • Post-aholic
  • *****
  • Posts: 2,967
  • HOW'S IT FEEEEEL IDOL
Re: Repetitive inane phrases from NPCs in long games
« Reply #5 on: Saturday, August 13, 2016, 04:57:17 AM »
Another thing I can't help but think about is "why in the hell are these people volunteering this personal information to a complete stranger?"

Offline Quemaqua

  • 古い塩
  • Administrator
  • Forum god
  • *
  • Posts: 16,498
  • パンダは触るな。
    • Bookruptcy
Re: Repetitive inane phrases from NPCs in long games
« Reply #6 on: Saturday, August 13, 2016, 12:22:25 PM »
Yeah, that's what bothers me even more. Like nobody just walks up and talks to you unless they're crazy. People don't just stand around waiting to spout dialog at you, that's not how people work. It's always broken immersion for me. Goes right back to what I was saying in the NMS thread about the world feeling built around the player. Something like that, where EVERYONE has a comment about what I'm doing and wants to tell me some random tidbit of information, makes the world feel extremely artificial. Witcher 3 wasn't as bad about it because at least there was a lot of ambient dialog not related to the player, and some of that stuff was negative because people don't necessarily like you, but it still hurt the overall feel because of the repetition.

天才的な閃きと平均以下のテクニックやな。 課長有野

Offline Cobra951

  • Gold Member
  • *
  • Posts: 8,934
Re: Repetitive inane phrases from NPCs in long games
« Reply #7 on: Saturday, August 13, 2016, 08:44:42 PM »
Good point.  Most people wouldn't just talk to you out of the blue, unless they're selling something.  I can see some admiration or chastising remarks rarely, but those need to be on long cooldown timers, and they need to make sense, in context with what's happening.  (What raggedy peasant is going to tell a gleaming mountain of muscle with two swords on his back to crawl back under his rock?)  Otherwise, it really is best to drop the whole practice of proximity-triggered running at the mouth.

Offline Xessive

  • Gold Member
  • *
  • Posts: 9,920
    • XSV @ deviantART
Re: Repetitive inane phrases from NPCs in long games
« Reply #8 on: Sunday, August 14, 2016, 06:24:04 AM »
I think it all started with a developer attempting to replicate the effect of crowds murmuring when you enter a room or walk down a street and then it just snowballed from there.

Aside from eavesdropping on a conversation between NPCs, I don't really pay much attention to generic commentary. Thanks to Oblivion, I'm now deaf to repetitive dialogue.

Offline Quemaqua

  • 古い塩
  • Administrator
  • Forum god
  • *
  • Posts: 16,498
  • パンダは触るな。
    • Bookruptcy
Re: Repetitive inane phrases from NPCs in long games
« Reply #9 on: Sunday, August 14, 2016, 08:56:52 AM »
Honestly, the Elder Scrolls games are probably directly responsible for the proliferation of this. Morrowind is the first game I can remember being such an egregious offender, and it never got any better. I thought it was ultra-dumb in Morrowind even back then, but the game world was so stunning and huge that it didn't matter a lot. Despite being a big fan of that franchise for years, stuff like that has grown tiresome. I have higher hopes for TES6 in terms of some of that stuff that I hope will get phased out, but we'll see.

天才的な閃きと平均以下のテクニックやな。 課長有野

Offline K-man

  • Post-aholic
  • *****
  • Posts: 2,967
  • HOW'S IT FEEEEEL IDOL
Re: Repetitive inane phrases from NPCs in long games
« Reply #10 on: Wednesday, September 07, 2016, 07:29:49 AM »
To this day, one of my favorite methods of interacting with NPCs was in Ultima VI.  Once you used the talk command, a character portrait would come up for the NPC and they would greet you.  Conversation from that point forward was entirely directed by the player.  You conversed by literally typing things into the field and hitting enter.  


So common practice would be to ask their name, job etc.  and keywords would show up in pink.  You could mention these keywords to further open up conversation.  The NPCs would also have things to say about other NPCs in town, local happenings, etc etc.  If you typed in gibberish or something not related to them you'd get a generic "i don't know about that" message.  



Tto this day it is about as organic as I've ever seen dialogue happen in a game, and it came out in 1991.
« Last Edit: Wednesday, September 07, 2016, 10:18:42 AM by K-man »

Offline Cobra951

  • Gold Member
  • *
  • Posts: 8,934
Re: Repetitive inane phrases from NPCs in long games
« Reply #11 on: Friday, September 09, 2016, 10:02:22 AM »
I remember those days well.  But it isn't really the same thing.  What you're describing is similar to initiating conversations with NPCs in TW3, and many other games.  Yeah, you don't get to type responses, but in reality those old games only knew a handful of words that would make a meaningful difference in the conversation.  What bugs me is the unsolicited chatter.  Do it right, or don't do it at all.

Offline K-man

  • Post-aholic
  • *****
  • Posts: 2,967
  • HOW'S IT FEEEEEL IDOL
Re: Repetitive inane phrases from NPCs in long games
« Reply #12 on: Friday, September 09, 2016, 11:50:20 AM »
I remember those days well.  But it isn't really the same thing.  What you're describing is similar to initiating conversations with NPCs in TW3, and many other games.  Yeah, you don't get to type responses, but in reality those old games only knew a handful of words that would make a meaningful difference in the conversation.  What bugs me is the unsolicited chatter.  Do it right, or don't do it at all.

Well the big difference here is that you're not confined to a "predetermined" set of conversation points.  You can ask NPCs about things that are not necessarily key words related to your main quest.  They'll have things to say about other NPC's, places, goings on, that aren't related to the main path.  The SNES version would actually populate the keywords as you discovered them (because of the obvious limitation), so it more resembles what you're describing.  Sure, breaking it down it's fairly simple.  But the system certainly provided the illusion of complexity.






Offline Xessive

  • Gold Member
  • *
  • Posts: 9,920
    • XSV @ deviantART
Re: Repetitive inane phrases from NPCs in long games
« Reply #13 on: Saturday, September 10, 2016, 04:22:48 PM »
If they integrate something like Dr. Sbaitso into NPC dialogues I'd be content :P I'd spend hours just having random conversations ;D haha

Offline Quemaqua

  • 古い塩
  • Administrator
  • Forum god
  • *
  • Posts: 16,498
  • パンダは触るな。
    • Bookruptcy
Re: Repetitive inane phrases from NPCs in long games
« Reply #14 on: Saturday, September 10, 2016, 08:00:49 PM »
Morrowind had a similar system. It wasn't typing things in, but words would get added to a list of known things you could ask about as you talked to people, and people would talk to you about those specific things when you clicked on them. It wasn't actually as elegant, I think, and I have fond memories of Ultima VI as well (even if they're a little hazy at this point).

But yeah, it's not really the same thing as people randomly coming up to you to say random shit for no reason every time you walk within ten feet. That's a different problem (and frankly, an easier one to solve, which is what makes it so baffling).

天才的な閃きと平均以下のテクニックやな。 課長有野