From 948985b0578a39b32e5db8529cfa0b1e91dde834 Mon Sep 17 00:00:00 2001 From: Martin Michelsen Date: Sun, 8 Oct 2023 12:35:34 -0700 Subject: [PATCH] describe card effect name_index field --- src/Episode3/DataIndexes.cc | 4 ++-- src/Episode3/DataIndexes.hh | 5 ++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/Episode3/DataIndexes.cc b/src/Episode3/DataIndexes.cc index a9177b98..d9014aef 100644 --- a/src/Episode3/DataIndexes.cc +++ b/src/Episode3/DataIndexes.cc @@ -671,7 +671,7 @@ bool CardDefinition::Effect::is_empty() const { this->arg2.is_filled_with(0) && this->arg3.is_filled_with(0) && this->apply_criterion == CriterionCode::NONE && - this->unknown_a2 == 0); + this->name_index == 0); } string CardDefinition::Effect::str_for_arg(const string& arg) { @@ -761,7 +761,7 @@ string CardDefinition::Effect::str(const char* separator) const { } tokens.emplace_back(std::move(cond_str)); } - tokens.emplace_back(string_printf("a2=%02hhX", this->unknown_a2)); + tokens.emplace_back(string_printf("name_index=%02hhX", this->name_index)); return join(tokens, separator); } diff --git a/src/Episode3/DataIndexes.hh b/src/Episode3/DataIndexes.hh index e301b504..ab642acf 100644 --- a/src/Episode3/DataIndexes.hh +++ b/src/Episode3/DataIndexes.hh @@ -488,7 +488,10 @@ struct CardDefinition { /* 16 */ ptext arg2; /* 1A */ ptext arg3; /* 1E */ CriterionCode apply_criterion; - /* 1F */ uint8_t unknown_a2; + // name_index specifies which string from TextEnglish.pr2 is shown next to + // the card when it is attacking or defending. Zero in this field means no + // string is shown for this ability. + /* 1F */ uint8_t name_index; /* 20 */ bool is_empty() const;