PCGen / pcgen

Main code and data development for pcgen program release
http://pcgen.org
GNU Lesser General Public License v2.1
431 stars 340 forks source link

Markdown formatted Character Export #6979

Open Notsonoble opened 11 months ago

Notsonoble commented 11 months ago

Describe the solution you'd like

It would be nice if one of the text options of character export was either a simple or extended markdown format.

Describe alternatives you've considered

I looked at building a character export, but failed after some simple testing.

I considered taking one of the existing text exports and changing it after the fact. This is doable, but slow.

LegacyKing commented 11 months ago

Having experienced the fact that markdown has many 'flavors' depending on which site has implemented it, I'll need something a little less vague.

I frequently use RPOL which uses a very different markdown (with quick tables) than other sites or even basic editors like Obsidian (I get completely different views based on the site/app).

Try this in Obsidian and it'll be different than what you'd see on RPOL |!<2 Span two columns |= Single not centered bold | | Item 1 | Something Else | notes |

Now that my concern for which markdown variant support is out there, what is the desired layout? Emulating the existing character layout is not possible if you begin using markdown tables, also what game system is this geared towards? What extra fields will be supported? Is this designed for 3.x, Pathfinder 1e, Pathfinder 2e, D&D 4e, D&D 5e, or a very generic sheet?

Here's just one layout sample I have:

PATHFINDER Character Sheet

| Name: | xxxxx | Race: | xxx | Height: | x'x" | | Player: | | Gender: | xxxx | Weight: | xxxlbs | | Update: | | Age: | xx | Eyes: | xxx | | Align: | xxx | Size: | xxxxx | Hair: | xxx | | Deity: | xxxxx | Speed: | xxft | Hand: | xxx |

|!! |2 Ability |2 Temporary | |!! | Score | Mod | Score | Mod | |! STR | xx | | | | |! DEX | xx | | | | |! CON | xx | | | | |! INT | xx | | | | |! WIS | xx | | | | |! CHA | xx | | | |

|!! Class | Level | | xxxxx | 1 | | xxxxx | x |

|Total Level: 1 | Extra Feats: 1 | |XP : 0 | Next: xxxxxx |

|!! | Total | Current | Subdual | |2 Total | Dex |2 Misc | | HP: | xx | xx | | Init: | +x | = | x | + | |

|!! | Total | | Armr |2 Shld |2 Dex |2 Misc | | Full: | 10 | = 10 + | | + | | + | | + | | | AC: | 10 | = 10 + | | + | | + | | + | | | Touch: | 10 | = 10 + | xxx | + | xxx | + | | + | | | FlatFoot: | 10 | = 10 + | | + | | + | xxx | + | |

|!! SAVES |7 Ability | |= |2 Bonus | Base |2 Mod |2 Magic | | Fort (Con): | +x | = | | + | | + | | | Ref (Dex): | +x | = | | + | | + | | | Will (Wis): | +x | = | | + | | + | |

|!! Base | Total | | Base | | Str | | Misc | | Base | Total | | Base | | Dex | | Misc | | Melee: | +x | = | | + | | + | | | Range: | +x | = | | + | | + | |

|!! Combat |2 Total | Base |2 Str |2 Misc | | Mnvr |2 Total | Base |2 Str |2 Dex |2 Misc | | Mnvr: | +x | = | 0 | + | 0 | + | 0 | | Def: | 10 | = | 10 | + | 0 | + | 0 | + | 0 | + | 0 |

|2 Weapon: |!3 xxxxxx |3 Weight: x lbs | | Move Name | Type | Atk | Damage | Crit | Range | Type | Special | | Attack | Melee | +xx | xdx+x | xx-20/x2 | - | x | | | Charge | Melee | +xx | xdx+x | xx-20/x2 | - | x | |

|2 Weapon: |!3 xxxxxx |3 Weight: x lbs | | Move Name | Type | Atk | Damage | Crit | Range | Type | Special | | Attack | Melee | +xx | xdx+x | xx-20/x2 | - | x | |

|2 Armor: |!3 xxxxxx |2 Weight: xx lbs | | AC | MaxDex | Pen. | SplFail | Speed | Special | | +x | +x | -x | xx% | xxft | None |

|2 Armor: |!3 xxxxxx |2 Weight: xx lbs | | AC | MaxDex | Pen. | SplFail | Speed | Special | | +x | +x | -x | xx% | xxft | None |

ABILITIES/FEATS Feats[list] [] [/list] Other Abilities[list] []Favored Class: [/list]

SPELLBOOK:


SPELLS KNOWN/PREPARED: 0: 1: 2: x:


|!! SPELLS PER DAY | / | SAVE DC (Spell Level + Ability Mod + 10) | | 1: | / | DC xx | | 2: | / | DC xx | | x: | / | DC xx |

SKILLS (Max Rank = Level, Class Skills get +3 bonus with at least 1 Rank)

|!! | Key |2 Total |3 Ability |2 Class |2 Misc | |!! | Ability |2 Mod | Mod |2 Ranks |2 Skill |2 Mod | | Acrobatics | (Dex) + | | = | | + | | + | | + | | | Appraise | (Int) + | | = | | + | | + | | + | | | Bluff | (Cha) + | | = | | + | | + | | + | | | Climb | (Str) + | | = | | + | | + | | + | | | Craft: | (Int) + | | = | | + | | + | | + | | | Diplomacy | (Cha) + | | = | | + | | + | | + | | | Disable Device^ | (Dex) + | | = | | + | | + | | + | | | Disguise | (Cha) + | | = | | + | | + | | + | | | Escape Artist | (Dex) + | | = | | + | | + | | + | | | Fly | (Dex) + | | = | | + | | + | | + | | | Handle Animal^ | (Cha) + | | = | | + | | + | | + | | | Heal | (Wis) + | | = | | + | | + | | + | | | Intimidate | (Cha) + | | = | | + | | + | | + | | | Knowledge:^ | (Int) + | | = | | + | | + | | + | | | Knowledge:^ | (Int) + | | = | | + | | + | | + | | | Knowledge:^ | (Int) + | | = | | + | | + | | + | | | Linguistics | (Int) + | | = | | + | | + | | + | | | Perception | (Wis) + | | = | | + | | + | | + | | | Perform:_ | (Cha) + | | = | | + | | + | | + | | | Profession:^ | (Wis) + | | = | | + | | + | | + | | | Ride | (Dex) + | | = | | + | | + | | + | | | Sense Motive | (Wis) + | | = | | + | | + | | + | | | Sleight of Hand^ | (Dex) + | | = | | + | | + | | + | | | Spellcraft^ | (Int) + | | = | | + | | + | | + | | | Stealth | (Dex) + | | = | | + | | + | | + | | | Survival | (Wis) + | | = | | + | | + | | + | | | Swim | (Str) + | | = | | + | | + | | + | | | Use Magic Device^ | (Cha) + | | = | | + | | + | | + | |

^Trained only Languages:


MONEY:

GEAR (Weight):

TOTAL WEIGHT:

| LOAD: | Light | Medium (-3) | Heavy/Max (-6) | Lift (x 2) | Push/Drag (x 5) | | |^ lb |^ lb |^ lb |^ lb |^ lb |

MAGIC ITEMS


DESCRIPTION


BACKGROUND


Notsonoble commented 11 months ago

Honestly I'm okay with just the basic syntax from here https://www.markdownguide.org/basic-syntax/ or maybe the github flavor. As for formatting, I'm looking for a statblock layout to quickly import into a hugo or jekyll managed webpage. So a something like this for PF1 and 3.5 (and possible PF2, as our group is considering moving):

 # Tezir

Male Catfolk sorcerer 1  
None Medium humanoid \(catfolk\)  
**Init** +3, **Senses** low-light vision; Perception +1  

## DEFENSE

**AC** 13, touch 13, flat-footed 10 \(+3 Dex, \)  
**hp** 7 \(\(1d6\)+1\)
**Fort** +1, **Ref** +3, **Will** +3

## OFFENSE

**Speed** 30 ft.
**Melee** claw +1/+1 \(1d4+1\)
**Special Attacks** Shadowstrike 6/day \(1d4 nonlethal\), 

**Sorcerer Spells Known** \(CL 1st; concentration +4\)

- 0th\(at will\)-*bleed*\(DC 13\), *flare*\(DC 13\), *read magic*\(DC \), *resistance*\(DC 13\)
- 1st\(4/day\)-*dancing darkness*, *vanish*\(DC 14\)

## STATISTICS

**Str** 13, **Dex** 16, **Con** 12, **Int** 14, **Wis** 12, **Cha** 16  
**Base Atk** +0; **CMB** +1; **CMD** 14  
**Feats** Arcane Strike, Eschew Materials  
**Skills** Knowledge \(Arcana\) +6, Spellcraft +6, Stealth +7, Use Magic Device +7  
**Languages** Catfolk, Common  
**SQ** bloodline arcana \(add darkness descriptor or shadow subschool spell's level to stealth for 1d4 rounds\), cantrips, cat's claws, cat's luck, shadow bloodline, spells, sprinter, weapon and armor proficiency  
**Combat Gear** 
**Other Gear** claw, 59.5 gp

## SPECIAL ABILITIES

**Bloodline** Each sorcerer has a source of magic somewhere in her heritage that grants her spells, bonus feats, an additional class skill, and other special abilities. This source can represent a blood relation or an extreme event involving a creature somewhere in the family's past. For example, a sorcerer might have a dragon as a distant relative or her grandfather might have signed a terrible contract with a devil. Regardless of the source, this influence manifests in a number of ways as the sorcerer gains levels. A sorcerer must pick one bloodline upon taking her first level of sorcerer. Once made, this choice cannot be changed.

**Bloodline Arcana** Whenever you cast a spell with the darkness descriptor or the shadow subschool, you gain a circumstance bonus on Stealth checks equal to the spell's level for 1d4 rounds.

**Bloodline Powers** Your benighted heritage infuses your mastery of magic with the essence of shadowstuff.

**Cantrips** Sorcerers learn a number of cantrips, or 0-level spells. These spells are cast like any other spell, but they do not consume any slots and may be used again.

**Cat's Claws** Some catfolk have stronger and more developed claws than other members of their race, and can use them to make attacks. Catfolk with this racial trait have a pair of claws they can use as natural weapons. These claws are primary attacks that deal 1d4 points of damage.

**Cat's Luck \(Ex\)** Once per day when a catfolk attempts a Reflex saving throw, he can roll the saving throw twice and take the better result. He must decide to use this ability before the saving throw is attempted.

**Eschew Materials** A sorcerer gains Eschew Materials as a bonus feat at 1st level.

**Shadow Bloodline** Spirits from the shadow plane dally at times in the world of light, and such as these lay with your ancestors once upon a time, imparting the mystery of shadow-stuff into your lineage. You are often sullen and withdrawn, preferring to skulk at the fringes of social circles and keep to yourself, cultivating an air of mystery and majesty that is all your own.

**Shadow Bloodline ~ Bonus Spells** 

**Shadowstrike \(Sp\)** You can make a melee touch attack as a standard action that inflicts 1d4 points of nonlethal damage. In addition, the target is dazzled for 1 minute. Creatures with low-light vision or darkvision are not dazzled by this ability. You can use this ability 6 times per day.

**Spells** A sorcerer casts arcane spells drawn primarily from the sorcerer/wizard spell list. She can cast any spell she knows without preparing it ahead of time. To learn or cast a spell, a sorcerer must have a Charisma score equal to at least 10 + the spell level. The Difficulty Class for a saving throw against a sorcerer's spell is 13 + the spell level.

**Sprinter** Catfolk gain a 10-foot racial bonus to their speed when using the charge, run, or withdraw actions.

**Weapon and Armor Proficiency** Sorcerers are proficient with all simple weapons. They are not proficient with any type of armor or shield. Armor interferes with a sorcerer's gestures, which can cause her spells with somatic components to fail.