Your use of "states" is wrong and flawed. Your script is stuck at State.BANK_WALK thus State.BANK won't activate due to full inventory.
I have cleaned up your code just a tiny bit however I can already see you will encounter more issues but the following code should be better than what you have at the moment. I recommend you create a "TREE_AREA" variable which it changes based on your woodcutting level. You don't need State.WAIT, just make it return null.
private State getState() {
if (myPlayer().isUnderAttack()) {
return State.UNDER_ATTACK;
} else if (inventory.isFull()) {
if (BANK_AREA.contains(myPlayer())) {
return State.BANK;
} else {
return State.BANK_WALK;
}
} else if (!myPlayer().isAnimating()) {
if (wcLvl2 >= 30) {
return State.CHOPW;
} else if (wcLvl2 >= 15) {
return State.CHOPO;
} else {
return State.CHOP;
}
}
return null;
}