Skip to content

Commit

Permalink
Merge branch 'main' into update
Browse files Browse the repository at this point in the history
  • Loading branch information
SrBedrock committed Feb 27, 2024
2 parents 854bcd1 + c403823 commit ddfe02a
Show file tree
Hide file tree
Showing 51 changed files with 865 additions and 510 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
### Crate Types:
* Added a new crate type called `Casino` ( Idea by slimemcstew )
* This allows a player to win 3 prizes with 3 animations while opening a crate.
### Ability to have files categorized by folder.
* It will search for folders in `crates` such as `crates/sub_folder`
* It will not search for folders inside `crates/sub_folder` such as `crates/sub_folder/secondary_folder`
### Other:
* Added War Crate as a default generated crate.
* Added the ability to have holograms created using CMI or DecentHolograms have a configurable "block" range.
Expand Down Expand Up @@ -136,13 +139,16 @@ Crate:
* Update /cc additem again to take input for custom chance, Note: The max range by default is still 100 so keep it under 100. /cc additem <crate_name> <prize_number> <chance> [tier]
* [tier] is an optional arg.
* No longer create a snapshot of the holder when checking for inventoryholders
* Add a config option to switch to a faster implementation of picking numbers. It defaults to `false` which is the old way of doing random.
* All messages in chat, lore of preview items, gui names even filler items have `PlaceholderAPI` support.

## Fixes:
* Fixed issues with crates being broken in worlds created by world plugins.
* Fixed a few other bugs I can't remember.
* Fixed a bug where the refund event needed to be fired sync.
* Fixed a bug with display damage where if you put a value that can't be parsed as an integer like 50f, It wouldn't just be empty durability.
* Fixed a bug where cc additem wouldn't add tiers to casino/cosmic crate.
* Fixed a bug where we stored the wrong value for PDC causing it to error when using QuadCrates.

## Other:
* [Feature Requests](https://github.com/Crazy-Crew/CrazyCrates/issues)
Expand Down
6 changes: 3 additions & 3 deletions buildSrc/src/main/kotlin/fabric-plugin.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ base {
archivesName.set("${rootProject.name}-${project.name.uppercaseFirstChar()}")
}

val mcVersion = rootProject.properties["minecraftVersion"] as String
val fabricVersion = rootProject.properties["fabricVersion"] as String
val mcVersion = providers.gradleProperty("mcVersion")
val fabricVersion = providers.gradleProperty("version")

project.version = if (System.getenv("BUILD_NUMBER") != null) "$fabricVersion-${System.getenv("BUILD_NUMBER")}" else fabricVersion

tasks {
val isBeta: Boolean = rootProject.extra["isBeta"]?.toString()?.toBoolean() ?: false
val isBeta: Boolean = providers.gradleProperty("isBeta").get().toBoolean()
val type = if (isBeta) "Beta" else "Release"

modrinth {
Expand Down
4 changes: 2 additions & 2 deletions buildSrc/src/main/kotlin/paper-plugin.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ repositories {
flatDir { dirs("libs") }
}

val mcVersion = rootProject.properties["minecraftVersion"] as String
val mcVersion = providers.gradleProperty("mcVersion").get()

project.version = if (System.getenv("BUILD_NUMBER") != null) "${rootProject.version}-${System.getenv("BUILD_NUMBER")}" else rootProject.version

Expand All @@ -52,7 +52,7 @@ tasks {
}

val directory = File("$rootDir/jars")
val isBeta: Boolean = rootProject.extra["isBeta"]?.toString()?.toBoolean() ?: false
val isBeta: Boolean = providers.gradleProperty("isBeta").get().toBoolean()
val type = if (isBeta) "Beta" else "Release"

// Publish to hangar.papermc.io.
Expand Down
2 changes: 1 addition & 1 deletion buildSrc/src/main/kotlin/root-plugin.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ tasks {
}

val directory = File("$rootDir/jars")
val mcVersion = rootProject.properties["minecraftVersion"] as String
val mcVersion = providers.gradleProperty("mcVersion").get()

modrinth {
autoAddDependsOn.set(false)
Expand Down
2 changes: 1 addition & 1 deletion common/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plugins {
dependencies {
api(project(":api"))

api(libs.config.me) {
api(libs.configme) {
exclude(group = "org.yaml", module = "snakeyaml")
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ public void registerComments(CommentsConfiguration conf) {
@Comment("Whether you want CrazyCrates to shut up or not, This option is ignored by errors.")
public static final Property<Boolean> verbose_logging = newProperty("root.verbose_logging", true);

@Comment("This option will let you test a different way of picking random numbers. If you have any issues, You can set it back to false.")
public static final Property<Boolean> use_different_random = newProperty("root.use-different-random", false);

@Comment({
"Sends anonymous statistics about how the plugin is used to bstats.org.",
"bstats is a service for plugin developers to find out how the plugin being used,",
Expand Down
5 changes: 3 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
org.gradle.jvmargs = '-Xmx3G'
org.gradle.parallel = false
org.gradle.caching = true
org.gradle.parallel = true
org.gradle.warning.mode = all

authors = ["RyderBelserion, Badbones69"]
Expand All @@ -12,5 +13,5 @@ description = Add unlimited crates to your server with 10 different crate types
version = 1.21
apiVersion = 1.20

minecraftVersion = 1.20.4
mcVersion=1.20.4
isBeta = false
21 changes: 0 additions & 21 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
[versions]
kyori_version = "4.14.0"

cluster_version = "6.3"

shadow_version = "8.1.1"
paperweight_version = "1.5.9"
runpaper_version = "2.2.3"
Expand All @@ -22,25 +20,6 @@ shadowjar = { id = "com.github.johnrengelman.shadow", version.ref = "shadow_vers
adventure = { module = "net.kyori:adventure-api", version.ref = "kyori_version" }
minimessage = { module = "net.kyori:adventure-text-minimessage", version.ref = "kyori_version" }

cluster_paper = { module = "com.ryderbelserion.cluster:paper", version.ref = "cluster_version" }
cluster_api = { module = "com.ryderbelserion.cluster:api", version.ref = "cluster_version" }

nbtapi = { module = "de.tr7zw:item-nbt-api", version = "2.12.2" }

triumph_cmds = { module = "dev.triumphteam:triumph-cmd-bukkit", version = "2.0.0-SNAPSHOT" }

config_me = { module = "ch.jalu:configme", version = "1.4.1" }

metrics = { module = "org.bstats:bstats-bukkit", version = "3.0.2" }

itemsadder = { module = "com.github.LoneDev6:api-itemsadder", version = "3.6.1" }
oraxen = { module = "io.th0rgal:oraxen", version = "1.164.0" }

holographicdisplays = { module = "me.filoghost.holographicdisplays:holographicdisplays-api", version = "3.0.0" }
decentholograms = { module = "com.github.decentsoftware-eu:decentholograms", version = "2.8.6" }

placeholderapi = { module = "me.clip:placeholderapi", version = "2.11.4" }

paperweight = { module = "io.papermc.paperweight:paperweight-userdev", version.ref = "paperweight_version" }
shadowjar = { module = "com.github.johnrengelman:shadow", version.ref = "shadow_version" }
runpaper = { module = "xyz.jpenilla:run-task", version.ref = "runpaper_version" }
Expand Down
10 changes: 4 additions & 6 deletions paper/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,12 @@ plugins {
id("paper-plugin")
}

val mcVersion = rootProject.properties["minecraftVersion"] as String

dependencies {
api(project(":common"))

implementation(libs.cluster.paper)

implementation(libs.triumph.cmds)
implementation(libs.triumphcmds)

implementation(libs.metrics)

Expand Down Expand Up @@ -46,9 +44,9 @@ tasks {
"version" to project.version,
"group" to rootProject.group,
"description" to rootProject.description,
"apiVersion" to rootProject.properties["apiVersion"],
"authors" to rootProject.properties["authors"],
"website" to rootProject.properties["website"]
"apiVersion" to providers.gradleProperty("apiVersion").get(),
"authors" to providers.gradleProperty("authors").get(),
"website" to providers.gradleProperty("website").get()
)

inputs.properties(properties)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import com.badbones69.crazycrates.listeners.crates.QuadCrateListener;
import com.badbones69.crazycrates.listeners.crates.WarCrateListener;
import com.badbones69.crazycrates.listeners.other.EntityDamageListener;
import com.badbones69.crazycrates.support.libraries.PluginSupport;
import com.badbones69.crazycrates.support.PluginSupport;
import com.badbones69.crazycrates.support.placeholders.PlaceholderAPISupport;
import com.badbones69.crazycrates.tasks.BukkitUserManager;
import com.badbones69.crazycrates.tasks.crates.CrateManager;
Expand Down
Loading

0 comments on commit ddfe02a

Please sign in to comment.