There have been a couple of posts of late pertaining to NPCs, their presence, and their role in the game. I was considering this quote in particular, which someone else had also reference but I was unable to locate:
"At the core of it this is my problem: this is why I want to see Gotham alive with people and culture and museums and parties and schools and celebrations and life. Because superhero stories make the most sense to me when the promises of their cities are made clear. The promise is vital..." from this article http://www.giantbomb.com/articles/superheroes-cities-and-empty-streets/1100-5241/
I believe this to be an insightful perspective about using NPCs to help reinforce the immersion factor, and started thinking about what else could be done in this context.
1st - do we WANT a realistic, or even semi-realistic urban environment where there are large numbers of civilian NPCs going about their day-to-day business? would this cause the inclusion of villain mobs to be perceived as an immersion breaker without tying their presence to changes in NPC behavior? A group of zombies is walking around - the area should become utterly barren of civilian NPCs rather quick. A group of large, aggressive men in masks with bats and guns would likely produce a similar outcome, etc.
If we do opt for a more realistic urban environment (i think we should) then here are a couple suggestions:
2nd - Align NPC total number, crowd density, gender/race dispersion, behavior, and movement patterns by neighborhood, by time, by weather (when introduced). Rush hour should see more people on the street walking or in cars than 4am. A waterfront should see more men than women, more manual labor clothes than business suits, less pedestrian traffic and more concentrated semi-stationary work/group activity, etc. The aim should be (if practical) to create a city that's alive and of which the heroes (and villains) are a part not the whole. CoH and most other games are really just urban arenas devoid of more than a few token NPCs walking the same strip of sidewalk.
3rd - incorporate behavioral effects. If a mob is present, the NPCs should avoid the mob (cross the street, walk faster, etc) or panic, or call for help. Whatever is deemed an appropriate reaction given the perceived danger of the mob. This same dynamic could/should hold true for player villains. As their infamy increases so does the intensity of NPC reaction.
4th - incorporate scatter effects. If a fight breaks out the civilians should scatter and break for cover or simply flee the scene, eventually returning to normal patterns once the conflict resolves. CoH sort of did this but was a little primitive in its approach. ONE guy walking down the sidewalk in Talos island, sees you fighting, throws up his hands, mock yells in fright, then scampers off in the opposite direction. This calls into question how to incorporate mobs into the urban context in a believable-ish manner.
5th - potentially incorporate curiosity/responsibility effects. some number of NPCs flee but only a short distance. Some might be police cordoning off the area, or police/concerned citizens helping their fellow citizens flee. Others could represent the youtube/selfie types who want to capture the event happening, so they turn and break out mobile phones to record it.
The latter could play into the 'fame dynamic' where if hero X is doing a lot of street level patrolling and assistance s/he could be captured on film by pedestrians. Done enough times in a concentrated area and the local people in that neighborhood might offer thanks or be heard discussing the hero. Again, something that CoH offered to a degree, but using NPCs at the scene to reinforce how a hero's fame spreads would reinforce the immersion by illustrating the start of the causality chain.
This could also differentiate neighborhood heroes from global heroes - think daredevil vs ironman - if someone is spending a lot of time mission-ing/patrolling a particular neighborhood then have it reflect in conversation, tips, maybe even temporary graffiti or other recognition symbols using the hero's/villain's name.
Nothing here is particularly groundbreaking, but the lack of most/all of these features contributes to a reduction of enjoyment and replay-ability. Obviously, capabilities/time/money need to be taken into account, but over time the aim should be to model and create as healthy and vibrant an urban environment as is practical.
Indeed, many good points here. We've discussed many of these possibilities (and more). It is something that may take time to develop as we iterate throughout the life of the game depending on how things go with our AI designer's mad scientist project. Basically many of these behaviors will not need to be a result of scripting behaviors but an extentions of AI needs/ wants, likes/dislikes. Civvies fleeing from potential harm when there is something going down would be the result of the AI's need to avoid violence for example.
The event goal is to create the experience of a thriving city where the NPC popluation behaves in accordannce with thier environment. If the mad scientist project is fully realized, we as devs may not fully know exactly where and what certain NPCs are because they aren't boxed in to scripting, but continue to act in accordance to their behavioral inputs. It is exciting stuff but ventures into incharted territory take time to develop. So, we will see how far we can take things.
[hr]I don't use a nerf bat, I have a magic crowbar!
- Combat Mechanic -
[color=#ff0000]Tech Team. [/color]
You may have to install choke-chains and tethers, to keep those unruly AI citizens from all running off to the Carnival, instead of populating the populace.
Be Well!
Fireheart
This is very encouraging. Is the AI system, as envisioned, intertwined with that controlling opponent actions? Meaning, is it all working in concert based on behavioral and other inputs, or are there separate systems running for 1 group and for another? just curious as to how it's being approached and how those inputs are affected by the player's actions.
very intriguing/ambitious approach, though.
That depends on the AI and the situation. I can give a brief combat scenario to illustrate a difference:
A power with a continuing location effect is used, let's just say it is damage over time. Now "dumb" AI stays in the location getting hurt. A player wouldn't stay there if they could avoid it, so why would an AI? A dev then throws an effect in the power to "trick" the AI into leaving the location. With this proposed AI, it would learn that it could simply step away and not suffer the effect based on learning to leave.
Our pets for the Operator class would respond to commands used according to taught behaviors instead of scripted. It is the difference between knowing and asking. This difference in design forced us to apply creative thinking in designing powers in that they must apply equally to NPCs and PCs. No forced behaviors but power affecting, behavior encouraging, effects. And we had to design in such a way that we can easily apply scripting should this heuristic AI prove either too difficult to implement for the over -all health of the game, to costly (not just in terms of funds but dev time in design testing), or require more time than what is budgeted for stages of development.
[hr]I don't use a nerf bat, I have a magic crowbar!
- Combat Mechanic -
[color=#ff0000]Tech Team. [/color]
I suppose that one way one could put it is that CoT NPCs will (hopefully?) be more The Sims and less Pac-Man.
- - - - -
[font=Pristina][size=18][b]Hail Beard![/b][/size][/font]
Support [url=http://cityoftitans.com/comment/52149#comment-52149]trap clowns[/url] for CoT!
AI is always going to be computationally expensive, but one of the beauties of a neural net is that it allows for fairly complex 'interpretation' at relatively low cost. An NxM matrix multiplied by an N dimensional vector, where in this case N is the number of observation 'lines' and M the number of possible responses.
You'll need several smaller (and that is a relative term in this) nets chained in parallel because each net can only weigh observations and responses of equal value. Survival response is much more important than curiosity, so the net that scans for external dangers needs to operate separately for more realistic behaviour.
The interesting part of it is that part of these computations can be handed off to the client and need not burden the server with herding thousands of non-interactive npcs. It doesn't even really matter if all npcs are in the same location for all players. Soon as the npc ceases to be of interest to the client because it is out of range for rendering it syncs up with the server one last time. This incidentally also would answer the ancient philosophical question of 'if there's nobody around to observe them do npcs exist' (answer is no).
Disadvantages of neural nets include that they get more useful the larger the number of input and output options to weigh. We're not aiming for emergent intelligence here7, so we don't need specialised hardware (aka the brain) to handle millions of input lines generating hundreds of thousands of output in thousands of nets simultaneously. The other disadvantage is that they can not be programmed. They need to be trained and the that is a tricky and time consuming process. But once trained it's just a block of numbers that any modern computer can crunch through in less than a millisecond.
The idea of local heroes vs global ones pleases me. Let's say I RP at the club down on 4th and Locust a lot. I also tend to street-sweep that area since I'm there anyway. So I'm more likely to spot a local crime or get a tip because everyone knows me? Yeah...like this.
Have to be careful regarding bases though. Too many bases in the same area = saturation
I remember when Star Wars was cool...a long, long time ago...