I fixed this with a kludge (that seems to work fine), in my Tiger Potion item.AndakRainor wrote:Potential bug with the spellbook:
PartyComponent.onClickItemSlot(self, champion, container, slot, button) => champion is nil if you click on the attack panel's hands
This could cause a crash, but the way the function is written I don't see a scenario for this. That said, I will add a fix the next time I get the project files just in case.
The way I did it was to maintain a currentPC variable (and setter function) in a script that you can check, and can call from a hook with context. Use that currentPC [ordinal] as the default champion in cases where champion is nil. Generally (if not always) it will update faster than the player can move the mouse.