• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

Dev Diary #6 — Narrative events

Hello everyone and welcome to today’s development diary about Narrative Events. I am Jakob (@Eomolch) from Triumph’s narrative team and I’ll be picking up where my colleague Michelle (@MichelleTriumph) left off two weeks ago with her more lore and story-focused journal.

Introduction​

In a wider sense Narrative Events have been a part of the Age of Wonders series ever since the original Age of Wonders. Back in AoW 1-3 they came as a dialogue based message system, which would feature some plot-defining choices and was generally restricted to the campaign mode of the game. Then, in Planetfall, Anomalous Sites made an appearance bringing dungeon crawling options with branching story and outcome to randomly generated maps. Now, for Age of Wonders 4, we have developed a system that unifies our interactive narrative content in one framework to bring Narrative Events to Story Realms and regular Realms (sandbox sessions) alike.

  • On a content level, a single Narrative Event is a mini-story presented to the player, followed by different options to react to the situation at hand, where each option will (typically) result in a different outcome in terms of gameplay consequences.
  • On a system level however, the flow of Narrative Events is uniquely tailored towards the player and their faction, analyzing the player situation, factoring in player actions and choices, with each Narrative Event becoming part of the player’s personal narrative.
  • Lastly, on a gameplay level, Narrative Events will provide meaningful choices to the player, through trade-offs that connect game play systems which normally would not interact with each other and unique rewards that can give a player tools outside their core strategy. When a moral dilemma is at odds with an economic one, many a benevolent Godir has been lured on the path of evil in this fourth Age of Wonders…

Event Format​

aow4-devdiary6-1.jpg


When it comes to the presentation of our Narrative Events, our art and UI team has blessed us with beautiful scenes in which one (or sometimes multiple) of our event actors are getting rendered in 3D. Those scenes are dynamic and will adjust to the locations, structures or factions involved. Ambient sounds, occasional weather effects and music tracks invite the player into a rich, living game world.

Transparency and player information are of high importance in a strategy game like ours. Therefore our event options give a full tooltip breakdown of all the gameplay effects that will happen when a button is clicked. This is complemented by tooltip (in tooltip) information for gameplay entities, concepts and lore, allowing players to make well-informed decisions within our events.
aow4-devdiary6-2.jpg


Inspecting the player city Centerspike through tooltips

Event Types and Conditions​

Our Narrative Events come in many different types and flavors, and can be categorized in different ways. From a player perspective an intuitive way to sort them is by assigning them to the following three groups:

Type 1: Exploration Events​

These are all events that will happen as a direct response to a player army movement, be it due to gaining vision of an unknown faction or an encounter with another army on the map. They promote exploration and give a narrative context to the locations, factions and armies you find on the map.
aow4-devdiary6-3-jpg.949994

The guards of Dawnspire need a break.

The above example is an encounter with a Free City army guarding a resource node. It allows the player to peacefully take over the structure, while also giving room for special interactions (here, hiring some of the guards) or a surprise attack.

This is only one archetype of exploration events we have in the game, others include army surrenders, Free City diplomatic meet events and our dungeon exploration events when entering an Ancient Wonder (which will be looked at in their own dev diary later on :) ).

Type 2: Emergent Events​

These events always happen at the start of the player's turn. They are diverse in their theme, actors and options and will come with a sense of surprise to the player, though the narrative will provide a context and usually leave some clues why the particular event is happening.

Each Narrative Event within the pool of events the player may receive comes with a custom set of conditions and settings, reflecting on the player situation, but also the general state of the map and factions present. They are managed by what we call our Story Flow System, which provides the player with a steady stream of narrative events in a controlled and fair fashion. Fairness and balance is of importance since our narrative events are given to AI players and are active in multiplayer mode too. Naturally, with an inherently random system such as this one, some RNG with lucky or unlucky event picks for a particular player will still happen. But we have paid much attention to event reward and cost balancing and scaling, as well as the scope and frequency of narrative events, to ensure that the system integrates well into the competitive strategy game that is Age of Wonders 4.


aow4-devdiary6-4.jpg

This event may happen for a city with a strong military focus.

Type 3: Quests​

The two event types we discussed so far were all instant in their resolution and consequences (even if some of those consequences may have a longer lasting effect). Quests as the third type give the player a task to complete within a given time and are presented in the same format with a Narrative Event starting and ending the quest. Just like regular events, quests may be offered to the player from different types of sources including Free Cities, heroes or the player’s own population (cities). We have 7 archetypes of quest objectives in the main game, ranging from standard “defeat this army” quests to diplomatic quests to improve the standing with a Free City. (More types of objectives may be encountered in our story missions ;))

aow4-devdiary6-5.jpg

A hero asks for the broken weapon of his kin to be reforged.

In the above example the player is asked to obtain a Magic Material, which are special resource nodes on the map that the player may connect to their cities for unique empire buffs. The quest already foreshadows the rewards that will be given to the player upon completion. However the exact rewards are not revealed to not undermine the narrative with spoilers. The “Mystery Bonus” is what the player will pick in the completion event of the quest.

aow4-devdiary6-6.jpg

Quest completions are set up as “pick your own reward” events.

Roleplaying Event Choices​

Role playing is an important part of Age of Wonders 4. What starts with faction creation, ruler customization and continues in game with tome picks and empire building is also complemented by narrative event choices that will suit different types of characters.

To support this we have different types of choice options in our Narrative Events. On the one hand there are good and evil deeds that inform the alignment of the player. The most extreme ones of those will only be available if you are already at a certain level of good or evil alignment and will otherwise be hidden.

On the other hand we have Affinity Checks, where the player ruler attempts to channel their magical skill in order to resolve a problem. They are similar to pen and paper roleplaying actions, where a challenge level and dice roll are compared to the stat of a character, only that in our game the affinity scores of the player empire are used instead.
  • Affinity Checks are hidden until the player empire has a high enough matching affinity (namely it must be as high as the challenge level of the check)
  • They are the only options in our events with a random chance attached. Still you can see beforehand the results of each possible outcome within the button tooltip.
    • The success chance is 50% when the affinity score equals the challenge level
    • Each affinity point on top will increase the chances of success by 10% (yes, this means guaranteed success is possible)
    • A lower success chance than 50% is not possible (then the option is still hidden)
  • Next to the gameplay effects, there are short narrative snippets within the tooltip that provide further context to what will happen with each outcome.
  • Affinity Checks are marked with a matching button icon, so they may easily be spotted when they are unlocked.
  • Failing an affinity check will always result in the player ruler temporarily losing affinity points of the involved affinity.

aow4-devdiary6-7.jpg

Negotiations with toads. Time to find the right antidote…

There are some other affinity informed options that do not involve affinity checks, but we will leave those to be explored within the game itself.

Dynamic Text​

Attentive readers of this dev diary will have noticed the many underlined text snippets within the narrative text and tooltips.

aow4-devdiary6-8.jpg


As can be seen above those underlined words indicate that a tooltip (in tooltip) is available, but it also gives a hint to the amount of dynamic text present in our Narrative Events. Dynamic means that the exact text is dependent on the specific context of the event instance when the Narrative Event is shown to the player. In the screenshot above this is the Free City name and the name of its Lord or Lady, but there could be other qualities derived from gameplay entities: titles, unit names, hero items, world map structures, etc… They are needed to keep up with the procedural nature of our game and promote replayability by giving variation to the same base event in different instances. Remember the quest about the shattered Chaos Orb? In another playthrough it may be about a Sword instead and in yet another about a famous Axe.

Normally dynamic text insertions cause all kinds of linguistic problems, starting with gendered text when the grammatical gender of the inserted words asks for different text versions - pronouns, adjectives, articles, all may change with what we insert and this gets amplified once texts are being translated (or localized as we say) into other languages. Often this means that the writing needs to adhere to many additional restrictions, the quality of translations will suffer or that inserting this many derived text entries is simply not possible (without breaking grammar).

However for Age of Wonders 4 we could secure the service of the Lingoona Grammar module and integrate it into our own pipeline. It is a linguistic engine that is made for supporting text variable insertions, parsing our text and making it conform with the correct grammar as long as we use its syntax where needed and annotate all text insertions properly. As a brief example of what this actually means let us look at the following sentence from a Narrative Event:

DevDiaryLingoonaParsed.png


It contains two inserted text entries (a hero and the player leader title) and several pronoun references to the hero. In the source text this looks like that:

devdiarylingoonasource-png.950001


As can be seen EventHero and PlayerLeader are both stored as variables in this Narrative Event. Using a mix of our own custom markup and the lingoona markup syntax then lets this source text be parsed in what could be seen above. (What is not visible here is that hero names and leader titles that may be inserted here all have annotations added to their string as well!)

Event Scripting​

Following up with some more tech, we can take a brief look at how our Narrative Events are set up under the hood. Generally speaking they are managed through our Resource Editor, which is our primary development tool for non-art asset content and system settings of the game. What makes the Narrative Events different from regular resource types is that they are heavily entwined with scripts. For this we have taken the Trigger System from Planetfall and pushed it to the next level.

The Trigger System is a modular high level scripting language that comes with a visual interface and lets us combine and instantiate the building blocks provided by our gameplay programmers to read and interact with the game and the state of a player getting the narrative event. At the core the scripting blocks are divided into four types:

  • Events
    • These are the trigger moments that make the game evaluate the script.
  • Setups
    • These are the variables created and stored as context of the script.
    • (These may also contain conditions further defining the variable content.)
  • Conditions
    • The conditions that must be fulfilled for the script to be valid and execute its actions.
  • Actions
    • The changes the script makes to the game or player UX.

ResourceED_2023-02-15_11-46-10.png

A sample narrative event script at its highest level. More actions and conditions are attached to the individual button options of the narrative event.

ResourceED_2023-02-15_13-23-00.png

The first layer of a variable creation script - all input fields are further defined in deeper layers of the script.

The trigger system is a very powerful tool, which includes many goodies you would expect from a simple programming language, such as core logical and mathematical operators, if/then statements and loops. It also allows the creation of Macros, which may be called in other scripts (or Macros ;-)) and are a vital boon for keeping our narrative event content consistent and maintainable.

For the community perhaps the greatest advantage of our narrative event setup (and part of the reason to make a more implementation focused detour in this dev diary) is that they will be fully moddable when the game comes out, as they are contained within the Resource Editor. This means that it will be possible to mod in new narrative events, also ones that completely deviate from the event content we developers have created. A fair warning that this will involve a quite steep learning curve, but I know by experience that the Age of Wonders modding community has very dedicated and talented members among them, who do not fear challenges like this one.

Conclusion​

To reflect a bit on what we have read in this dev diary, it can be said from a developer perspective that with the Narrative Event framework and their surrounding systems we have created a powerful narrative tool, which has enough robustness and flexibility to support any narrative ambitions we (will) have for the ongoing development and support of the game.

From a player perspective, the Narrative Events we created will lead to personal stories and immersion within the gameworld that is more tangible and player agency driven than ever before within an Age of Wonders game. Where previous Age of Wonders excelled at bespoke Campaign storytelling, the Narrative Events are set up to give previous campaign players an intriguing experience in all modes of our game, not just the Story Realms.

I thank you all for reading my dev diary :)

Best regards, Eomolch

Stay tuned for a new dev diary next week and consider adding the game to the Wishlist!
 

Attachments

  • aow4-devdiary6-3.jpg
    aow4-devdiary6-3.jpg
    164,2 KB · Views: 0
  • aow4-devdiary6-9.jpg
    aow4-devdiary6-9.jpg
    12,6 KB · Views: 0
  • DevDiaryLingoonaSource.png
    DevDiaryLingoonaSource.png
    26,2 KB · Views: 0
Last edited:
  • 55Like
  • 30Love
  • 7
Reactions:
I don't get one thing in this Diary. And it's in relation to Affinity Check.

Why decisions are only possible when the chances of success are bigger or equal to 50%? Why are the decisions hidden otherwise? Why can't I gamble my life for that 10% of success?
 
  • 5Like
  • 3Haha
Reactions:
The armors and clothings look great :D

I noticed that when you meet the gargoyle you can let them run and fight them as normal, but you can also let them run after shacking them for their money. That third addition is a good idea and middle point between the normal leave/good fight/evil. Adding new options to the normal events is very welcome :)

I like too the variety of options to pick. On the warlock event you got gold, military training, city happiness and a unit. Useful and varied rewards :)

Game looks great and each DD you make it look even better. Thanks for the work you put on it, gonna enjoy it when game is out :D
 
  • 4
  • 3Like
Reactions:
I don't get one thing in this Diary. And it's in relation to Affinity Check.

Why decisions are only possible when the chances of success are bigger or equal to 50%? Why are the decisions hidden otherwise? Why can't I gamble my life for that 10% of success?
I would guess it's kind of a threshold to know what to do related to the affinity in question.
For example you need X nature affinity to know specific poison and how to cure it or you need X arcane affinity to understand the spell you want to dispell.
50% would represent the complicated thing you know or have intuition to try based on your experience.
At least that's how I understand it.
 
  • 3Like
  • 2
Reactions:
Hard question: Will characters from previous game act like old themselves usually?

So if I meet Ham Binger or Sundren or Werlac can I expect how they will act?
Or magic blast did change them all? :D
 
  • 2Like
  • 1Haha
Reactions:
Why decisions are only possible when the chances of success are bigger or equal to 50%? Why are the decisions hidden otherwise? Why can't I gamble my life for that 10% of success?
"10% of success" means "I once heard that there are things called antidotes, so why don't I throw a random substance into the bottle? Maybe it will work..."
As for me, pretty obvious, why this style of planning is blocked. Classical RPG where you can play character with 1 intelligence is great, but here a quite different genre ))
 
  • 5Like
  • 2Haha
Reactions:
I got a question related to the soldiers that, like in that military city example, join you, are they determined by the leaders inside the realm or by the saved empires? in other words, lets say i make a race of ice-cold Tigrans. can those now appear in any event. only when the leader of said faction is ascended, or only when the leader is active in the current campaign?
 
  • 2Like
Reactions:
Why decisions are only possible when the chances of success are bigger or equal to 50%? Why are the decisions hidden otherwise? Why can't I gamble my life for that 10% of success?
Perhaps you can in some circumstances!:
There are some other affinity informed options that do not involve affinity checks, but we will leave those to be explored within the game itself.
 
  • 3
Reactions:
Will there be only one type of affinity check? For example, in the antidote case, can we cast on ourselves a healing spell or shrug off the effects because of our high constitution, or what happens if we are a toad ourselves?
 
  • 1Like
Reactions:
Great stuff, I will like it, I am sure! Especially the chance for modders to use this given system is really cool. :)

On a system level however, the flow of Narrative Events is uniquely tailored towards the player and their faction, analyzing the player situation, factoring in player actions and choices, with each Narrative Event becoming part of the player’s personal narrative.
So if I enter a narrative event on turn 3 it would be different from entering it in turn 32, because my faction evolved in those turns, my situation might have changed, my affinity scores growed etc.?
 
So far, there is every reason to think that AoW4 will become a benchmark in the genre of step-by-step 4 х strategies. I have never seen such a study of details and such a voluminous variable nature of the gameplay. Bravo.
 
  • 8Like
  • 2
Reactions:
wow, very impressive, I can't wait to delve into an awesome story driven 4x game, after all it is AoW 4 ;) but might I add a suggestion, will we be able to have spies to infiltrate an empire and cause havoc and maybe add a little bit of a politics events based on what you set your spies to do, maybe even a set the blame on another empire if they never find out that you were the culprit that assassinated their leader for an example? I mean there's so many narrative options with spies thrown into the mix. Just a thought which I hope will see the light in the game before it comes out =) if not I'm sure some one will make a mod for it.
 
  • 5Like
  • 2
Reactions:
While this may be a feature that easily may go over one's head and seem less exciting than everything else, I feel this is the system that will, in the long run, keep the game replayable and fresh more than everything else so far, depending how many different events and variety there is in the pool.

I love how stylized it is, rather than just a block of text on a plain screen, it shows more dialogue, personality and having units and such be part of it you can look over, but most of all, having your hero and units pop up really adds to the immersion way more than you may realize, coming from someone who's played tons of RP games, that little detail of not detaching yourself from the world and who the interaction is about brings you into it way more than "wall of text, skip" mentality. Atleast imo.

So glad you went over how moddable it is, cause it was my biggest curiosity for modding. Stellaris is a game that thrives on its RP potential and getting you immersed in the world of discovery and giving the world personality, which is a lot for a 4x space game with little else than a lot of numbers to track. AoW on the other hand with its more direct approach on the ground, with heroes you can identify as, going on adventures and more personal exploration, makes this system feel a lot more like a Crusader Kings game and I'm excited for that.

But to get back to the mod point, it's these two other games I brought as an example where events makes the game thrive when experiencing them and imo there can never ever be enough events. Hence the ability to mod more in, letting the people create more will just open up way more replayability as it has in my experience with Stellaris and Crusader Kings. The more events are in the pool, less you'll see certain events several times and the less you see it the more it'll feel refreshing as you might've already forgotten about it. And as said, this means you can continue playing with a lot more new kinds of encounter in games.

The amazing modders who create this huge event mods in these games always been my favorite and "must have". While there can arise some balance issues, I feel the randomness still keeps it fair and it makes it less possible to game them cause it's never a guarantee. Overall though it just adds roleplay flavor and immersion that outweights the need for balancing, as long as there's no ridiculous rewards, but there usually aren't and more a trickle of small ones.
 
Last edited:
  • 13
  • 8Like
Reactions:
Wow, that is an impressive Dev Diary! Many things to like here, most obvious about the elaborate event system. And Deosiderio the Puzzler looks like an interesting hero, both in appearance and name. Also a nice explanation about the Grammar Module.
Most excited about the MOD-opportunities part because this means lots of stuff to look forward to!!
 
  • 3Like
Reactions:
wow, very impressive, I can't wait to delve into an awesome story driven 4x game, after all it is AoW 4 ;) but might I add a suggestion, will we be able to have spies to infiltrate an empire and cause havoc and maybe add a little bit of a politics events based on what you set your spies to do, maybe even a set the blame on another empire if they never find out that you were the culprit that assassinated their leader for an example? I mean there's so many narrative options with spies thrown into the mix. Just a thought which I hope will see the light in the game before it comes out =) if not I'm sure some one will make a mod for it.
I would love to see something like this. Espionage is to diplomacy what the rogue archetype is to combat. It is a playstyle that has a lot of potential to pull off high risk, high reward maneuvers which would be very fun for a lot of people, me included. I think this would be super doable through this quest / event system. All you'd have to do is, for example, start by sending a spy unit to an enemy city, enacting an espionage doctrine, casting a spell, or something like that. Then you get an event with potential rewards being things like: this empire declares war on x empire, this empire is intimidated and calls for peace, this empire is struck with fear and abandons this city, or others. Of course the price of failure would have to be equally dramatic: this empire has evidence of your schemes, it declares war and all other empires are now less trusting of you, or this empire thinks x city that belongs to you rightfully should be theirs, so expect a large assault soon, for example.
 
  • 4Like
Reactions: