#help-development

1 messages · Page 1207 of 1

remote swallow
#

if i had an income stream id get a small hetzner vps

#

but i dont so im stuck with a free oracle

#

theres fuck all commissions about that arent 9 years long or that dont want hypixel remaking for the 300000th time

river oracle
#

I know

#

I had to restart my server ended up losing ssh Key, but hetzner console legit can't understand the character '@'

#

so I can't add my new ssh key

#

I'm going to go insane

remote swallow
#

kekw

#

try without the username@ip

#

mine worked without it on that one server so urs might too

river oracle
#

oh also I can't exit nano

#

that too

#

or save it

#

that's another issue

remote swallow
#

how tf?

eternal night
river oracle
#

yeah ctrl+x won't work to exit

eternal night
#

remind me to not have miles run anything remotely important

river oracle
#

no clue this cloud console is legit scuffed

eternal night
#

restarts a server
looses ssh key

remote swallow
river oracle
#

well switched OS's

remote swallow
#

i literally told you to save it

eternal night
#

Do you not have them backed up??!?!?

river oracle
#

I did, but apparently it was the wrong one??

eternal night
remote swallow
#

why do you have multiple you dont keep track of

river oracle
#

I have like 5 ssh keys, but I made sure they were all in my .ssh

#

idk why my one for my server wasn't seemingly there

#

wait I wonder if I have it on my laptop

#

might as well check

blazing ocean
#

mf how

#

how do you get to this point

remote swallow
#

proton pass is actually so weird

#

some days i have access to TOTP and others i dont

blazing ocean
#

You need to make sure to back up and save your SSH keys!

#

I only have two keys

#

How do you even get to five??

remote swallow
#

i only have 1 atm

river oracle
#

I use a different key for everything

blazing ocean
#

Why???

remote swallow
#

the only thing id do like that is a personal and a "work" one

blazing ocean
#

Would be possible but also no reason to

remote swallow
#

well yeah

#

if i cared enough id do it, but i dont'

blazing ocean
#

There isn't really a reason to

river oracle
#

one sec I might have had the right key and I was being dumb

#

gotta copy it back over

remote swallow
#

someone should send me 36 euros to get proton pass plus fr fr

river oracle
#

yeah no idfk

blazing ocean
#

It's 3.81€ a month cmon

remote swallow
#

gonna ssh into it to get the ssh key to ssh into it

river oracle
#

finally got back in

#

my ssh keys had bad permissions

#

that's why they weren't working

#

all is fixed

blazing ocean
river oracle
#

@eternal night haha I'm not totally stupid only somewhat mostly (courtesy of rad) stupid

minor chasm
#

hi
i write a plugin named kill cooldown and compile it
it give a cooldown to any one who kills someone so it prevents kill farms
the problem is that the plugin is not showing in /plugins command
and its not working

blazing ocean
#

mostly stupid

smoky anchor
undone axleBOT
minor chasm
smoky anchor
#

do you use gradle to build the plugin then ?

#

And don't send the plugin itself

#

?bootstrap

undone axleBOT
#

Bootstrap Jar
The main spigot-1.18.jar is now a bootstrap jar which contains all libraries. You cannot directly depend on this jar. You should depend on Spigot/Spigot-API/target/spigot-api-1.18-R0.1-SNAPSHOT-shaded.jar, or the entire contents of the bundler directory from your server, or use a dependency manager such as Maven or Gradle to handle this automatically.

Please read the release notes for further information: https://www.spigotmc.org/threads/9-years-of-spigotmc-spigot-bungeecord-1-18-1-18-1-release.534760/#post-4305163

minor chasm
#

i used this:

blazing ocean
#

Oh god

smoky oak
#

dw i didnt put any malware in it

#

im not taht good

minor chasm
smoky anchor
#
  1. I would recommend you fix whatever is wrong with your BT
  2. use an actual dependency manager, not just IntelliJ (which I assume you're using)
minor chasm
smoky anchor
#

Maven

minor chasm
#

ok

minor chasm
#

i have errors about spigot api

#

what i have to put in C:\Users\user.m2\repository\org\spigotmc\spigot-api\1.21.4 ?

remote swallow
#

use a build system such as maven and use the repo

eternal oxide
#

if you ONLY need the API you don;t need it locally

#

?maven

undone axleBOT
minor chasm
eternal oxide
#

use maven

#

you are making things harder just to not use it

minor chasm
#

im using maven but i get this error:
[ERROR] Failed to execute goal on project killcooldown: Could not resolve dependencies for project com.example:killcooldown🫙1.0-SNAPSHOT
[ERROR] dependency: org.spigotmc:spigot-api🫙1.21.4 (provided)
[ERROR] org.spigotmc:spigot-api🫙1.21.4 was not found in https://hub.spigotmc.org/repo/releases/ during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of spigot-repo has elapsed or updates are forced
[ERROR] Could not find artifact org.spigotmc:spigot-api🫙1.21.4 in local-spigot-repo (file:///C:/Users/user/.m2/repository/org/spigotmc/spigot-api/1.21.4/)
[ERROR] org.spigotmc:spigot-api🫙1.21.4 was not found in https://repo.maven.apache.org/maven2 during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of central has elapsed or updates are forced
[ERROR]
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException

eternal oxide
#

you have your pom setup wrong

#

the url for the repo in your pom shoudl be https://hub.spigotmc.org/nexus/content/repositories/snapshots/

remote swallow
#

the version is wrong too

eternal oxide
#

it works for me, unless it changed in the past month

remote swallow
#

its 1.21.4-R0.1-SNAPSHOT

#

not 1.21.4

minor chasm
#

where i haev to download 1.21.4?

remote swallow
#

you dont need to download anything, maven will download it

blazing ocean
remote swallow
#

legacy bukkit

blazing ocean
#

Like I get the snapshot but why the-

#

Ah

minor chasm
#

so i have to delet that url for 1.21.4-R0.1-SNAPSHOT?

remote swallow
#

no

#

?maven

undone axleBOT
remote swallow
#

the version for the spigot api dependency should be 1.21.4-R0.1-SNAPSHOT NOT 1.21.4

minor chasm
#

ok

#

thx

eternal oxide
#

any reason?

blazing ocean
#

1.20.6-experimental?

remote swallow
#

no idea why bukkit has a 1.20.5 publish if thats what you mean

eternal oxide
#

does the wiki need changing for the repo now then?

remote swallow
#

that is the correct repo for spigot-api

#

bukkit not having anything on there is deliberate im guessing bc bt doesnt even build it by default anymore

eternal oxide
#

I see

#

spigot api is all versions but bukkit is not, at the recommended url

remote swallow
#

you should be using spigot api anyway at this point

blazing ocean
#

Using the bukkit API in 2025 is crazy

eternal oxide
#

I checked and https://hub.spigotmc.org/nexus/content/repositories/snapshots/ is the maven access, redirects to teh same place as your link when accessed using maven

remote swallow
#

the thing i linked is just the browser manual access of it

eternal oxide
#

yep

old dirge
#

Hey Id like to customize my plugin description adding some images for example discord logo that brings you on the discord server, so Id like to do an image that has a link, but Idk how to that.

minor chasm
#

thx

minor chasm
eternal oxide
#

missing api version in your plugin.yml

#

its also red so it failed to start

#

check servers latest.log

minor chasm
#

thats my plugin.yml
name: KillCooldown
version: 1.0
main: com.example.killcooldown.KillCooldown
author: funnyman1389
description: kill cooldown.
whats missing?

minor chasm
blazing ocean
eternal oxide
#

api-version

#

yes there is

#

?paste your latest log, from startup

undone axleBOT
minor chasm
#

api version should bi 1.21.4?

blazing ocean
#

Yes

minor chasm
#

thx

minor chasm
eternal oxide
#

you need to copy the link it gives you to here

minor chasm
urban cloak
#

Is there a rest api for the spigotmc website? To search download etc plugins

#

To search download etc plugins

eternal oxide
#

line 58

minor chasm
#

?

#

yeah

#

what i have to do?

eternal oxide
#

no clue you are not using spigot

minor chasm
#

i think purpor is fork of paper that paper is fork of spigot

eternal oxide
#

yes but its not spigot

minor chasm
#

hmmmmm

eternal oxide
#

paper and purpur do lots of fuckery on top of spigot

river oracle
#

yeah and purpur is a fork of a paper fork too

#

so its even further derived

minor chasm
#

thanks a lot about maven and other things

eternal oxide
#

You seem to be having a shading issue

#

Without seeing your pom I can;t tell if its your shading issue or the server you are using

blazing ocean
#

are we shading spigot

eternal oxide
#

he could be

#

paper/purpor org.bukkit.plugin.InvalidPluginException: java.lang.NoClassDefFoundError: no/org/bukkit/shaded/event/Listener

worldly cradle
#

hey guys, I used to code spigot plugins but I'm just now getting into it, does anyone know fi there's a way to make non-hostile mobs hostile? Like a chicken for example.

minor chasm
worldly cradle
#

I don't mean to interrupt but it seems like every time I come here someone is alr talking lol

smoky anchor
#

yeah~ who tought you to shade bukkit

worldly cradle
#

feel free to figure ur stuff out first

eternal oxide
#

yep you are tryign to shade/relocate bukkit for some reason

minor chasm
#

so what i have to do?

eternal oxide
#

delete teh whole shade plugin entry from your pom

minor chasm
#

ok

smoky anchor
#

personally, I would recommend changing the groupId

eternal oxide
#

I'm sure his name is example 🙂

minor chasm
#

problem fixed

#

thanks a lot

tight compass
#

Why does the spigot source have as a dependency a more complete nms compilation than the one actually in the project?

remote swallow
#

what

tight compass
#

Like, I'm looking at spigot-server, and there's org.bukkit and net.minecraft. But certain dependencies used throughout the project, like maybe GenerationChunkHolder, are from an nms dependency and not the net.minecraft package in the spigot-server src

#

I just don't get why

#

Or maybe I'm reading something wrong here?

remote swallow
#

are you talking about the fact spigot-server has some nms classes but a org.spigotmc:minecraft-server dep

tight compass
#

yep

remote swallow
#

spigot-server only contains classes craftbukkit or spigot patch, the rest are provided by the minecraft-server dep created inside of buildtools

tight compass
#

Okay so if I wanted to modify any of those classes I'd have to just add it to the net.minecraft package in the spigot-server src and change where it's used in the project?

#

alright

sullen marlin
#

Yes

remote swallow
#

theres a guide on the readme afaik

tight compass
#

Let me see

remote swallow
#

on craftbukkit

tight compass
blazing ocean
#

No

remote swallow
#

if you plan on putting it on git you'll want to run that too

tight compass
#

oh I see

#

okay

remote swallow
#

john minecraft gets annoyed when any net/minecraft packages are on version control

blazing ocean
#

what about john wolvereness

remote swallow
#

idk if hes submitted anymore

blazing ocean
#

Man what

remote swallow
#

mojang havent submitted any new claims this year woah

golden turret
#

how can i make a chunk be always loaded and ticking? adding a plugin ticket keeps it loaded, but if i plant a bamboo there it doesnt grow

wraith delta
golden turret
#

that didnt seem to work

wraith delta
golden turret
#

the thing is that i dont need that only for crops

#

but for eveyrthing

smoky oak
#

does maven clean compile package verify add the compiled plugin to .m2? im doing library stuff

slender elbow
#

install will

smoky oak
#

kty

earnest girder
#

does anyone know if its possible to use NMS packets to update an item's meta without updating the item and therefore causing the item to bob down/up in the player's hand?

drowsy helm
#

not sure how you would achieve that with meta

desert aspen
#

anyone have a example of a portfolio?

drowsy helm
earnest girder
slender elbow
#

the client does that, no way around that

drowsy helm
slender elbow
#

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

nowhere to be seen :Clueless:

drowsy helm
slender elbow
#

just being nitty

young knoll
#

Nope you’re going to court

earnest girder
#

if anyone knows a method with nms packets or something to prevent this when the item is updated I would much appreciate it

drowsy helm
smoky anchor
sweet pike
#

when compiling jars using md_5's specialsource maven plugin, what is the use of the third, very heavily obfuscated jar?

one of them is the original, as written.
one of them is the spigot-mapped / slightly obfuscated -> the one that runs on normal spigot servers.
one of them is a very heavily obfuscated jar. what's the purpose of this?

earnest girder
smoky anchor
#

Describing if down-and-up animation should be played in first-person view when item slot is changed (either type, count, components or by swapping the item into the other hand)
It may have some side-effects that may not be desired, never tried it myself.
But it will resolve what you're asking for. Yes.

earnest girder
#

okay cool

#

thanks so much

remote swallow
sweet pike
young knoll
#

In case you can somehow get it to run on a vanilla server inflatable

viscid carbon
#

Ij isn't finding nothing lol

#

this is all i get

Could not find artifact com.github.MrArcane:Core:pom:main-SNAPSHOT in spigotmc-repo (https://hub.spigotmc.org/nexus/content/repositories/snapshots/)```
remote swallow
#

?paste ur pom

undone axleBOT
viscid carbon
remote swallow
#

jitpack is using an old version of maven

sullen marlin
#

Is your core in jitpack or compiled?

remote swallow
#

on https://jitpack.io/com/github/MrArcane/Core/snapshot/build.log it says its using java 3.6.1 but [ERROR] Failed to execute goal org.apache.maven.plugins:maven-shade-plugin:3.6.0:shade (default) on project Core: The plugin org.apache.maven.plugins:maven-shade-plugin:3.6.0 requires Maven version 3.6.3 -> [Help 1]

viscid carbon
#

so i gotta downgrade maven?

remote swallow
#

i would hope jitpack has a way to use a newer version of maven

#

i dont use jitpack so no idea, try repsy if you want a more common repo setup where you push the build from your machine

viscid carbon
#

theres another way to do this?

remote swallow
#

try repsy

slender elbow
viscid carbon
#

yeah looking into it now. thanks @remote swallow

slender elbow
#

i mean, i don't see a maven wrapper in the repo xD

viscid carbon
#

I thought it just meant to change my settings in maven to wrapper

viscid carbon
#

When uploading to respy maven gives me

[IJ]-1-MojoFailed-[IJ]-source=LIFECYCLE-[IJ]-goal=deploy-[IJ]-id=me.arkallic:Core:jar:1.0-SNAPSHOT-[IJ]-error=status code: 401, reason phrase: Unauthorized (401)```
viscid carbon
#

<servers>
<server>
<id>repsy</id>
<username></username>
<password></password>
</server>
</servers>
</settings>

#

yeah i followed that

remote swallow
#

did you add the distribution management section with the same id and correct repo info

viscid carbon
#

yes sir

    <distributionManagement>
        <repository>
            <id>repsy</id>
            <name>core</name>
            <url>https://repo.repsy.io/mvn/arkallic/Core/</url>
        </repository>
    </distributionManagement>
#

i swear maven just hates me

remote swallow
#

double check the settings.xml file is saved and run deploy again

#

if it still fails

#

?paste the full log

undone axleBOT
viscid carbon
#

im stupid, sorry. i managed to fat finger my username -.-

#

YES FINALLY

#

thank you @remote swallow

amber fjord
#

making a crafting recipe, one of the ingredients is a dragon's breath and when it is crafted the dragon's breath becomes an empty bottle. is there a way to prevent the empty bottle from being a result?

potent atlas
#

Hi guys
I made an ender dragon you can ride but it destroys the player's armor. I see that the armor damage modifier is deprecated and googling didn't come up with any up to date options. Any help?

wet breach
potent atlas
#

No it did not

potent atlas
#

Fixed it a different way anyways 🙂

halcyon hemlock
#

greetings everyone

#

It's been a long time since I've talked here 😂

blazing ocean
#

it has been

jovial mason
#

My Shop Plugin eats a ton of memory i guess its poorly optimized can some1 help me??

blazing ocean
#

Why do you think it's your plugin using the memory?

jovial mason
#

doesnt the spark profiler say that=

#

idk how to read it tbh

#

if i can read it correctly its using the second most ram rn

blazing ocean
#

The percentage there is how much time of a tick it takes to process that

#

You should rather change that to the millisecond view

jovial mason
#

Idk how to use it aghh

mortal hare
#

is it just me of law of demeter just doesnt make sense sometimes? why should i create another function which parses the given data an returns result, when i can instead i can do it in one in less code and more readable approach? it just bloats your code with useless methods which you use use once...

drowsy helm
#

and also just following foundational SOLID principles. (Single responsiblity)

summer scroll
#

It’s better to check if the chunk is loaded first. But Location#getChunk will load the chunk.

#

Here’s how to get the chunk coordinates (no markdown cuz on mobile):

int x = this.location.getBlockX() >> 4;
int z = this.location.getBlockZ() >> 4;

jovial mason
glossy laurel
#
java.lang.NullPointerException: null
[13:30:56] [Server thread/WARN]: [FadedPVP] Task #70 for FadedPVP v1.0 generated an exception
java.lang.NullPointerException: null
[13:30:56] [Server thread/WARN]: [FadedPVP] Task #70 for FadedPVP v1.0 generated an exception
java.lang.NullPointerException: null```
any idea what could be generating these stack traceless exceptions?
pliant topaz
#

well its just an exception occuring in a bukkit task apparently from a plugin called 'FadedPVP'

#

and its an NPE

#

everything else is not directly known through the stacktrace

eternal oxide
#

set a java flag to stop truncating stacktraces -XX:-OmitStackTraceInFastThrow

#

if they happen frequently they get cut off

glossy laurel
chrome beacon
#

Full stacktrace might also be available higher up in the log

glossy laurel
#

yeah there is one

#

so it prints the full one a few times

#

but if it keeps on being

#

spamming*

#

then it just trims it off?

chrome beacon
#

Yes the JVM will optimize away the stacktrace for performance

glossy laurel
#

that'

#

s

#

really cool

#

I thought I lost the stacktrace

smoky thunder
#

good day I have a problem why does not work hide attributes

#

its not hide attributes

chrome beacon
#

also is that your plugin

amber fjord
#

plus if it does have more than one usage then theyre really useful

smoky thunder
smoky oak
#

how can i clone an IntelliJ project whilst changing the name? Having to setup everything new for every project is getting a tad annoying

chrome beacon
#

Do you have a project template?

smoky oak
#

not really

#

is that something separate?

chrome beacon
#

I was just asking if the thing you're trying to clone is a template for your plugins

smoky oak
#

well i was cloning a fairly empty one

#

the problem i have is that it keeps displaying the old name in the top left

#

tried changing file names and project settings

chrome beacon
#

Is it a gradle or maven project?

smoky oak
#

mvn

chrome beacon
#

In the project window

smoky oak
#

yea though its not showing the spigot symbol for me

#

its likek NewName[oldName]

chrome beacon
#

Yeah

#

Right click and click rename

#

What your seeing is the module name

#

This for example is folder name SpigotMavenTest and module name smt
EDIT: changed project name to folder name*

frigid forge
#

Hello, i've got a problem with my plugin, it's actually my first time making one for the server and i don't know how everything behaves in-game according to the code. I'm trying to make sitting functionality, and so far i'm using the arrow method i read online about and my friend used to use this method too, back on one of his servers. The problem is, the arrow gets spawned and launched at wooden stair block, but it falls short under my legs, or goes through the stairs and ground in the basement. I used set player as passenger right away, but thought maybe if i check if arrow hit the block i could then set him as passenger thinking the positioning would need less adjusting, but now the player is never mounting one. I'm also not sure what to put for speed and spread? Like what is the range of these values? If there's a clear docs for it i apologize. ||```
for (Material stair : woodStairsList) {
if (block != null && block.getType() == stair && event.getAction() == Action.RIGHT_CLICK_BLOCK) {
//player.sendMessage("You clicked on " + stair + " stairs!");
if (block.getLocation().distance(player.getLocation()) <= 2) {

                // The arrow speed is slow, and players position must be fixed.
                Arrow arrow = player.getWorld().spawnArrow(player.getLocation(), player.getLocation().getDirection(), 1, 0);
                arrow.addPassenger(player);
            }
        }
    }```||
pliant topaz
#

theres a raytrace method you can access through Player

#

Player#raytraceBlocks iirc

#

no need for an arrow

chrome beacon
#

The arrow is not for finding blocks

#

it's for the player to ride on

#

You'd want to disable the gravity and such for the arrow to stop it from moving

brazen obsidian
#

Hey, what's the getPersistentDataContainer() equivalent for #chunk in version 1.12.2?

frigid forge
frigid forge
#

But still don't know what value to enter for speed

wet breach
#

probably should avoid the arrow hitting a block unless there is a method to prevent it from sticking to blocks XD

chrome beacon
#

That would be a bit difficult to do without patching the server

quaint mantle
#

Or maybe use the latest version

smoky oak
#

why is strings not realizing its annotated here?

quaint mantle
#

There's can be nulls inside array I think

smoky oak
#

the passed parameter itself still cannot be null

#

{"a", null, "b"}is a valid string[]

slender elbow
#

you are annotating the array element type, not the array type itself

#

String @NN [] args

smoky oak
#

huh ty

#

unrelated but is there a way to get rid of the 'requires non null' warning for adding commands to a plugin?

smoky anchor
#

do a null check

smoky oak
#

what im trying to say is i know how my plugin.yml looks like, and can say it WILL have a command like that

quaint mantle
#

Undefined null ability 🗿

smoky oak
#

anyway. how do i deal with /help and duplicate commands? i cannot seem to declare what plugin i want it from.

does 'getPluginCommand' override the global command under the given string?
ok no minecraft:kill works

frigid forge
#

Disabling the gravity and setting velocity to zero just slows down the arrow, it hits the stairs only if you are right infront of it, but you still get on top of it the position isnt good

#

I remember using launchProjectile it sort of worked better but arrow gets despawned right away

#

Is there a way to keep it

noble current
#

can anyone help me to add a 1.20 jar to my buildpath on eclipse ide?

#

i add it but it doesnt work

chrome beacon
#

?bootstrap

undone axleBOT
#

Bootstrap Jar
The main spigot-1.18.jar is now a bootstrap jar which contains all libraries. You cannot directly depend on this jar. You should depend on Spigot/Spigot-API/target/spigot-api-1.18-R0.1-SNAPSHOT-shaded.jar, or the entire contents of the bundler directory from your server, or use a dependency manager such as Maven or Gradle to handle this automatically.

Please read the release notes for further information: https://www.spigotmc.org/threads/9-years-of-spigotmc-spigot-bungeecord-1-18-1-18-1-release.534760/#post-4305163

noble current
#

im wanting to use the armor trims and the sonic boom

chrome beacon
#

Follow those instructions but with the 1.20 jar instead

noble current
#

okay

chrome beacon
#

but I would recommend using maven

noble current
#

i dont know how to setup it

manic delta
#
public void setCreeperCamera(Player player){
  player.setGameMode(GameMode.SPECTATOR);
  Location location = player.getLocation().clone();
  LivingEntity entity = (LivingEntity) player.getWorld().spawnEntity(location, EntityType.ENDERMAN);
  entity.setInvisible(true);
  entity.setInvulnerable(true);
  entity.setAI(false);
  setCamera(player, entity)
  Bukkit.getScheduler().runTaskLater(PandemiaSchooldays.getInstance(), () -> {
    entity.remove();
    player.setGameMode(GameMode.SURVIVAL);
    player.setHealth(0.0);
  , 10L);
}
public static void setCamera(Player player, Entity entity) {
  PacketPlayOutCamera packet = new PacketPlayOutCamera(((CraftEntity) entity).getHandle());
  ((CraftPlayer) player).getHandle().playerConnection.sendPacket(packet);
}

i want to have visual effects from mobs vision, i made it by killing the player (if i dont the player got a bug that i cant move) but i cant kill the players for some reasons, there isnt any other way?

chrome beacon
#

Intellij can do it for you, no idea about Eclipse

noble current
#

okay thanks

chrome beacon
manic delta
#

but the player keeps the visual effect

chrome beacon
#

Tell it to stop spectating the entity

#

?

manic delta
#

but i want the visual effect

#

It is deleted if I remove the camera from the entity.

chrome beacon
#

So you say it will only work if you kill the player but it doesn't work when you kill the player?

#

what exactly doesn't work

#

also you appear to be wanting to abuse a bug. So make sure that what you're trying to do still works in your version

manic delta
noble current
#

im adding the entire content of the bundler directory to the buildpath of my plugin and it still doesn't works

manic delta
#

ill show you, give me a second

pliant topaz
#

that way you dont have to worry about the arrow moving

manic delta
#

thats the problem

#

and i cant kill them on my server

#

for some reasons

#

so im asking if theres any way to do it without killing him

chrome beacon
#

Could probably send the packets for a player death

#

So the client thinks it does

frigid forge
manic delta
#

it exist?

chrome beacon
#

Yes the server needs to be able to tell the player when to die

manic delta
#

so it is fake right

#

not a real death

chrome beacon
#

Whether this is a separate packet or if's just handled automatically with health

#

yes

chrome beacon
smoky oak
#

it seems like /help <command> can onyl show the last registered command

#

so if i have two commands with the same name (say /kill) itll only show for one

chrome beacon
#

I don't know if it's a separate packet or not to begin with

chrome beacon
manic delta
#

ill search

smoky oak
#

a la /help plugin:command

chrome beacon
#

Could just make your own /help command

#

Less intrusive and easier

smoky oak
#

yeah, i guess...

#

im currently much more worried about not managing to setup my FTP lol

manic delta
#

i think i need a respawn packet or something

chrome beacon
#

Yeah ofc you need to respawn the player

brazen obsidian
#

ig ill make my own file for it

eternal night
#

Well no, that is why that method was added in the first place

noble current
#

@chrome beacon

#

can you help me please

chrome beacon
#

I don't use Eclipse

#

nor do I recommend adding the jars directly like that

noble current
chrome beacon
#

Use maven

noble current
#

im using maven

#

and the plugin doesn't work

#

Error loading plugin: java.lang.IllegalArgumentException: Directory 'plugins\test.jar' does not contain a paper-plugin.yml or plugin.yml! Could not determine plugin type, cannot load a plugin from it!
java.lang.RuntimeException: java.lang.IllegalArgumentException: Directory 'plugins\test.jar' does not contain a paper-plugin.yml or plugin.yml! Could not determine plugin type, cannot load a plugin from it!
at io.papermc.paper.plugin.provider.source.FileProviderSource.registerProviders(FileProviderSource.java:70) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paper.plugin.provider.source.DirectoryProviderSource.registerProviders(DirectoryProviderSource.java:47) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paper.plugin.provider.source.DirectoryProviderSource.registerProviders(DirectoryProviderSource.java:17) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paper.plugin.util.EntrypointUtil.registerProvidersFromSource(EntrypointUtil.java:15) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paper.plugin.PluginInitializerManager.load(PluginInitializerManager.java:101) ~[paper-1.20.4.jar:git-Paper-499]
at net.minecraft.server.Main.main(Main.java:120) ~[paper-1.20.4.jar:git-Paper-499]
at org.bukkit.craftbukkit.Main.main(Main.java:326) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paperclip.Paperclip.lambda$main$0(Paperclip.java:42) ~[app:?]
at java.lang.Thread.run(Thread.java:1583) ~[?:?]
Caused by: java.lang.IllegalArgumentException: Directory 'plugins\test.jar' does not contain a paper-plugin.yml or plugin.yml! Could not determine plugin type, cannot load a plugin from it!
... 9 more

chrome beacon
#

You need to put the plugin.yml in the resources folder

noble current
#

it is

chrome beacon
#

Make sure you actually compiled with maven

noble current
noble current
chrome beacon
#

mvn package

#

would be the command, as for how to do it in Eclipse I have no idea

#

I don't use it

noble current
#

i tried intellij idea and the same error happened

chrome beacon
#

and did you run the mvn package command in Intellij

noble current
#

where i can run the command?

#

in the terminal?

chrome beacon
#

That works

#

Now did you use the jar from the target folder

noble current
#

yeah

#

should i use shaded?

chrome beacon
#

No

noble current
chrome beacon
#

Now that's a different error

#

You have your plugin twice in the plugins folder

noble current
#

of my server?

chrome beacon
#

yes

noble current
#

i only have one

wet breach
#

don't use reload

#

restart the server

noble current
#

thats what im doing

blazing ocean
#

are you calling your plugins constructor

noble current
noble current
wet breach
#

either you are calling the plugin constructor twice or you are using reload. You can't get that error any other way

chrome beacon
#

If you don't have the plugin twice then you're calling the constructor

noble current
chrome beacon
#

No reload in that stacktrace

chrome beacon
#

Are you calling new PermaDeath() ?

#

Don't do that

blazing ocean
#

They're calling the constructor of a diff plugin

eternal night
#

does Test maybe extend JavaPlugin omegaroll

chrome beacon
#

I... did not even think of that 💀

noble current
#

the class loads automatically if it extends java plugin?

blazing ocean
#

If you specified it as your main class in your plugin.yml yea

#

why are you doing that in the first place

noble current
#

you mean use test as main?

blazing ocean
#

and why do you have two

noble current
#

im wanting to organize

blazing ocean
#

then don't have it be a javaplugin

noble current
#

if i dont extends javaplugin many methods dont work

#

@blazing ocean

#

you have experience using eclipse ide?

blazing ocean
#

What

blazing ocean
noble current
#

rip

#

i need to see how to use the librarys of 1.20+ without using maven

blazing ocean
#

Why do you not want to use a build tool lmao

noble current
blazing ocean
#

Have you considered fixing those

noble current
#

i was using librarys of 1.17 until today and all worked

#

idk why with maven dont work

river oracle
#

skill issue

noble current
#

yes

river oracle
#

if you're using intellij make sure your IDE is up to date and you're on java 21 for latest version of minecraft

wet breach
river oracle
#

also make sure maven and your maven plugins are up to date

noble current
#

how i can use bundler librarys as a build path?

eternal oxide
#

Just use Maven. it works fine for all versions of Spigot with Eclipse

noble current
eternal oxide
#

you create a run profile

noble current
#

maven build?

eternal oxide
#

yes

#

clean package

noble current
eternal oxide
#

in goals type clean package

noble current
#

done

eternal oxide
#

give it a profile name at teh top

#

then apply... run

noble current
eternal oxide
#

the buttons bottom right

noble current
#

below goals?

eternal oxide
#

the profile will then be available from teh run menu in the toolbar

noble current
#

sorry im new on this

#

i dont understand what you mean

kind hatch
#

You use both IJ and Eclipse?

noble current
#

but i use eclipse

eternal oxide
noble current
#

intellij idea gives me errors

noble current
eternal oxide
#

the run is a pulldown you can pick which profile to run

kind hatch
eternal oxide
#

whatever you named it, you select

kind hatch
noble current
blazing ocean
noble current
#

and the code work

kind hatch
#

What error specifically?

noble current
#

Error loading plugin: java.lang.IllegalArgumentException: Directory 'plugins\test.jar' does not contain a paper-plugin.yml or plugin.yml! Could not determine plugin type, cannot load a plugin from it!
java.lang.RuntimeException: java.lang.IllegalArgumentException: Directory 'plugins\test.jar' does not contain a paper-plugin.yml or plugin.yml! Could not determine plugin type, cannot load a plugin from it!
at io.papermc.paper.plugin.provider.source.FileProviderSource.registerProviders(FileProviderSource.java:70) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paper.plugin.provider.source.DirectoryProviderSource.registerProviders(DirectoryProviderSource.java:47) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paper.plugin.provider.source.DirectoryProviderSource.registerProviders(DirectoryProviderSource.java:17) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paper.plugin.util.EntrypointUtil.registerProvidersFromSource(EntrypointUtil.java:15) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paper.plugin.PluginInitializerManager.load(PluginInitializerManager.java:101) ~[paper-1.20.4.jar:git-Paper-499]
at net.minecraft.server.Main.main(Main.java:120) ~[paper-1.20.4.jar:git-Paper-499]
at org.bukkit.craftbukkit.Main.main(Main.java:326) ~[paper-1.20.4.jar:git-Paper-499]
at io.papermc.paperclip.Paperclip.lambda$main$0(Paperclip.java:42) ~[app:?]
at java.lang.Thread.run(Thread.java:1583) ~[?:?]
Caused by: java.lang.IllegalArgumentException: Directory 'plugins\test.jar' does not contain a paper-plugin.yml or plugin.yml! Could not determine plugin type, cannot load a plugin from it!
... 9 more

#

3 hours trying to fix this

kind hatch
#

Bruh

#

That's not even an IJ error. 💀

noble current
#

thats the error of eclipse ide

#

i mean

#

when i export the project to a jar file

river oracle
#

welll you need to build with maven

noble current
#

and use it on my server appears like that

kind hatch
#

How did you build the jar in IJ?

noble current
#

but it is builded

eternal oxide
#

do not export, use run

noble current
#

oh wait

#

ill try

eternal oxide
#

and fix your pom

kind hatch
#

IJ has an entire side panel dedicated for maven. You should be using it to compile your jar file.

noble current
#

the problem is that when i build with maven it says up to date

kind hatch
#

Wut?

blazing ocean
#

Have you already built it before

noble current
#

what do you mean?

#

i build the project with maven and later use the jar in my server

blazing ocean
#

what jar did you use

river oracle
#

maven only gives out one jar lmao

#

paste your pom

#

?paste

undone axleBOT
wet breach
river oracle
#

I highly doubt our individual here has configured their maven to output multiple jar files

wet breach
#

you can produce more then one jar

kind hatch
#

I feel like this is a pom issue and they probably forgot to filter resources.

wet breach
#

you only filter when you want to change something with the resources or check etc

blazing ocean
noble current
blazing ocean
#

kek

noble current
#

in scale of 1 and 10 how many errors are there

blazing ocean
#

<filtering>true</filtering>

wet breach
#

set that to false

blazing ocean
#

remove the whole resources thing

#

or that

wet breach
#

also, your maven compiler is outdated

river oracle
#

your java version is outdated for what you're targeting as well

wet breach
#

and possibly the shade plugin, and since you don't configure shade plugin you will have multiple jars

#

one jar is the unshaded and the other is the shaded

river oracle
#

pretty much everything is out of date version wise

wet breach
#

you should end up with a jar that has shaded in its name

noble current
noble current
wet breach
#

yes

eternal oxide
#

you shade nothign so delete the whole section

kind hatch
wet breach
kind hatch
#

For simple plugins, shading is not needed.

kind hatch
wet breach
#

filtering is not for replacing

#

rather it will filter your document and change encodings etc

noble current
#

im gonna die

wet breach
#

in maven you should typically keep filtering set to false unless you have a specific need to do real filtering which for simple plugins you shouldn't need it

noble current
#

anyone has a base project with the things working inflatable

wet breach
#

probably all of us do

kind hatch
noble current
#

i just want a 1.20 plugin nothing more tardigrade

wet breach
#

you are not the new developer you once were years ago

kind hatch
#

But I didn't know it changed encodings. But then again, I always have the defautEnccoding property set to UTF-8 anyways.

#

I kinda want to see that in action now

wet breach
#

it will sometimes change those

#

which can be annoying lmao

kind hatch
noble current
kind hatch
#

Have you updated your pom with the suggestions that everyone has mentioned?

noble current
#

i updated the filtering to false

wet breach
#

you have to update your java version in there, one of the most important things

#

other then updating versions on the compiler plugin

#

currently you have it set to compile with java 1.8

noble current
#

oh

kind hatch
#

I think 1.20.4 still uses Java 17

wet breach
#

remove the shade plugin completely since you are not using it, and the updated version for the compiler plugin is 3.13.0

#

yeah, try to not use a java version higher then what the MC version is using

#

so as shadow points out, probably should just set it to 17

kind hatch
#

Please paste your updated pom when you are done.

noble current
#

okay wait

#

i just deleted all and i have to create the classes again

#

i was rage

kind hatch
#

All you had to do is update your pom file though. 🥲

noble current
noble current
#

i was doing that

wet breach
#

now, you should be able to compile, might have to compile twice since it has to pull in updated compiler plugin

#

but it might work on first run

kind hatch
#

You could probably remove the resource filtering altogether if it's going to be set to false.

#

If you wanted a shorter pom

noble current
#

i cant believe it works 🙏

#

thanks so much guys

#

i was in this for more than 3 hours

wet breach
#

it happens, but hopefully you learned a bit

noble current
#

now something happens

#

when i write something in the file i can't see if its wrote correctly or not

#

like if i have errors

wet breach
#

oh code completion stuff? well that is the editor

kind hatch
#

You're gonna have to send a screenshot about that.

noble current
kind hatch
#

But IJ should have a default theme

#

It has been too long since I last used eclipse.
Did they change their default color scheme?

noble current
#

idk

eternal oxide
kind hatch
#

I thought keywords were that weird magenta / purple

eternal oxide
#

ensure you are set to download javadocs

noble current
#

artifact javadoc?

eternal oxide
#

yes

kind hatch
#

Then again, the last time I used Eclipse was years ago.
Back in Eclipse Luna and Eclipse Mars days.

noble current
eternal oxide
#

colorws using dark theme in Eclipse

noble current
#

yeah

#

im looking for that

#

also it shows if i have errors

#

nothing work

kind hatch
#

Yea... 2015 lmao
Can't belive I still had it on my drive.

coarse finch
#

What's the best way to support multiple different database types (e.g. sqlite, MySQL, mariadb, postgres) in my plugin? Is there a premade library for this?

kind hatch
kind hatch
#

No there are no premade libraries for switching between them, but there are guides everywhere on how to use each one.

#

Implementing them should be easy enough, but swapping between them will require some thought on your part.

blazing ocean
#

jdbc drivers

graceful meadow
#

actually i think there is a library

#

I used it before, I'll look it up

coarse finch
eternal oxide
#

yes

kind hatch
#

Pretty much lol

eternal oxide
#

I did all those in GroupManager

kind hatch
#

You might just have to look at how different projects do it to get an idea of how you want to handle it.

graceful meadow
#

Apache commons dbcp2

kind hatch
#

LuckPerms is interesting because it has hybrid storage

coarse finch
#

I know something like what I want exists though

kind hatch
coarse finch
#

Oh an ORM is what I'm thinking of

kind hatch
#

They want different databases entirely, not multiple of the same type.

graceful meadow
#

it has BasicDataSourceFactory class where you just need to pass driver class name and some other properties and it will create a DataSource for you

coarse finch
brazen obsidian
#

whats the EntityPlaceEvent equivalent for 1.12.2?

#

lol

eternal oxide
#

at least he's not on 1.8 😉

brazen obsidian
#

exactly ^^

blazing ocean
#

1.12 for non-modded should be a crime

kind hatch
#

I mean yea, I guess I'll give him that

eternal oxide
#

There probably was no entity event for that in 1.12 as only Endermen could place blocks back then

brazen obsidian
#

no i want to detect if a player placed a minecart

eternal oxide
#

then player interact

brazen obsidian
#

ok

eternal oxide
#

a minecart is an Entity not a Block

brazen obsidian
#

PlayerInteractAtEntityEvent?

#

or PlayerInteractEntityEvent

eternal oxide
#

not atEntity

#

as its just the player clicking a block

brazen obsidian
#

so is it PlayerInteractEntityEvent?

eternal oxide
#

PlayerInteractEvent probably

brazen obsidian
#

ok thanks

eternal oxide
#

check which type of click it is, make sure they are clicking a Block with a Minecart in their hand

brazen obsidian
#

and how do i then get the Minecart?

eternal oxide
#

thats not going to be so simple

#

especially in 1.12

brazen obsidian
#

yes... i know...

eternal oxide
#

you'd probably be best to cancel the event, reduce the Minecart stack size and spawn teh cart yourself

brazen obsidian
#

k

#

also does a parent category exist for all rails? it used to be Rail

#

in the new version

eternal oxide
#

1.12 new? or are you taking about another?

#

in current you'd use Tags

brazen obsidian
#

no like its Rail in the new version

#

what was it back then?

#

1.12.2

eternal oxide
#

no clue in 1.12

brazen obsidian
#

let me try

#

btw is there docs for the 1.12.2 version?

eternal oxide
#

somewhere there is

#

at help something

brazen obsidian
#

thanks

remote swallow
blazing ocean
#

its beautiful

remote swallow
#

beautifuk

blazing ocean
#

fuck off

remote swallow
#

nuhuh

blazing ocean
#

yuh uh

remote swallow
#

check catposting

grim hound
#

besides using CreatureSpawnEvent & EntitySpawnEvent does anyone know of a decent way for spawning custom mobs?

grave lagoon
#

on enable, i call this function:

    public void discoverRecipes() {
        for (Player player : getServer().getOnlinePlayers()) {
            for (NamespacedKey key : scrollRecipeKeys) {
                player.discoverRecipe(key);
            }
        }
    }```

(also on join)

but it only actually shows up when i relog
#

its really annoying for rapid testing

#

is there a fix?

sullen marlin
#

Possibly a bug?

#

?jira

undone axleBOT
grave lagoon
#

let me actually try someoen tho 1 sec

#

yeah

#

it seems so

#

its fine

#

ill just relog ig\

sullen marlin
#

Get online players shouldn't be empty during /reload if that's what you're suggesting

glossy laurel
#

Hey guys, any trick for debugging errors that don't throw exceptions?

sullen marlin
#

What errors

glossy laurel
#

Logic erros Im guessing though

blazing ocean
#

rubber ducky

glossy laurel
blazing ocean
#

yes

glossy laurel
#

Peak

remote swallow
cosmic delta
#

hello, how i can get working the libraries of 1.20.2 in my project?

sullen marlin
#

What build system?

#

Maven recommended

cosmic delta
#

could it be without maven?

sullen marlin
#

What IDE?

cosmic delta
#

eclipse

sullen marlin
#

What have you done so far?

#

?bootstrap

undone axleBOT
#

Bootstrap Jar
The main spigot-1.18.jar is now a bootstrap jar which contains all libraries. You cannot directly depend on this jar. You should depend on Spigot/Spigot-API/target/spigot-api-1.18-R0.1-SNAPSHOT-shaded.jar, or the entire contents of the bundler directory from your server, or use a dependency manager such as Maven or Gradle to handle this automatically.

Please read the release notes for further information: https://www.spigotmc.org/threads/9-years-of-spigotmc-spigot-bungeecord-1-18-1-18-1-release.534760/#post-4305163

cosmic delta
#

but don't work

#

1 sec

sullen marlin
#

Show your project dependency configuration

cosmic delta
#

where is that?

#

or you mean build path

sullen marlin
#

Sure

#

Idk I don't use eclipse

cosmic delta
#

i think i can't sent images

sullen marlin
#

?verify

eternal oxide
#

!

#

?img

undone axleBOT
#

Can't send images? That's because you're not verified! Use !verify to complete verification.
Alternatively, you can upload screenshots to any image hosting site and share the link.

Here's some screenshot utilities that you can use to upload images.
Lightshot: https://prnt.sc
Imgur: https://imgur.com/upload
Flameshot: https://flameshot.org

cosmic delta
#

!verify

undone axleBOT
#

Usage: !verify <forums username>

cosmic delta
#

!verify doggy223

undone axleBOT
#

A private message has been sent to your SpigotMC.org account for verification!

wooden hearth
#

Hey I know this sounds stupid but what's the new way of ChatColor.translateAlternateColorCodes();?

remote swallow
#

asking in the paper discord id say

cosmic delta
sullen marlin
cosmic delta
#

i already tried that

sullen marlin
#

Is spigot-api there?

#

What's your issue exactly then?

cosmic delta
#

i can't use the imports or the methods of spigot

eternal oxide
#

is there a reason you don't want to use Maven?

#

its much simpler

cosmic delta
sullen marlin
#

What import do you have?

cosmic delta
#

when i build or run the project the jar simply dont appears

cosmic delta
eternal oxide
#

in eclipse (without a build system) you export not run

cosmic delta
#

the plugin.yml doesn't exist

eternal oxide
#

you also don;t have the api in your libraries

cosmic delta
#

i has

eternal oxide
#

try project menu -> clean

cosmic delta
#

doesn't change

eternal oxide
#

show your problems tab

cosmic delta
eternal oxide
#

no, problems tab at teh bottom of your IDE

cosmic delta
eternal oxide
#

makes zero sense

cosmic delta
#

yeah

#

i tried many jars

#

sometimes it works but later if i try on other project it dont work

pallid oxide
#

does eclipse have system where u have set source folder/package

eternal oxide
#

show yoru project structure

remote swallow
#

im gonna say thats eclipse causing an issue, also it being in src/test not src/main

cosmic delta
eternal oxide
#

yeah should not be in test

#

thats reserved for tests

cosmic delta
#

i create a new package named main?

eternal oxide
#

shoudl be src/main/java

cosmic delta
#

or just move into src

eternal oxide
#

then expand your referenced libraries and show

cosmic delta
#

im confused

eternal oxide
#

you only have main so just right click on the Main.java and refactor -> move

cosmic delta
#

yeah but i can't create folders

#

it appears like packages

eternal oxide
glossy laurel
#

Guys I have a funny bug

#

When player has their bow loaded and gets put in spectator

#

They can still shoot it

cosmic delta
eternal oxide
#

close

#

src/main/java

glossy laurel
cosmic delta
#

but its not possible for me

eternal oxide
#

once its in teh right place, select main.java and press F5

cosmic delta
eternal oxide
#

no

cosmic delta
#

its not possible for me

#

it doesn't let me

eternal oxide
#

package main. Then inside that package java

cosmic delta
#

should be that?

eternal oxide
#

no

cosmic delta
#

i mean to create the package inside main

eternal oxide
#

try it

cosmic delta
#

bruh

#

im gonna look if i can find one in github and copy it

remote swallow
#

you can always just use file manager

cosmic delta
eternal oxide
#

you would do better starting from scratch

#

create a new maven project

cosmic delta
#

hey

#

idk how but

#

the error dissapeared

eternal oxide
#

it has because its now on teh classpath

cosmic delta
#

magic

eternal oxide
#

no idea why you added .com though

cosmic delta
#

idk

#

but i renamed again

#

and still works

#

eclipse magic

#

lets see if it opens

eternal oxide
#

without maven you need to move your plugin.yml to your src root

#

drag and drop

cosmic delta
#

no way it worked

#

thanks ElgarL

#

eclipse magic

quaint mantle
blazing ocean
#

is that modded or vanilla

#

because if vanilla, that's extremely impressive

#

oh wait

#

it's probably the slowness effect, it changes your fov

quaint mantle
#

And how to place coins above the food bar? I have their texture pack and there are numbers in a row that are used in the coin indicator, It's called "coin_hud_numbers"

nova notch
# quaint mantle And how to place coins above the food bar? I have their texture pack and there a...

It uses some method of displaying text (action bar, scoreboard, etc. - likely action bar in this case), combined with a custom font to offset the position of the text. It is quite limited, but it can be used to move text horizontally and vertically, to some extent. Theres some tutorials out there, but I dont make resource packs so I cant say for certain whether this one still works https://www.youtube.com/watch?v=EL2X6ppZSCQ

We cover how to make custom ui bars similar to the health and hunger bar, in Minecraft.

💡 Amber's Negative Space Font (included in example pack) : https://github.com/AmberWat/NegativeSpaceFont

📦 Download (Contains Resource Pack and Datapack: https://www.dropbox.com/s/1fa3byoz6ugrwx3/cw_mana_bar.zip?dl=1

🔵 Discord Server: https://discord.gg/Hy...

▶ Play video
sage patio
#

Hey, I'm trying to set both blocks of an IRON_DOOR back to their original type (which i saved in a Pair of Material), but instead of a door, it drops as an item. How can I properly place the door?

sullen marlin
#

Use the physics false param

thorny dock
#

Did you find the solution? I've been struggling to figure it out myself

wraith delta
#

lmk if that one works

thorny dock
viscid carbon
#

this has became a mess 😂

     if (requirementType == CollectRequirement.class && target instanceof ItemStack collected) {
                CollectRequirement collectRequirement = (CollectRequirement) daily.getRequirement();
                matches = collectRequirement.getItemStack().getType() == collected.getType();
            } else if (requirementType == KillRequirement.class && target instanceof EntityType entityType) {
                KillRequirement killRequirement = (KillRequirement) daily.getRequirement();
                matches = killRequirement.getEntityType() == entityType;
            } else if (requirementType == MineRequirement.class && target instanceof Material material) {
                MineRequirement mineRequirement = (MineRequirement) daily.getRequirement();
                matches = mineRequirement.getMaterial() == material;
            } else if (requirementType == CraftRequirement.class && target instanceof ItemStack crafted) {
                CraftRequirement craftRequirement = (CraftRequirement) daily.getRequirement();
                ItemStack requiredItem = craftRequirement.getItemStack();
                if (requiredItem.getType() == crafted.getType()) {
                    matches = requiredItem.isSimilar(crafted);
                }
            }```
buoyant viper
#

can saddles have attributes to increase a horse's move speed?

drowsy helm
viscid carbon
#

boolean matchesTarget(Object target);

echo basalt
#

eH, not a big fan

#

What if instead you just get rid of it at the source

#

By using generics :)

viscid carbon
#

generics?

echo basalt
#

the fancy <T> stuff yeah

viscid carbon
#

everytime i come in here i hear something new xD

#

ooh that

echo basalt
#

I played around with a different structure at work the other day

viscid carbon
#

is it a structure thats going to make my brain hurt?

#

xD

echo basalt
#

lil bit

#

I could probably reuse some code by making the data have an abstract parent that loads the modifiers and stuff but cba

#

missed these two

#

The modifiers are just some funky stuff we use at work

#

Where you have objectives that you must do with certain conditions (kill 5 zombies in 15 seconds) otherwise it resets your progress

#

You can ignore them for now, implementation is a bit hacky

lost matrix
echo basalt
#

yeah

#

Basically the system picks a bunch of objectives for the player to do

#

and if the player has it on hard mode or whatever it also applies a couple modifiers

#

I can probably toss the modifiers on the holder or whatever but it feels wrong

#

this is some serious "I gotta clock out in 10 minutes" code

lost matrix
#

I meant rand access on the List of modifiers. Otherwise this should probably be a Set

#

Ah ok

echo basalt
#

Ideally it's just a Collection<Whatever> because no one needs to know whether it's a list/set/whatev

#

implementation details like these can be hidden

#

and I pick it based on performance etc

lost matrix
#

Thats probably the way

echo basalt
#

It's usually the way

#

Now I'm writing a packet system on top of redisson with kryo :)

#

I'm so blessed I get to choose not to use jedis

summer gale
#

Help i cant remove mending from my custom item lore

smoky anchor
#

Cool, show some code where you create/modify the item

summer gale
summer gale
#

yes

undone axleBOT
#

It’s hard to answer a programming question without code
Oh no! You ran into a problem. But no worries, people are willing to help, but first they need to see your code. This is because otherwise, they would be providing help based on guesses instead of concrete knowledge. Whether it be a compile error, runtime error, or an unexpected output, I'm sure that if you were to provide code, you'd receive a quick solution.

smoky anchor
#

I'm out of ideas
All looks good, and it appears to hide the other enchantments

summer gale
#

yes

#

i tried changing where to add the flag too

smoky anchor
#

just to confirm, the other enchantments do get applied, right

summer gale
#

yes

summer gale
sullen marlin
#

Do you have a client mod?

#

Vanilla doesn't look like that does it

summer gale
#

i am just using optifine and nothing else

smoky anchor
#

What version you on, 1.12 ?

summer gale
#

1.21

smoky anchor
#

no you're not

summer gale
#

one thing is i am running this spigot plugin in a paper server

smoky anchor
#

1.21 will not show the item id number

summer gale
#

1 sec

smoky anchor
#

how long does it take to do F3 and see version

#

sorry, I seem a bit cranky today

summer gale
#

ok it was a viaversion problem

#

the server and plugin is in 1.21 with viaversion

#

i relaunched mc with 1.21 and its fixed

#

but its still a bug ima report it

smoky anchor
#

Assuming your client was on 1.8 (why)
I could see that bug being the case as the enchantment does not exist on that version, viaver would just force that into lore...

smoky anchor
vagrant stratus
#

Does 1.20+ happen to have a built-in way to allow hostile mob spawns during the day or is it like... still NMS modifications lol

#

nope. damnit

vagrant stratus
#

Nothing in the spigot api

smoky anchor
#

well ye, but you can make a datapack instead of touching nms

vagrant stratus
#

Not for what I'm trying to do

smoky anchor
#

fair

vagrant stratus
#

or at the bare minimum it'll just main things a million times more difficult for devs & server owners

#

@worldly ingot can we have a spigot api method to allow hostile mob spawns or does one exist already lmfao

I know about EntityMonster#isDarkEnoughToSpawn but I don't think there's a way to modify this w/o using NMS (and even then idk how I'd get it to affect ALL hostile mobs)

#

why do all the fun things have to be NMS only D:
Need the ability to modify isSunSensitive too

upper hazel
#

I’m wondering if hackers, when hacking a server, can also attract the client due to the fact that the client runs the server part?

#

I was hear today cristalix was hacked and add virus to player clients

vagrant stratus
#

ugh it'd help if it weren't a protected method at least 😐

quaint mantle
#

Hackers just pushed malware

upper hazel
quaint mantle
upper hazel
#

I mean I was hear long time ago one hack with logs but exists smth else ? Why client so buggy

smoky anchor
#

hacking clients was only possible with log4j, and that was an exploit that got fixed as soon as it was "discovered"

smoky anchor
upper hazel
#

Fixed core of server or clients?

quaint mantle
#

Both

upper hazel
#

Nice

smoky anchor
#

The game has been around for that long, yes

#

And I can't recall any vanilla exploit of that scale ever happening before log4j

vagrant stratus
#

May 17, 2009 MC's old

smoky anchor
#

Related, this is the fun things you could do with it
https://fxtwitter.com/gegybeans/status/1469714451716882434

so fixing log4shell is great and all, but.. wouldn't it be ✨ amazing ✨ if we all just promised to be nice and instead use this power to make vanilla minecraft doom server 🤔

▶ Play video
quaint mantle
#

One day client scripting...

upper hazel
#

When I downloaded the server core for version 1.16 I saw a warning about it so it wasn't that long ago, was it?

#

In purpure site

#

🙂

sonic goblet
#

?howold 1.16

undone axleBOT
upper hazel
#

Not so big

#

I was trying load core 2 years ago