Compare commits
9 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
af198d30f7 | ||
|
|
637b239c66 | ||
|
|
9a66e78dcd | ||
|
|
0fcf229bfb | ||
|
|
d2ffc43b17 | ||
|
|
c50f69b372 | ||
|
|
f5eafafc4c | ||
|
|
39372c9b1a | ||
|
|
4c64f03aa1 |
@@ -39,7 +39,7 @@ and many more.
|
||||
# For developers
|
||||
|
||||
## Javadoc
|
||||
The 6.13.0 Javadoc can be found [here](https://javadoc.jitpack.io/com/willfp/eco/6.13.0/javadoc/)
|
||||
The 6.27.2 Javadoc can be found [here](https://javadoc.jitpack.io/com/willfp/eco/6.27.2/javadoc/)
|
||||
|
||||
## Plugin Information
|
||||
|
||||
@@ -68,7 +68,7 @@ dependencies {
|
||||
}
|
||||
```
|
||||
|
||||
Replace `Tag` with a release tag for eco, eg `6.13.0`.
|
||||
Replace `Tag` with a release tag for eco, eg `6.27.2`.
|
||||
|
||||
Maven:
|
||||
|
||||
@@ -88,7 +88,7 @@ Maven:
|
||||
</dependency>
|
||||
```
|
||||
|
||||
Replace `Tag` with a release tag for eco, eg `6.13.0`.
|
||||
Replace `Tag` with a release tag for eco, eg `6.27.2`.
|
||||
|
||||
## Build locally:
|
||||
|
||||
|
||||
@@ -12,6 +12,10 @@ dependencies {
|
||||
group 'com.willfp'
|
||||
version rootProject.version
|
||||
|
||||
java {
|
||||
withJavadocJar()
|
||||
}
|
||||
|
||||
build.dependsOn publishToMavenLocal
|
||||
|
||||
publishing {
|
||||
|
||||
@@ -40,9 +40,9 @@ public abstract class CustomGoal<T extends Mob> implements EntityGoal<T>, Target
|
||||
/**
|
||||
* Tick the goal.
|
||||
* <p>
|
||||
* Runs ever tick as long as {@link this#canUse()} returns true.
|
||||
* Runs ever tick as long as canUse returns true.
|
||||
* <p>
|
||||
* Runs after {@link this#start()}.
|
||||
* Runs after start().
|
||||
*/
|
||||
public void tick() {
|
||||
// Override when needed.
|
||||
@@ -51,7 +51,7 @@ public abstract class CustomGoal<T extends Mob> implements EntityGoal<T>, Target
|
||||
/**
|
||||
* Start the goal.
|
||||
* <p>
|
||||
* Runs once {@link this#canUse()} returns true.
|
||||
* Runs once canUse() returns true.
|
||||
*/
|
||||
public void start() {
|
||||
// Override when needed.
|
||||
@@ -60,7 +60,7 @@ public abstract class CustomGoal<T extends Mob> implements EntityGoal<T>, Target
|
||||
/**
|
||||
* Stop the goal.
|
||||
* <p>
|
||||
* Runs once {@link this#canUse()} returns false.
|
||||
* Runs once canUse() returns false.
|
||||
*/
|
||||
public void stop() {
|
||||
// Override when needed.
|
||||
|
||||
@@ -298,7 +298,7 @@ public final class Items {
|
||||
* @param itemStack The itemStack to check.
|
||||
* @return If is recipe.
|
||||
*/
|
||||
public static boolean isCustomItem(@NotNull final ItemStack itemStack) {
|
||||
public static boolean isCustomItem(@Nullable final ItemStack itemStack) {
|
||||
return getCustomItem(itemStack) != null;
|
||||
}
|
||||
|
||||
@@ -309,7 +309,11 @@ public final class Items {
|
||||
* @return The custom item, or null if not exists.
|
||||
*/
|
||||
@Nullable
|
||||
public static CustomItem getCustomItem(@NotNull final ItemStack itemStack) {
|
||||
public static CustomItem getCustomItem(@Nullable final ItemStack itemStack) {
|
||||
if (itemStack == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return CACHE.get(HashedItem.of(itemStack)).map(Items::getOrWrap).orElse(null);
|
||||
}
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ public interface LookupHandler<T extends Testable<?>> {
|
||||
* <p>
|
||||
* You shouldn't override this method unless you're doing something
|
||||
* technically interesting or weird. This is the entry point for all
|
||||
* lookup parsers, {@link this#parse(String[])} is to specify implementation-specific
|
||||
* lookup parsers, parse() is to specify implementation-specific
|
||||
* parsing.
|
||||
*
|
||||
* @param key The key.
|
||||
@@ -56,7 +56,7 @@ public interface LookupHandler<T extends Testable<?>> {
|
||||
/**
|
||||
* Get the failsafe object.
|
||||
* <p>
|
||||
* A failsafe object should never pass {@link this#validate(Testable)}, as this will
|
||||
* A failsafe object should never pass validate(), as this will
|
||||
* cause issues with segment parsers. See {@link com.willfp.eco.core.items.ItemsLookupHandler} and
|
||||
* {@link com.willfp.eco.core.recipe.parts.EmptyTestableItem} for examples.
|
||||
*
|
||||
|
||||
@@ -22,8 +22,10 @@ class MiniMessageTranslator : MiniMessageTranslatorProxy {
|
||||
).toLegacy()
|
||||
}.getOrNull() ?: mut
|
||||
|
||||
if (startsWithPrefix) {
|
||||
mut = Display.PREFIX + miniMessage
|
||||
mut = if (startsWithPrefix) {
|
||||
Display.PREFIX + miniMessage
|
||||
} else {
|
||||
miniMessage
|
||||
}
|
||||
|
||||
return mut
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
version = 6.27.1
|
||||
version = 6.27.3
|
||||
plugin-name = eco
|
||||
kotlin.code.style = official
|
||||
Reference in New Issue
Block a user