RPG idea: Mechanics follow personality

There’s often a disconnect in TTRPGs between what characters can do, their mechanical options, and how they do it, their personalities and emotions.  Here’s an example of how to make mechanical options come from character behavior.

Characters start out as generalists: a little magic, a little sneaky, a little smashy.  At the end of a significant chunk of play (maybe clearing a dungeon, or solving a mystery, or completing a journey), each player writes down a descriptor that matches how each other character has behaved during that chunk.

Eladrial was reckless.  Fogban was cunning.  Rex was oblivious.

Each descriptor maps to one or more character moves:

  • Reckless
    • Reckless attack. You have advantage on attack rolls. Enemies have advantage on attack rolls against you.
    • Charge through: You have +3 AC vs. Opportunity Attacks, readied actions, and attacks from traps.
  • Cunning
    • When you take a moment to observe a target undetected, the GM will tell you one of the target’s weaknesses.
    • +1 to Deception
    • When you explain a cunning plan, party members get +1 forward when following your direction.
  • Oblivious
    • When you are targeted by charm, compulsion, or manipulation effects, there is a 50% chance they completely fail, as you simply don’t notice the attempt.

The GM gives each player a list of potential moves that is all the moves mapped to all the descriptors that the other players assigned to his character.  The player chooses 1 move to add to his character’s list of moves.

PROCJAM / 7DFPS 2018, Photo Copy: final push

PROCJAM, 7DFPS

Day 1, Day 2, Day 3, Day 4, Day 5, Day 6]

Play Photo Copy in your browser!

 

Time was almost up, so I concentrated on getting the game into a playable state.  After breaking the AI photographer the day before, I needed a quick way to make it functional again. I added an invisible box around the extents of each landmark and had the AI photographer point at that.  Alas, no understanding of symmetry, or lining up multiple landmarks in one image, or any other things I was hoping to implement at the start of the project.

I also cleaned up the menus and functionality to start and end the game.  The introduction used to be a separate scene, but I pulled it into the main scene.  Less to keep track of, and it let the player look at the instructions while playing by hitting Escape.  Alas, walking through the exit portal, then canceling the exit UI was causing trouble, and it was faster to cut the portal than to debug it.  RIP Exit Portal. I still believe in diagetic UI.

At this point the player could start the game, enter the world, see photos from the AI photographer, take photos, have them scored, then leave the game.  I exported a copy and uploaded it to itch.io, just so I’d have a working version to fall back on.  I still wanted to add features.

The inspiration for this entire Black Rock City generator was a camp name generator written in Tracery. Since Unity supports JavaScript, I tried just putting the Tracery files in my Unity project, but there were some errors.  Fortunately, Max Kreminski had ported Tracery to C# specifically for use in Unity. (TracerySharp on github) Once I could generate camp names in Unity, I assigned each city block a name.  When the user “looked” at a camp (when a ray from the center of the screen intersected the block’s collider) the name would appear on screen.

This added a lot of character to the city.  Just running from camp to camp, reading the amusing names was fun.  This technique was easily extended to the street signs as well, so the player could actually read the street signs by looking at the them, which really makes the city feel like a real place.

My mind raced.  Photos from the AI photographer could be annotated with hints, like, “Found this cool art piece on Echidna street”, “took this picture while chilling at the Undetectable Capitalism Dome”, “some guy told me this thing is called Normie Zone”  Before I started that sub-project, I wanted to be sure that looking at things still worked when two cameras shared the same viewport.  it seemed to work as expected in the editor, but I built an EXE to be sure.  IT worked differently in the EXE.  I built to WebGL, since most people would play it in the browser on itch.io, and it worked a third way!  I did not have time to debug that and add all those new features, so stopped there.

The first version that I uploaded to itch.io would be the final version.  Rushing and stressing were against the spirit of PROCJAM, so I practiced the  skill of knowing when to leave well enough alone.  After I made peace with ending in a stable state instead of working up to the deadline, 7DFPS extended the deadline! Self-control was required to avoid diving in once more.

Play Photo Copy in your browser!

PROCJAM / 7DFPS 2018: Day 6

PROCJAM, 7DFPS

Day 1, Day 2, Day 3, Day 4, Day 5

I’m approaching the end, so I need to wrap things up.  Here are some relatively quick fixes.

Pressing Escape will exit the game, but there’s also a diagetic exit at the end of the 6:00 road.

Also visible in that image is the trash fence. Burning Man is surrrounded by a pentagonal fence meant to catch anything form the city that blows away in the desert wind.  I added a circular fence to keep players from wandering off the edge of the world. The real fence has a square lattice pattern, but I made the width of the fence segments adjustable and I didn’t want to deal with the texture stretching, so my fence has only horizontal bands.

One of the last things I added to my Burning Man simulation was the Man himself.  He’s another low-poly mesh built in Milkshape, although the base is generated with the same Lathe that creates the Temple.

Camp structures will now fill long blocks.  I just re-run the structure placement algorithm with several starting locations along the long axis of the camp.

There are some weird things visible in the above image that aren’t normal camp structures.  Those are landmarks! Yes, I’ve finally added some landmarks to a game ostensibly about photographing landmarks.  There’s a two level-generator that lays out several paths, then puts objects along those paths. It can create.

Balloons (1 thin, irregular path with a large sphere at the end)

Towers ( a line of vertical lines)

Abstract art (irregular paths of irregular shapes)

An unfortunate side effect of these wonderful new landmarks: the AI Photographer doesn’t know how to look at them.  The Burning Man sim has overtaken the photography sim so much that the original goal of the project no longer works.  Whoops!  There’s still a bit of time to re-write the photographer, though.

PROCJAM / 7DFPS 2018, Day 5

PROCJAM, 7DFPS

Day 1, Day 2, Day 3, Day 4

Unity uses two programming languages:  C# and JavaScript.  I use C# because I like strongly-typed languages.  I want to see as many mistakes at compile-time as possible. But Tracery (which I used to generate Burning Man Camp names) is written in JavaScript. Can I just copy the files in to my project’s directory structure? No! Unity finds several errors in files that work just fine in a web browser.  Searching online reveals two people that ported Tracery to C# specifically for use in Unity.  Both authors caution that these ports are completely unsupported, but that’s good enough for me.  I assign a name to each city block, but displaying that name to the user requires learning how to use Unity’s UI features.  I don’t want to deal with that hassle, so I switch tasks!

The Temple was a giant blank cylinder, and the Man was standing on a similarly boring box. I create a Lathe algorithm to replace both.  The Lathe draws some line segments from bottom to top, then rotates that outline around the Y-axis, kinda like a vase.  This is quite-low-level compared to most of what I’ve built.  I’m not using built-in primitives or importing meshes I built in a 3D editor.  I’m creating the object one piece at a time while the game is running. Not only do I have to write nested loops to place each vertex, I have to remember what order I created them, because the triangles are one giant list of references to the one giant list of vertices.  Speed is important at this level, so I don’t get the luxury of a big tree structure of objects. After writing some triangles backwards, and forgetting a few numbers, I get a shape!

What is this? The light acts like it’s completely flat!  I had missed two things.

  1. Unity stores only one normal per vertex, so if two triangles share a vertex, Unity will smooth the join between those triangles.  I want the angular, low-poly look, so I don’t want any triangles to share vertexes.  A quick sketch shows that each vertex borders six triangles, so I have to edit my vertex generation loop so it creates six times as many verticex!  Now the triangle creation loop needs to use each of those vertices exactly once.  Yikes!
  2. The second step is to call the RecalculateNormals() function.  Much easier!

So much better!  You’ll notice that this temple is spikier than a vase.  That’s “star mode.”  I bring a piece of code over from my bodypaint generator that reduces  the radius of every other vertical row of vertices.

After finishing this project, I am ready to tackle some UI work. People won’t enjoy even the coolest game if they don’t know how to play, so I need to explain myself.  I add a title screen with a list of controls and a bit of story.  This is a game about copying photo.s. The original code name was “Art Fraud” But now i’m having second thoughts.  Taking photos in a magical, beautiful place seems so joyful and positive. Do I really want to flavor it as theft and subterfuge? As a compromise, I let the user select Light or Dark stories. There’s no mechanical difference, but the little paragraph re-contextualizes why one has these photos, and why one wants to re-create them.

PROCJAM / 7DFPS 2018: Day 4

PROCJAM, 7DFPS

Day 1, Day 2, Day 3

Building Burning Man is really fun, so I neglected the photography part of the game to generate even more types of things.  I happen to have an extensive list of galleries of photos from Burning Man, so I perused a few of them to see what types of tents and vehicles people used in their camps.  It turns out that’s the least interesting part of Burning Man.  Most people photograph the huge installations, the mutant vehicles, or their friends, not the tent they sleep in 3 hours a day.

I made a few tents, a small cargo truck, a “fifth wheel” trailer, and a school bus to put in camps, as well as a street sign for intersections.  I had to look up dimensions, because I want these objects be the proper size in the world.  I still create 3D models in Milkshape, a program I got almost 20 years ago to do Half-Life 1 mods.  This encourages a low-poly, flat-shaded styles, since I don’t have the skills or the tools to make fancier objects.

Now that I have these objects, how do I place them into the city blocks I have defined?  I have an algorithm for packing rectangles into a 2D space from last year’s PROCJAM entry: Spaceship Wrecker!

The constraints are different.  Instead of packing a per-determined list of parts into an unbounded space, I want to fill a bounded space with whatever will fit. I also had to pad the dimensions of these vehicles and structures, since people need space to walk between them.  I pick an object at random, and if I have to push it out of bounds to avoid colliding with objects that have already been placed, I discard that object and count a failure.  After a certain number of failures, I figure the camp is full and move on.  Since the algorithm pushes objects in all directions equally, it works well for squarish camps, but not for the very long camps at the far rim of the city.

This algorithm still needs improvement.  I could try something more like Tetris, where I try to fill things up from one end to the other, or I could just use the current algorithm at multiple points along the long campsite.  With relatively cheap, simple algorithms, and especially with the time constraints of a game jam, finding the most efficient solution may not be worth the trouble.

To make camps look unified, structures in a camp will have similar colors.  How similar? That varies by camp. The camp in the foreground above has blue, green, cyan, even purple, but the ones behind it are all green or all magenta.

So I planned to generate photos, and what am I generating?

  • Width, number, & spacing of radial & concentric roads
  • location & size of landmarks
  • Structure type, structure position, structure color, and range of structure color.in camps
  • Also photos, I guess

PROCJAM 2018: Photo Copy, Day 3

PROCJAM, 7DFPS

Day 1, Day 2

Now that the game could display photos and the player could move around to recreate them, I wanted something to photograph.  The weird snowy test map with its bright primitive shapes wasn’t doing it for me.  But what landscape could I create that would have cool landmarks and not be too hard to navigate.  Well, remember the toy I made back on day 1 that had no relation to this project?

Burning Man is a geometric city on a flat plain.  It can’t be too hard to generate radial and concentric streets, right?  Man in the middle, temple in the gap where the roads don’t touch. Simple, right?

Yeah, it’s pretty simple.  I’m approximating the concentric roads with straight segments between the radial roads, which mostly works.  After defining the roads, I defined “blocks”, spaces between roads where structures could go.  Most would be basic tents & shelters, but a few would be landmarks.

A mistake in the code that rotates the blocks into place created something that looked like the solar collectors from Blade Runner 2049.  While cool, that’s the wrong sci-fi alternate universe.

The block in the center will eventually be the giant “Man” statue, and the large cylinder will be the “temple”

These temporary assets are already more interesting than the old landscape.  The shape of the city creates pleasing leading lines.  I did increase the height of the player character and the AI photographer to 6 meters so they can see over the camps, but are still shorter than the landmarks.  Maybe they are piloting quadcopters. If so, I’ll have to remove the footstep sounds that came with the FPS controller.

PROCJAM / 7DFPS 2018: Photo Copy, Day 2

PROCJAM, 7DFPS

Day 1

Today I worked on mostly the non-procedural parts of the game.  Of course the procedural generation is the reason I’m doing the jam, but I have to build a game around it so that other people can actually find and experience what I generate.

Updates to the AI photographer were minor.  Instead of placing the camera completely anywhere on the terrain, I picked a distance from my selected landmark based on that landmark’s size.  Distance and a random angle gave me X & Z coordinates, and I ray-casted downwards to place the AI Photographer on the terrain.  That ensured the player could reach the same position.

Setting up the camera views were trickier.  Unity can send a camera’s output to something called a RenderTexture instead of the screen. I thought I’d make a few of these RenderTextures, get the AI photographer to render photos to them, then display them on the UI.  But I couldn’t figure out how to do that, despite clicking around in the Editor and the documentation for a while.

Instead I decided to have two cameras render to the same screen.  On the left, the player’s view, controllable with standard FPS controls.  On the right, the AI photographer’s view.  There’s a key to hide the AI photographer’s view and fill the screen with the normal FPS view.  There’s a nice transition where the FPS view shrinks and the AI photographer’s view slides in from the edge of the screen.  In photo comparison mode, both viewports are square, regardless of the window the game is running in.  Again, the player needs to be able to recreate the AI photographer’s photos perfectly, so the two views need to be identical.

With the cameras sorted, I was able to play the game!  Even in its simple form, with temporary assets and no scoring system, I found it very satisfying to match up every little thing in the photo.  I’m probably biased, since I really enjoy composing photographs with physical cameras, but it’s a good sign that this game is going to work.

PROCJAM 2018: Photo Copy, Day 1

I’m participating in PROCJAM, a low-pressure game jam whose motto is “Make Something That Makes Something.”

What should I generate?  I like photography, and I had an idea for teaching an AI to generate photographs of landmarks in a landscape. The player would walk through the landscape to the location where the photo was taken.  Breath of the Wild and Skyrim both have sidequests where players try to find a location based on a drawing or photograph, and I enjoy them.  I also relish the chance to pass some of my photographic knowledge on to an electronic protege. The player’s goal in my game is to replicate the generated photograph as closely as possible, so I call the game “Photo Copy.”

I had uninstalled the version of Unity I had used last year to create Spaceship Wrecker (play in your browser, blog post), and thought I might as well get the latest version instead of re-installing that one.  So I downloaded Unity 2018.2 and set about trying to mock up some test assets: some terrain with landmarks on it.

I didn’t enjoy sculpting the terrain in the Unity Editor. I wanted vertical walls around the edge to keep the player contained, and thought it would be easier to make them by drawing a heightmap in an image editor.  Alas, Unity only accepts heightmaps in .RAW format, and my image editors didn’t output to .RAW.  I found a tool that could import a normal image (BMP, PNG, or JPG) and output a RAW, so I had to use 3 programs to get my terrain.  GIMP -> L3TD -> Unity.

I needed normal FPS controls for the player to move around on the terrain.  Surely something like that is included, right?  Forum threads indicated it was, but those threads were old.  Previous versions had “Standard Assets” included as part of the installer, but this version didn’t.  I would have to use the Asset Store to download them separately.

Last year I used MonoDevelop as my code editor.  Visual Studio felt like overkill, and it was another account to create, another EULA to accept.  Unity 2018 dropped support for MonoDevelop.  Visual Studio was my only option.

Because of this sequence of frustrations, I uninstalled Unity and looked at some cool photos from Burning Man.  All the art installations and quirky camp themes are fun and inspiring.  I started another Tracery project to generate some wacky camps.  I’ve used Javascript and Tracery a lot, so starting a new project and getting some output was quick and easy!

I considered using Cheap Bots Done Quick, to put the output in a Twitter Bot, but I don’t see many benefits to that format, so I kept it on a local webpage. What a fun distraction that is not at all related to my PROCJAM project.

Feeling much better, I downloaded Unity 2017. Now I had the First Person Controller and could write code in MonoDevelop. Once i had the landmarks in the terrain, I made the first photography algorithm: place the camera in a random location, high above anything it might collide with, and point it at a random landmark.

It is technically a photo!  That was enough excitement for day 1.

Death and consequences

There’s controversy in the TTRPG world about character death.  Some don’t like it. Some say it’s part of the game. Some say, and this is the part I disagree with, that without character death, a game has no real stakes. So let’s talk about some of my characters, and how they won and lost important things that were not their own lives

Heathcliff

Heathcliff was a level 5 Halfling Ranger who charged lance-first into battle atop a mastiff.  In the climactic showdown with an undead Sorcerer in flooded catacombs, he was paralyzed and executed.  (Don’t worry, the dog was OK.) The rest of the party sold his gear to pay for his resurrection.  A level 5 character is a super-hero compared to commoners with no class levels.  Like, Daredevil or the Punisher, not Green Lantern, but still a super-hero.  I figured that he would excel as a town guard or a hunter even without his magical gear.  Death was a major setback, yes, but he could wait a while, save up some cash for new gear, and go adventuring again later.  It’s like when one’s first career doesn’t work out, and one has to move back to one’s parents for a while.

Cklypherrderrime

Cklypherrderrime (call him Cklyph) was a Gnome (later Suli) Wizard who started off as cheerful, mischievous, and curious. The party had no Cleric, so they often had to return to the capital city to remove harmful effects like blindness, negative levels, or death. Since Cklyph had not picked a god to follow, he would visit a different temple each time, and listen to the priests explain the virtues and benefits of following their god.

The campaign was long, and the party was always behind, always chasing another death cult, never able figure out the grand scheme that united all these villains.  No one could help them, because they were superheroes. Yet after the party defeated each scheme, they had to sit and wait for something else to catch fire.  No research or prevention was effective.

Cklyph lost his Good alignment in the pursuit of power to keep his party alive, because they were all that he cared about.  The rest of the world was either hostile or useless.  He used to eschew necromancy, and declared Cloudkill a spell for terrorists, but by the end, everything was on the table.  After defeating a powerful dragon, he raised it as a skeletal servant.  “I’m going to make this guy die for us twice.”

I mentioned that Cklyph was a Gnome and a Suli. Cklyph did die once, but he had prepared.  A younger, more fun-loving Cklyph had prepared a kit in case of his death and given it to the healer.  It contained material components for a Reincarnation spell, instructions to for contacting a Druid to cast the spell, and cash to pay the Druid. So when Cklyph was finally struck down, he returned to life in a new Suli body, not the Gnome body he was used before. That was a cool experience, and Cklyph did experience a bit of wonder getting used to the new, stronger, taller body.

The Bard’s friend from her hometown was turned to stone and shattered, and Cklyph did not help pay for the resurrection because he considered it a waste of resources.  The Bard, a much better person, bore the whole cost herself.  This same hometown had an election and an organized crime family was close to winning.  Cklyph didn’t care. The town kept getting attacked by giants and serial killers and whatnot.  Poor or unfair administration seemed unimportant.   He did offer to make a copy of the Bard so she could both be mayor and continue adventuring.  The party almost missed a plot hook because Cklyph couldn’t be bothered to leave his magical wizard fortress and check in on this town of weak, useless people.

So at the end of a year and half of constant fighting, Cklyph was callous, power-hungry, and paranoid.  The campaign fell apart, so Cklyph never got closure, but his options seemed to be death, or isolation in his own personal dimension.

Wally

Wally was a knight in shining armor.  He loved his city, even though he knew it was corrupt. He saw the good in it and was dedicated to making it a better place.  He and the party decided that they were going to clean up the town non-lethally.  During a riot he found some ruffians threatening to beat someone.  Wally stepped up, drew his warhammer, then dropped it and beat the ruffians down by slapping them with his armored hand. The healer dragged them to the curb, healed them a bit, then scolded them about being productive members of society. Criminals and low-lifes tried to kill the party and they would beat them down, stabilize them, and drag them in to the police.  Once a fight got really out of hand and the building caught fire, so Wally ran back and forth, dragging his unconscious enemies out of danger on his tower shield.

But then the archer critted a demi-human and killed it instantly.  Wally was distraught!  He stopped in the middle of the dungeon to yell at his own party!  He should not have blamed the archer, since crits are random, but he did. One party member argued that demi-humans weren’t really people, so it was OK to kill them. (Wally was OK with killing animals but not people.) Another revealed that he didn’t mind killing at all.  Wally almost left the party right then, but was convinced to do one last mission. Someone was going to be executed for assassinating the king, and the party was there to make sure there was no funny business.  Before the main event, the police brought out and executed the criminals that the party had captured.  Even those closest to Wally didn’t share his commitment to improving the town non-lethally, and the good he thought he had done was destroyed right in front of him.

Sure enough, someone disrupted the main execution. As the rest of the party leapt into action, Wally turned and left.  We walked out of the palace and out of the city without stopping or saying good bye. He’s out there looking for a place he can fit in, where he can do the right thing and make things better, a place that probably doesn’t exist.

Conclusion

In my games, for my characters, death has not been the only true failure, the one thing that could actually stop them from accomplishing their goals.  Yes, an unrecoverable death means the end of that character, but there are often ways to recover from death.  I think of the time we TPKed after skipping straight to the boss fight and think, “A perfect storm of nonsense.  What a great story.”  I think of the barbarian who almost died rather than ask for help and think, “That would have been a good way to go.” I think of Cklyph slowly sliding into the cruelty that he was supposedly fighting, or the utter failure of Wally’s idealism and I still get emotional.

Narrative Scars

Like actual physical scars, traumatic events can permanently change people.  People marked by such events are always reminded of them.  Here’s a way to represent emotional or mental scars with physical scars in a magical role-playing game.  I use Powered By The Apocalypse jargon, since that’s the kind of RPG I usually run.

When you rest and heal after battle, consider how you earned your wounds. If a wound or the circumstances surrounding it are important to you, it does not heal like normal and you gain a Scar.

When you display a Scar to remind yourself or others of the lesson you earned with blood, everyone who sees it takes +1 forward when acting on your lesson.

When you decide that a Scar no longer holds power or significance, mark XP. The next time you receive magical healing, the Scar will fade.

Examples:

  • A bodyguard re-affirms her conviction by showing the wounds she took in her charge’s place.
  • Friends gleefully show the burns from that experimental hoverbike that almost worked.
  • The hero tears off his neckerchief.  “You should have finished the job, Warwick! I won’t make the same mistake!”
  • “We got in too deep on bad intel. I lost a finger and two comrades in that jungle.  Never again!”