talkgroup

Ryuutama character generator

I’m going to make an online character generator for Ryuutama. I’m still going through the classes at Ryuutama, Natural Fantasy RPG (read-thru), but I’ve read ahead and have some ideas.

I’m using the same stack I use for survey websites:

  • WordPress
  • GravityForms + add-ons
  • Pods

I’ll be capturing most of the information on the character sheet included in the book:

Ryuutama_Natural_Fantasy_Roleplay_character_sheet.pdf (185.4 KB)

I’ll use this topic to walk through each section, and how I’ll accept and validate input, and store some of it for later (maybe). :slight_smile:

So players can use this form while following the book, I’m going to ask questions in the same order, more or less. There is an outline at Ryuutama, Natural Fantasy RPG (read-thru) - #13 by maiki.

Okay, there are a set number of Classes. Since they are collections of skills, when a player chooses their Class they are actually choosing three skills. But the Farmer also gets to choose from a subset of the total skill pool (those with a Skill Check), so we can create a follow-up conditional question to choose it.

My impulse is to create custom post types and taxonomies to hold Skills and Classes, and then reference those objects in the form; then adding new classes or skills is just adding some data to the site. However, I’m not going to support that level of flexibility in Ryuutama. I think keeping it limited to the skills and classes in the core book helps with the format of play the book is promoting. I know there is an eight class called “Navigator”, and later I’ll add it to show how much “work” the process is.

Another thing to keep in mind is the upgrade path for characters. They get a second class and associated skills! But it is done in a particular order that will simplify this form. So for now I’m going to focus on making a 1st level character. After I’ve figured that out, we’ll adopt it to second level, and so forth.

Given the importance of the Class question, it makes sense to show all the options for easy comparison. And they will only choose one.

:thinking:

I’m thinking radio buttons with “Class - Class Description” format. I bet I can use CSS in a clever way to make that look really nice across devices, too…

WIP is online at Ryuutama Character Creator – maiki, xyz.

Screenshot 2021-06-16 at 20-03-16 Ryuutama Character Creator – maiki, xyz

I did the same thing as for Class, name and description. I also added a bit of help text to assist players who may not have the book in front of them.

This part is very interesting to me. I’m trying to work with a minimal techstack for this form, while also making a form that is accessible, and also understandable by a player trying to make a character sheet…

:sweat_smile:

Okay, it’s a bit ambitious! Anyhow, here are some some thoughts…

We get three arrays of numbers to use for starting stats:

  • 6 6 6 6
  • 4 6 6 8
  • 4 4 8 8

Another, less player-friendly, more technical way of saying that is: each stat may be 4, 6, or 8, and all stats must total 24.

I considered having text present the arrays available, and make each stat a dropdown (4,6,8), and seeing if I could use a hidden calculate field in GravityForms to trip an error message if they don’t equal 24… but ugh that feels kinda clunky.

Then I thought about how many permutations there were present, and fortunately those arrays were already available and are much easier for non-mathematicians to figure out… there are 49. Each one has 24 (4x3x2x1), but 6 6 6 6 is an outlier as each value will be the same, despite each “die” being assigned to a specific stat (I mean, whatevs, the math doesn’t really track human behavior in this regard, and I’m building a human tool, so it’s interesting and I don’t know enough math to explain it ^_^).

6 6 6 6
4 6 6 8
4 6 8 6
4 6 6 8
4 8 6 6
4 6 8 6
4 8 6 6
6 4 6 8
6 4 8 6
6 4 6 8
8 4 6 6
6 4 8 6
8 4 6 6
4 4 8 8
4 4 8 8
4 8 4 8
4 8 4 8
4 8 8 4
4 8 8 4
4 4 8 8
4 4 8 8
8 4 4 8
8 4 4 8
8 4 8 4
8 4 8 4

I think a drop-down with 49 options is doable… because I live in USA and that is a common amount of place to ship stuff. But I’m not sure that makes any sense to a player trying to make a character.

Then I started thinking… what if we really got user friendly and defaulted to recommended stats based on Class and Type?! And then, we provide the dropdown with all the possible options for folks that have an opinion, presuming they know what they are doing… whatcha think of that?

1 Like

Okay, instead of a list of arrays we’ll just create a hidden field to calculate the sum of the four stats fields, and will show a validation error if it doesn’t add to 24. If I make the form multi-step, I can probably validate before the form is submitted, so that’s nice.

:thinking:

Here’s what I did, how I did it, and what I’d like to do.

I have four drop-downs, one for each ability score. I used my paraphrase to give some assistance in determining which a given stat meant. I need to make the text leading up to the ability scores better, but it works for now:

I’m considering explaining the default, and then making them opt-in to change them, so I can hide this whole section. But it works for my purposes! Each drop-down is three options: 4, 6, or 8. They default to 6. Check out what happens if you change a stat:

A message appears:

:game_die: The total of all your stats should be exactly 24. :game_die:

And it hides again once the stats total 24.

How’d I do it?

I used a couple of additional hidden fields.

The first is a number field that is hidden, and calculates the total of the four score fields, using the formula: {Strength:3} + {Dexterity:4} + {Intelligence:5} + {Spirit:6}. Those are the names and field_id.

The hidden number field just calculates and holds the sum of those fields, but it provides the conditional logic for the hidden HTML field that hold the line about the total adding up. The conditional logic is fairly simple: only show if “Stats Total” is not “24”.

And that’s it. Since the default is all 6, and totals 24 the hidden message starts hidden, and only changes if someone fiddles with the numbers.

What I’d like to do…

Well, I’m not sure how this works, accessibility-wise. I mean, it’s fairly straightforward web scripting, but I’m not sure un-hiding text under the field is a good policy… on the other hand this form doesn’t function without javascript, and my scripting may be basic enough to not be obstructive.

So that means I could use some accessibility testing on this. One option I have is to make it a multipage form, so on the first page you choose what level you are, and then fill in the successive pages (there are only 10 levels, making this straightforward). If I did that I wonder if I could pre-validate the fields before moving forward in the process, and would give an accessible, inline error message (I’d override it with a function).

Well… lots to ponder! :slight_smile:

It isn’t relevant to this (I think), but I noticed another way of doing ability scores is:

Your stats start at 4, and each stat may be upgraded twice. Each upgrade shifts it up by two (4 → 6, 6 → 8). You have 4 Upgrades.

Not sure that is easier to explain or program in a form, but interesting way to apply the ramping dice average across a spectrum of options. Reminds me of FTL…

1 Like

These are interesting, as they are derived values. Meaning technically there is nothing to choose here, merely calculate. For my purposes this is very simple, just a few fields which calculate their values from the relevant Ability Scores (namely, STR and SPI). I don’t even need to show these until the results of the form are… formed.

However, it does raise an interesting question of expectations. What I mean is: if I were writing on a character sheet I’d be using pencil, and at any point in the character creation process I’d go back and change stuff and re-calculate.

I kinda want to avoid that for the form. I’m thinking maybe I could add some text to the stats, ex:

Strength
Physical power, stamina, endurance. (Determines starting HP and Carrying Capacity)

But I don’t like that, because it loads up a simple description with knowledge about the game, and doesn’t feel like it pulls either off.

:thinking:

For the gameplay type, this is what I’m calling “cafe play dates”, and I’m thinking of someone new to this format… here’s how I think it goes:

  1. First character, the simpler the better. I don’t need to know what stats mean or how they interact with the game, I need to get in with my party and have fun because this is a game.
  2. Subsequent character, hey, I’m kinda getting into this, so I want to optimize some stuff. I see here STR and SPI changed some starting derived values; because this is a relatively simple calculation, and this online form is known to do the math for me, I’ll do the mental math in my head just before seeing the next web page load that shows my STR and SPI times some numbers.

Anyhow, rather than show this, I’m just going to produce it on output. If folks want to change it they can fill out the form again…

Okay, what does that mean for this step? Well, I just need three hidden number fields that calculate properly, and we’re done. I’ll go do that now.

And added. They produce the following output (no changes to stats):

Choose a Class
Healer - Medic and herbalist
Choose a Type
Technical - Concentration and problem-solving
Strength
6
Dexterity
6
Intelligence
6
Spirit
6
Stats Total
24
Max HP
12
Max MP
12
Carrying Capacity
9

Groovy!

1 Like

Well, this is an issue I need to resolve to move forward: picnic rules, or no?

See, if it’s picnic rules, weapons are more a choice of flair, they all mechancially act the same…

If not picnic rules, the differences between weapons is actually kind of a big deal, as they work with different stats, so each Class will lean towards a particular weapon category…

But I actually have some guidance on how to resolve this:

An experienced player will know what to choose, and a new player can easily correct their option if it doesn’t make sense, which a friend can help them with.

So that means just presenting the categories in a drop-down.

I meant of course, a set of radio buttons. Because I like to show all the options next to each other, when the number of options are reasonable as in this case.

Screenshot 2021-07-03 at 17-36-02 Ryuutama Character Creator – maiki, xyz

And of course it produces some expected output:

Choose a Class
Minstrel - Knowledgable and plays music
Choose a Type
Magic - Seasonal and Incantation spells
Strength
4
Dexterity
6
Intelligence
6
Spirit
8
Stats Total
24
Max HP
8
Max MP
16
Carrying Capacity
7
Which type of weapon have you mastered?
Polearm

Currently it just ask the question and notes the choice. Eventually I’ll need to figure out inventory, at which point this decision will add a weapon from the proficient category. Ah, “proficiency”, such a nicer sounding word than “master”…

I’m removing that WordPress instance, and thus the form. We’re about to play here on talkgroup (Let's play a game of Ryuutama), and instead I’ll just build some markdown-based templates for “Character Sheets”.

In case I or someone else what to pickup on this GravityForm configuration:

gravityforms-export-2021-08-12.json (16.5 KB)