Wednesday, January 23, 2019

The Frenchman's Curse

A parasitic spell for LotFP or similar.
The death of a Frenchman, if not "the Frenchman" of my notes.

When the Frenchman dies, all who witness his dying breath save or catch the curse.

Spellcasters

The curse lives in a spell slot. It prefers high-level spell slots, but can be persuaded to take a lower-level slot temporarily. You cannot cast the curse, it just lives there.

When another spellcaster witnesses you casting a spell, they must save or catch the curse also. This is how the curse "reproduces". If you are cunning, you may be able to coax the curse onto a scroll, or convince it to allow itself to be "cast" into another host (without leaving a copy behind). It knows that the target will get a save in both of these cases, so it needs to be a good deal.

When you die, the curse dies with you.

Others

The curse cannot "reproduce" properly if you can't cast spells, so instead it seeks out spellcasters. Intermediate hosts have disadvantage on saves vs. magic, and their skin is covered in crawling tattoos that are offensive, enraging, insulting, confusing, distracting, and profane. Fortunately, these tattoos are only visible to Read Magic, True Seeing, or those with second sight.
"The Op Tattoo", Robert Williams, 1993 (not public domain or anything like that)
On a 1-in-6, the intermediate host has some innate magical potential, and instead carries the curse asymptomatically.

When you die, the curse will pass into all who witness your death. If you manage to otherwise rid yourself of the curse, it will leave behind an empty spell slot.

References

Talking to your spells:
Parasites with intermediate hosts:
Memetic diseases:

Sunday, January 13, 2019

Being Useful

Always feels good to help people with things. Sometimes this is just recommending resources, but sometimes I get to flex my slowly-dying engineer muscles. These are two things I got to help people with recently on some Discord chats, but Discord is temporary so I'm writing them down here for posterity.

RPS Mechanics in Play-by-Post Games

Image source: wikimedia.

Rock-paper-scissors only works in person because you can throw more-or-less simultaneously. In a play-by-post environment, someone has to go first. Here's how:
  1. Alice generates a random number and appends it to her choice.
    Example: "paper04"
  2. Alice takes a hash* of the result and shares it.
    Example: "md5:fbe1a7f5e0330c5cf5a986d40065a21e"
  3. Bob shares his choice.
    Example: "scissors"
  4. Alice shares her original string.
    Example: "paper04"
  5. Bob checks the hash of the original string.
This is not a protocol focused on security. For example, given that the salt is a number 00-99, Bob could generate a rainbow table of all the possible checksums and guess Alice's answer before she revealed it.
It could be automated in some ways if you ran the forum, for example, a bot could automate the final check.




Weighted Selection from a Compact Table

It's common for a table in a book to be formatted like:
1-10. Very common result
11-15. Less common result
16-19. Slightly less common result
20. Very rare result
This is useful if you want to mimic a specific type of distribution given a flat input curve. The theory is that if you use this table a lot, then it will make the results feel more natural.
This presents a problem if you would like to automatically roll on the table in a spreadsheet. A naive way to do this is the format it like:
(A1) Very common result
(A2) Very common result
(A3) Very common result
. . .
(A20) Very rare result
But this is time-consuming and annoying to change. Using VLOOKUP, you can format it like:
(A1) 10 (B1) Very common result
(A2) 15 (B2) Less common result
(A3) 19 (B3) Slightly less common result
(A4) 20 (B4) Very rare result
And then roll as normal. There is a (rough) proof of concept here. There's a couple mistakes in it, but if you play around with it you can see how it works.
Cols A & B are the actual table, while Cols C & D are for illustrative purposes and aren't necessary for the table to function. Cols E & F show how an automated roller might function.
* = I use DuckDuckGo as my default search engine. If you search "md5 [term]" it will auto-suggest the md5sum of "[term]", which is neat. Wolfram Alpha also does this.