nihlaeth / dnd

online character sheets for Dungeons & Dragons v2.tomaas
GNU General Public License v3.0
8 stars 4 forks source link

Skills specifications and prerequisites #17

Open dazdya opened 7 years ago

dazdya commented 7 years ago

I was wondering about prerequisites in: -weapon specialisation -skill focus -skill mastery -reading This needs to be checked.

Specifications are basically the same problem, mostly. It's a matter of how we define things. Problematic skills are: -weapon training (I used the variable weapon_category in weapons.yaml) -weapon specialisation (it needs a combination of weapon_category and size) (side note: should I have named the variable weapon_size? I can still do that if it's perferable) -skill focus (the same skill as the prerequisite) -skill mastery (a skill in which the character already has focus) -reading (a known language, which is usually ill-defined in the story, and even then, sometimes many -languages tend to use the same alphabet. And madness ensued...) -history (historical periods are often defined only after the campaign is underway, and are different for every campaign) -animal handling (bird, pet or mount) -language (similar problem to reading)

I may have missed a few skills here. But we need to figure this out.

nihlaeth commented 7 years ago

Proposal for syntax

Prerequisites

The examples you mention here all have the same prerequisite as specification. So I think you can leave this out. I will assume that if the specification is an actual skill or specification, that it is a prerequisite.

Specification

No specification

specification: !!null

Simple specification

specification: [birds, pets, mounts]

Specification of any skill

specification: skill

Note that this should be the word skill, not the name of any specific skill.

Specification of another specification

specification:
  specification: skill_name

Note that this should be the actual skill name.

User specification

specification: custom

Here the user gets a text field and can define their own specification.

Information from other config files as specification

specification: WEAPON_TRAINING

Uppercasing it would make sense, since I would expose this information via constants which are supposed to be uppercase. Other than that I can work with how you did it right now.

Examples

weapon specialisation is complicated, since the prerequisite is not the same as the specification. maybe something like this?

prerequisite:
  specification: weapon training
specification:
  - WEAPON_CATEGORY
  - WEAPON_SIZE

The downside is that there is no way for the back and to infer that the weapon training specification should be the same as the specification WEAPON_CATEGORY. I also dislike keeping in the prerequisite field just for this one skill. We could just let the user figure this out. Or clutter up the back and with an exception.

It's also an exception in another sense, in that it is the only skill with specification that can only have one specification.

Edit: my example for weapon specialisation would not actually work, since this specification is identical to the simple specification I mentioned above.

dazdya commented 7 years ago

Another problem I realised: how can a person learn 2 or more weapons, or languages?

nihlaeth commented 7 years ago

I'm working on that, that should not be a problem at all

dazdya commented 7 years ago

I did not mention the skills where prerequisites were not the same as specifications, such as for tracking and craft(weaponsmith), because I thought they would not be a problem. Was I wrong?

nihlaeth commented 7 years ago

Now that's a simple dependency, I just overlooked it. so then we definitely need the prerequisite field.

Maybe then we should copy the specification syntax as much as possible.

Skill prerequisite

prerequisite: skill name

Any skill prerequisite (same as specification)

prerequisite: skill

Specification prerequisite (same as a specification)

prerequisite:
  specification: skill name

Are there any skills with prerequisites that are just plain text? Also this still does not account for the weapon specialisation skill. Does this account for all the other situations?

dazdya commented 7 years ago

Yes, I think this is complete. I can't think of any that are just text.

I think I capitalised the first letter of the skill prerequisite. Should I put all these in lower-case?

nihlaeth commented 7 years ago

Yes, I would prefer a lowercase.

After sleeping at night on it, I dislike that the different options are not visually distinguishable with the examples that I gave. This seems like a better idea:

prerequisite

prerequisite:
  skill: skill name
  any_skill: true
  specification: skill name

Here you can specify one or more different options. You don't have to input null for options you don't use, you can just leave them out. Same goes for the specification example below.

specification

specification:
  literal: [choice_one, choice_two]
  any_skill: true
  specification: skill name
  custom: true
  catalog: WEAPON_TRAINING

weapon specialisation

prerequisite:
  specification: weapon training
specification:
  specification: weapon training
  catalog: WEAPON_SIZE

The only thing missing here is that there is maximum one specification, right?

dazdya commented 7 years ago

I think you're right. I can't see if skill focus would cost more skill slots for more specifications, but I trust you on that.

I will start editing the skills according to these guidelines.

nihlaeth commented 7 years ago

That's because there is nothing about specifications in the backend yet. But I will fix that when you're done with the skill configuration file.