-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
v1.3 - Fix inventory full not drop. Add support grief prevention, cus…
…tom model data, configs yaml.
- Loading branch information
Showing
18 changed files
with
1,046 additions
and
738 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
src/main/kotlin/me/phantomx/fjetpackreloaded/annotations/Pure.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package me.phantomx.fjetpackreloaded.annotations | ||
|
||
/** | ||
* Don't modify value, like put 'field' or "field" | ||
*/ | ||
@Target(AnnotationTarget.FIELD, AnnotationTarget.PROPERTY) | ||
annotation class Pure |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,14 @@ | ||
package me.phantomx.fjetpackreloaded.data | ||
|
||
import kotlinx.serialization.Serializable | ||
import net.mamoe.yamlkt.Comment | ||
|
||
@Serializable | ||
data class Config( | ||
@Comment("The configs version") | ||
val version: Int = 1, | ||
val updateNotification: Boolean = true | ||
@Comment("Enable/Disable Update Notification") | ||
val updateNotification: Boolean = true, | ||
@Comment("Set all format configs to yaml") | ||
val configsYaml: Boolean = true | ||
) |
36 changes: 29 additions & 7 deletions
36
src/main/kotlin/me/phantomx/fjetpackreloaded/data/CustomFuel.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,33 @@ | ||
package me.phantomx.fjetpackreloaded.data | ||
|
||
import kotlinx.serialization.Serializable | ||
import kotlinx.serialization.Transient | ||
import me.phantomx.fjetpackreloaded.annotations.Pure | ||
import net.mamoe.yamlkt.Comment | ||
|
||
@Serializable | ||
data class CustomFuel( | ||
var id: String, | ||
var customDisplay: String, | ||
var displayName: String, | ||
var lore: List<String>, | ||
var item: String, | ||
var permission: String, | ||
var glowing: Boolean | ||
@Pure | ||
@Transient | ||
var id: String = "CVIP", | ||
@Comment(""" | ||
Custom display name the fuel in jetpack placdeholder {#fuel} | ||
Leave empty, will using DisplayName | ||
""") | ||
var customDisplay: String = "&6&lPertamax", | ||
@Comment("Display Name item") | ||
var displayName: String = "&b&lC&6&lVIP", | ||
@Comment("The lore of item") | ||
var lore: MutableList<String> = mutableListOf( | ||
"", | ||
"&eFuel for &l&6VIP!", | ||
"", | ||
"&6&lPremium &efuel" | ||
), | ||
@Comment("Item minecraft item id") | ||
var item: String = "GOLD_INGOT", | ||
@Comment("Permission to use this fuel") | ||
var permission: String = "fjetpackreloaded.fuel.#id", | ||
@Comment("Glow this item") | ||
var glowing: Boolean = true | ||
) |
Oops, something went wrong.