Aabahran

Formatting Guide [locked]

edited by Erelei · · 5 revisions
Contents
Contents

Everything below works on any wiki or forum page. CommonMark plus GFM extras (tables, strikethrough, autolinks, task lists) work the standard way. The custom tags after that are unique to Aabahran.

Each entry shows the source first, then how it renders.

Paragraphs and line breaks

Plain text becomes paragraphs. A blank line starts a new paragraph. A single newline becomes a hard break.

First line.
Second line is still in the same paragraph.

Third paragraph after a blank line.

First line.
Second line is still in the same paragraph.

Third paragraph after a blank line.

Emphasis

*italic*, _also italic_
**bold**, __also bold__
***bold italic***
~~strikethrough~~

italic, also italic
bold, also bold
bold italic
strikethrough

Headings

# H1 page title
## H2 section
### H3 subsection
#### H4
##### H5
###### H6

Headings get an auto-generated id so #section-name links work. Override the id with {#anchor}:

## Races {#races}

Lists

- Bullet
- Another bullet
  - Nested
  - Nested
- Last
  • Bullet
  • Another bullet
    • Nested
    • Nested
  • Last
1. First
2. Second
3. Third
  1. First
  2. Second
  3. Third

Task lists:

- [x] Done
- [ ] Not done
- [ ] Still pending
  • Done
  • Not done
  • Still pending
External: [Aabahran](https://theforsakenlands.com)
Autolink: <https://theforsakenlands.com>
Wiki page: [[Cabals]]
Wiki rename: [[Cabals/Tribunal\|the Tribunal]]
Same-page anchor: [jump to Embeds](#embeds)

External: Aabahran
Autolink: https://theforsakenlands.com
Wiki page: Cabals
Wiki rename: the Tribunal
Same-page anchor: jump to Embeds

Images

![alt text](/static/skull.png)

For full-width wiki banners, use the {banner:} tag in the custom section below.

Blockquotes

> This is a quote.
> Second line of the same quote.
>
> > Nested quote.

This is a quote.
Second line of the same quote.

Nested quote.

Code

Inline:

Use `get_skill(ch, sn)` to read a skill value.

Use get_skill(ch, sn) to read a skill value.

Fenced block with language:

```c
void example(int x) {
    if (x > 0) return;
}
```
void example(int x) {
    if (x > 0) return;
}

Horizontal rule

---

Tables

| Race  | Vulnerable | Resistant |
| :---  | :---:      | :---:     |
| Avian | air        | -         |
| Drow  | silver     | charm     |
| Dwarf | drowning   | poison    |
Race Vulnerable Resistant
Avian air -
Drow silver charm
Dwarf drowning poison

Custom tags

Tags use single curly braces. Either {name}, {name:arg}, or {name}...{/name}. Anything inside a fenced code block stays as plain text, so the source blocks below render exactly as written.

Color text

{#c4a872}A muted gold phrase{/} and {#8BA4B0}highlight-color text{/}.

A muted gold phrase and highlight-color text.

Script font

{script}From the journals of Erelei{/}

From the journals of Erelei

Redact

A bar in the page background color hides the text. Click the bar to reveal it.

The traitor was {redact}Vellichor{/redact}.

The traitor was Vellichor.

Drop cap

Big initial letter on the first character of a paragraph.

{drop}A abahran is a world shaped by war, divine conflict, and the struggle between Life and Death.

A abahran is a world shaped by war, divine conflict, and the struggle between Life and Death.

Stat bar

Inline scaled bar with the number on top. Format: low:current:cap.

{statbar:14:18:25}

18

Mentions

nice fix @Erelei

nice fix @erelei

Eyebrow heading

A small lowercase label above a heading. Prefix any heading with [Label].

## [Setting] The World
## [Character] Races and Classes

The World

Aabahran has endured three great ages.

Races and Classes

Twenty-four races call Aabahran home.

Wide banner pulled from web/static/img/wiki/. Extensions png, jpg, svg. Path can include subdirs.

{banner:before_cataclysm.png}

Table of contents

Drops a TOC card that floats on the right on desktop, full width on mobile. Only fires when the page has two or more headings.

{toc}

Stat card

A key/value table wrapped as a compact card. Title is optional.

{statcard:Stat Block}
| Name  | Erelei the Wanderer |
| ----- | ------------------- |
| Race  | Elf                 |
| Class | Rogue               |
| Cabal | Vellichor           |
{/statcard}
Stat Block
Name Erelei the Wanderer
Race Elf
Class Rogue
Cabal Vellichor

Mudlog

A pasted MUD log rendered in monospace with backtick color codes applied. Use a fenced block tagged mudlog.

```mudlog
Between Ice Bars [Room 10874]
  You walk into an open cage surrounded by frozen bars and icy blocks.  
Whomever was in here, must of had a very good immunity to cold or his 
skin must of been twice that of any normal man.  Icicles hang freely from 
the ceiling as footing becomes extremely slippery.

[Exits: west]
(Dark Aura) An important Baron is frozen here.

>  kill baron
Your punch LACERATES The Baron Helgardium!
The Baron Helgardium dodges your attack.
You feign and strike at The Baron Helgardium's nerve point.
Your shadow strike wounds The Baron Helgardium.
The Baron Helgardium has a few scratches. 

>  
The Baron Helgardium dodges your attack.
Your punch LACERATES The Baron Helgardium!
You feign and strike at The Baron Helgardium's nerve point.
Your shadow strike misses The Baron Helgardium.
Your punch maims The Baron Helgardium!
You dodge The Baron Helgardium's attack.
The Baron Helgardium's freezing bite DISMEMBERS you!
You dodge The Baron Helgardium's attack and redirect the momentum!
Your counterblow MASSACRES The Baron Helgardium!
Your deathly chill hits The Baron Helgardium.
Your deathly chill decimates The Baron Helgardium!
The Baron Helgardium has a few scratches. 
```
Between Ice Bars [Room 10874]
  You walk into an open cage surrounded by frozen bars and icy blocks.  
Whomever was in here, must of had a very good immunity to cold or his 
skin must of been twice that of any normal man.  Icicles hang freely from 
the ceiling as footing becomes extremely slippery.

[Exits: west]
(Dark Aura) An important Baron is frozen here.

>  kill baron
Your punch LACERATES The Baron Helgardium!
The Baron Helgardium dodges your attack.
You feign and strike at The Baron Helgardium's nerve point.
Your shadow strike wounds The Baron Helgardium.
The Baron Helgardium has a few scratches. 

>  
The Baron Helgardium dodges your attack.
Your punch LACERATES The Baron Helgardium!
You feign and strike at The Baron Helgardium's nerve point.
Your shadow strike misses The Baron Helgardium.
Your punch maims The Baron Helgardium!
You dodge The Baron Helgardium's attack.
The Baron Helgardium's freezing bite DISMEMBERS you!
You dodge The Baron Helgardium's attack and redirect the momentum!
Your counterblow MASSACRES The Baron Helgardium!
Your deathly chill hits The Baron Helgardium.
Your deathly chill decimates The Baron Helgardium!
The Baron Helgardium has a few scratches. 

Table modifiers

These sit on their own line right before a markdown table. Stack them on consecutive lines to compose.

Column widths

{cols:} takes one width per column. Percentages, pixels, em, or auto. Percentages summing to 100 or less get normalized so the table fills the container while keeping their relative proportions. Sums above 100 convert to pixels and the table scrolls horizontally.

{cols: 30% 20% 20% 30%}
| Race   | Vulnerable | Resistant | Bonus Skills |
| :---   | :---       | :---      | :---         |
| Avian  | air        | -         | fly          |
| Drow   | silver     | charm     | sneak, infravision |
| Dwarf  | drowning   | poison    | berserk, infravision |
Race Vulnerable Resistant Bonus Skills
Avian air - fly
Drow silver charm sneak, infravision
Dwarf drowning poison berserk, infravision

Vertical headers

Rotates <th> cells 90 degrees. Optional alignment: top, center, bottom. Default is bottom.

{vhead}
| Race  | Strength | Dexterity | Constitution | Intelligence | Wisdom |
| :---  | :-:      | :-:       | :-:          | :-:          | :-:    |
| Avian | 19       | 23        | 19           | 21           | 21     |
| Dwarf | 23       | 17        | 23           | 17           | 19     |
| Elf   | 16       | 23        | 16           | 23           | 21     |
Race Strength Dexterity Constitution Intelligence Wisdom
Avian 19 23 19 21 21
Dwarf 23 17 23 17 19
Elf 16 23 16 23 21

Sleek

Minimal borders, mono uppercase headers, hover effect on rows. Good for dense data tables.

{sleek}
| Patron    | Domain  | Cabal    |
| :---      | :---    | :---     |
| Rathe     | Death   | Nexus    |
| Maesil    | Light   | Knight   |
| Athaketha | Justice | Tribunal |
Patron Domain Cabal
Rathe Death Nexus
Maesil Light Knight
Athaketha Justice Tribunal

Pins the header row to the top of the viewport while you scroll past long lists. Combines fine with {cols:} as long as the percentages sum to 100 or less.

{stickyhead}
{cols: 22% 22% 19% 19% 18%}
| Race  | Bonus Skills | Vulnerable | Resistant | Immune |
| :---  | :---         | :---:      | :---:     | :---:  |
| Avian | fly          | air        | -         | -      |
| Drow  | sneak, infravision, faerie fire | silver, mithril | charm | - |
| Dwarf | berserk, infravision | drowning | poison, magic | - |
Race Bonus Skills Vulnerable Resistant Immune
Avian fly air - -
Drow sneak, infravision, faerie fire silver, mithril charm -
Dwarf berserk, infravision drowning poison, magic -

Merged cells (colspan, rowspan)

{cspan:N} at the start of a cell makes that cell span N columns. Leave the next N-1 cells in the row blank.

{rspan:N} at the start of a cell makes that cell span N rows. Leave the same column position blank in the next N-1 rows.

Both can appear in one brace group, in either order: {cspan:2 rspan:3} or {rspan:3 cspan:2}.

Grouped headers (colspan):

| Rank | {cspan:2} Combat |   | {cspan:3} Disarm |   |   |
| ---  | :---:            | :---: | :---:        | :---: | :---: |
|      | Offense          | Defense | To Disarm | Shield | Be Disarmed |
| Best | Whip             | Staff   | Whip      | Flail  | Whip        |
RankCombatDisarm
OffenseDefenseTo DisarmShieldBe Disarmed
BestWhipStaffWhipFlailWhip

Repeated leftmost value (rowspan):

| Path     | Skill     | Cost | Notes             |
| -------- | --------- | ---- | ----------------- |
| {rspan:4} Adept | Meditate  | 30 | heal mind |
|          | Destroy Undead  | 25   | ?  |
|          | Recover   | 20   | regen      |
|          | Aura | 35   | Defensive      |
| {rspan:2} Crusader | Bless | 25 | crusade     |
|          | Behead    | 30   | bypass parry      |
PathSkillCostNotes
AdeptMeditate30heal mind
Destroy Undead25?
Recover20regen
Aura35Defensive
CrusaderBless25crusade
Behead30bypass parry

Rules:

  • Marker must be at the start of cell content, before any text.
  • Consumed cells must be blank. A cell in a span's shadow with text in it stays put, so forgetting the marker degrades to side-by-side rather than data loss.
  • GFM grid rule still applies: every row needs the same number of pipe-separated cells.
  • Spans inside {row}...{/row} work fine.

Side-by-side row

Lay out two or more tables (or any block content) on the same horizontal plane. Wrap blocks with {row} / {/row}. Children share the row equally and wrap below ~300px on narrow screens.


{row}


| Skill | Cost |
| :---  | :---: |
| Shoulder Smash  | 30   |
| Fasting  | 25   |

| Stat | Value |
| :--- | :---: |
| STR  | 19    |
| DEX  | 17    |


{/row}

Skill Cost
Shoulder Smash 5
Fasting 25
Stat Value
STR 19
DEX 17

Each table needs the usual blank line above and below it so markdown renders them as separate blocks. Other tags inside the row still work: a {cols:} or {stickyhead} on a child table behaves normally.

When a column needs more than one element (a heading, intro paragraph, and a table), use {col} on its own line as a divider. Each {col} starts a new column. Content from {row} to the first {col} is the first column.


{row}


{col}

## What to Use

Pick a weapon.

| Goal       | Best  |
| :---       | :---  |
| Hit harder | Whip  |
| Stay alive | Staff |


{col}

## Weapon Values

Bars run -5 to +5.

| Weapon | Attack |
| :---   | :---:  |
| Whip   | +5     |
| Staff  | -4     |


{/row}

What to Use

Pick a weapon.

Goal Best
Hit harder Whip
Stay alive Staff

Weapon Values

Bars run -5 to +5.

Weapon Attack
Whip +5
Staff -4

Embeds

These pull live data from the game DB into the page.

Help

Multi-word keywords go in single quotes.

{help:berserk}
Syntax: berserk

This ability allows talented fighters to enter into a wild trance, with their pulses racing and the whole body consumed with rage. While in this state, these fighters are known to be able to strike harder in his frenzy, but consequently also let down his defenses more than usual.

Item

Reference an item by vnum or by name.

{item:vorpal sword}
'Khyer-Dirohm', the Vorpal Sword of Atonementview details →
Faction of SteelWorn: wield
Object 'vorpal sword' is type weapon, material steel.
Extra flags: antigood noremove.
Weight is 33, value is 2, level is 54.
Weapon type is sword.
Damage is 8d6 (average 28).
Affects sword by 5.
Affects damroll by 6.
Affects hitroll by 3.
Unique item.

Item stat block

A compact box with just the stats, no description.

{stato:10801}
stat obj'Khyer-Dirohm', the Vorpal Sword of Atonementview item →
Name(s): vorpal sword
Area: Faction of Steel
Vnum: 10801  Format: new  Type: weapon  Material: steel
Resets: 1  Factor: 2  Allowed: 2  Count: 0
Short description: 'Khyer-Dirohm', the Vorpal Sword of Atonement
Long description: A bleak looking sword lies dully on the ground.
Wear bits: take wield unique
Extra bits: antigood noremove
Number: 1/1  Weight: 330/330/330 (10th pounds)
Level: 54  Cost: 2  Condition: 100%
Values: 1 8 6 21 16
Weapon type is sword.
Damage is 8d6 (average 28).
Damage noun is cleave.
Weapon flags: vorpal
Affects sword by 5 (skill).
Affects damroll by 6.
Affects hitroll by 3.

Pseudocode

Renders the pseudocode for a game function.

{pseudo:do_berserk}
do_berserkskills.c
fFerocity = skill_percent(ferocity) > 1
if (chance = skill_percent(berserk)) == 0:
chance = 3 * chance / 4
if caster.has_flag(CALM) or caster.has_affect(prayer):
paf = caster.find_affect(berserk)
mana = 50
if fFerocity and paf: mana += 20 * ((paf.level + 1) - caster.level)
if not caster.is_npc and caster.mana < mana:
if caster.position == POS_FIGHTING and chance > 1: chance += 35
hp_percent = percent_of(caster.hp, caster.max_hp)
if random(1..100) < chance:
  caster.moves = max(caster.moves - 50, 1)
  if not caster.is_npc: caster.mana = max(caster.mana - mana, 1)
  caster.hp += 2 * caster.level
  if not caster.has_affect(berserk):
  else if paf and fFerocity: paf.level += 1
else:
  caster.mana -= mana / 2

Escapes

A literal { without firing tag detection:

\{toc} renders as plain text instead of a TOC.

{toc} renders as plain text instead of a TOC.

A literal < or > inside prose works as-is. HTML tags get stripped by the sanitizer except for the small allow-list (b, i, em, strong, br, p, code, blockquote, hr, etc.).