You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
int varcIntValue = methods.client.getVarcIntValue(VarcIntIndices.CURRENT_INTERFACE_TAB);
return switch (VarcIntValues.valueOf(varcIntValue)) {
case TAB_COMBAT_OPTIONS -> InterfaceTab.COMBAT;
case TAB_SKILLS -> InterfaceTab.SKILLS;
case TAB_QUEST_LIST -> InterfaceTab.QUESTS;
case TAB_INVENTORY -> InterfaceTab.INVENTORY;
case TAB_WORN_EQUIPMENT -> InterfaceTab.EQUIPMENT;
case TAB_PRAYER -> InterfaceTab.PRAYER;
case TAB_SPELLBOOK -> InterfaceTab.MAGIC;
case TAB_FRIEND_LIST -> InterfaceTab.FRIENDS;
case TAB_LOGOUT -> InterfaceTab.LOGOUT;
case TAB_SETTINGS -> InterfaceTab.SETTINGS;
case TAB_MUSIC -> InterfaceTab.MUSIC;
case TAB_CHAT_CHANNEL -> InterfaceTab.CHAT;
case TAB_ACC_MANAGEMENT -> InterfaceTab.ACC_MAN;
case TAB_EMOTES -> InterfaceTab.EMOTES;
default -> throw new IllegalStateException("Unexpected value: " + VarcIntValues.valueOf(varcIntValue));
};
This code will fail if you were to check say 0 as zero could refer to a number of enumerations and as this switch case is a check on the enumeration and not the actual value it isn't valid. This is likely an issue in a number of classes Bia revised.
The text was updated successfully, but these errors were encountered:
This code will fail if you were to check say 0 as zero could refer to a number of enumerations and as this switch case is a check on the enumeration and not the actual value it isn't valid. This is likely an issue in a number of classes Bia revised.
The text was updated successfully, but these errors were encountered: