New OOTS products from CafePress
New OOTS t-shirts, ornaments, mugs, bags, and more
Results 1 to 3 of 3
  1. - Top - End - #1
    Barbarian in the Playground
     
    Albions_Angel's Avatar

    Join Date
    Feb 2014
    Location
    South West UK
    Gender
    Male

    Default Automatically determining the probability of a random encounter and selecting it

    Hi all,

    Bit of an odd question. I am back rebuilding my giant 3.5e world that no one will ever play in. But I am having fun, which is all that matters. A while ago, I started building my own random encounter tables. Massive ones. The idea was to have thematically appropriate random encounters that fit both the area, and the level of the party. I did this in spreadsheets with vlookup tables. But I quickly ran into issues. You see, I wanted the tables to match the location difficulty. So a party with CR 1-3 generally only faced encounters CR 1/4 to 5, so long as they stuck to the safe roads. Higher level parties venture into more unsafe territory and so on. But I was quickly looking at 8 or 9 tables, each with hundreds of unique encounters and non-encounters PER CONTINENT, with 10 or so distinct continents/locals in my world.

    Well, I am back at it, and I want to change a couple of things.

    1. I am going to do this in Python, with Pandas databases. Far more versatile, and I can include dictionaries as entries and save the whole thing as a CSV.
    2. I want the encounters to scale mostly off location difficulty, but also off party CR. My level brackets were too coarse, and to keep random encounters interesting for the top end of the bracket, I needed to make them not just challenging, but certain death for the lower end of the bracket. Scaling by both will mean that weak parties that walk into bad areas are still doomed, but level appropriate areas remain interesting and sensible for decent lengths of time.
    3. Modify what encounters are available via environment keywords. My Borieal area has everything from swamps to plains to icy tundra and mountains. And unfortunately, I realised that with my old method, I needed low, mid and high level tables for EACH BIOME. With environment flags, I can filter encounters out before I select one.
    4. I want just one encounter table. It will be far easier to manage.


    Its the second and last point that are the purpose of this post. With just one list of encounters, I can pick out certain options dependent on just 3 parameters - current biome, current area difficulty (or area CR), and party CR. Certain encounters will never happen (dealing with an avalanche is not going to happen while fishing off the coast of a swamp), most encounters will be appropriate for the party and location (a party of level 2s in a CR 0-5 area will get a nice distribution of encounters centred on CR2), while a few outliers are permitted via very small probabilities (because thats how story points happen - when your level 1 party has to flee from the great wyrm that just landed on the well patrolled Kings Road).

    I can deal with the flags. But determining the probabilities, and then picking them, is proving difficult. And I wondered if anyone had any ideas?

    I feel like each encounter should have a "base probability" - the base likelihood of that encounter happening irrespective of the party level or the location. A common encounter (e.g. goblins attacking the party) should be, well, more common than a unique encounter (e.g. the party passes a group of sheep and a shepherd, and have a chance to discover that an evil witch has swapped the shepherd with one of his sheep!). The trick comes in determining these probabilities. I want to just be able to stick down a number (say 10 for common, 5 for uncommon, 1 for rare and 0.1 for unique) indicating the rough proportional chance of the encounter compared to others.

    But I THEN want to modify this by
    1. The location CR
    2. The party CR


    And THEN it needs to be turned into a number, preferably a probability, that can be drawn from by a random number generator.

    And I got that far and my brain decided to forget all the stats I know.

    Probably, it will end up something like:

    Chance = Base Chance * (1 - (Abs(encounter CR - location CR) / encounter CR) - 0.5 * (Abs(encounter CR - party CR) / encounter CR))

    That would produce a number between, in my example case, 0 and 10. 10 would only be possible if both the location CR and party CR exactly matched the encounter CR AND that encounter was a common encounter. Any deviation from those three would lower the resulting Chance number.

    I could then sum ALL the chance numbers for possible encounters, and draw a random number in the range between 0 and the sum.

    But, does anyone else have a better way of doing it? Or any tweaks and suggestions? I feel like the location CR should account for a range of CRs before it really starts hurting the chances. And I want the level to be less of a factor. The region will already be heavily gating encounters, so I wont need to wiggle things much to further tailor it to the party.

    Thanks

  2. - Top - End - #2
    Ogre in the Playground
    Join Date
    Aug 2012
    Location
    Vacation in Nyalotha

    Default Re: Automatically determining the probability of a random encounter and selecting it

    If you want a smoother response for close level offsets while still dropping away at more distant separations you could make use of parabolic functions.

    Instead of encounter CR E, you are looking at the equation
    -(x - E + N)(x - E - M)
    Where N and M are scaling factor that you decide upon for fine tuning the range and tolerance of the equation. At X=E+M and X= E-N this equates out to zero.

    Observing that the largest possible output is NM, we divide by that value to keep this as a fraction. Take max(value,0) to constrain the output to [0,1] and voila.

    F(L,E) = max(0,-(L-E+N)(L-E-M)/(NM))

    L is location CR, E encounter CR. N is the lower bound tolerance (how much the equation will tolerate the location being under CR) and M is the upper bound tolerance.
    If all rules are suggestions what happens when I pass the save?

  3. - Top - End - #3
    Pixie in the Playground
    Join Date
    Sep 2016

    Default Re: Automatically determining the probability of a random encounter and selecting it

    Hello, I would love to join this project if you don't mind. We could figure it out together and I could maybe make use of it in my campaign.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •