Commit 3a56e53e authored by fallenstardust's avatar fallenstardust

加载卡组时置换先行密码为正式密码

parent 33ec5d6a
......@@ -100,7 +100,7 @@ dependencies {
// implementation 'com.android.support:appcompat-v7:' + rootProject.ext.supportVersion
// implementation 'com.android.support:recyclerview-v7:' + rootProject.ext.supportVersion
// implementation 'com.android.support:design:' + rootProject.ext.supportVersion
implementation 'cn.hutool:hutool-all:latest.release'
implementation 'org.jdeferred:jdeferred-android-aar:1.2.4'
implementation 'com.github.bumptech.glide:glide:4.12.0'
implementation 'androidx.navigation:navigation-fragment:2.3.5'
......
package cn.garymb.ygomobile.loader;
import static cn.garymb.ygomobile.Constants.newIDsArray;
import static cn.garymb.ygomobile.Constants.oldIDsArray;
import android.text.TextUtils;
import android.util.Log;
import android.util.SparseArray;
......@@ -16,6 +19,7 @@ import cn.garymb.ygomobile.bean.Deck;
import cn.garymb.ygomobile.bean.DeckInfo;
import cn.garymb.ygomobile.ui.cards.deck.DeckItemType;
import cn.garymb.ygomobile.utils.IOUtils;
import cn.hutool.core.util.ArrayUtil;
import ocgcore.data.Card;
import ocgcore.data.LimitList;
......@@ -72,6 +76,10 @@ public class DeckLoader {
if (type == DeckItemType.MainCard && deck.getMainCount() < Constants.DECK_MAIN_MAX) {
Integer i = mIds.get(id);
if (i == null) {
if (ArrayUtil.contains(oldIDsArray, id)) {
id = ArrayUtil.get(newIDsArray,id);
Log.i("3.10.1","看看id="+id);
}
mIds.put(id, 1);
deck.addMain(id);
} else if (i < Constants.CARD_MAX_COUNT) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment