Skip to content
This repository has been archived by the owner on Feb 16, 2023. It is now read-only.

Commit

Permalink
1.0.8
Browse files Browse the repository at this point in the history
  • Loading branch information
My-Name-Is-Jeff committed Aug 15, 2021
1 parent bf5d3c4 commit 18e1640
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ plugins {

ext.kotlin_version = "1.5.21"

version = "1.0.7"
version = "1.0.8"
group = "mynameisjeff"
archivesBaseName = "SkyblockClient-Updater"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ import net.minecraftforge.fml.common.gameevent.TickEvent
@Mod(modid = "skyblockclientupdater", name = "SkyClient Updater", version = SkyClientUpdater.VERSION, clientSideOnly = true, modLanguage = "kotlin", modLanguageAdapter = "mynameisjeff.skyblockclientupdater.utils.kotlin.KotlinAdapter")
object SkyClientUpdater {

const val VERSION = "1.0.7"
const val VERSION = "1.0.8"

@JvmField
val mc = Minecraft.getMinecraft()
val mc: Minecraft
get() = Minecraft.getMinecraft()

var displayScreen: GuiScreen? = null

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ object UpdateChecker {
loopMods@ for (modFile in needsChecking) {
val fileName = modFile.name
for (modEntry in allowedRemoteChecks) {
if (!checkMatch(modEntry, fileName))
if (!checkMatch(modEntry, fileName)) continue
needsUpdate.add(Triple(modFile, modEntry, latestMods[modEntry]!!))
continue@loopMods
}
Expand All @@ -159,8 +159,8 @@ object UpdateChecker {
val distance = StringUtils.getLevenshteinDistance(expected, received)
if (distance !in 1..6) return false

val ec = e.filterIndexed { index, c -> c != r[index] }
val rc = r.filterIndexed { index, c -> c != e[index] }
val ec = e.filterIndexed { index, c -> c != r.getOrNull(index) }
val rc = r.filterIndexed { index, c -> c != e.getOrNull(index) }

if (listOf(ec, rc).flatten().none { !it.isDigit() && !whitespace.contains(it) }) {
return (ec.firstOrNull { it.isDigit() }?.digitToInt() ?: 0) > (rc.firstOrNull { it.isDigit() }?.digitToInt() ?: 0)
Expand Down

0 comments on commit 18e1640

Please sign in to comment.