Template:AstrologistEventDef: Difference between revisions
From Heroes of Might and Magic: Olden Era Official Wiki
obelisk-bot: uploading initial Cargo templates |
obelisk-bot: uploading initial Cargo templates |
||
| Line 7: | Line 7: | ||
<code>Data:AstrologistEvent/<id></code> carries: | <code>Data:AstrologistEvent/<id></code> carries: | ||
# <code>{{AstrologistEventDef | id=… | category=week|month | name=… | desc=… | …}}</code> | # <code><nowiki>{{AstrologistEventDef | id=… | category=week|month | name=… | desc=… | …}}</nowiki></code> | ||
# <code>{{TranslationDef | type=astrologist_event | target_id=<id> | …}}</code> — name+desc in the 16 supported languages | # <code><nowiki>{{TranslationDef | type=astrologist_event | target_id=<id> | …}}</nowiki></code> — name+desc in the 16 supported languages | ||
== Schema == | == Schema == | ||
| Line 16: | Line 16: | ||
| name = String | | name = String | ||
| name_sid = String | | name_sid = String | ||
| | | description = Wikitext | ||
| desc_sid = String | | desc_sid = String | ||
| icon = String | | icon = String | ||
| Line 31: | Line 31: | ||
| name = String <!-- resolved English --> | | name = String <!-- resolved English --> | ||
| name_sid = String | | name_sid = String | ||
| | | description = Wikitext <!-- resolved English --> | ||
| desc_sid = String <!-- nullable --> | | desc_sid = String <!-- nullable --> | ||
| icon = String <!-- nullable --> | | icon = String <!-- nullable --> | ||
| Line 57: | Line 57: | ||
| name = {{{name|}}} | | name = {{{name|}}} | ||
| name_sid = {{{name_sid|}}} | | name_sid = {{{name_sid|}}} | ||
| | | description = {{{description|}}} | ||
| desc_sid = {{{desc_sid|}}} | | desc_sid = {{{desc_sid|}}} | ||
| icon = {{{icon|}}} | | icon = {{{icon|}}} | ||
Revision as of 00:02, 13 May 2026
One row per astrologist event — the periodically-rolled global modifiers the in-game Astrologer announces between weeks and months. 26 entries total in 2026-05-05: 15 weeks (e.g. "Week of Sorcery", "Week of Luck") + 11 months ("Month of the Locust", and so on).
A single discriminator column category separates weeks from months — the source ships them in two parallel files (DB/weeks/weeks.json + DB/weeks/months.json) but the schema is identical, so we collapse to one table.
Page layout
Data:AstrologistEvent/<id> carries:
{{AstrologistEventDef | id=… | category=week|month | name=… | desc=… | …}}{{TranslationDef | type=astrologist_event | target_id=<id> | …}}— name+desc in the 16 supported languages
Schema
This template defines the table "AstrologistEvent". View table.
{{AstrologistEventDef
| id = String
| category = String <!-- week | month -->
| name = String <!-- resolved English -->
| name_sid = String
| description = Wikitext <!-- resolved English -->
| desc_sid = String <!-- nullable -->
| icon = String <!-- nullable -->
| buff_sid = String <!-- nullable; pointer into DB/buffs/ for the actual mechanical effect -->
| roll_chance = Integer <!-- nullable; weight in the random-pick table -->
| count_to_return = Integer <!-- global re-roll threshold (countToReturnWeek / countToReturnMonth) -->
| source_path = String
}}
Field notes
idis the source JSON id (e.g.astrologist_week_1,astrologist_month_3).categoryis the primary filter discriminator:WHERE category='week'to find every week event.buff_sidpoints at an entry inDB/buffs/carrying the actual mechanical payload (the bonuses the buff applies while the event is active). Not flattened into this table — the player-facing description on the event already covers gameplay impact.roll_chanceis the relative weight in the engine's random-pick table when an astrology phase rolls. Per-event scalar; values across the 15-week table sum to roughly the same magnitude as the 11-month table since each is independently rolled.count_to_returnis the global re-roll cooldown — the same event can't repeat within this many ticks. Stored per row (rather than as a global config) so queries don't need a join. Currently 3 for weeks and (a different value, seeweeks_info.json) for months.
Related tables
TranslationDef— one row per event withtype=astrologist_event,target_id=id.


