kiooeht / ModTheSpire

External mod loader for Slay The Spire
MIT License
413 stars 87 forks source link

Source error #12

Closed Rwolder closed 6 years ago

Rwolder commented 6 years ago

When I try to load ModTheSpire it never gets past the first console. This is the log: (Finding core patches... Finding patches... Injecting patches... javassist.CannotCompileException: [source error] no such field: tmpPool at javassist.CtBehavior.insertAt(CtBehavior.java:1213) at javassist.CtBehavior.insertAt(CtBehavior.java:1140) at com.evacipated.cardcrawl.modthespire.patcher.InsertPatchInfo.doPatch(InsertPatchInfo.java:105) at com.evacipated.cardcrawl.modthespire.Patcher.finalizePatches(Patcher.java:124) at com.evacipated.cardcrawl.modthespire.Loader.runMods(Loader.java:90) at com.evacipated.cardcrawl.modthespire.ModSelectWindow.lambda$null$1(ModSelectWindow.java:71) at java.lang.Thread.run(Unknown Source) Caused by: compile error: no such field: tmpPool at javassist.compiler.TypeChecker.fieldAccess(TypeChecker.java:845) at javassist.compiler.TypeChecker.atFieldRead(TypeChecker.java:803) at javassist.compiler.TypeChecker.atMember(TypeChecker.java:988) at javassist.compiler.JvstTypeChecker.atMember(JvstTypeChecker.java:66) at javassist.compiler.ast.Member.accept(Member.java:39) at javassist.compiler.JvstTypeChecker.atMethodArgs(JvstTypeChecker.java:221) at javassist.compiler.TypeChecker.atMethodCallCore(TypeChecker.java:735) at javassist.compiler.TypeChecker.atCallExpr(TypeChecker.java:695) at javassist.compiler.JvstTypeChecker.atCallExpr(JvstTypeChecker.java:157) at javassist.compiler.ast.CallExpr.accept(CallExpr.java:46) at javassist.compiler.CodeGen.doTypeCheck(CodeGen.java:242) at javassist.compiler.CodeGen.atStmnt(CodeGen.java:330) at javassist.compiler.ast.Stmnt.accept(Stmnt.java:50) at javassist.compiler.CodeGen.atStmnt(CodeGen.java:351) at javassist.compiler.ast.Stmnt.accept(Stmnt.java:50) at javassist.compiler.Javac.compileStmnt(Javac.java:567) at javassist.CtBehavior.insertAt(CtBehavior.java:1192) ... 6 more)

Any idea what is causing this? Would love to hear a fix.

kiooeht commented 6 years ago

What version of ModTheSpire? What mod(s) are you trying to load? Run ModTheSpire in debug mode and post that log, it provides me more information of which patch is causing the error.

Rwolder commented 6 years ago

I'm trying to load BaseMod using the latest version of ModTheSpire (2.3.0) and the latest version of BaseMod.

Debug mode! Finding core patches... Finding patches... Injecting patches... Patch [com.evacipated.cardcrawl.modthespire.patches.CreditsModList] Patching [com.megacrit.cardcrawl.credits.CreditsScreen()] Adding Insert @ r5 (abs:55)... { float[] tmpY = new float[]{tmpY}; com.evacipated.cardcrawl.modthespire.patches.CreditsModList.Insert($0, $$, tmpY); tmpY = tmpY[0]; } Patch [com.evacipated.cardcrawl.modthespire.patches.DisableGdxForceExit] Patching [com.badlogic.gdx.backends.lwjgl.LwjglApplication.mainLoop()] Adding Insert @ 248... { com.evacipated.cardcrawl.modthespire.patches.DisableGdxForceExit.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.helpers.CardLibrary.CustomCardsPatch] Patching [com.megacrit.cardcrawl.helpers.CardLibrary.initialize()] Adding Insert @ 233... { basemod.patches.com.megacrit.cardcrawl.helpers.CardLibrary.CustomCardsPatch.Insert($$); } Patch [basemod.patches.com.megacrit.cardcrawl.characters.AbstractPlayer.PostInitializeStarterDeckHookSwitch] Patching [com.megacrit.cardcrawl.characters.AbstractPlayer.initializeStarterDeck()] Adding Insert @ 246... { java.util.ArrayList[] cards = new java.util.ArrayList[]{cards}; basemod.patches.com.megacrit.cardcrawl.characters.AbstractPlayer.PostInitializeStarterDeckHookSwitch.Insert($0, $$, cards); cards = cards[0]; } Patch [basemod.patches.com.megacrit.cardcrawl.helpers.CardLibrary.GetCardListSwitch] Patching [com.megacrit.cardcrawl.helpers.CardLibrary.getCardList(com.megacrit.cardcrawl.helpers.CardLibrary$LibraryType)] Adding Insert @ 693... { basemod.patches.com.megacrit.cardcrawl.helpers.CardLibrary.GetCardListSwitch.Insert($$, retVal); } Patch [basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.CreateCharacterSwitch] Patching [com.megacrit.cardcrawl.core.CardCrawlGame.createCharacter(com.megacrit.cardcrawl.characters.AbstractPlayer$PlayerClass)] Adding Insert @ 980... { java.lang.Object[] p = new java.lang.Object[]{p}; basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.CreateCharacterSwitch.Insert($$, p); p = (com.megacrit.cardcrawl.characters.AbstractPlayer)p[0]; } Patch [basemod.patches.com.megacrit.cardcrawl.core.EnergyManager.PostEnergyRechargeHook] Patching [com.megacrit.cardcrawl.core.EnergyManager.recharge()] Adding Insert @ 39... { basemod.patches.com.megacrit.cardcrawl.core.EnergyManager.PostEnergyRechargeHook.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.RenderHook] Patching [com.megacrit.cardcrawl.core.CardCrawlGame.render()] Adding Insert @ 395... { basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.RenderHook.Insert($0, $$, sb); } Patch [basemod.patches.com.megacrit.cardcrawl.screens.charSelect.CharacterSelectScreen.InitializeSwitch] Patching [com.megacrit.cardcrawl.screens.charSelect.CharacterSelectScreen.initialize()] Adding Insert @ 66... { basemod.patches.com.megacrit.cardcrawl.screens.charSelect.CharacterSelectScreen.InitializeSwitch.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.cards.AbstractCard.RenderEnergySwitch] Patching [com.megacrit.cardcrawl.cards.AbstractCard.renderEnergy(com.badlogic.gdx.graphics.g2d.SpriteBatch)] Adding Insert @ 2545... { basemod.patches.com.megacrit.cardcrawl.cards.AbstractCard.RenderEnergySwitch.Insert($0, $$, drawX, drawY); } Patch [basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.StartGameHook] Patching [com.megacrit.cardcrawl.core.CardCrawlGame.startNewGame(com.megacrit.cardcrawl.characters.AbstractPlayer$PlayerClass)] Adding Insert @ 610... { basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.StartGameHook.Insert($$); } Patch [basemod.patches.com.megacrit.cardcrawl.screens.charSelect.CharacterOption.CtorSwitch] Patching [com.megacrit.cardcrawl.screens.charSelect.CharacterOption(java.lang.String,com.megacrit.cardcrawl.characters.AbstractPlayer$PlayerClass,java.lang.String,java.lang.String)] Adding Insert @ 87... { basemod.patches.com.megacrit.cardcrawl.screens.charSelect.CharacterOption.CtorSwitch.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.characters.AbstractPlayer.PostInitializeStarterRelicsHookSwitch] Patching [com.megacrit.cardcrawl.characters.AbstractPlayer.initializeStarterRelics(com.megacrit.cardcrawl.characters.AbstractPlayer$PlayerClass)] Adding Insert @ 271... { java.util.ArrayList[] relics = new java.util.ArrayList[]{relics}; basemod.patches.com.megacrit.cardcrawl.characters.AbstractPlayer.PostInitializeStarterRelicsHookSwitch.Insert($0, $$, relics); relics = relics[0]; } Patch [basemod.patches.com.megacrit.cardcrawl.cards.AbstractCard.RenderOuterGlowSwitch] Patching [com.megacrit.cardcrawl.cards.AbstractCard.renderOuterGlow(com.badlogic.gdx.graphics.g2d.SpriteBatch)] Adding Insert @ 1237... { basemod.patches.com.megacrit.cardcrawl.cards.AbstractCard.RenderOuterGlowSwitch.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.PreUpdateHook] Patching [com.megacrit.cardcrawl.core.CardCrawlGame.update()] Adding Insert @ 649... { basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.PreUpdateHook.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.characters.AbstractPlayer.PostDrawHook] Patching [com.megacrit.cardcrawl.characters.AbstractPlayer.draw(int)] Adding Insert @ 1036... { basemod.patches.com.megacrit.cardcrawl.characters.AbstractPlayer.PostDrawHook.Insert($0, $$, c); } Patch [basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.PreStartGameHook] Patching [com.megacrit.cardcrawl.core.CardCrawlGame.update()] Adding Insert @ 697... { basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.PreStartGameHook.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.PostUpdateHook] Patching [com.megacrit.cardcrawl.core.CardCrawlGame.update()] Adding Insert @ 792... { basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.PostUpdateHook.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.PostRenderHook] Patching [com.megacrit.cardcrawl.core.CardCrawlGame.render()] Adding Insert @ 443... { basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.PostRenderHook.Insert($0, $$, sb); } Patch [basemod.patches.com.megacrit.cardcrawl.cards.AbstractCard.CreateCardImageSwitch] Patching [com.megacrit.cardcrawl.cards.AbstractCard.createCardImage()] Adding Insert @ 844... { basemod.patches.com.megacrit.cardcrawl.cards.AbstractCard.CreateCardImageSwitch.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.StartActHook] Patching [com.megacrit.cardcrawl.core.CardCrawlGame.update()] Adding Insert @ 778... { basemod.patches.com.megacrit.cardcrawl.core.CardCrawlGame.StartActHook.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.rooms.CampfireUI.InitializeButtonsSwitch] Patching [com.megacrit.cardcrawl.rooms.CampfireUI.initializeButtons()] Adding Insert @ 71... { basemod.patches.com.megacrit.cardcrawl.rooms.CampfireUI.InitializeButtonsSwitch.Insert($0, $$); } Patch [basemod.patches.com.megacrit.cardcrawl.dungeons.AbstractDungeon.InitializeCardPoolsSwitch] Patching [com.megacrit.cardcrawl.dungeons.AbstractDungeon.initializeCardPools()] Adding Insert @ 1393... { basemod.patches.com.megacrit.cardcrawl.dungeons.AbstractDungeon.InitializeCardPoolsSwitch.Insert($0, $$, tmpPool); } javassist.CannotCompileException: [source error] no such field: tmpPool at javassist.CtBehavior.insertAt(CtBehavior.java:1213) at javassist.CtBehavior.insertAt(CtBehavior.java:1140) at com.evacipated.cardcrawl.modthespire.patcher.InsertPatchInfo.doPatch(InsertPatchInfo.java:105) at com.evacipated.cardcrawl.modthespire.Patcher.finalizePatches(Patcher.java:124) at com.evacipated.cardcrawl.modthespire.Loader.runMods(Loader.java:90) at com.evacipated.cardcrawl.modthespire.ModSelectWindow.lambda$null$1(ModSelectWindow.java:71) at java.lang.Thread.run(Unknown Source) Caused by: compile error: no such field: tmpPool at javassist.compiler.TypeChecker.fieldAccess(TypeChecker.java:845) at javassist.compiler.TypeChecker.atFieldRead(TypeChecker.java:803) at javassist.compiler.TypeChecker.atMember(TypeChecker.java:988) at javassist.compiler.JvstTypeChecker.atMember(JvstTypeChecker.java:66) at javassist.compiler.ast.Member.accept(Member.java:39) at javassist.compiler.JvstTypeChecker.atMethodArgs(JvstTypeChecker.java:221) at javassist.compiler.TypeChecker.atMethodCallCore(TypeChecker.java:735) at javassist.compiler.TypeChecker.atCallExpr(TypeChecker.java:695) at javassist.compiler.JvstTypeChecker.atCallExpr(JvstTypeChecker.java:157) at javassist.compiler.ast.CallExpr.accept(CallExpr.java:46) at javassist.compiler.CodeGen.doTypeCheck(CodeGen.java:242) at javassist.compiler.CodeGen.atStmnt(CodeGen.java:330) at javassist.compiler.ast.Stmnt.accept(Stmnt.java:50) at javassist.compiler.CodeGen.atStmnt(CodeGen.java:351) at javassist.compiler.ast.Stmnt.accept(Stmnt.java:50) at javassist.compiler.Javac.compileStmnt(Javac.java:567) at javassist.CtBehavior.insertAt(CtBehavior.java:1192) ... 6 more

kiooeht commented 6 years ago

Are you using https://github.com/t-larson/BaseMod or https://github.com/daviscook477/BaseMod? If you're using t-larson's, it is out of date and you should switch to the other.

Rwolder commented 6 years ago

You are right, I didn't have the correct version. Thank you!