Module:BassaridianCalendar: Difference between revisions

From MicrasWiki
Jump to navigationJump to search
NewZimiaGov (talk | contribs)
No edit summary
NewZimiaGov (talk | contribs)
No edit summary
Tag: Manual revert
Line 32: Line 32:
     }
     }


     ------------------------------------------------------------------------
     -- Month and zodiac logic
     -- Below is a table of events with short descriptions referencing lore --
    local month, dayInMonth, zodiac
     ------------------------------------------------------------------------
    if dayOfYear <= 61 then
        month = "Atosiel"
        dayInMonth = dayOfYear
        if dayInMonth <= 12 then zodiac = "Atosien"
        elseif dayInMonth <= 24 then zodiac = "Eosena"
        elseif dayInMonth <= 36 then zodiac = "Micrasha"
        elseif dayInMonth <= 48 then zodiac = "Pyreska"
        else zodiac = "Indomin" end
    elseif dayOfYear <= 122 then
        month = "Thalassiel"
        dayInMonth = dayOfYear - 61
        if dayInMonth <= 12 then zodiac = "Chrysen"
        elseif dayInMonth <= 24 then zodiac = "Thalassian"
        elseif dayInMonth <= 36 then zodiac = "Nephelia"
        elseif dayInMonth <= 48 then zodiac = "Glinaeus"
        else zodiac = "Noctien" end
    else
        month = "Opsitheiel"
        dayInMonth = dayOfYear - 122
        if dayInMonth <= 12 then zodiac = "Opsithia"
        elseif dayInMonth <= 24 then zodiac = "Stygian"
        elseif dayInMonth <= 36 then zodiac = "Faunian"
        elseif dayInMonth <= 48 then zodiac = "Silenian"
        else zodiac = "Catosien" end
     end
 
     -- Events with corrected day alignment
     local events = {
     local events = {
        -- Month: Atosiel
         ["Atosiel,6"] = "Bayram al-Nur (Festival of Light) [Vaeringheim]",
         ["Atosiel,6"] = [[Bayram al-Nur (Festival of Light) [Vaeringheim]
         ["Atosiel,18"] = "Chag Or Hadash (Festival of New Light) [Luminaria]",
            - Originating in Vaeringheim, the oldest city in Bassaridia Vaeringheim, this festival honors Atos, Divine of Light and Creation. Locals gather near the famed Lake Morovia canals to celebrate the rebirth of the sun, embracing the city’s blend of Stripping Path and Alperkin traditions.]],
         ["Atosiel,30"] = "Symposion Eirinis (Symposium of Harmony) [Serena]",
         ["Atosiel,18"] = [[Chag Or Hadash (Festival of New Light) [Luminaria]
         ["Atosiel,43"] = "Alev Günü (Day of Flame) [Pyralis]",
            - Observed in Luminaria, where the Order of Aurora Mystica holds sway, this festival extols Eos, Lady Divine of dawn. Believers practice morning rites on the Plains of Vaeringheim, lighting lanterns symbolizing new beginnings and enlightenment.]],
         ["Atosiel,48"] = "Day of Abandonment [Vaeringheim]",
         ["Atosiel,30"] = [[Symposion Eirinis (Symposium of Harmony) [Serena]
         ["Atosiel,55"] = "Tikkun Tzel (Repair of Shadows) [Symphonara]",
            - Held in Serena’s Harmony Sanctum, devoted to Micras, Lady Divine of balance and wisdom. Citizens and priestesses engage in peaceful debates on the ruins of the ancient Normarkian military outpost, reflecting Serena’s journey from conflict to serenity.]],
         ["Thalassiel,6"] = "Panegyris Chrysou (Golden Gathering) [Aurelia]",
         ["Atosiel,43"] = [[Alev Günü (Day of Flame) [Pyralis]
         ["Thalassiel,17"] = "Constitution Day [Luminaria]",
            - Celebrated in Pyralis, the spiritual haven of Ignis Aeternum, which venerates Pyros, Divine of fire. Worshippers gather around the city’s geothermal hot springs, welcoming the spark of creativity and paying homage to the Highland Port marketplace.]],
         ["Thalassiel,19"] = "Mehtap Dalgası (Moonlit Tide) [Vaeringheim]",
         ["Atosiel,48"] = [[Day of Abandonment [Vaeringheim]
         ["Thalassiel,31"] = "Oneiro Foteino (Dream of Illumination) [Somniumpolis]",
            - A solemn remembrance in the capital city, marking the exile of Vaeringheim’s early inhabitants by the Old Gods. Locals visit shrines of Thalassa, reciting prayers for redemption and introspection, echoing the Reformed Stripping Path’s journey from chaos to renewed order.]],
         ["Thalassiel,39"] = "Anniversary of victory in the New South Jangsong Campaign [Nexa]",
         ["Atosiel,55"] = [[Tikkun Tzel (Repair of Shadows) [Symphonara]
         ["Thalassiel,44"] = "Erev Galgal (Eve of Cycles) [Nexa]",
            - A reflective ceremony in Symphonara, home of the Celestial Harmony Sect (devoted to Indigo and Momiji). Rituals focus on healing discord between warring cults. Participants invoke the city’s famed Harmony Gardens to unify shadow and light through music and discourse.]],
         ["Thalassiel,45"] = "Bassaridia Festival [Somniumpolis]",
 
         ["Thalassiel,48"] = "Anniversary of victory in the Southern Lake Morovia Campaign [Somniumpolis]",
        -- Month: Thalassiel
         ["Thalassiel,54"] = "Leilat al-Kamar (Night of the Moon) [Lunalis Sancta]",
         ["Thalassiel,6"] = [[Panegyris Chrysou (Golden Gathering) [Aurelia]
         ["Thalassiel,61"] = "Taşrakah (Reverence of the Stone) [Luminaria]",
            - Aurelia, a former Morovian Nationalist stronghold, now prospers under Chrysos, Divine of wealth. Merchants and travelers converge here to trade rare gems and pay homage to the Guild of Golden Shadows, reflecting on the city’s gold-infused past.]],
         ["Opsitheiel,6"] = "Chag Tvuah (Festival of Harvest) [Sylvapolis]",
         ["Thalassiel,17"] = [[Constitution Day [Luminaria]
         ["Opsitheiel,18"] = "Anagenesis Eirmos (Procession of Rebirth) [Acheron]",
            - Commemorates the signing of the first civic charter in Luminaria’s underground halls. Marked by processions led by the Conclave Illuminara, adherents of Tarsica, Lady Divine of illumination, symbolizing unity between Alperkin and Bassaridian peoples.]],
         ["Opsitheiel,28"] = "Panagia Therizis (Holy Day of the Reaper) [Sylvapolis]",
         ["Thalassiel,19"] = [[Mehtap Dalgası (Moonlit Tide) [Vaeringheim]
         ["Opsitheiel,37"] = "Anniversary of victory in the Morovian Frontier Campaign [Acheron]",
            - Vaeringheim’s Reformed Stripping Path priestesses guide night processions along Lake Morovia, celebrating Thalassa’s lunar mysteries. Worshipers honor the city’s maritime heritage with candlelit canal ceremonies that link sky, water, and tradition.]],
         ["Opsitheiel,43"] = "Karnavali Thysias (Carnival of Celebration) [Erythros]",
         ["Thalassiel,31"] = [[Oneiro Foteino (Dream of Illumination) [Somniumpolis]
         ["Opsitheiel,53"] = "Sefar Yashar (Straight Path Celebration) [Catonis Atrium]"
            - Centered in Somniumpolis’s Reverie Nebulous, devoted to Nephele, Lady Divine of clouds and inspiration. Visions and dream-dances fill the Odiferae Wetlands, reflecting the city’s legendary bonds with pirates and mystics who navigate Morovia’s hidden currents.]],
         ["Thalassiel,39"] = [[Anniversary of victory in the New South Jangsong Campaign [Nexa]
            - Nexa’s Eon Fellowship, followers of Glinos, Divine of ice and life cycles, commemorate the annexation of New South Jangsong. Pilgrims circle the Bloodbaths of Laprind, recalling the campaign’s harsh winters and the city’s transformation from hidden refuge to strategic bastion.]],
         ["Thalassiel,44"] = [[Erev Galgal (Eve of Cycles) [Nexa]
            - Another Nexan observance dedicated to the cycle of life and death. Devotees of Glinos spend the evening chanting among the Gloom Forest’s crimson foliage, inviting renewal and reflecting on the city’s ancient Alperkin legends of cyclical rebirth.]],
         ["Thalassiel,45"] = [[Bassaridia Festival [Somniumpolis]
            - A grand festival celebrating the Alperkin roots of Somniumpolis and the expansion of Reformed Stripping Path values around Lake Morovia. Revelers exchange goods imbued with Noctic-Rabrev, fueling the city’s pirate-friendly reputation and artistic flair.]],
         ["Thalassiel,48"] = [[Anniversary of victory in the Southern Lake Morovia Campaign [Somniumpolis]
            - Marks the city’s successful stand against anti-Bassarid insurgencies, culminating in a turning point for the Reformed Stripping Path’s hold over the Odiferae Wetlands. Historic canals become filled with floating lanterns, honoring those lost in the campaign.]],
         ["Thalassiel,54"] = [[Leilat al-Kamar (Night of the Moon) [Lunalis Sancta]
            - Celebrated by the Order of the Umbral Oracle, devoted to Noctis, Lady Divine of the night. Pilgrims journey through Lunalis Sancta’s moonlit hills, reading from sacred tomes kept in the city’s labyrinthine libraries to glean hidden truths from the shadows.]],
         ["Thalassiel,61"] = [[Taşrakah (Reverence of the Stone) [Luminaria]
            - Conducted by the Conclave Illuminara and the Order of Aurora Mystica. The day highlights Luminaria’s famed subterranean temples, reaffirming Eos’s light in every carved tunnel. Families inscribe prayers onto stone tablets, symbolizing resilience and faith.]],
 
        -- Month: Opsitheiel
         ["Opsitheiel,6"] = [[Chag Tvuah (Festival of Harvest) [Sylvapolis]
            - Held in the rainy Odiferae Wetlands, where Opsithe, Lady Divine of harvest, is venerated. Locals and visiting pilgrims unite for seed-blessing rituals in Sylvapolis’s lush farmland, celebrating the city’s link to Alperkin myths of the “Emptiness” below.]],
         ["Opsitheiel,18"] = [[Anagenesis Eirmos (Procession of Rebirth) [Acheron]
            - A pilgrimage in Acheron’s Canyonlands to venerate Styx, Lady Divine of transformation and rebirth. Participants soak their feet in sacred pools, symbolizing the passage from mortal constraint to spiritual renewal as they near the Tomb of Styx.]],
         ["Opsitheiel,28"] = [[Panagia Therizis (Holy Day of the Reaper) [Sylvapolis]
            - Another Sylvapolis festival celebrating Opsithe and Faun, Lady Divine of natural balance. Farmers honor the end of the harvest season with communal feasts, reaffirming the city’s historical role as the “pathway” to the Alperkin Underworld.]],
         ["Opsitheiel,37"] = [[Anniversary of victory in the Morovian Frontier Campaign [Acheron]
            - Commemorates Acheron’s strategic triumph in securing trade routes near the Gloom Forest of Perpetual Autumn. The Mystery of the Stygian Veil hosts solemn rites in the canyonlands, bridging past battles and the city’s ethos of transformation.]],
         ["Opsitheiel,43"] = [[Karnavali Thysias (Carnival of Celebration) [Erythros]
            - Erythros’s Mystery of Red Mirth, devoted to Silenus, Divine of merriment, transforms the sacred Tar-Lands into a stage for music and dance. Statues of the Archigós—the golden Adlet—are honored, weaving Alperkin funeral rites with Bassarid revelry.]],
         ["Opsitheiel,53"] = [[Sefar Yashar (Straight Path Celebration) [Catonis Atrium]
            - In Catonis Atrium, home of Rex Catonis, worshipers of Cato, Divine of discipline and order, gather for public recitations of civic codes. The festival promotes discipline and self-improvement, reflecting the city’s satyr-influenced legacy of law, apple groves, and vegetable lamb herds.]]
     }
     }



Revision as of 06:51, 30 December 2024

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

local p = {}

function p.getCurrentDate()
    local startDate = os.time({year = 1999, month = 8, day = 6})
    local secondsInDay = 86400
    local daysPerYear = 183

    local currentDate = os.time()
    local totalDaysElapsed = math.floor((currentDate - startDate) / secondsInDay)

    local yearFraction = totalDaysElapsed / daysPerYear
    local psscYear = math.floor(yearFraction)
    local dayOfYear = math.floor((yearFraction - psscYear) * daysPerYear) + 1

    -- Define zodiac proverbs
    local zodiacProverbs = {
        Atosien = "The first light reveals the sacred cycle of renewal.",
        Eosena = "The dawn whispers: every step is a rebirth.",
        Micrasha = "Wisdom is the balance of shadow and flame.",
        Pyreska = "Creation ignites in the fires of transformation.",
        Indomin = "Two paths intertwine: strength in unity, clarity in duality.",
        Chrysen = "Gold is the soul's test: will you hoard or share?",
        Thalassian = "The tides of Thalassiel teach patience and purpose.",
        Nephelia = "Dreams are stars, fleeting yet eternal in the night sky.",
        Glinaeus = "The frost preserves what must endure.",
        Noctien = "Night guides those who seek the unseen truths.",
        Opsithia = "The harvest feeds not just the body, but the spirit.",
        Stygian = "Through the Styx flows the essence of transformation.",
        Faunian = "The forests sing of life and the balance it brings.",
        Silenian = "Celebration is the nectar of divine abundance.",
        Catosien = "Order shapes greatness; the straight path ascends."
    }

    -- Month and zodiac logic
    local month, dayInMonth, zodiac
    if dayOfYear <= 61 then
        month = "Atosiel"
        dayInMonth = dayOfYear
        if dayInMonth <= 12 then zodiac = "Atosien"
        elseif dayInMonth <= 24 then zodiac = "Eosena"
        elseif dayInMonth <= 36 then zodiac = "Micrasha"
        elseif dayInMonth <= 48 then zodiac = "Pyreska"
        else zodiac = "Indomin" end
    elseif dayOfYear <= 122 then
        month = "Thalassiel"
        dayInMonth = dayOfYear - 61
        if dayInMonth <= 12 then zodiac = "Chrysen"
        elseif dayInMonth <= 24 then zodiac = "Thalassian"
        elseif dayInMonth <= 36 then zodiac = "Nephelia"
        elseif dayInMonth <= 48 then zodiac = "Glinaeus"
        else zodiac = "Noctien" end
    else
        month = "Opsitheiel"
        dayInMonth = dayOfYear - 122
        if dayInMonth <= 12 then zodiac = "Opsithia"
        elseif dayInMonth <= 24 then zodiac = "Stygian"
        elseif dayInMonth <= 36 then zodiac = "Faunian"
        elseif dayInMonth <= 48 then zodiac = "Silenian"
        else zodiac = "Catosien" end
    end

    -- Events with corrected day alignment
    local events = {
        ["Atosiel,6"] = "Bayram al-Nur (Festival of Light) [Vaeringheim]",
        ["Atosiel,18"] = "Chag Or Hadash (Festival of New Light) [Luminaria]",
        ["Atosiel,30"] = "Symposion Eirinis (Symposium of Harmony) [Serena]",
        ["Atosiel,43"] = "Alev Günü (Day of Flame) [Pyralis]",
        ["Atosiel,48"] = "Day of Abandonment [Vaeringheim]",
        ["Atosiel,55"] = "Tikkun Tzel (Repair of Shadows) [Symphonara]",
        ["Thalassiel,6"] = "Panegyris Chrysou (Golden Gathering) [Aurelia]",
        ["Thalassiel,17"] = "Constitution Day [Luminaria]",
        ["Thalassiel,19"] = "Mehtap Dalgası (Moonlit Tide) [Vaeringheim]",
        ["Thalassiel,31"] = "Oneiro Foteino (Dream of Illumination) [Somniumpolis]",
        ["Thalassiel,39"] = "Anniversary of victory in the New South Jangsong Campaign [Nexa]",
        ["Thalassiel,44"] = "Erev Galgal (Eve of Cycles) [Nexa]",
        ["Thalassiel,45"] = "Bassaridia Festival [Somniumpolis]",
        ["Thalassiel,48"] = "Anniversary of victory in the Southern Lake Morovia Campaign [Somniumpolis]",
        ["Thalassiel,54"] = "Leilat al-Kamar (Night of the Moon) [Lunalis Sancta]",
        ["Thalassiel,61"] = "Taşrakah (Reverence of the Stone) [Luminaria]",
        ["Opsitheiel,6"] = "Chag Tvuah (Festival of Harvest) [Sylvapolis]",
        ["Opsitheiel,18"] = "Anagenesis Eirmos (Procession of Rebirth) [Acheron]",
        ["Opsitheiel,28"] = "Panagia Therizis (Holy Day of the Reaper) [Sylvapolis]",
        ["Opsitheiel,37"] = "Anniversary of victory in the Morovian Frontier Campaign [Acheron]",
        ["Opsitheiel,43"] = "Karnavali Thysias (Carnival of Celebration) [Erythros]",
        ["Opsitheiel,53"] = "Sefar Yashar (Straight Path Celebration) [Catonis Atrium]"
    }

    -- Check for today's event
    local eventKey = month .. "," .. dayInMonth
    local event = events[eventKey] or "No significant events today."
    local dailyProverb = zodiacProverbs[zodiac]

    -- Return the date, event, and proverb
    return dayOfYear .. ", " .. month .. " (" .. zodiac .. "), " .. psscYear .. " PSSC – " .. event .. " – Proverb: " .. dailyProverb
end

return p