diff --git a/core/src/commonMain/kotlin/cn/rdlevel/rdkt/core/RDLevel.kt b/core/src/commonMain/kotlin/cn/rdlevel/rdkt/core/RDLevel.kt index d48bade..52660de 100644 --- a/core/src/commonMain/kotlin/cn/rdlevel/rdkt/core/RDLevel.kt +++ b/core/src/commonMain/kotlin/cn/rdlevel/rdkt/core/RDLevel.kt @@ -1,7 +1,11 @@ +@file:JvmName("RDLevels") + package cn.rdlevel.rdkt.core +import cn.rdlevel.rdkt.core.annotations.RDKTExperimentalAPI import cn.rdlevel.rdkt.core.settings.LevelSettings import kotlinx.serialization.Serializable +import kotlin.jvm.JvmName /** * A Rhythm Doctor custom level representation. @@ -10,5 +14,11 @@ import kotlinx.serialization.Serializable public data class RDLevel( public val settings: LevelSettings, ) { +} -} \ No newline at end of file +/** + * Allows using levels with versions other than [LevelSettings.CURRENT_LEVEL_VERSION]. + * It is not recommended to use this unless you know what you are doing, as it may cause unexpected behavior and this library may not be compatible with levels with other versions. + */ +@RDKTExperimentalAPI +public var allowOldLevels: Boolean = false \ No newline at end of file diff --git a/core/src/commonMain/kotlin/cn/rdlevel/rdkt/core/settings/LevelSettings.kt b/core/src/commonMain/kotlin/cn/rdlevel/rdkt/core/settings/LevelSettings.kt index cf6b12b..476c796 100644 --- a/core/src/commonMain/kotlin/cn/rdlevel/rdkt/core/settings/LevelSettings.kt +++ b/core/src/commonMain/kotlin/cn/rdlevel/rdkt/core/settings/LevelSettings.kt @@ -2,11 +2,11 @@ package cn.rdlevel.rdkt.core.settings +import cn.rdlevel.rdkt.core.allowOldLevels import cn.rdlevel.rdkt.core.annotations.RDKTExperimentalAPI import cn.rdlevel.rdkt.core.annotations.RDKTInternalAPI import cn.rdlevel.rdkt.core.serialization.MutableStringListSerializedInString import cn.rdlevel.rdkt.core.settings.LevelSettings.Companion.CURRENT_LEVEL_VERSION -import cn.rdlevel.rdkt.core.settings.LevelSettings.Companion.allowOldLevels import kotlinx.serialization.Serializable import kotlin.jvm.JvmName import kotlin.random.Random @@ -207,13 +207,6 @@ public class LevelSettings { * The current level version the level editor is using. */ public const val CURRENT_LEVEL_VERSION: Int = 67 - - /** - * Allows using levels with versions other than [CURRENT_LEVEL_VERSION]. - * It is not recommended to use this unless you know what you are doing, as it may cause unexpected behavior and this library may not be compatible with levels with other versions. - */ - @RDKTExperimentalAPI - public var allowOldLevels: Boolean = false } }