Skip to content

Commit

Permalink
Revert "fix not accepted"
Browse files Browse the repository at this point in the history
This reverts commit ad00133.
  • Loading branch information
hannibal002 committed Dec 4, 2024
1 parent c8266c3 commit 1bec238
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -231,6 +231,7 @@ class DailyQuestHelper(val reputationHelper: CrimsonIsleReputationHelper) {

private fun Quest.needsTownBoardLocation(): Boolean = state.let { state ->
state == QuestState.READY_TO_COLLECT ||
state == QuestState.NOT_ACCEPTED ||
(this is RescueMissionQuest && state == QuestState.ACCEPTED)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ class QuestLoader(private val dailyQuestHelper: DailyQuestHelper) {
return
}

val state = if (green) QuestState.READY_TO_COLLECT else QuestState.ACCEPTED
val state = if (green) QuestState.READY_TO_COLLECT else QuestState.NOT_ACCEPTED
dailyQuestHelper.update()
addQuest(addQuest(name, state, needAmount))
}
Expand Down Expand Up @@ -152,6 +152,11 @@ class QuestLoader(private val dailyQuestHelper: DailyQuestHelper) {
dailyQuestHelper.update()
}

val accepted = !stack.getLore().any { dailyQuestHelper.clickToStartPattern.matches(it) }
if (accepted && quest.state == QuestState.NOT_ACCEPTED) {
quest.state = QuestState.ACCEPTED
dailyQuestHelper.update()
}
if (name == "Miniboss") {
fixMinibossAmount(quest, stack)
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
package at.hannibal2.skyhanni.features.nether.reputationhelper.dailyquest.quest

enum class QuestState(val displayName: String, val color: String) {
ACCEPTED("Active", "§b"),
NOT_ACCEPTED("Not Accepted", "§c"),
ACCEPTED("Accepted", "§b"),
READY_TO_COLLECT("Ready to collect", "§a"),
COLLECTED("Collected", "§7"),
}
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ package at.hannibal2.skyhanni.features.nether.reputationhelper.dailyquest.quest
import at.hannibal2.skyhanni.utils.NEUInternalName

class UnknownQuest(unknownName: String) :
Quest(NEUInternalName.MISSING_ITEM, null, QuestCategory.UNKNOWN, unknownName, QuestState.ACCEPTED)
Quest(NEUInternalName.MISSING_ITEM, null, QuestCategory.UNKNOWN, unknownName, QuestState.NOT_ACCEPTED)

0 comments on commit 1bec238

Please sign in to comment.