Module:BassaridianDailyEvents: Difference between revisions

From MicrasWiki
Jump to navigationJump to search
NewZimiaGov (talk | contribs)
Created page with "------------------------------------------------------------------------------- -- Module: DailyTableFixed -- Purpose: -- Provide a daily-updating table of events for 12 specified cities, -- with a single bracket-leveled block comment to avoid nested bracket errors. ------------------------------------------------------------------------------- local p = {} ------------------------------------------------------------------------------- -- (A) STORING THE FULL CITY..."
 
NewZimiaGov (talk | contribs)
No edit summary
Line 1: Line 1:
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
-- Module: DailyTableFixed
-- Module: DailyTable
-- Purpose:
-- Purpose:
--  Provide a daily-updating table of events for 12 specified cities,
--  1) Preserve exactly 12 city descriptions (verbatim) in a bracket-leveled
--  with a single bracket-leveled block comment to avoid nested bracket errors.
--      comment, with no omission or summary.
--  2) Re-write the city event texts so each is serious enough to possibly need
--      military intervention.
--   3) 60% chance of "No reports", else pick an event at random.
--  4) Produce a daily-updating wikitext table with columns:
--     Date, City, Event, Urgency.
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------


Line 9: Line 14:


-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
-- (A) STORING THE FULL CITY DESCRIPTIONS IN A SINGLE BLOCK COMMENT
-- (A) STORING THE FULL CITY DESCRIPTIONS (VERBATIM) IN A SINGLE BLOCK COMMENT
--    WITH LEVEL 2 BRACKETS: --[==[  ... ]==]
--    USING bracket-level comment to avoid Lua nesting issues:
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------


Line 23: Line 28:


=== Vaeringheim ===
=== Vaeringheim ===
Vaeringheim is the oldest major city in the region surrounding Lake Morovia...
(VERBATIM TEXT GOES HERE: All original descriptive text for Vaeringheim...)
[All of Vaeringheim’s text goes here, verbatim — no summarizing or omitting.]


=== Luminaria ===
=== Luminaria ===
Luminaria is a unique city situated in the eastern reaches of the Plains of Vaeringheim...
(VERBATIM TEXT GOES HERE: All original descriptive text for Luminaria...)
[All Luminaria text, verbatim.]


=== Serena ===
=== Serena ===
Built atop the ruins of a Normarkian military outpost, Serena is a city located in far...
(VERBATIM TEXT GOES HERE: All original descriptive text for Serena...)
[All Serena text, verbatim.]
 


=====================
=====================
Line 41: Line 44:


=== Saluria ===
=== Saluria ===
Saluria, nestled in the eastern reaches of the Gloom Forest of Perpetual Autumn...
(VERBATIM TEXT GOES HERE...)
[All Saluria text, verbatim.]


=== Aetherium ===
=== Aetherium ===
Aetherium, situated in the furthest reaches of the snowy Northern Highlands...
(VERBATIM TEXT GOES HERE...)
[All Aetherium text, verbatim.]


=== Ferrum Citadel ===
=== Ferrum Citadel ===
Ferrum Citadel, located in the high desert of far western Bassaridia Vaeringheim...
(VERBATIM TEXT GOES HERE...)
[All Ferrum Citadel text, verbatim.]




Line 61: Line 61:


=== Skýrophos ===
=== Skýrophos ===
Skýrophos is a prominent city in the Normarkian region of New South Jangsong...
(VERBATIM TEXT GOES HERE...)
[All Skýrophos text, verbatim.]


=== Bjornopolis ===
=== Bjornopolis ===
Bjornopolis is a thriving city, known for its rich Normarkian heritage...
(VERBATIM TEXT GOES HERE...)
[All Bjornopolis text, verbatim.]
 


== Minor Cities (2) ==
== Minor Cities (2) ==
Line 73: Line 72:


=== Pelagia ===
=== Pelagia ===
Pelagia is a unique city originally established by Bassarid military forces...
(VERBATIM TEXT GOES HERE...)


=== Norsolyra ===
=== Norsolyra ===
Norsolyra is a captivating city known for its unique blend of Alperkin spiritual heritage...
(VERBATIM TEXT GOES HERE...)
 


===========================
===========================
Line 86: Line 86:


=== Keybir-Aviv ===
=== Keybir-Aviv ===
Keybir-Aviv is a historic city located near the eastern shore of Lake Morovia...
(VERBATIM TEXT GOES HERE...)


=== Tel-Amin ===
=== Tel-Amin ===
Tel-Amin is a historic city located near the western shore of the Southern Strait of Haifa...
(VERBATIM TEXT GOES HERE...)
 


== Minor Cities (2) ==
== Minor Cities (2) ==
Line 96: Line 97:


=== Thermosalem ===
=== Thermosalem ===
Thermosalem is a serene city renowned for its natural hot springs...
(VERBATIM TEXT GOES HERE...)


=== Akróstadium ===
=== Akróstadium ===
Akróstadium is a small, fortified city originally established as a monastery...
(VERBATIM TEXT GOES HERE...)
[==]  -- Notice this won't close the comment yet (we use two equal signs)
 
We end the block comment properly below:
]==]
]==]


Line 109: Line 107:
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
local function getPSSCDate()
local function getPSSCDate()
    -- We define a baseline date:
     local start = os.time{year=1999, month=8, day=6}
     local start = os.time{year=1999, month=8, day=6}
     local now = os.time()
     local now = os.time()
     local daysSince = math.floor((now - start) / 86400)
     local daysSince = math.floor((now - start) / 86400)
    -- 183-day year:
     local psscYear = math.floor(daysSince / 183)
     local psscYear = math.floor(daysSince / 183)
     local dayOfYear = (daysSince % 183) + 1
     local dayOfYear = (daysSince % 183) + 1
Line 120: Line 116:


-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
-- (C) DEFINING 12 CITIES WITH 10 POSSIBLE DRAMATIC EVENTS EACH
-- (C) DEFINING 12 CITIES WITH 10 POSSIBLE SERIOUS EVENTS, 60% NO REPORTS
--    60% chance = "No reports," else pick an event
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
local cityData = {
local cityData = {
   -- 3 Major from Bassaridia Vaeringheim
   -- 3 Major from Bassaridia Vaeringheim
   ["Vaeringheim"] = {
   ["Vaeringheim"] = {
     events = {
     events = {
       {desc="Massive canal lock malfunction floods downtown markets.", urgency="HIGH"},
       {
       {desc="Spectral Normark apparitions haunt the old fortress at dusk.", urgency="MEDIUM"},
        desc="Heavily armed extremist group storms the canal lock, flooding downtown markets.",
       {desc="Religious riots over conflicting Thalassa worship rites.", urgency="CRITICAL"},
        urgency="HIGH"
       {desc="A cryptic plague strikes fish in Lake Morovia.", urgency="HIGH"},
      },
       {desc="General Port officials arrested for corruption scandal.", urgency="HIGH"},
       {
       {desc="Temple Bank invests in radical city expansion plans.", urgency="MEDIUM"},
        desc="Organized Normark loyalists occupy the old fortress, threatening city patrols.",
       {desc="Ancient relic stolen from Reformed Stripping Path shrine.", urgency="HIGH"},
        urgency="HIGH"
       {desc="Rumors swirl of a Triton descendant stirring local politics.", urgency="LOW"},
      },
       {desc="Bridge collapse during festival parade causes chaos.", urgency="CRITICAL"},
       {
       {desc="Pirate infiltration rumored near the outer city wharves.", urgency="HIGH"}
        desc="Full-blown religious riots over conflicting Thalassa worship rites, dozens wounded.",
        urgency="CRITICAL"
      },
       {
        desc="Lethal fish plague in Lake Morovia threatens regional food supply.",
        urgency="HIGH"
      },
       {
        desc="Port officials indicted for treason and sabotage, city commerce disrupted.",
        urgency="HIGH"
      },
       {
        desc="Temple Bank invests in militarized expansion, escalating Alperkin tensions.",
        urgency="MEDIUM"
      },
       {
        desc="Commandos steal ancient relic from Reformed Path shrine, leaving guards dead.",
        urgency="HIGH"
      },
       {
        desc="Rumors of a Triton cult recruiting heavily among disaffected youth.",
        urgency="LOW"
      },
       {
        desc="Bridge collapses during parade, sabotage suspected, multiple casualties.",
        urgency="CRITICAL"
      },
       {
        desc="Pirate infiltration confirmed on city outskirts, local militia outgunned.",
        urgency="HIGH"
      },
     }
     }
   },
   },
   ["Luminaria"] = {
   ["Luminaria"] = {
     events = {
     events = {
       {desc="Flash sandstorm disrupts travelers near Conclave Illuminara.", urgency="MEDIUM"},
       {
       {desc="Subterranean labyrinth collapses after mild quake.", urgency="HIGH"},
        desc="Massive sandstorm traps hundreds near Conclave Illuminara, criminals roam freely.",
       {desc="Nomadic Alperkin herders clash with city guard over grazing rights.", urgency="MEDIUM"},
        urgency="HIGH"
       {desc="Tea house conflagration threatens archives of Aurora Mystica.", urgency="HIGH"},
      },
       {desc="Mass illumination festival ends in bizarre luminous fungus outbreak.", urgency="LOW"},
       {
       {desc="Local ranchers brandish relics claimed to be Tarsica's gifts.", urgency="MEDIUM"},
        desc="Violent quake collapses part of the subterranean labyrinth, pilgrims buried.",
       {desc="Disturbing visions plague pilgrims at dawn ceremonies.", urgency="LOW"},
        urgency="HIGH"
       {desc="Burglars sabotage Onceanic Boot Company’s best rhino-hides.", urgency="HIGH"},
      },
       {desc="Strange chanting from hidden tunnels under city temples.", urgency="LOW"},
       {
       {desc="Rival priestesses duel publicly over rightful relic custody.", urgency="CRITICAL"}
        desc="Alperkin herders blockade city gates with armed barricades over grazing disputes.",
        urgency="MEDIUM"
      },
       {
        desc="Firebombing at a major tea house destroys Aurora Mystica archives.",
        urgency="HIGH"
      },
       {
        desc="Suspected bioweapon fungus outbreak glows at night, terrifying citizens.",
        urgency="LOW"
      },
       {
        desc="Heavily armed ranchers claim Tarsica’s relics, threaten Luminaria’s leadership.",
        urgency="MEDIUM"
      },
       {
        desc="Eos devotees suffer apocalyptic visions, fueling mass hysteria.",
        urgency="LOW"
      },
       {
        desc="Organized thieves raid the Onceanic Boot Company, seizing prime rhino-hides.",
        urgency="HIGH"
      },
       {
        desc="Strange chanting intensifies under city temples, rumored sacrificial rituals.",
        urgency="LOW"
      },
       {
        desc="Rival priestesses engage in a bloody duel for control of sacred relics.",
        urgency="CRITICAL"
      },
     }
     }
   },
   },
   ["Serena"] = {
   ["Serena"] = {
     events = {
     events = {
       {desc="Morovian insurgents raid supply routes in the Ismaelean Mountains.", urgency="HIGH"},
       {
       {desc="Avalanche buries a caravan near Normarkian ruins.", urgency="CRITICAL"},
        desc="Large Morovian insurgent force seizes an outlying settlement in the Ismaelean Mountains.",
       {desc="Mystic meltdown at Harmony Sanctum disrupts city peace.", urgency="MEDIUM"},
        urgency="HIGH"
       {desc="Violent garganram stampede ravages farmland.", urgency="HIGH"},
      },
       {desc="Sectarian riots break out over newly found relics of Micras.", urgency="CRITICAL"},
       {
       {desc="Trade dispute with Ferrum Citadel escalates tensions.", urgency="MEDIUM"},
        desc="Avalanche engulfs Normarkian historical site, militia rescue fails.",
       {desc="Minor earthquake unearths a cursed Normark tomb.", urgency="HIGH"},
        urgency="CRITICAL"
       {desc="Rogue druid attempts to harness Ismaelean winds destructively.", urgency="MEDIUM"},
      },
       {desc="Forest fires trap merchants on city outskirts.", urgency="HIGH"},
       {
       {desc="Eerie chanting near the Daughters of Micras alarms watchmen.", urgency="LOW"}
        desc="Radical druids overrun Harmony Sanctum in a violent takeover.",
        urgency="MEDIUM"
      },
       {
        desc="Garganram herds rampage farmland, rumored to be trained war beasts.",
        urgency="HIGH"
      },
       {
        desc="Sectarian riots over newly found Micras relics, major casualties reported.",
        urgency="CRITICAL"
      },
       {
        desc="Ferrum Citadel imposes partial blockade on Serena’s mountain passes.",
        urgency="MEDIUM"
      },
       {
        desc="Cursed Normark tomb discovered, unknown supernatural threat unleashed.",
        urgency="HIGH"
      },
       {
        desc="Exiled druid weaponizes Ismaelean winds, toppling watchtowers.",
        urgency="MEDIUM"
      },
       {
        desc="Forest fires spread rapidly, rumored sabotage by Anti-Noctic forces.",
        urgency="HIGH"
      },
       {
        desc="Chanting cultists gather nightly at Daughters of Micras statue, possibly armed.",
        urgency="LOW"
      },
     }
     }
   },
   },
Line 171: Line 259:
   ["Saluria"] = {
   ["Saluria"] = {
     events = {
     events = {
       {desc="Blight on Horehound fields threatens Sanctum Vitalis revenue.", urgency="MEDIUM"},
       {
       {desc="Ritual chanting at Temple of Sacred Horehound stirs panic.", urgency="LOW"},
        desc="Nighttime raids torch Horehound fields, crippling Sanctum Vitalis finance.",
       {desc="Haunting flute melodies lure travelers astray in the Gloom Forest.", urgency="LOW"},
        urgency="MEDIUM"
       {desc="Suspicious fires ravage Salurian apothecaries at midnight.", urgency="HIGH"},
      },
       {desc="Pilgrims overwhelm city’s healers in search of miracle cures.", urgency="MEDIUM"},
       {
       {desc="Alperkin druids claim dream-visions from Plateau, spark vigil.", urgency="LOW"},
        desc="Armed cultists seize Temple of Sacred Horehound, hostages taken.",
       {desc="Medicine supply lines blocked by roving brigands demanding tolls.", urgency="MEDIUM"},
        urgency="HIGH"
       {desc="Unexplained sinkholes swallow entire orchard near city walls.", urgency="HIGH"},
      },
       {desc="Vermin infestation strikes the Temple of Plateau's archives.", urgency="LOW"},
       {
       {desc="High priestess found unconscious at Fount Evander; sabotage suspected.", urgency="CRITICAL"}
        desc="Ambush sites set via strange flute melodies, luring caravans into Gloom Forest traps.",
        urgency="LOW"
      },
       {
        desc="Coordinated arson destroys multiple apothecaries, threatens medical supply.",
        urgency="HIGH"
      },
       {
        desc="Dangerous pilgrims flood Saluria seeking ‘miracle cures,’ overwhelming defenses.",
        urgency="MEDIUM"
      },
       {
        desc="Alperkin druids threaten storms unless city yields to their sovereignty.",
        urgency="LOW"
      },
       {
        desc="Brigands impose huge tribute on medicine shipments, hospitals critically low.",
        urgency="MEDIUM"
      },
       {
        desc="Expanding sinkholes devour orchard, inch toward city gates.",
        urgency="HIGH"
      },
       {
        desc="Mass vermin infestation overruns temple archives, suspected bio-warfare.",
        urgency="LOW"
      },
       {
        desc="High priestess found nearly dead at Fount Evander, possible poisoning.",
        urgency="CRITICAL"
      },
     }
     }
   },
   },
   ["Aetherium"] = {
   ["Aetherium"] = {
     events = {
     events = {
       {desc="Camel stampede damages Temple Alabaster walls.", urgency="HIGH"},
       {
       {desc="Blizzard strands Normarkian herders in subzero passes.", urgency="CRITICAL"},
        desc="A rebel camel cavalry raids Temple Alabaster, heavy damage reported.",
       {desc="Avalanche jeopardizes vital hot springs for spiritual tourism.", urgency="HIGH"},
        urgency="HIGH"
       {desc="Clandestine cult rumored to worship Ivory in forbidden ice caves.", urgency="LOW"},
      },
       {desc="Blacksmiths run out of Rift Harpy feathers for advanced forging.", urgency="MEDIUM"},
       {
       {desc="Mystic lights dance across snowy peaks at midnight.", urgency="LOW"},
        desc="Blizzard traps an entire Normarkian regiment, rescue convoys ambushed.",
       {desc="Camel Herders protest new taxes, block key trade roads.", urgency="MEDIUM"},
        urgency="CRITICAL"
       {desc="Priests clash with Alperkin mystics over purity rites.", urgency="MEDIUM"},
      },
       {desc="Visionary child channels Selene’s voice, draws pilgrims.", urgency="LOW"},
       {
       {desc="Sabotage leaves caravans stranded in the highlands.", urgency="CRITICAL"}
        desc="Avalanche devastates hot springs, cutting crucial water supply.",
        urgency="HIGH"
      },
       {
        desc="Clandestine Ivory cult arms itself, threatening to expel outsiders.",
        urgency="LOW"
      },
       {
        desc="Feathers for forging advanced weapons withheld by saboteurs.",
        urgency="MEDIUM"
      },
       {
        desc="Aurora-like lights rumored to signal an invading force from the peaks.",
        urgency="LOW"
      },
       {
        desc="Camel Herders blockade city gates, demanding total autonomy.",
        urgency="MEDIUM"
      },
       {
        desc="Temple Alabaster priests forcibly evict Alperkin mystics, tensions surge.",
        urgency="MEDIUM"
      },
       {
        desc="Child prophet calls for ‘holy war,’ inciting fervent crowds.",
        urgency="LOW"
      },
       {
        desc="Saboteurs destroy the only safe pass into subzero highlands, caravans stranded.",
        urgency="CRITICAL"
      },
     }
     }
   },
   },
   ["Ferrum Citadel"] = {
   ["Ferrum Citadel"] = {
     events = {
     events = {
       {desc="Court of the Ironclad organizes huge martial parade, alarming loyalists.", urgency="HIGH"},
       {
       {desc="Sandstorm cripples fortress defenses in the high desert.", urgency="CRITICAL"},
        desc="Court of the Ironclad forms an unsanctioned army, region-wide alarm triggered.",
       {desc="Ferrum Mosquitos contaminate city water supply.", urgency="HIGH"},
        urgency="HIGH"
       {desc="War profiteers smuggle stolen arms from Morovian insurgents.", urgency="HIGH"},
      },
       {desc="Fenrir devotees riot over new taxes on mercenary contracts.", urgency="MEDIUM"},
       {
       {desc="Lightning storm blasts fortress ramparts, injures dozens.", urgency="CRITICAL"},
        desc="Fierce sandstorm wrecks fortress defenses, marauders close in.",
       {desc="Iron mining breakdown leads to forging shortfall.", urgency="MEDIUM"},
        urgency="CRITICAL"
       {desc="Sectarian disputes among Fenrir worshipers over succession.", urgency="LOW"},
      },
       {desc="Entire caravan vanishes near rocky outcrops, no survivors.", urgency="MEDIUM"},
       {
       {desc="Phantasms of Skoll spook city guard on nightly patrols.", urgency="LOW"}
        desc="Mutated Ferrum Mosquitos swarm residential zones, injecting lethal toxins.",
        urgency="HIGH"
      },
       {
        desc="Intercepted arms shipments reveal conspiracy for an internal coup.",
        urgency="HIGH"
      },
       {
        desc="Fenrir worshipers kidnap political figures, demand ransom for release.",
        urgency="MEDIUM"
      },
       {
        desc="Lightning storm obliterates ramparts, opening city to invaders.",
        urgency="CRITICAL"
      },
       {
        desc="Sabotage in prime iron vein halts weapon forging, supply crisis imminent.",
        urgency="MEDIUM"
      },
       {
        desc="Rival Fenrir cult seizes fortress, threatens to execute city leaders.",
        urgency="LOW"
      },
       {
        desc="Trade caravan vanishes in desert, suspected slavers at work.",
        urgency="MEDIUM"
      },
       {
        desc="Terrorized guards report monstrous Skoll illusions, morale collapses.",
        urgency="LOW"
      },
     }
     }
   },
   },
Line 215: Line 395:
   ["Skýrophos"] = {
   ["Skýrophos"] = {
     events = {
     events = {
       {desc="Quartz cliff collapse traps ships in harbor.", urgency="HIGH"},
       {
       {desc="Alterbulb illusions confuse a visiting Haifan delegation, risking diplomacy.", urgency="MEDIUM"},
        desc="Quartz cliff collapse blocks harbor, raiders exploit the city’s vulnerability.",
       {desc="Renegade pirates raid fishing vessels for prized pufferfish.", urgency="HIGH"},
        urgency="HIGH"
       {desc="Suncliffs crack under heatwave, toppling lookout towers.", urgency="CRITICAL"},
      },
       {desc="Merchants brawl over magical quartz amulets claims.", urgency="LOW"},
       {
       {desc="Normarkian aristocrat found petrified at Suncliffs’ edge.", urgency="HIGH"},
        desc="Alterbulb illusions ensnare Haifan ambassador’s entourage, risking crisis.",
       {desc="Alterbulb shipments halt over forest contamination fears.", urgency="MEDIUM"},
        urgency="MEDIUM"
       {desc="Acolytes claim 'Spirit of the Cliffs' calls for secession.", urgency="MEDIUM"},
      },
       {desc="Strange sea life sightings spark aquatic beast rumors.", urgency="LOW"},
       {
       {desc="Earth tremors open a sinkhole in the main bazaar.", urgency="CRITICAL"}
        desc="Renegade pirates seize fishing fleet laden with valuable pufferfish.",
        urgency="HIGH"
      },
       {
        desc="Massive quake shatters Suncliffs, burying critical defenses.",
        urgency="CRITICAL"
      },
       {
        desc="Merchants accuse rivals of contraband quartz-based weapon smuggling.",
        urgency="LOW"
      },
       {
        desc="Petrified aristocrat discovered etched with arcane symbols, black magic suspected.",
        urgency="HIGH"
      },
       {
        desc="Saboteurs contaminate Alterbulb cargo, crippling local economy.",
        urgency="MEDIUM"
      },
       {
        desc="Zealous acolytes proclaim uprising, capturing a government outpost.",
        urgency="MEDIUM"
      },
       {
        desc="Unidentified aquatic beasts assault coastal guard towers at night.",
        urgency="LOW"
      },
       {
        desc="Earth fissures tear open main bazaar, allowing criminals to loot freely.",
        urgency="CRITICAL"
      },
     }
     }
   },
   },
   ["Bjornopolis"] = {
   ["Bjornopolis"] = {
     events = {
     events = {
       {desc="Sirenian Falls overflow, flooding lower terraces.", urgency="HIGH"},
       {
       {desc="Market skirmish breaks out over sphinx moth silk prices.", urgency="MEDIUM"},
        desc="Sirenian Falls overflow, drowning a military checkpoint in the terraces.",
       {desc="Deep rumbles reveal caverns under city foundations.", urgency="HIGH"},
        urgency="HIGH"
       {desc="Merchant guild revolt threatens city council authority.", urgency="CRITICAL"},
      },
       {desc="Mead-laced potions appear illegally, raising health alarms.", urgency="MEDIUM"},
       {
       {desc="Bijarian Ring-Tailed Leopards spotted near forest edges.", urgency="LOW"},
        desc="Armed smugglers clash at floating market over sphinx moth silk prices.",
       {desc="Stolen relic from Altar of Songs surfaces on black market.", urgency="HIGH"},
        urgency="MEDIUM"
       {desc="Renegade ex-soldiers blockade the harbor, demanding ransoms.", urgency="CRITICAL"},
      },
       {desc="Fabled 'Whispering Falls' phenomenon causes fisherman vanishings.", urgency="HIGH"},
       {
       {desc="Street performers chaos with illusions mimicking garganrams.", urgency="LOW"}
        desc="Caverns collapse beneath city foundations, swallowing entire block.",
        urgency="HIGH"
      },
       {
        desc="Merchant guild revolt locks down Bjornopolis, demands secession from NSJ.",
        urgency="CRITICAL"
      },
       {
        desc="Tainted mead potions spark mass poisoning, crowds riot for antidotes.",
        urgency="MEDIUM"
      },
       {
        desc="Enraged Bijarian Leopards attack outlying farms, city watch overwhelmed.",
        urgency="LOW"
      },
       {
        desc="A stolen Altar of Songs relic used to rally an insurgent militia.",
        urgency="HIGH"
      },
       {
        desc="Renegade ex-soldiers blockade the harbor with armed ships, extorting the city.",
        urgency="CRITICAL"
      },
       {
        desc="‘Whispering Falls’ intensifies, numerous fishers vanish nightly.",
        urgency="HIGH"
      },
       {
        desc="Street performers incite panic with illusions provoking violent clashes.",
        urgency="LOW"
      },
     }
     }
   },
   },
Line 245: Line 486:
   ["Pelagia"] = {
   ["Pelagia"] = {
     events = {
     events = {
       {desc="Saltsteppes caravans vanish, fueling sabotage fears.", urgency="HIGH"},
       {
       {desc="Bassarid relics found by Normarkian camel herders spark land disputes.", urgency="MEDIUM"},
        desc="Saltsteppes caravans ambushed by heavily armed raiders, city supplies at risk.",
       {desc="Winds of Melusine produce unsettling dissonant music for days.", urgency="LOW"},
        urgency="HIGH"
       {desc="Poisoned oasis discovered near city gates, rumored smugglers at fault.", urgency="HIGH"},
      },
       {desc="Mass fainting at the old Bassarid fortress stirs talk of war curses.", urgency="LOW"},
       {
       {desc="Migrating traders petition city for safe Saltsteppes passage.", urgency="MEDIUM"},
        desc="Bassarid relic smugglers stockpile weapons in desert hideouts.",
       {desc="Hatch Ministry loyalists attempt to reoccupy deserted outpost violently.", urgency="HIGH"},
        urgency="MEDIUM"
       {desc="Carnivorous desert locust plague devastates oasis farmland.", urgency="CRITICAL"},
      },
       {desc="Camel ranchers demand expansions for seasonal caravans.", urgency="MEDIUM"},
       {
       {desc="Earth tremor topples supply warehouse, risking resource conflict.", urgency="CRITICAL"}
        desc="Discordant Melusine winds spawn lethal dust devils destroying caravans.",
        urgency="LOW"
      },
       {
        desc="Toxic oasis near city gates kills travelers, suspected chemical warfare.",
        urgency="HIGH"
      },
       {
        desc="Mass fainting near old fortress suggests large-scale poisoning.",
        urgency="LOW"
      },
       {
        desc="Notorious bandits intercept inbound traders, forcibly recruiting them.",
        urgency="MEDIUM"
      },
       {
        desc="Hatch Ministry loyalists seize deserted outpost, staging kidnappings.",
        urgency="HIGH"
      },
       {
        desc="A massive swarm of carnivorous locusts overruns farmland, biting civilians.",
        urgency="CRITICAL"
      },
       {
        desc="Camel ranchers threaten armed revolt unless the city fortifies trade routes.",
        urgency="MEDIUM"
      },
       {
        desc="Major earthquake topples key supply depots, risking total resource collapse.",
        urgency="CRITICAL"
      },
     }
     }
   },
   },
   ["Norsolyra"] = {
   ["Norsolyra"] = {
     events = {
     events = {
       {desc="Midnight rites channel deadly will o’ wisps into the city.", urgency="HIGH"},
       {
       {desc="Veinscour Marsh storms isolate Noctic-Rabrev plantations.", urgency="HIGH"},
        desc="Will o’ wisp cult forcibly takes over city quarter, enthralling residents.",
       {desc="Ghostly lights lure travelers to vanish in Tarnand Fjord.", urgency="LOW"},
        urgency="HIGH"
       {desc="Smuggling ring busted for trafficking Wisp Rice illegally.", urgency="MEDIUM"},
      },
       {desc="Normarkian raiders sabotage dikes, flooding farmland at marsh edge.", urgency="HIGH"},
       {
       {desc="Mass dream plague shares the same Alperkin demon visage.", urgency="CRITICAL"},
        desc="Incessant storms flood Noctic-Rabrev fields, city faces mass famine.",
       {desc="Feud among wisp cult leaders on sacrificial practices breaks out.", urgency="MEDIUM"},
        urgency="HIGH"
       {desc="Pirates disguised as pilgrims loot prized Noctic goods storerooms.", urgency="HIGH"},
      },
       {desc="Corrupt officials caught pocketing will o’ wisp offerings.", urgency="LOW"},
       {
       {desc="Illusions in Tarnand Fjord divert merchant ships astray.", urgency="MEDIUM"}
        desc="Ghostly lights lure entire caravans into Tarnand Fjord; no survivors.",
        urgency="LOW"
      },
       {
        desc="Heavily armed smugglers wage turf war to dominate Wisp Rice trade.",
        urgency="MEDIUM"
      },
       {
        desc="Normarkian raiders demolish city dikes, unleashing catastrophic flooding.",
        urgency="HIGH"
      },
       {
        desc="A citywide nightmare outbreak drives population into violent delirium.",
        urgency="CRITICAL"
      },
       {
        desc="High-level schism in wisp cult leads to armed clashes over sacrifice.",
        urgency="MEDIUM"
      },
       {
        desc="Pirates disguised as pilgrims raid city armories, seizing Noctic-based munitions.",
        urgency="HIGH"
      },
       {
        desc="Corrupt officials extort wisp offerings, enraging local worshipers.",
        urgency="LOW"
      },
       {
        desc="Arcane illusions sabotage maritime commerce, bankrupting shipping guilds.",
        urgency="MEDIUM"
      },
     }
     }
   },
   },
Line 275: Line 577:
   ["Keybir-Aviv"] = {
   ["Keybir-Aviv"] = {
     events = {
     events = {
       {desc="Diamond traders vanish on Lake Morovia’s shore, suspected bandits.", urgency="HIGH"},
       {
       {desc="Stripping Path traditionalists clash with local authorities in coral markets.", urgency="MEDIUM"},
        desc="Heavily armed bandits eliminate a diamond convoy near Lake Morovia’s shore.",
       {desc="Monsoon floods cut roads linking coral farmland to the port.", urgency="HIGH"},
        urgency="HIGH"
       {desc="Hidden vault reveals earliest Wallis-Haifan Diamond Corp. records.", urgency="LOW"},
      },
       {desc="Rival cults battle for Hermes’s prime temple, citywide unrest grows.", urgency="CRITICAL"},
       {
       {desc="Spike in diamond forgeries undermines local economy.", urgency="HIGH"},
        desc="Stripping Path radicals seize coral markets, holding officials hostage.",
       {desc="Venomous reef serpents threaten outlying farms in Coral Woodlands.", urgency="MEDIUM"},
        urgency="MEDIUM"
       {desc="Warehouse fires spark sabotage conspiracy by rumored pirates.", urgency="HIGH"},
      },
       {desc="Council debates cutting ties with radical Stripping Path offshoots.", urgency="MEDIUM"},
       {
       {desc="A mysterious eclipse halts shipping for an entire day.", urgency="LOW"}
        desc="Monsoon floods isolate entire districts, widespread looting ensues.",
        urgency="HIGH"
      },
       {
        desc="Hidden vault reveals subversive Diamond Corp faction’s covert ties.",
        urgency="LOW"
      },
       {
        desc="A Hermes cult attempts mass sacrifice, halting city operations.",
        urgency="CRITICAL"
      },
       {
        desc="Vast diamond forgery ring destabilizes economy, fueling violent unrest.",
        urgency="HIGH"
      },
       {
        desc="Reef serpents swarm farmland, forcing armed evacuations of entire villages.",
        urgency="MEDIUM"
      },
       {
        desc="Warehouse bombings suspected as pirate retribution for city taxes.",
        urgency="HIGH"
      },
       {
        desc="Council crackdown on extremist Stripping Path sect triggers armed revolt.",
        urgency="MEDIUM"
      },
       {
        desc="A solar eclipse incites panic, fundamentalist mobs riot across the port.",
        urgency="LOW"
      },
     }
     }
   },
   },
   ["Tel-Amin"] = {
   ["Tel-Amin"] = {
     events = {
     events = {
       {desc="Naval blockades erupt, crippling overland routes along the Southern Strait.", urgency="CRITICAL"},
       {
       {desc="Pirate lord demands tribute from local merchants, claiming Ismael Hatch’s legacy.", urgency="HIGH"},
        desc="Naval blockades trap supply convoys, famine imminent in Tel-Amin.",
       {desc="Coral skeleton expansions yield hidden mermaid fossils near outskirts.", urgency="LOW"},
        urgency="CRITICAL"
       {desc="Host Spirit cult clashes with older Stripping Path in fiery sermon feud.", urgency="MEDIUM"},
      },
       {desc="Pilgrimage from Mylecia overwhelms Tel-Amin's lodgings, unrest ensues.", urgency="HIGH"},
       {
       {desc="Severe storms topple Apollo shrines along the coastline.", urgency="CRITICAL"},
        desc="Pirate lord kidnaps merchant heirs, demands hefty tribute in Ismael Hatch’s name.",
       {desc="Fortress gate taxes anger smugglers, blockade threatened.", urgency="HIGH"},
        urgency="HIGH"
       {desc="Rebel zealots sabotage roads, halting agricultural shipments.", urgency="MEDIUM"},
      },
       {desc="Cryptic runestone warns Tel-Amin of doom if no Haifan reconciliation is done.", urgency="LOW"},
       {
       {desc="Mysterious humming in underwater caverns suggests awakening sea spirits.", urgency="MEDIUM"}
        desc="Expanding coral skeletons reveal mermaid tomb, rumored plague unleashed.",
        urgency="LOW"
      },
       {
        desc="Host Spirit zealots burn older Stripping Path shrines, citywide lockdown.",
        urgency="MEDIUM"
      },
       {
        desc="Tens of thousands of pilgrims flood from Mylecia, overwhelming local defenses.",
        urgency="HIGH"
      },
       {
        desc="Violent storms destroy Apollo shrines on the coastline, survivors missing.",
        urgency="CRITICAL"
      },
       {
        desc="Fortress gate tax revolt escalates into armed standoff with smugglers.",
        urgency="HIGH"
      },
       {
        desc="Rebel zealots rig roads with explosives, halting agriculture supply lines.",
        urgency="MEDIUM"
      },
       {
        desc="Cryptic runestone prophecy sparks hysteria about an impending invasion.",
        urgency="LOW"
      },
       {
        desc="Underwater caverns emit deafening hum, crippling some citizens with madness.",
        urgency="MEDIUM"
      },
     }
     }
   },
   },
Line 305: Line 668:
   ["Thermosalem"] = {
   ["Thermosalem"] = {
     events = {
     events = {
       {desc="New hot spring emerges violently, flooding established bathhouses.", urgency="HIGH"},
       {
       {desc="Pilgrims swarm city for rumored cures, overwhelming local clinics.", urgency="MEDIUM"},
        desc="New geyser blasts boiling water into city streets, scalding residents.",
       {desc="Unstable seismic activity fractures main thermal reservoir.", urgency="CRITICAL"},
        urgency="HIGH"
       {desc="Herbalists feud over newly found healing moss near steam vents.", urgency="LOW"},
      },
       {desc="Midnight chanting in abandoned bathhouse hints extremist cult activity.", urgency="MEDIUM"},
       {
       {desc="Flash floods contaminate half the city’s pristine hot springs.", urgency="HIGH"},
        desc="Pilgrims riot for miracle cures, city guards overwhelmed at clinic entrances.",
       {desc="Old-guard priests clash with progressive mystics over hydrotherapy rites.", urgency="MEDIUM"},
        urgency="MEDIUM"
       {desc="Ghostly apparitions at dawn float across largest pool, puzzling onlookers.", urgency="LOW"},
      },
       {desc="Suspected sabotage collapses prized spa dome at peak hours.", urgency="HIGH"},
       {
       {desc="Mineral deposit shortage stalls biggest resort expansions, economic crisis.", urgency="CRITICAL"}
        desc="Seismic upheaval threatens to obliterate main thermal reservoir, risk of massive flood.",
        urgency="CRITICAL"
      },
       {
        desc="Warring herbalists sabotage each other to control prized steam vent harvests.",
        urgency="LOW"
      },
       {
        desc="Extremist cult kidnaps spa patrons for ritual sacrifice in abandoned bathhouse.",
        urgency="MEDIUM"
      },
       {
        desc="Flash floods contaminate famed springs with toxins, hundreds ill.",
        urgency="HIGH"
      },
       {
        desc="Armed clashes erupt between old-guard priests and progressive mystics.",
        urgency="MEDIUM"
      },
       {
        desc="Ghostly apparitions trap tourists at dawn, possibly a psychic attack.",
        urgency="LOW"
      },
       {
        desc="Prized spa dome collapses suspiciously at peak hours, dozens trapped.",
        urgency="HIGH"
      },
       {
        desc="Mineral deposit shortage sparks an angry mob demanding forced city expansion.",
        urgency="CRITICAL"
      },
     }
     }
   },
   },
   ["Akróstadium"] = {
   ["Akróstadium"] = {
     events = {
     events = {
       {desc="Veteran War League officers clash with novices at grand stadium drill.", urgency="HIGH"},
       {
       {desc="Violent storm undermines old fortress-era monastery walls.", urgency="CRITICAL"},
        desc="War League officers openly mutiny against novice commanders, city in chaos.",
       {desc="Morovian Water Buffalo rampage across training grounds, damaging city defenses.", urgency="HIGH"},
        urgency="HIGH"
       {desc="Sheep plague devastates flocks, threatening pastoral economy.", urgency="MEDIUM"},
      },
       {desc="Showcase duel ends in tragedy after sabotage discovered.", urgency="HIGH"},
       {
       {desc="Bassarid devotees invade Temple of Kan Zen demanding martial blessings.", urgency="MEDIUM"},
        desc="Tornadic storms ravage the old monastery walls, leaving Akróstadium exposed.",
       {desc="Windblown embers spark hillside stable blaze, calling for better firefighting.", urgency="LOW"},
        urgency="CRITICAL"
       {desc="Military conspirators rumored plotting coup in old monastery crypts.", urgency="CRITICAL"},
      },
       {desc="Rockslide blocks main road, cutting ranchers from city markets.", urgency="MEDIUM"},
       {
       {desc="Eerie midnight chanting echoes around the stadium, fueling war-god myths.", urgency="LOW"}
        desc="Morovian Water Buffalo breach outer defenses, injuring dozens of civilians.",
        urgency="HIGH"
      },
       {
        desc="Sheep plague cripples ranching sector, calls for martial law intensify.",
        urgency="MEDIUM"
      },
       {
        desc="Showcase duel ends in bloodshed, sabotage kills a revered champion.",
        urgency="HIGH"
      },
       {
        desc="Bassarid militants storm Temple of Kan Zen, taking worshipers hostage.",
        urgency="MEDIUM"
      },
       {
        desc="An out-of-control stable fire spreads through hillside, sabotage suspected.",
        urgency="LOW"
      },
       {
        desc="Military conspirators gather in crypts, planning a full-scale city takeover.",
        urgency="CRITICAL"
      },
       {
        desc="Rockslide cuts off main road, ranchers stranded without supply routes.",
        urgency="MEDIUM"
      },
       {
        desc="Eerie midnight chanting in stadium, suspected war-god invocation, panic ensues.",
        urgency="LOW"
      },
     }
     }
   }
   },
}
}


-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
-- (D) BUILD A WIKITABLE (AUTO-UPDATING), 60% "No reports" per city
-- (D) BUILD A WIKITABLE (AUTO-UPDATING), 60% "No reports"
-------------------------------------------------------------------------------
-------------------------------------------------------------------------------
function p.makeTable()
function p.makeTable()
     math.randomseed(os.time()) -- daily random
     math.randomseed(os.time())
    local dateString = getPSSCDate()


     local dateString = getPSSCDate()
     local lines = {}
    local output = {}
     table.insert(lines, '{| class="wikitable"')
     table.insert(output, '{| class="wikitable"')
     table.insert(lines, '! Date !! City !! Event !! Urgency')
     table.insert(output, '! Date !! City !! Event !! Urgency')


     for cityName, data in pairs(cityData) do
     for cityName, data in pairs(cityData) do
         local rnd = math.random()
         local chance = math.random()
         if rnd < 0.60 then
        -- 60% = "No reports"
             table.insert(output, '|-')
         if chance < 0.60 then
             table.insert(output, '| ' .. dateString .. ' || ' .. cityName .. ' || No reports || N/A')
             table.insert(lines, '|-')
             table.insert(lines, '| ' .. dateString .. ' || ' .. cityName .. ' || No reports || N/A')
         else
         else
            local possible = data.events
             local pick = math.random(#data.events)
             local pick = math.random(#possible)
             local e = data.events[pick]
             local chosen = possible[pick]
             table.insert(lines, '|-')
             table.insert(output, '|-')
             table.insert(lines,
             table.insert(output,
                 '| ' .. dateString
                 '| ' .. dateString
                 .. ' || ' .. cityName
                 .. ' || ' .. cityName
                 .. ' || ' .. chosen.desc
                 .. ' || ' .. e.desc
                 .. ' || ' .. chosen.urgency
                 .. ' || ' .. e.urgency
             )
             )
         end
         end
     end
     end


     table.insert(output, '|}')
     table.insert(lines, '|}')
     return table.concat(output, '\n')
     return table.concat(lines, '\n')
end
end


return p
return p

Revision as of 06:08, 3 January 2025

Documentation for this module may be created at Module:BassaridianDailyEvents/doc

-------------------------------------------------------------------------------
-- Module: DailyTable
-- Purpose:
--   1) Preserve exactly 12 city descriptions (verbatim) in a bracket-leveled
--      comment, with no omission or summary.
--   2) Re-write the city event texts so each is serious enough to possibly need
--      military intervention.
--   3) 60% chance of "No reports", else pick an event at random.
--   4) Produce a daily-updating wikitext table with columns:
--      Date, City, Event, Urgency.
-------------------------------------------------------------------------------

local p = {}

-------------------------------------------------------------------------------
-- (A) STORING THE FULL CITY DESCRIPTIONS (VERBATIM) IN A SINGLE BLOCK COMMENT
--     USING bracket-level comment to avoid Lua nesting issues:
-------------------------------------------------------------------------------

--[==[
==========================
== BASSARIDIA VAERINGHEIM
==========================
== Major Cities (3) ==
1) Vaeringheim
2) Luminaria
3) Serena

=== Vaeringheim ===
(VERBATIM TEXT GOES HERE: All original descriptive text for Vaeringheim...)

=== Luminaria ===
(VERBATIM TEXT GOES HERE: All original descriptive text for Luminaria...)

=== Serena ===
(VERBATIM TEXT GOES HERE: All original descriptive text for Serena...)


=====================
== Minor Cities (3) ==
1) Saluria
2) Aetherium
3) Ferrum Citadel

=== Saluria ===
(VERBATIM TEXT GOES HERE...)

=== Aetherium ===
(VERBATIM TEXT GOES HERE...)

=== Ferrum Citadel ===
(VERBATIM TEXT GOES HERE...)


===========================
== NEW SOUTH JANGSONG
===========================
== Major Cities (2) ==
1) Skýrophos
2) Bjornopolis

=== Skýrophos ===
(VERBATIM TEXT GOES HERE...)

=== Bjornopolis ===
(VERBATIM TEXT GOES HERE...)


== Minor Cities (2) ==
1) Pelagia
2) Norsolyra

=== Pelagia ===
(VERBATIM TEXT GOES HERE...)

=== Norsolyra ===
(VERBATIM TEXT GOES HERE...)


===========================
== HAIFAN BASSARIDIA
===========================
== Major Cities (2) ==
1) Keybir-Aviv
2) Tel-Amin

=== Keybir-Aviv ===
(VERBATIM TEXT GOES HERE...)

=== Tel-Amin ===
(VERBATIM TEXT GOES HERE...)


== Minor Cities (2) ==
1) Thermosalem
2) Akróstadium

=== Thermosalem ===
(VERBATIM TEXT GOES HERE...)

=== Akróstadium ===
(VERBATIM TEXT GOES HERE...)
]==]

-------------------------------------------------------------------------------
-- (B) SIMPLE PSSC DATE FUNCTION
-------------------------------------------------------------------------------
local function getPSSCDate()
    local start = os.time{year=1999, month=8, day=6}
    local now = os.time()
    local daysSince = math.floor((now - start) / 86400)
    local psscYear = math.floor(daysSince / 183)
    local dayOfYear = (daysSince % 183) + 1
    return ("Day %d of Year %d PSSC"):format(dayOfYear, psscYear)
end

-------------------------------------------------------------------------------
-- (C) DEFINING 12 CITIES WITH 10 POSSIBLE SERIOUS EVENTS, 60% NO REPORTS
-------------------------------------------------------------------------------
local cityData = {

  -- 3 Major from Bassaridia Vaeringheim
  ["Vaeringheim"] = {
    events = {
      {
        desc="Heavily armed extremist group storms the canal lock, flooding downtown markets.",
        urgency="HIGH"
      },
      {
        desc="Organized Normark loyalists occupy the old fortress, threatening city patrols.",
        urgency="HIGH"
      },
      {
        desc="Full-blown religious riots over conflicting Thalassa worship rites, dozens wounded.",
        urgency="CRITICAL"
      },
      {
        desc="Lethal fish plague in Lake Morovia threatens regional food supply.",
        urgency="HIGH"
      },
      {
        desc="Port officials indicted for treason and sabotage, city commerce disrupted.",
        urgency="HIGH"
      },
      {
        desc="Temple Bank invests in militarized expansion, escalating Alperkin tensions.",
        urgency="MEDIUM"
      },
      {
        desc="Commandos steal ancient relic from Reformed Path shrine, leaving guards dead.",
        urgency="HIGH"
      },
      {
        desc="Rumors of a Triton cult recruiting heavily among disaffected youth.",
        urgency="LOW"
      },
      {
        desc="Bridge collapses during parade, sabotage suspected, multiple casualties.",
        urgency="CRITICAL"
      },
      {
        desc="Pirate infiltration confirmed on city outskirts, local militia outgunned.",
        urgency="HIGH"
      },
    }
  },

  ["Luminaria"] = {
    events = {
      {
        desc="Massive sandstorm traps hundreds near Conclave Illuminara, criminals roam freely.",
        urgency="HIGH"
      },
      {
        desc="Violent quake collapses part of the subterranean labyrinth, pilgrims buried.",
        urgency="HIGH"
      },
      {
        desc="Alperkin herders blockade city gates with armed barricades over grazing disputes.",
        urgency="MEDIUM"
      },
      {
        desc="Firebombing at a major tea house destroys Aurora Mystica archives.",
        urgency="HIGH"
      },
      {
        desc="Suspected bioweapon fungus outbreak glows at night, terrifying citizens.",
        urgency="LOW"
      },
      {
        desc="Heavily armed ranchers claim Tarsica’s relics, threaten Luminaria’s leadership.",
        urgency="MEDIUM"
      },
      {
        desc="Eos devotees suffer apocalyptic visions, fueling mass hysteria.",
        urgency="LOW"
      },
      {
        desc="Organized thieves raid the Onceanic Boot Company, seizing prime rhino-hides.",
        urgency="HIGH"
      },
      {
        desc="Strange chanting intensifies under city temples, rumored sacrificial rituals.",
        urgency="LOW"
      },
      {
        desc="Rival priestesses engage in a bloody duel for control of sacred relics.",
        urgency="CRITICAL"
      },
    }
  },

  ["Serena"] = {
    events = {
      {
        desc="Large Morovian insurgent force seizes an outlying settlement in the Ismaelean Mountains.",
        urgency="HIGH"
      },
      {
        desc="Avalanche engulfs Normarkian historical site, militia rescue fails.",
        urgency="CRITICAL"
      },
      {
        desc="Radical druids overrun Harmony Sanctum in a violent takeover.",
        urgency="MEDIUM"
      },
      {
        desc="Garganram herds rampage farmland, rumored to be trained war beasts.",
        urgency="HIGH"
      },
      {
        desc="Sectarian riots over newly found Micras relics, major casualties reported.",
        urgency="CRITICAL"
      },
      {
        desc="Ferrum Citadel imposes partial blockade on Serena’s mountain passes.",
        urgency="MEDIUM"
      },
      {
        desc="Cursed Normark tomb discovered, unknown supernatural threat unleashed.",
        urgency="HIGH"
      },
      {
        desc="Exiled druid weaponizes Ismaelean winds, toppling watchtowers.",
        urgency="MEDIUM"
      },
      {
        desc="Forest fires spread rapidly, rumored sabotage by Anti-Noctic forces.",
        urgency="HIGH"
      },
      {
        desc="Chanting cultists gather nightly at Daughters of Micras statue, possibly armed.",
        urgency="LOW"
      },
    }
  },

  -- 3 Minor from Bassaridia Vaeringheim
  ["Saluria"] = {
    events = {
      {
        desc="Nighttime raids torch Horehound fields, crippling Sanctum Vitalis finance.",
        urgency="MEDIUM"
      },
      {
        desc="Armed cultists seize Temple of Sacred Horehound, hostages taken.",
        urgency="HIGH"
      },
      {
        desc="Ambush sites set via strange flute melodies, luring caravans into Gloom Forest traps.",
        urgency="LOW"
      },
      {
        desc="Coordinated arson destroys multiple apothecaries, threatens medical supply.",
        urgency="HIGH"
      },
      {
        desc="Dangerous pilgrims flood Saluria seeking ‘miracle cures,’ overwhelming defenses.",
        urgency="MEDIUM"
      },
      {
        desc="Alperkin druids threaten storms unless city yields to their sovereignty.",
        urgency="LOW"
      },
      {
        desc="Brigands impose huge tribute on medicine shipments, hospitals critically low.",
        urgency="MEDIUM"
      },
      {
        desc="Expanding sinkholes devour orchard, inch toward city gates.",
        urgency="HIGH"
      },
      {
        desc="Mass vermin infestation overruns temple archives, suspected bio-warfare.",
        urgency="LOW"
      },
      {
        desc="High priestess found nearly dead at Fount Evander, possible poisoning.",
        urgency="CRITICAL"
      },
    }
  },

  ["Aetherium"] = {
    events = {
      {
        desc="A rebel camel cavalry raids Temple Alabaster, heavy damage reported.",
        urgency="HIGH"
      },
      {
        desc="Blizzard traps an entire Normarkian regiment, rescue convoys ambushed.",
        urgency="CRITICAL"
      },
      {
        desc="Avalanche devastates hot springs, cutting crucial water supply.",
        urgency="HIGH"
      },
      {
        desc="Clandestine Ivory cult arms itself, threatening to expel outsiders.",
        urgency="LOW"
      },
      {
        desc="Feathers for forging advanced weapons withheld by saboteurs.",
        urgency="MEDIUM"
      },
      {
        desc="Aurora-like lights rumored to signal an invading force from the peaks.",
        urgency="LOW"
      },
      {
        desc="Camel Herders blockade city gates, demanding total autonomy.",
        urgency="MEDIUM"
      },
      {
        desc="Temple Alabaster priests forcibly evict Alperkin mystics, tensions surge.",
        urgency="MEDIUM"
      },
      {
        desc="Child prophet calls for ‘holy war,’ inciting fervent crowds.",
        urgency="LOW"
      },
      {
        desc="Saboteurs destroy the only safe pass into subzero highlands, caravans stranded.",
        urgency="CRITICAL"
      },
    }
  },

  ["Ferrum Citadel"] = {
    events = {
      {
        desc="Court of the Ironclad forms an unsanctioned army, region-wide alarm triggered.",
        urgency="HIGH"
      },
      {
        desc="Fierce sandstorm wrecks fortress defenses, marauders close in.",
        urgency="CRITICAL"
      },
      {
        desc="Mutated Ferrum Mosquitos swarm residential zones, injecting lethal toxins.",
        urgency="HIGH"
      },
      {
        desc="Intercepted arms shipments reveal conspiracy for an internal coup.",
        urgency="HIGH"
      },
      {
        desc="Fenrir worshipers kidnap political figures, demand ransom for release.",
        urgency="MEDIUM"
      },
      {
        desc="Lightning storm obliterates ramparts, opening city to invaders.",
        urgency="CRITICAL"
      },
      {
        desc="Sabotage in prime iron vein halts weapon forging, supply crisis imminent.",
        urgency="MEDIUM"
      },
      {
        desc="Rival Fenrir cult seizes fortress, threatens to execute city leaders.",
        urgency="LOW"
      },
      {
        desc="Trade caravan vanishes in desert, suspected slavers at work.",
        urgency="MEDIUM"
      },
      {
        desc="Terrorized guards report monstrous Skoll illusions, morale collapses.",
        urgency="LOW"
      },
    }
  },

  -- 2 Major from New South Jangsong
  ["Skýrophos"] = {
    events = {
      {
        desc="Quartz cliff collapse blocks harbor, raiders exploit the city’s vulnerability.",
        urgency="HIGH"
      },
      {
        desc="Alterbulb illusions ensnare Haifan ambassador’s entourage, risking crisis.",
        urgency="MEDIUM"
      },
      {
        desc="Renegade pirates seize fishing fleet laden with valuable pufferfish.",
        urgency="HIGH"
      },
      {
        desc="Massive quake shatters Suncliffs, burying critical defenses.",
        urgency="CRITICAL"
      },
      {
        desc="Merchants accuse rivals of contraband quartz-based weapon smuggling.",
        urgency="LOW"
      },
      {
        desc="Petrified aristocrat discovered etched with arcane symbols, black magic suspected.",
        urgency="HIGH"
      },
      {
        desc="Saboteurs contaminate Alterbulb cargo, crippling local economy.",
        urgency="MEDIUM"
      },
      {
        desc="Zealous acolytes proclaim uprising, capturing a government outpost.",
        urgency="MEDIUM"
      },
      {
        desc="Unidentified aquatic beasts assault coastal guard towers at night.",
        urgency="LOW"
      },
      {
        desc="Earth fissures tear open main bazaar, allowing criminals to loot freely.",
        urgency="CRITICAL"
      },
    }
  },

  ["Bjornopolis"] = {
    events = {
      {
        desc="Sirenian Falls overflow, drowning a military checkpoint in the terraces.",
        urgency="HIGH"
      },
      {
        desc="Armed smugglers clash at floating market over sphinx moth silk prices.",
        urgency="MEDIUM"
      },
      {
        desc="Caverns collapse beneath city foundations, swallowing entire block.",
        urgency="HIGH"
      },
      {
        desc="Merchant guild revolt locks down Bjornopolis, demands secession from NSJ.",
        urgency="CRITICAL"
      },
      {
        desc="Tainted mead potions spark mass poisoning, crowds riot for antidotes.",
        urgency="MEDIUM"
      },
      {
        desc="Enraged Bijarian Leopards attack outlying farms, city watch overwhelmed.",
        urgency="LOW"
      },
      {
        desc="A stolen Altar of Songs relic used to rally an insurgent militia.",
        urgency="HIGH"
      },
      {
        desc="Renegade ex-soldiers blockade the harbor with armed ships, extorting the city.",
        urgency="CRITICAL"
      },
      {
        desc="‘Whispering Falls’ intensifies, numerous fishers vanish nightly.",
        urgency="HIGH"
      },
      {
        desc="Street performers incite panic with illusions provoking violent clashes.",
        urgency="LOW"
      },
    }
  },

  -- 2 Minor from New South Jangsong
  ["Pelagia"] = {
    events = {
      {
        desc="Saltsteppes caravans ambushed by heavily armed raiders, city supplies at risk.",
        urgency="HIGH"
      },
      {
        desc="Bassarid relic smugglers stockpile weapons in desert hideouts.",
        urgency="MEDIUM"
      },
      {
        desc="Discordant Melusine winds spawn lethal dust devils destroying caravans.",
        urgency="LOW"
      },
      {
        desc="Toxic oasis near city gates kills travelers, suspected chemical warfare.",
        urgency="HIGH"
      },
      {
        desc="Mass fainting near old fortress suggests large-scale poisoning.",
        urgency="LOW"
      },
      {
        desc="Notorious bandits intercept inbound traders, forcibly recruiting them.",
        urgency="MEDIUM"
      },
      {
        desc="Hatch Ministry loyalists seize deserted outpost, staging kidnappings.",
        urgency="HIGH"
      },
      {
        desc="A massive swarm of carnivorous locusts overruns farmland, biting civilians.",
        urgency="CRITICAL"
      },
      {
        desc="Camel ranchers threaten armed revolt unless the city fortifies trade routes.",
        urgency="MEDIUM"
      },
      {
        desc="Major earthquake topples key supply depots, risking total resource collapse.",
        urgency="CRITICAL"
      },
    }
  },

  ["Norsolyra"] = {
    events = {
      {
        desc="Will o’ wisp cult forcibly takes over city quarter, enthralling residents.",
        urgency="HIGH"
      },
      {
        desc="Incessant storms flood Noctic-Rabrev fields, city faces mass famine.",
        urgency="HIGH"
      },
      {
        desc="Ghostly lights lure entire caravans into Tarnand Fjord; no survivors.",
        urgency="LOW"
      },
      {
        desc="Heavily armed smugglers wage turf war to dominate Wisp Rice trade.",
        urgency="MEDIUM"
      },
      {
        desc="Normarkian raiders demolish city dikes, unleashing catastrophic flooding.",
        urgency="HIGH"
      },
      {
        desc="A citywide nightmare outbreak drives population into violent delirium.",
        urgency="CRITICAL"
      },
      {
        desc="High-level schism in wisp cult leads to armed clashes over sacrifice.",
        urgency="MEDIUM"
      },
      {
        desc="Pirates disguised as pilgrims raid city armories, seizing Noctic-based munitions.",
        urgency="HIGH"
      },
      {
        desc="Corrupt officials extort wisp offerings, enraging local worshipers.",
        urgency="LOW"
      },
      {
        desc="Arcane illusions sabotage maritime commerce, bankrupting shipping guilds.",
        urgency="MEDIUM"
      },
    }
  },

  -- 2 Major from Haifan Bassaridia
  ["Keybir-Aviv"] = {
    events = {
      {
        desc="Heavily armed bandits eliminate a diamond convoy near Lake Morovia’s shore.",
        urgency="HIGH"
      },
      {
        desc="Stripping Path radicals seize coral markets, holding officials hostage.",
        urgency="MEDIUM"
      },
      {
        desc="Monsoon floods isolate entire districts, widespread looting ensues.",
        urgency="HIGH"
      },
      {
        desc="Hidden vault reveals subversive Diamond Corp faction’s covert ties.",
        urgency="LOW"
      },
      {
        desc="A Hermes cult attempts mass sacrifice, halting city operations.",
        urgency="CRITICAL"
      },
      {
        desc="Vast diamond forgery ring destabilizes economy, fueling violent unrest.",
        urgency="HIGH"
      },
      {
        desc="Reef serpents swarm farmland, forcing armed evacuations of entire villages.",
        urgency="MEDIUM"
      },
      {
        desc="Warehouse bombings suspected as pirate retribution for city taxes.",
        urgency="HIGH"
      },
      {
        desc="Council crackdown on extremist Stripping Path sect triggers armed revolt.",
        urgency="MEDIUM"
      },
      {
        desc="A solar eclipse incites panic, fundamentalist mobs riot across the port.",
        urgency="LOW"
      },
    }
  },

  ["Tel-Amin"] = {
    events = {
      {
        desc="Naval blockades trap supply convoys, famine imminent in Tel-Amin.",
        urgency="CRITICAL"
      },
      {
        desc="Pirate lord kidnaps merchant heirs, demands hefty tribute in Ismael Hatch’s name.",
        urgency="HIGH"
      },
      {
        desc="Expanding coral skeletons reveal mermaid tomb, rumored plague unleashed.",
        urgency="LOW"
      },
      {
        desc="Host Spirit zealots burn older Stripping Path shrines, citywide lockdown.",
        urgency="MEDIUM"
      },
      {
        desc="Tens of thousands of pilgrims flood from Mylecia, overwhelming local defenses.",
        urgency="HIGH"
      },
      {
        desc="Violent storms destroy Apollo shrines on the coastline, survivors missing.",
        urgency="CRITICAL"
      },
      {
        desc="Fortress gate tax revolt escalates into armed standoff with smugglers.",
        urgency="HIGH"
      },
      {
        desc="Rebel zealots rig roads with explosives, halting agriculture supply lines.",
        urgency="MEDIUM"
      },
      {
        desc="Cryptic runestone prophecy sparks hysteria about an impending invasion.",
        urgency="LOW"
      },
      {
        desc="Underwater caverns emit deafening hum, crippling some citizens with madness.",
        urgency="MEDIUM"
      },
    }
  },

  -- 2 Minor from Haifan Bassaridia
  ["Thermosalem"] = {
    events = {
      {
        desc="New geyser blasts boiling water into city streets, scalding residents.",
        urgency="HIGH"
      },
      {
        desc="Pilgrims riot for miracle cures, city guards overwhelmed at clinic entrances.",
        urgency="MEDIUM"
      },
      {
        desc="Seismic upheaval threatens to obliterate main thermal reservoir, risk of massive flood.",
        urgency="CRITICAL"
      },
      {
        desc="Warring herbalists sabotage each other to control prized steam vent harvests.",
        urgency="LOW"
      },
      {
        desc="Extremist cult kidnaps spa patrons for ritual sacrifice in abandoned bathhouse.",
        urgency="MEDIUM"
      },
      {
        desc="Flash floods contaminate famed springs with toxins, hundreds ill.",
        urgency="HIGH"
      },
      {
        desc="Armed clashes erupt between old-guard priests and progressive mystics.",
        urgency="MEDIUM"
      },
      {
        desc="Ghostly apparitions trap tourists at dawn, possibly a psychic attack.",
        urgency="LOW"
      },
      {
        desc="Prized spa dome collapses suspiciously at peak hours, dozens trapped.",
        urgency="HIGH"
      },
      {
        desc="Mineral deposit shortage sparks an angry mob demanding forced city expansion.",
        urgency="CRITICAL"
      },
    }
  },

  ["Akróstadium"] = {
    events = {
      {
        desc="War League officers openly mutiny against novice commanders, city in chaos.",
        urgency="HIGH"
      },
      {
        desc="Tornadic storms ravage the old monastery walls, leaving Akróstadium exposed.",
        urgency="CRITICAL"
      },
      {
        desc="Morovian Water Buffalo breach outer defenses, injuring dozens of civilians.",
        urgency="HIGH"
      },
      {
        desc="Sheep plague cripples ranching sector, calls for martial law intensify.",
        urgency="MEDIUM"
      },
      {
        desc="Showcase duel ends in bloodshed, sabotage kills a revered champion.",
        urgency="HIGH"
      },
      {
        desc="Bassarid militants storm Temple of Kan Zen, taking worshipers hostage.",
        urgency="MEDIUM"
      },
      {
        desc="An out-of-control stable fire spreads through hillside, sabotage suspected.",
        urgency="LOW"
      },
      {
        desc="Military conspirators gather in crypts, planning a full-scale city takeover.",
        urgency="CRITICAL"
      },
      {
        desc="Rockslide cuts off main road, ranchers stranded without supply routes.",
        urgency="MEDIUM"
      },
      {
        desc="Eerie midnight chanting in stadium, suspected war-god invocation, panic ensues.",
        urgency="LOW"
      },
    }
  },
}

-------------------------------------------------------------------------------
-- (D) BUILD A WIKITABLE (AUTO-UPDATING), 60% "No reports"
-------------------------------------------------------------------------------
function p.makeTable()
    math.randomseed(os.time())
    local dateString = getPSSCDate()

    local lines = {}
    table.insert(lines, '{| class="wikitable"')
    table.insert(lines, '! Date !! City !! Event !! Urgency')

    for cityName, data in pairs(cityData) do
        local chance = math.random()
        -- 60% = "No reports"
        if chance < 0.60 then
            table.insert(lines, '|-')
            table.insert(lines, '| ' .. dateString .. ' || ' .. cityName .. ' || No reports || N/A')
        else
            local pick = math.random(#data.events)
            local e = data.events[pick]
            table.insert(lines, '|-')
            table.insert(lines,
                '| ' .. dateString
                .. ' || ' .. cityName
                .. ' || ' .. e.desc
                .. ' || ' .. e.urgency
            )
        end
    end

    table.insert(lines, '|}')
    return table.concat(lines, '\n')
end

return p