Skip to content

Commit 8024c91

Browse files
authored
Show NP color based on position (#1762)
Co-authored-by: arthur <16458204+ArthurKun021@users.noreply.github.com>
1 parent 876c0af commit 8024c91

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

app/src/main/java/io/github/fate_grand_automata/ui/skill_maker/SkillMakerAtk.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,10 @@ private fun SelectNps(
5656

5757
val canSelect = numberOfCardsSelected + numberOfNPs + 1 <= 3
5858

59-
val selectedColor = when (servantNumber) {
60-
1 -> R.color.colorServant1
61-
2 -> R.color.colorServant2
62-
3 -> R.color.colorServant3
59+
val selectedColor = when (npSequence.indexOf("$servantNumber")) {
60+
0 -> R.color.colorServant1
61+
1 -> R.color.colorServant2
62+
2 -> R.color.colorServant3
6363
else -> R.color.colorAccent
6464
}
6565

0 commit comments

Comments
 (0)