Skip to content

Commit

Permalink
Merge remote-tracking branch 'Slimefun/master'
Browse files Browse the repository at this point in the history
DEV - 1063
  • Loading branch information
xMikux committed Jun 21, 2023
2 parents db6e5ea + 25bbe4f commit f798839
Show file tree
Hide file tree
Showing 9 changed files with 545 additions and 27 deletions.
20 changes: 18 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Table of contents
- [Release Candidate 34 (TBD)](#release-candidate-34-tbd)
- [Release Candidate 35 (TBD)](#release-candidate-35-tbd)
- [Release Candidate 34 (20 Jun 2023)](#release-candidate-34-20-jun-2023)
- [Release Candidate 33 (07 Jan 2023)](#release-candidate-33-07-jan-2023)
- [Release Candidate 32 (26 Jun 2022)](#release-candidate-32-26-jun-2022)
- [Release Candidate 31 (14 Mar 2022)](#release-candidate-31-14-mar-2022)
Expand Down Expand Up @@ -34,8 +35,16 @@
- [Release Candidate 2 (29 Sep 2019)](#release-candidate-2-29-sep-2019)
- [Release Candidate 1 (26 Sep 2019)](#release-candidate-1-26-sep-2019)

## Release Candidate 35 (TBD)

## Release Candidate 34 (TBD)
#### Additions

#### Changes

#### Fixes

## Release Candidate 34 (20 Jun 2023)
https://thebusybiscuit.github.io/builds/TheBusyBiscuit/Slimefun4/stable/#34

#### Additions
* Added "Cobbled Deepslate -> Gravel" recipe to the Grind Stone
Expand All @@ -45,6 +54,7 @@
* (API) Added EnergyNet#getConsumers()
* Added Bamboo as a fuel type for Tier 1 Androids
* Added "Basalt -> Blackstone" recipe to the Grind Stone
* Added a way to automate salt with the Ore Washer
* Added compatibility for Minecraft 1.20

#### Changes
Expand All @@ -57,6 +67,7 @@
* Tuff
* Clay
* Skulk
* Lumber Axe no longer works when shifting

#### Fixes
* Fixed #3741
Expand All @@ -67,6 +78,11 @@
* Fixed #3361
* Fixed #3254
* Fixed #3443
* Fixed #3511
* Fixed #3524
* Fixed #3657
* Fixed #3768
* Fixed #3414

## Release Candidate 33 (07 Jan 2023)
https://thebusybiscuit.github.io/builds/TheBusyBiscuit/Slimefun4/stable/#33
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@

| | 開發版 (最新) | "穩定版 (官方)" |
| ------------------ | -------- | -------- |
| **Minecraft 版本** | :video_game: **1.16.\* - 1.20.\*** | :video_game: **1.14.\* - 1.19.\*** |
| **Minecraft 版本** | :video_game: **1.16.\* - 1.20.\*** | :video_game: **1.14.\* - 1.20.\*** |
| **Java 版本** | :computer: **Java 16 (或以上)** | :computer: **Java 16 (或以上)** |
| **自動更新** | :heavy_check_mark: | :heavy_check_mark: |
| **頻繁更新** | :heavy_check_mark: | :x: |
Expand Down
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@
<!-- Dependency shading -->
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.4.1</version>
<version>3.5.0</version>

<configuration>
<!-- Relocate these to avoid clashes and conflicts -->
Expand Down Expand Up @@ -418,7 +418,7 @@
<dependency>
<groupId>com.sk89q.worldedit</groupId>
<artifactId>worldedit-core</artifactId>
<version>7.2.14</version>
<version>7.2.15</version>
<scope>provided</scope>

<exclusions>
Expand All @@ -432,7 +432,7 @@
<dependency>
<groupId>com.sk89q.worldedit</groupId>
<artifactId>worldedit-bukkit</artifactId>
<version>7.2.14</version>
<version>7.2.15</version>
<scope>provided</scope>

<exclusions>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
package io.github.thebusybiscuit.slimefun4.api.events;

import javax.annotation.Nonnull;
import javax.annotation.ParametersAreNonnullByDefault;

import org.bukkit.block.Block;
import org.bukkit.entity.Player;
import org.bukkit.event.Cancellable;
import org.bukkit.event.Event;
import org.bukkit.event.HandlerList;
import org.bukkit.event.block.BlockEvent;
import org.bukkit.inventory.ItemStack;

import io.github.thebusybiscuit.slimefun4.api.items.SlimefunItem;

/**
* This {@link Event} is fired whenever a {@link SlimefunItem} placed as a {@link Block} in the world is broken.
*
* @author J3fftw1
*/
public class SlimefunBlockBreakEvent extends Event implements Cancellable {

private static final HandlerList handlers = new HandlerList();

private final Block blockBroken;
private final SlimefunItem slimefunItem;
private final ItemStack heldItem;
private final Player player;

private boolean cancelled = false;

/**
* @param player
* The {@link Player} who broke this {@link SlimefunItem}
* @param heldItem
* The {@link ItemStack} held by the {@link Player}
* @param blockBroken
* The {@link Block} broken by the {@link Player}
* @param slimefunItem
* The {@link SlimefunItem} within the {@link ItemStack}
*/
@ParametersAreNonnullByDefault
public SlimefunBlockBreakEvent(Player player, ItemStack heldItem, Block blockBroken, SlimefunItem slimefunItem) {
super();

this.player = player;
this.heldItem = heldItem;
this.blockBroken = blockBroken;
this.slimefunItem = slimefunItem;
}

/**
* This gets the broken {@link Block}
*
* @return The broken {@link Block}
*/
public @Nonnull Block getBlockBroken() {
return blockBroken;
}

/**
* This gets the {@link SlimefunItem} being broken
*
* @return The {@link SlimefunItem} being broken
*/
public @Nonnull SlimefunItem getSlimefunItem() {
return slimefunItem;
}

/**
* The {@link ItemStack} held by the {@link Player}
*
* @return The held {@link ItemStack}
*/
public @Nonnull ItemStack getHeldItem() {
return heldItem;
}

/**
* This gets the {@link Player}
*
* @return The {@link Player}
*/
public @Nonnull Player getPlayer() {
return player;
}

@Override
public boolean isCancelled() {
return cancelled;
}

@Override
public void setCancelled(boolean cancelled) {
this.cancelled = cancelled;
}

public static @Nonnull HandlerList getHandlerList() {
return handlers;
}

@Override
public @Nonnull HandlerList getHandlers() {
return getHandlerList();
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
package io.github.thebusybiscuit.slimefun4.api.events;

import javax.annotation.Nonnull;
import javax.annotation.ParametersAreNonnullByDefault;

import org.bukkit.block.Block;
import org.bukkit.entity.Player;
import org.bukkit.event.Cancellable;
import org.bukkit.event.Event;
import org.bukkit.event.HandlerList;
import org.bukkit.inventory.ItemStack;

import io.github.thebusybiscuit.slimefun4.api.items.SlimefunItem;

/**
* This {@link Event} is fired whenever a {@link SlimefunItem} is placed as a {@link Block} in the world.
*
* @author J3fftw1
*/
public class SlimefunBlockPlaceEvent extends Event implements Cancellable {

private static final HandlerList handlers = new HandlerList();

private final Block blockPlaced;
private final SlimefunItem slimefunItem;
private final ItemStack placedItem;
private final Player player;

private boolean cancelled = false;

/**
* @param player
* The {@link Player} who placed this {@link SlimefunItem}
* @param placedItem
* The {@link ItemStack} held by the {@link Player}
* @param blockPlaced
* The {@link Block} placed by the {@link Player}
* @param slimefunItem
* The {@link SlimefunItem} within the {@link ItemStack}
*/
@ParametersAreNonnullByDefault
public SlimefunBlockPlaceEvent(Player player, ItemStack placedItem, Block blockPlaced, SlimefunItem slimefunItem) {
super();

this.player = player;
this.placedItem = placedItem;
this.blockPlaced = blockPlaced;
this.slimefunItem = slimefunItem;
}

/**
* This gets the placed {@link Block}
*
* @return The placed {@link Block}
*/
public @Nonnull Block getBlockPlaced() {
return blockPlaced;
}

/**
* This gets the {@link SlimefunItem} being placed
*
* @return The {@link SlimefunItem} being placed
*/
public @Nonnull SlimefunItem getSlimefunItem() {
return slimefunItem;
}

/**
* This gets the placed {@link ItemStack}.
*
* @return The placed {@link ItemStack}
*/
public @Nonnull ItemStack getItemStack() {
return placedItem;
}

/**
* This gets the {@link Player}
*
* @return The {@link Player}
*/
public @Nonnull Player getPlayer() {
return player;
}

@Override
public boolean isCancelled() {
return cancelled;
}

@Override
public void setCancelled(boolean cancelled) {
this.cancelled = cancelled;
}

public static @Nonnull HandlerList getHandlerList() {
return handlers;
}

@Override
public @Nonnull HandlerList getHandlers() {
return getHandlerList();
}
}
Loading

0 comments on commit f798839

Please sign in to comment.