mikebaldi / Idle-Champions

Scripts for the game Idle Champions
MIT License
122 stars 199 forks source link

Gap between Krux and Certainty - Issues with GetHeroHandlerIndexByChampID() #108

Closed Emmotes closed 1 year ago

Emmotes commented 1 year ago

Heya

Commodore Krux is champ id 136. Certainty Dran is id 138. And champion id 137 doesn't exist. This is causing GetHeroHandlerIndexByChampID(...) in IC_MemoryFunctions_Class.ahk to give Certainty Dran the id 137 which is causing issues with her.

I made this edit on mine and it seems to work - but I'm not 100% sure on what I'm doing so you may want to check my working:

GetHeroHandlerIndexByChampID(champID)
{
    if(champID < 107)
        return champID - 1
    if(champID == 107)
        return ""
    if(champID < 135)
        return champID - 2
    if(champID == 135)
        return ""
    if(champID == 136)
        return champID - 3
    if(champID == 137)
        return ""
    return champID - 4
}
antilectual commented 1 year ago

Thanks for the heads up. Should be fixed now.