| 28 | } |
| 29 | |
| 30 | void CodexItem::fireTriggered() { |
| 31 | if (auto player = as<Player>(owner())) { |
| 32 | auto codexLearned = player->codexes()->learnCodex(m_codexId); |
| 33 | if (codexLearned) { |
| 34 | player->queueUIMessage(Root::singleton().assets()->json("/codex.config:messages.learned").toString()); |
| 35 | } else { |
| 36 | player->codexes()->markCodexUnread(m_codexId); |
| 37 | player->queueUIMessage(Root::singleton().assets()->json("/codex.config:messages.alreadyKnown").toString()); |
| 38 | } |
| 39 | } |
| 40 | } |
| 41 | |
| 42 | List<Drawable> CodexItem::iconDrawables() const { |
| 43 | return m_iconDrawables; |
nothing calls this directly
no test coverage detected