Use enums instead of union types #364

Merged
LunarTides merged 6 commits from enums into main 2025-02-17 08:49:36 +00:00
LunarTides commented 2024-07-10 18:08:06 +00:00 (Migrated from github.com)

Closes #378

I like to put what I'm working on out there instead of keeping it on my computer, especially since I'm working on different computers often.

The cards have not been touched yet, and there are still 49 errors outside the cards, and some logic might have broken.

  • Find more union types and destroy them:
    • interact.prompt.useLocation
    • Player.addQuest
  • Make EventListenerMessage enum the return value of the quest callback.
  • Make the card creators work:
    • Lib:
      • Minion
      • Spell
      • Weapon
      • Location
      • Hero
      • Heropower
    • Custom:
      • Minion
      • Spell
      • Weapon
      • Location
      • Hero
      • Heropower
    • Vanilla:
      • Minion
      • Spell
      • Weapon
      • Location
      • Hero
      • Heropower
    • Class
  • Make sure the deck creator works.
  • Make sure the scripts work.
  • Make sure the game works.
Closes #378 I like to put what I'm working on out there instead of keeping it on my computer, especially since I'm working on different computers often. ~~The cards have not been touched yet, and there are still 49 errors outside the cards, and some logic might have broken.~~ - [x] Find more union types and destroy them: - [x] `interact.prompt.useLocation` - [x] `Player.addQuest` - [x] Make `EventListenerMessage` enum the return value of the quest callback. - [x] Make the card creators work: - [x] Lib: - [x] Minion - [x] Spell - [x] Weapon - [x] Location - [x] Hero - [x] Heropower - [x] Custom: - [x] Minion - [x] Spell - [x] Weapon - [x] Location - [x] Hero - [x] Heropower - [x] Vanilla: - [x] Minion - [x] Spell - [x] Weapon - [x] Location - [x] Hero - [x] Heropower - [x] Class - [x] Make sure the deck creator works. - [x] Make sure the scripts work. - [x] Make sure the game works.
LunarTides commented 2025-02-13 11:44:42 +00:00 (Migrated from github.com)

Completely rewrote this PR.

Completely rewrote this PR.
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
LunarTides/Hearthstone.js!364
No description provided.