#help-development

1 messages · Page 1200 of 1

slender elbow
#

BlockData = minecraft's block state; direction, facing, powered, half/side, etc

#

BlockState = minecraft's block entity data, a chest's inventory contents for example

#

or a sign's text

chrome beacon
#

^^ basically it's NBT tag

glossy laurel
#

right

#

why does

#

createEntity

#

require a location

slender elbow
#

because

blazing ocean
#

Entity#getLocation be like

slender elbow
#

you are creating an Entity, it just isn't placed in the world yet

eternal night
#

It's a bit of a funny API

slender elbow
#

very much

worthy yarrow
#

In that case the entity would be noted by the world right? But without a location it can’t be considered a physical entity can it?

jagged quail
#

Who pinged

kind hatch
worthy yarrow
#

Hmm I wasn’t here for that

chrome beacon
#

This random guy looking for devs @jagged quail

worthy yarrow
#

Would virtual entities in this case even make sense? I mean we’ve already got display entities so

blazing ocean
jagged quail
#

@blazing ocean did you get the laptop for Christmas

blazing ocean
#

yes

jagged quail
blazing ocean
#

currently still W11 since I don't have a USB here

#

will install arch later

jagged quail
#

Ew

blazing ocean
#

yea W11 is ew

prime reef
#

how does that interact with the library plugin itself actually running?

marsh hawk
#

Is smooth teleportation possible? In this case:

  • I have an entity walking around
  • Player is the entity that should get teleported to the entity location
  • Tick delay is fine, so no exact synchronozation

The question Im having is more like, is it possible to do teleports in a way, that it doesnt bug around when done frequently (like you can feel you get teleported)? Ideally, the same as it would feel as when e.g "walking". I could imagine that you would perhaps do it in a bunch of steps, so its more fluent, however, that would take too many ticks. So how does mc walking work? Isnt that also just teleports? Why doesnt that bug around when moving very fast?

lilac dagger
#

If you link to it the reshading will change the imports to whatever the library you're using uses

glossy laurel
#

I'm using compassMeta.setLodestone(pointTo); to set the location for a compass, but then the compass becomes enchanted and named "Lodestone compass". Can I somehow make it not modify itself?

lilac dagger
radiant plaza
#

Can someone give me a list of plugins for Lobby on minecraft server?

radiant plaza
#

?

blazing ocean
#

what

blazing ocean
chrome beacon
#

pfp I assume

blazing ocean
#

probably

remote swallow
#

rad stop putting alts in spigot

blazing ocean
#

no u

eternal night
#

Wait epic is a rad alt

#

Wtf

lost matrix
remote swallow
#

nuhuh

lost matrix
eternal night
blazing ocean
#

well fuck

#

they got us

prime reef
# lilac dagger Are you trying to link to the library or modify the library itself?

I'm trying to use the library I wrote, yeah. I have the shade plugin set to relocate Jackson 2.15.1 to a separate package, and I can get the plugin to compile against that shaded version, but then the plugin itself breaks because it does a lot of reflection and when it locates a subclass of a Jackson (de)serializer, the plugin class loader from Spigot loses its fucking mind

blazing ocean
#

me*

blazing ocean
eternal night
#

What do you meaaaan 163

remote swallow
blazing ocean
blazing ocean
kind hatch
#

Can't believe rad has over 163 alts. :3
Glad I'm not one of them.
-# Sent from #21

lost matrix
#

Wait... am i a rad alt?

blazing ocean
#

yes, #87

prime reef
#

We all are, really.

blazing ocean
#

exactly #26485

remote swallow
#

is 0 the real rad and then 1-10 are the sub controllers

blazing ocean
#

yes

remote swallow
#

whos the real rad eyes_sus

prime reef
#

I read one of those "existential dread" type horror stories once where we're basically the same person living out infinite different lifetimes, so technically, we could all be rad alts.

blazing ocean
#

we are.

#

smile i saw that

#

what was that

lost matrix
#

Only one way to handle being a rad alt

blazing ocean
#

😭

#

maybe the real rad was the friends we made along the way

kind hatch
#

Eh, being an alt isn't so bad.
I don't have to worry about anything since I can be deleted at anytime.

blazing ocean
#

fuck you deletes you

#

maybe md_5 is another alt

#

it's sha-1's alt

remote swallow
#

whats choco

blazing ocean
#

vanilla's alt aka dinnerbone

echo basalt
#

oo maybe it is true

blazing ocean
#

mhm mhm

hybrid spoke
#

i would just make the map myself, set a spawn in there, cancel the playermoveevent until he sent the code in chat

#

no like installing mvcore, voidgen, generating the world via command and then use that world

#

the whole world gen fuckery just adds unnecessary complexity just to make the world once

echo basalt
#

nah fuck running commands

#

that's cursed

hybrid spoke
#

rather have a setspawn system which then gives the player an unverified state until he chats your code. after that set him to verified

blazing ocean
hybrid spoke
#

to make an empty world all over again?

blazing ocean
#

creating a void world?

hybrid spoke
#

not everything has to be made programmatically

#

especially not something you would only run once and can be done way simpler

inner mulch
#

i have a method with depending on the abstraction can return something or nothing, is there a way to abstract this well, or should i just return null when there is nothing and something if there is?

hybrid spoke
inner mulch
#

i have an interface some impl return something some dont when put into a method

#

it isnt really optional as some have a 100% chance of not returning something

hybrid spoke
#

either use optional or you have to think of a better design

#

if the return is not reliable there is probably a better design choice

inner mulch
#

im sending messages in between my servers, some might get a response, some simply inform

#

i have a send method

#

im not sure how make this better i could add another method, but that would come with problems

hybrid spoke
#

i would just always send a response

inner mulch
#

i tested this and it can slow it down 10x

#

when sending 1.000.000 messages which takes 3000ms, when waiting for an ack it results in 53000ms

#

:(

hybrid spoke
#

so then check if a response was given, if not just craft one and return it? and if its just a "RECEIVED"

inner mulch
#

okay

hybrid spoke
#

but by that your api is consistent

#

and your response could have a response code and the actual response wrapped in an Optional, so you can always check if an actual response was given

#
class Response {
  ResponseCode responseCode;
  Optional<ResponseBody> responseBodyOptional;
}

something like that

inner mulch
fresh mesa
#
public static ItemStack getSkull(String url) {
        ItemStack head = new ItemStack(Material.PLAYER_HEAD);
        if (url.isEmpty()) {
            return head;
        }

        SkullMeta headMeta = (SkullMeta) head.getItemMeta();
        GameProfile profile = new GameProfile(UUID.randomUUID(), "null");
        profile.getProperties().put("textures", new Property("textures", url));
        Field profileField;
        try {
            profileField = headMeta.getClass().getDeclaredField("profile");
            profileField.setAccessible(true);
            profileField.set(headMeta, profile);
        } catch (NoSuchFieldException | IllegalArgumentException | IllegalAccessException event) {

        }
        head.setItemMeta(headMeta);
        return head;
    }

I don't why It's not working and i want this custom head texture:
https://minecraft-heads.com/player-heads/head/47397-lucky-block

#

??

civic sluice
fresh mesa
chrome beacon
#

Spigot 1.18.1 added the new PlayerProfiles class, which finally allows us to use custom heads without needing any reflection! You can obtain them as normal items, or actually place them down into the world. I’ll show you how both works: Creating a new PlayerProfile First, we gotta create a new PlayerProfile object. To do so,...

fresh mesa
#

Thank you so much, @chrome beacon and @civic sluice! I really appreciate all of your help. ❤️

mellow gulch
#

Dade Robinson is spamming up the Jira, not sure if this is allowed behavior

blazing ocean
#

just wait for md to wake up and ban em

stiff violet
#

whats the best resource to learn plugin development?

neon storm
#

Def not allowed

mellow gulch
spiral light
#

Almost 30 mails so far ....

river oracle
#

Back when I was a young kid I'd collect cards or something

spiral light
#

👌😅

mellow gulch
#

he's probably just angry that he's alone on christmas

inner mulch
#

once you got the basics, plugins are gonna be easy

mellow gulch
#

also, after you learn java the spigot javadocs are incredibly useful

neon storm
#

Just do stuff that interest you, I would say

river oracle
lilac dagger
eternal oxide
#

@worldly ingot @young knoll There is a porn spam bot on jira

worldly ingot
#

Yeah md's aware now

eternal oxide
#

yep

rancid mauve
#

why associate yourself with that behaviour

blazing ocean
#

no they didn't

#

they linked lynx' github lmfao

rancid mauve
#

ah

#

figured

eternal oxide
#

So Lynx is the guilty party!

rancid mauve
#

xD

#

I never look at the Jira usually, wouldn't have even known if it wasn't posted in here

stiff violet
# inner mulch once you got the basics, plugins are gonna be easy

ill be real im a novice hobby programmer - currently learning the ropes through javascript and python. think im fairly confident on key concepts i just currently dont know the java translation if that makes sense? the plugin im intending to create is very (seemingly) simple, so im thinking i could use it as a project to work towards to help me learn java

#

just not sure how to start plugin development specifically, like the meta way of starting in 2024 (or 2025) if that makes sense :p

mellow gulch
#

look into strong typed languages and faniliarize yourself with that, it's going to be one of the bigger things to get used to when switching over from python/javascript to java

stiff violet
#

ive done a fair bit with typescript if thats what u mean

mellow gulch
#

ok, yeah, you shouldn't be unfamiiar with the concept then

#

the hurdles are mostly just going to be about API/library details and Java syntax specifics then.

stiff violet
#

Yeah thats what im thinking, like i say i think i can accomplish what i have in mind for a plugin idea as its relatively simple, like it just sends a player message upon player executing a command and logs a random number generated within the player message string to db on the backend - im just wondering where to start

neon storm
#

I think that plugin development is something you can start with when starting Java, I did the same. Just follow the guide and use a IDE, like intellij

mellow gulch
#

Eclipse is another good IDE, I like how it lets you add custom javadocs so you can have the info right there in your ide

chrome beacon
#

Intellij does have that feature as well

mellow gulch
#

oh nice, im more familiar with eclipse and didn't know that, but at any rate, it's a very good feature when learning a new library

chrome beacon
#

One feature that Intellij does not have is the ability to compile broken code

#

By simply replacing methods with runtime errors

mellow gulch
#

sounds fun

eternal oxide
#

I like Eclipse as it can have multiple projects open in a single workspace

#

and its light weight

mellow gulch
#

yeah i like that about it too

eternal oxide
#

probably the only two features over IJ

lilac dagger
#

the multiple projects in a single window was really nice

#

altho intellij's multiple windows feature is not the hardest to get used to either

mellow gulch
#

can it let you follow methods and classes across projects?

#

(like hyperlinks)

chrome beacon
lilac dagger
mellow gulch
#

i see.

lilac dagger
#

there's the built in decompiler that you can use to follow code in other projects

#

altho it will look a bit different

prime reef
#

jackson is a serialization/deserialization library, is it not?

#

the library I wrote is specifically designed to automate annoying plugin tasks and use Jackson to automatically read configs and generate new ones where necessary lol

#

the thing is, in the plugin I'm using that references Jackson, there are places where I want to define custom Jackson serializers for certain structs

lilac dagger
#

but i don't see where the reflections are needed

tidal kettle
#

hey do you think you can create world async or at least don't have a BIG lag when creating a world?

prime reef
#

this has nothing to do with serialization

#

just so we're on the same page :p

eternal oxide
tidal kettle
blazing ocean
#

tho you can provide a fixed spawn location and disable keeping the spawn in memory, use an empty biome provider and chunk generator ^

eternal oxide
#

NOT async though

tidal kettle
lilac dagger
tidal kettle
#

but what is fixed spawnn and empty biome provider and chunk generator

prime reef
#

fair warning

#

it's pretty old code i wrote in uni, so there's places where it's just ???

#

Actually here's the simplest use case

#
@Preload
public class AbilityFromStringDeserializer extends FromStringDeserializer<Ability> {
    protected AbilityFromStringDeserializer() {
        super(Ability.class);
    }

    @Override
    protected Ability _deserialize(String s, DeserializationContext deserializationContext) throws IOException {
        return AbilityManager.getAbility(s);
    }
}```
#

FromStringDeserializer is a Jackson class

#

the @Preload annotation just refers to the setup phase, basically something that needs to be loaded before doing any config injection (because it's a serializer)

#

Now this part isn't the problem, the problem is actually the import

#

actually hang on - this one is fine

lilac dagger
#

the import is still not reflection

prime reef
#

right

#

Sorry I should clarify

lilac dagger
#

you can use the addon method i said in the begining

prime reef
#

wait no

#

let me finish

#

actually, I think I might know what the problem could be

#

There's a section where, during init, the library attempts to instantiate that serializer

#

There's some security manager bullshit that Java does that doesn't like that, though

lilac dagger
#

is there a security manager still in java?

prime reef
#

I don't know the details because I'm not an expert on Java

chrome beacon
#

The Security Manager is getting removed

prime reef
#

yeah it's deprecated

#

This isn't the exception I get btw

lilac dagger
#

but this should be fine for most classes

prime reef
#

Yeah I don't know what the hell breaks when I do a relocate

#

It worked fine with shaded code back in like 1.19

lilac dagger
#

i think it's when accessing classes from a different jar maybe?

prime reef
#

That was what I was thinking happened

lilac dagger
#

that seems a bit unsafe

prime reef
#

It's just weird because like...all this shit worked totally fine before

#

I can't test it without the relocate because minecraft (and by extension spigot) is using an outdated version of Jackson lol

#

And I can't downgrade server versions because I'm using 1.20/1.21 stuff :')

#

Hang on let me see what happens if I just wantonly set external to true when trying to load the class

lilac dagger
#

hmm, i thought spigot/minecraft uses gson

prime reef
#

they do (or did? or maybe it's guava), but for some reason jackson is now in the bundled libraries for spigot 1.21.3

#

I have no idea what they use it for

chrome beacon
#

I believe it's Mojang uses both gson and jackson in their code

prime reef
#

Weirdly enough I could probably contact someone at Mojang through work

#

But that'd be a really specific and weird question lmao

chrome beacon
#

Or it's a transitive

lilac dagger
#

i think it's transitive

prime reef
#

I'm inclined to say transitive because the version is actually ancient

#

You don't deliberately add ancient libraries for new features. normally.

#

so maybe they're using a new library that in turn hasn't had a dependency update in years lol

lilac dagger
#

the spigot api shouldn't have it exposed tho

prime reef
#

it's not exposed, I was already using Jackson

#

been using it for years

#

or rather I did use it for years, I've been doing nothing but C++ for about 3 years now

#

spigot just loads it at runtime

#

...i wonder what would happen if i just removed it

lilac dagger
#

what i mean is you should be able to use your library without minecraft messing it up if you just depend on spigot api

prime reef
#

yeah but why would i do that

#

this is a freaky edge case lol

lilac dagger
#

i gave up on json simple because it was in craftbukkit

#

it can be removed at any point in the future

#

there's a simpler solution to your problems

prime reef
#

probably

#

i'm not using spigot's config API though

#

unless they've improved it since 2021

#

was kind of awful for years tbh

lilac dagger
#

yaml?

prime reef
#

i also already have my own config system

#

format doesn't matter

#

it's the methods/ease of use

lilac dagger
#

it's not bad for user files

prime reef
#

ehh

#

it's not very good at handling proper serialization/deserialization

#

the reason I turned away from it in the first place is because I have a fair amount of use cases that were, at the time, too complex for it

i don't remember the details because it's been more than 3 years, you'd have to give me some time to remember why I had to use an external library

lilac dagger
#

i made a cool serializer for the yaml and it can be made to look good

#

it depends how much effort you're willing to put in

#

anyway

prime reef
#

right now my shit works by:

  1. add field to class
    1a. make a serializer/deserializer if needed
  2. annotate field
  3. it now appears in the config file you specified
#

takes like 3 seconds

#

ig there are a few things I could try

lilac dagger
#

it should work

#

it doesn't seem to require reflections, just a way to access the library to add a custom serializer

prime reef
#

well, again, the issue was that the class loader had a stroke when i tried to initialize a class that depended on something from the shaded files

#

now that you mention it I think the reflection is probably orthogonal anyway

#

so yeah fair point

#

thanks for putting up with me here, I've been baffled on this for a couple hours lmao

lilac dagger
#

no problem, was of more help to me

prime reef
#

i'm a C++ dev, we just "shade" everything all the time or force you to include a .dll. there is no compromise

mellow gulch
prime reef
mellow gulch
#

oh that too, lol

prime reef
#

all c++ clang programs compile to one really long file, basically

mellow gulch
#

clang doesn't make obj files?

#

im one of those plebs that uses visual studio for c++

rugged nova
#

I can use getDirection() or getYaw() to get the orientation of the face, but how to get the orientation of the player's body is difficult to realize with the current API?

sullen marlin
#

getLocation().getYaw()?

#

what's difficult about that?

rugged nova
sullen marlin
#

Sorry not sure I'd have to look

#

I do seem to remember some sort of headyaw method somewhere but maybe not in the api

young knoll
#

Isn’t that getEyeLocation().getYaw()

mellow gulch
#

for body i think you can use Entity.getPose() and if the player's is gliding, or swimming then their body's yaw is their head yaw. But when they are just standig there or crouching, im pretty sure that the orientation of the body is clientside only, and that's why players look like their heads are on backwards sometimes... but i could be remembering wrongly

hasty gyro
#

Hello guys, I'm working on a plugin to block certain commands from being executed, but can't get auto complete to work this is what I have tried: java if (args.length == 2 && args[0].equalsIgnoreCase("add")) { CommandMap commandMap = Bukkit.getServer().getCommandMap(); return commandMap.getKnownCommands().keySet().stream() .filter(cmd -> !blockedCommands.contains(cmd.toLowerCase())) .collect(Collectors.toList()); }

#

trying to get all registered commands on the server like also with specific args.

mellow gulch
#

why not use the permissions system?

hasty gyro
#

not really something with permissions

mellow gulch
#

just make a plugin that auto bans ops

#

that's what my plugin on my personal server does

hasty gyro
#

nah also things like gamerule randomtickspeed need to be blocked as it can crash your server so easily

#

and keep crashing it when it starts

mellow gulch
#

nvm, i see what you're saying now

#

but i still think perms and disallowing op is a better option than trying to get a list of commands and stopping them

#

pretty sure commands don't have to be registered either, so what you're trying to do might not work with every plugin

hasty gyro
#

Yeah I know, that was the first thing I did when I started my server.
I had only problems with blocking randomtickspeed as gamerule is only one permission

hasty gyro
mellow gulch
#

you could write your own gamerule command, commands have namespaces, and then in your perms you can give permission to use your version of the command

#

that way you don't have to give the perm node that gives unwanted things in addition

hasty gyro
#

Yeah, but that will just make it more difficult than it needs to be.

#

This is a really easy way to patch these things

mellow gulch
#

i think this is an easier approach, but you do you

young knoll
#

You could also just disable the gamerule command

#

You generally don’t need to use it

mellow gulch
#

could also look into PlayerCommandPreprocessEvent

#

might help you

hasty gyro
#

The system is already running and uploaded to spigotmc

hasty gyro
indigo orchid
#

Is it possible to add multiple world borders in one world

lost matrix
indigo orchid
lost matrix
#

So you want a per-player WorldBorder?

indigo orchid
#

I want each island plot to have its own border

#

Yeah pre much

lost matrix
#

when a player enters an island -> get WB from island -> call player.setWorldBorder(wb)

indigo orchid
#

It only sets one world borders per world

#

Hmm ig i can try that

lost matrix
indigo orchid
#

Yeah i tried that, it only made a border for one island. The other islands didn’t have one and when a player tpd he insta died (bc being outside of border is instant death) but after turning it off too there was no border on their island only the first island created

#

I didn’t try it per “player” but I’m assuming you just mean for every island owner so I’m not sure it’ll work

lost matrix
#

You need to change the border when a player changes islands of course...

indigo orchid
#

But if i have 100 people online at once

#

Who have their own island

#

I don’t want the border to just be on one island

lost matrix
#

doesnt matter

#

Each player has its own border

indigo orchid
#

Ahh okay i can try that

#

Thanks a lot

silver robin
#

is it possible to defer player getting on the server while fetching some data from external database for example? i want to first load the player's stats and then let him play. maybe AsyncPlayerPreLoginEvent?

ivory sleet
#

should work fine

lost matrix
#

yes exactly that

silver robin
#

ah that's nice ty
so the player will "officially join" after the event handler finishes on some non-main thread?

ivory sleet
#

it runs not on server thread and yea

silver robin
#

fantastic

#

tyvm

ivory sleet
#

ye no worries, have fun multithreading

wet breach
#

15 minutes because that is typically what desktop OS's have the TCP timeout set at when not receiving data

#

not that I recommend making players wait that long though lmao

#

personally I like to allow players to connect to the lobby and allow the player to somewhat do something while data loads though

lost matrix
#
if(playerName.equals("frostalf") {
  Thread.sleep(...);
}
ivory sleet
#

I think sleeping one thread isnt enough smile, we need greater measures!

wet breach
#

lol

lost matrix
#

System.exit(-1)

ivory sleet
young knoll
#

15 minutes won’t work

#

The client gives up after 30 seconds

lost matrix
#

Not if you coach it properly

silver robin
slender elbow
#

hold on a second, i've seen this scenario being played before 🤔

faint meadow
#

I'm confused, how can I create a pixel art minigame on my server, in which the game is played in pairs, the idea is that if a player places a block only that player can break it within a time limit.

mellow gulch
#

put metadata on the block including the player's uuid and a timestamp

#

compare in the break event

inner mulch
#

can you add data to every block now?

#

to me it seems like metadatable is only limited to certain blocks

mellow gulch
#

it's to block and blockstate

#

block is the coordinate in the world basically

#

if you move the block with a piston the metadata wont move

young knoll
#

It’s not persistent though

mellow gulch
#

yeah that too

young knoll
#

It will also leak if you don’t remove it properly

mellow gulch
#

yep

inner mulch
#

hmm okay

#

i didnt know that

slender elbow
#

it's a half assed api that isn't even finished

inner mulch
#

:(

slender elbow
#

like, it's better and easier if you just keep track of stuff in a Map yourself

mellow gulch
#

i think it's pretty useful for minigames in its current state though

inner mulch
#

did you block me?

ancient plank
young knoll
#

It’s 30 seconds

ancient plank
#

tbf it only takes a couple seconds for our data to be fetched

#

deferring is always better than kicking imo

young knoll
#

Well yeah 30 seconds should be plenty

#

Unless your database is on the moon

buoyant viper
#

if the servers were on the moon, could it still be considered the cloud?

#

or would it be the satellite ...

nova notch
#

have fun waiting 1.28 seconds every time something is updated

hybrid spoke
nova notch
#

just use quantum teleportation 👍

hybrid spoke
#

teleport the server to earth, query data, teleport the server back?

#

im just waiting for micro dbs which i can implant into my brain

vast panther
#

"[Vulcan] incompatible spigot fork detected. Please contact the developer of you spigot forkand tell them to fix this!Your server tps Is being read 0 because they changed thing unnecessary"

#

Anyone help me with this

#

Error

hybrid spoke
#

Please contact the developer of you spigot forkand tell them to fix this!

vast panther
#

??

#

Bruh

quaint mantle
#

Anywho

#
                player.sendMessage(Util.sendMessage(plugin.getConfig().getString("prefix.banker" + " messages.transaction-coins-640-successful")));

This seems to be returning an error, to be exact a null error
https://paste.md-5.net/iboqojebiz.bash
Any thoughts?

summer scroll
quaint mantle
#

Why though?

summer scroll
#

Because it's invalid path

#

Path prefix.banker messages.transaction-coins-640-successful doesn't have a value

quaint mantle
#

🤔

summer scroll
#

You need to get both string, so:

String prefix = config.getString("prefix.banker");
String otherMessage = config.getString("other.messages.path");

player.sendMessage(color(prefix + otherMessage))
#

I'm guessing that's what you meant to do.

quaint mantle
#

Wait, so, if it's prefix.banker, isn't the yaml supposed to be formatted like this?

prefix:
banker:
summer scroll
#
# Path: prefix.banker

prefix:
  banker: "prefix"
quaint mantle
#

So, you are supposed to use indentation?

#

Hmm, did that as well

summer scroll
#

I'm not sure if the indentation is mandatory but without indentation it's gonna be confusing as hell.

#

Your whole path is prefix.banker messages.transaction-coins-640-successful

#

You need to get the string from the config twice.

quaint mantle
#

What if there are multiple?

summer scroll
#

What do you mean multiple?

quaint mantle
#

Oh, wait, I got it

summer scroll
#

Yeah yeah, it's kinda hard to explain xd.

quaint mantle
summer scroll
#

If you want to get multiple values, then you need to call multiple getString method

quaint mantle
#

Got it

fast jasper
#

I have a /give command I made a while ago that has an item that gives a written book to a player. is there a way to use either item stacks and/or "setItem" method to give a book using the same meta data? recreating it from scratch using the API would take a while, so is it at all possible to use the existing data present within the /give command? (the part of the command to the right of the item ID is specified wraped in square brackets)

frigid depot
#

is there a plugin/api i can use that allows me to "share" data between a bukkit player and a bungeecord player

upper hazel
#

does anyone know what plugin can be used to fix archeitectural errors in code (inteliji ultimate)?

blazing ocean
#

none

sullen marlin
#

What errors

pure dagger
#

@blazing ocean

#

what does it even mean primitive, in python str is primitive, i dont get it

blazing ocean
#

a primitive is a type not represented by a class

pure dagger
#

what is class

#

wait.

#

is array primitive

#

or what is it actually

#

i guess its not a type or nothing

#

its just more primitives

hazy parrot
#

Arrays are not primitives in java

pure dagger
#
public class int {
    
    private final int int;
    
    public int(int int) {
        this.int = int;
    }
    
    public int() {
        return this.int;
    }
}
blazing ocean
#

literally Integer

#

and stop calling everything int

pure dagger
#

but its int

blazing ocean
pure dagger
#

thats int.java

blazing ocean
#

....

shadow night
blazing ocean
#

yea

shadow night
#

int is a reserved keyword

pure dagger
#

blip blap

#

blip

#

👽

blazing ocean
#

???

nova notch
remote swallow
#

You just got called an alien

blazing ocean
nova notch
#

mf doesn't know about records

#

my beloved :D

blazing ocean
#

mf doesn't know about java.lang.Integer

nova notch
#

yeah ignoring that

pure dagger
#

how to make maps

#

and display images in maps

chrome beacon
#

Make a MapRenderer and add it to the MapView

acoustic pendant
#

Does someone know why can't I use the github library if I have it like this?

pure dagger
late sonnet
pure dagger
#

i mean is it permanent?

acoustic pendant
jovial mason
#
        <dependency>
            <groupId>me.clip</groupId>
            <artifactId>placeholderapi</artifactId>
            <version>2.11.1</version>
            <scope>provided</scope>
        </dependency>
    </dependencies>
``` any1 knows the right groupId?
#

Dependency 'me. clip:placeholderapi:2.11.1' not found

remote swallow
#

did you add the repo

jovial mason
#

No i never added a dependency

#

hmm

remote swallow
#

you need to add the repo and then the dependency

jovial mason
#

Like this ?

  <repositories>
        <repository>
            <id>papermc-repo</id>
            <url>https://repo.papermc.io/repository/maven-public/</url>
        </repository>
        <repository>
            <id>sonatype</id>
            <url>https://oss.sonatype.org/content/groups/public/</url>
        </repository>
        <repository>
            <id>placeholderapi</id>
            <url>https://repo.extendedclip.com/content/repositories/placeholderapi/</url>
        </repository>
    </repositories>
remote swallow
#

no

#

add the repo specified here then the dependency

jovial mason
#
    <repositories>
        <repository>
            <id>papermc-repo</id>
            <url>https://repo.papermc.io/repository/maven-public/</url>
        </repository>
        <repository>
            <id>sonatype</id>
            <url>https://oss.sonatype.org/content/groups/public/</url>
        </repository>
        <repository>
            <id>placeholderapi</id>
            <url>https://repo.extendedclip.com/releases/</url>
        </repository>
    </repositories>

    <dependencies>
        <dependency>
            <groupId>io.papermc.paper</groupId>
            <artifactId>paper-api</artifactId>
            <version>1.21.3-R0.1-SNAPSHOT</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>me.clip</groupId>
            <artifactId>placeholderapi</artifactId>
            <version>2.11.6</version>
            <scope>provided</scope>
        </dependency>
    </dependencies>
remote swallow
#

yes

jovial mason
#

still doesnt work

remote swallow
#

reload maven

jovial mason
#

ah okay

#

tysm

spare ruin
#

Hello, is there a way to spawn falling block entities without removing the original block at its position, and without the falling block’s position being rounded to integer ? I’m using world#spawnFallingBlock, but I’m facing these two issues. I tried using world#spawnEntity, but it seems like FallingBlock can’t set its blockData.

sonic goblet
eternal oxide
#

use teh spawn method which takes a Consumer

worldly ingot
#

FallingBlock doesn't have a method to change its BlockData

#

You're forced to use spawnFallingBlock(), which yes, does center the block coordinates. NMS accepts a BlockPosition and centers it

#

It doesn't have to because it just passes the coordinates as centered doubles, but at least currently it just takes a BP

spare ruin
#

I see, thanks.

marsh hawk
#

Is there any way to make entities visible through walls without glow?

hybrid spoke
inner mulch
hybrid spoke
#

you could try to go the hacky way and scale the entity down and put it in its place so it looks like its there

#

but thats something you dont really want to do

marsh hawk
inner mulch
#

what are you trying to do with the effect, maybe there is a workaround?

marsh hawk
#

I have an armorstand. I want to be able to see the armorstand through blocks, without the glow lines. Like, I want to see the actual armorstand.

inner mulch
#

yeah i got that, but whats the purpose of the armorstand?

#

maybe you can get such a effect differently

marsh hawk
#

There is no alternative purpose, just messing around with entities. And right now, just trying to see them through blocks.

inner mulch
#

okay, then i can just tell you that this probably wont work, i dont know anything except glow for such an effect

#

maybe some1 else has an idea

marsh hawk
#

I see :c

inner mulch
#

altough i dont know how and what, but im certain that shaders are managing the rendering

marsh hawk
#

Yeah, if there is no serverside solution

ashen notch
#

how does /tick work? i want to slow dont entity when they by me including arrows but i dont understand. im very new

remote swallow
#

/tick affects the whole server not just entities

stiff violet
#

Hi guys just wondering if anybody could help me with a problem in my java minecraft plugin where for some reason it wont connect to the backend supabase db ive specified

hazy parrot
maiden hearth
#

what's the best way to handle reloading config changes?

pseudo hazel
#

depends on what the config options do

maiden hearth
#

i think for this specific config itd be best to just have commands which let you directly add or remove stuff

lapis spade
#

Hi guys, I'm developing a plugin, but I can't figure out how I can check whether a wolf has armour. Can anyone help me?

lilac dagger
#

The wolf entity should have a method I think

#

Let me see

#

I can only see this

#

Hmm

worldly ingot
#

It's an inventory holder, isn't it?

#

It's not. It should be

lilac dagger
#

Ah

#

Living entity has get equipment

#

I think the armor is set there

worldly ingot
#

That sounds correct

#

getEquipment().getChestplate() I think. Wolf refers to it as body

lapis spade
#

I'll try this. Thanks!

worldly ingot
#

There does need to be a WolfInventory though

#

And I think wolves should be inventory holders

#

This is how horses are

cedar depot
#

aew

#

HUH

inner mulch
#

how do people make this green documentation text?

worldly ingot
#

Not sure I understand the question

ivory sleet
#

/** instead of /*

remote swallow
worldly ingot
#

My IDE formats things just fine lol

#

Also, I'm adding WolfInventory API for armour and whatnot. Guess it was just overlooked

civic sluice
#

Just Sonnenfinsternis things.

worldly ingot
#

But in the future, wolf.getInventory().getArmor() would work fine

worthy yarrow
carmine mica
#

... you can set the body for all mob

remote swallow
#

yeah but thats not the point

#

how is spigot gonna survive without more inventory classes

remote swallow
#

atleast you dont have to pull it if it does get merged

worldly ingot
remote swallow
#

choco did you see md commented already

worldly ingot
#

Why do you care? You’re not part of the stream anymore so

#

Im up, no :p

river oracle
glad prawn
worldly ingot
#

Why not player.getChestplate()? 👀

glad prawn
#

But it only has one armor, unlike the player.

worldly ingot
#

But maybe they add more!

#

Maybe you can put little socks on your pets

remote swallow
#

dog crocs

sly topaz
#

I mean, it probably is going to stay as is, don't see horses getting new armor pieces lol

worldly ingot
#

Yes, but horses have an inventory is my point :p

#

Ideally anything that can hold an item should probably have an inventory

remote swallow
#

do foxes have inventories

worldly ingot
#

An inventory doesn't constitute something the player can see. That's what InventoryView is for

sly topaz
#

can foxes hold anything

remote swallow
#

yeah

worldly ingot
#

In their mouths, yes

sly topaz
#

there doesn't seem to be a way to get/set the item they're biting either

remote swallow
#

why can a fox be a server operator

sly topaz
#

any entity can

remote swallow
sly topaz
#

ah that makes sense

worldly ingot
#

We're circling back to the wolf armour dilemma lol

sly topaz
#

wait, if you can already get the armor of a horse/wolf through entity equipment, why do you need an inventory

worldly ingot
#

Readability and ease of access tbh. wolf.getInventory().getArmor() is a lot clearer than wolf.getEquipment().getItem(EquipmentSlot.BODY);

sly topaz
#

though the fox one is indeed weird considering there is no "mouth" equipment slot lol, what would it be considered I wonder

worldly ingot
#

Right. Inventory makes it clearer. Could be getItemInMouth() or some shit lol

sly topaz
#

getItemBeingCurrentlyBitten

worldly ingot
#

getItemCoveredInFoxSalivaAfterBeingInItsMouthSinceWhoKnowsHowLong()

true mural
#

Can I release a plugin that needs a license if its unofuscated and not encrypted whatsoever

#

kinda lazy to go through everything and remove the license stuff rn

worldly ingot
#

Not sure what you mean

true mural
#

Like the plugin needs a license key to start

worldly ingot
#

Oh license key

true mural
#

Yeah

worldly ingot
#

If it's premium, we don't allow license key systems. They're forbidden by the premium guidelines. It'll get insta-rejected

sly topaz
#

I've never seen anyone do that yet, imagine your server not being able to start until you renew some plugin's license key lmao

worldly ingot
#

And if it's free - why license key it? lol

true mural
#

Oh okay, I'll remove it then

sly topaz
worldly ingot
#

me when im adobe

true mural
lilac dagger
#

That's not free anymore and abusing premium rule somewhere

sly topaz
#

there is no explicit rule that disallows it however I'd like to believe one would have to be made whenever someone attempts that

#

it's kind of pointless given how easy it is to remove any kind of protection the plugin might have against cracking anyway

#

the biggest barrier of entry to cracking plugins is someone actually wanting to spend money in order to get the original jar. Without that you're basically asking these people in shady markets to do it

lilac dagger
sly topaz
#

though now that I am thinking about it, since it wouldn't be explicitly a premium plugin you don't have to abide the rules like "needs to work without an internet connection" or "no heavy obfuscation" so you could potentially apply stronger protection lol

true mural
#

yeah its pointless, even if someone were to use a leaked version at this point there's most likely another plugin that does the same thing so doesn't matter tbh, as long as they don't get support its all good to me now lol

worldly ingot
#

That's typically the approach people take (and the approach more should lean towards). Leaks are inevitable, but if you have a way to identify a leaked copy, just don't offer support

#

Paying for support is just less worrying

true mural
#

Yeah I see that its the best thing to do

abstract totem
#

Is there a way without NMS to get all components on an item/block

ocean hollow
#

why InventoryClickEvent has less events in PlayerInventory than in chest inventory

chrome beacon
#

Are you in creative mode?

ocean hollow
#

oh in survival it works.

#

thank you

wise mesa
#

is there one maprenderer per map per server or per player?

#

I can't test because I don't have two accounts and friends are away

pseudo hazel
#

you add a map renderer to a map

#

you can even have multiple map renderers per map item

sullen marlin
#

I think it's per map

wise mesa
#

oh right because im the one adding it of course

#

appreciate it

inner mulch
clear elm
#

Does someone know Kody simpson if yes is he good

I want to improve my plugin skills

inner mulch
clear elm
#

I want to work with packages nms and databases

inner mulch
#

if he has tutorials for that sure, by packages i assume you mean modules?

clear elm
#

Yes

#

For example creating npcs

clear elm
inner mulch
#

whats wrong with him?

clear elm
#

Nothing I haven’t even started watching but probably there is something who explains better

inner mulch
#

i usually ask chatgpt for api

#

maybe he knows about nms too

wet breach
clear elm
#

What do you mean

clear elm
blazing ocean
#

it will almost always be completely outdated and wrong

inner mulch
#

okay

#

i agree

#

chatgpt is hallucinating sometimes

clear elm
inner mulch
#

i wouldn't do that if you only want to add npcs to ur knowledge just search "how to make npcs spigot"

clear elm
#

He like also has videos „understanding packets with ProctolLib“ what I also wanna learn

inner mulch
#

okay, altough, i wouldnt recommend using packets unless ur usecase is for something that the api doesnt cover

clear elm
#

Idk if I want to use it if I don’t know what it exactly does

#

I just know the word

inner mulch
#

the spigot api also sends packets, altough hidden behind the methods, if the packets change with a version spigot takes care of that, adn you dont need to worry that something doesnt working anymore

#

packets can break every version

#

sometimes they are removed, replaced or new params are added

clear elm
#

Would you say it’s important to know how to use them to make good plugins

inner mulch
#

no, you can do almost everything with the api with some exceptions, which is when u need to use packets

clear elm
#

What about nms?

inner mulch
#

nms is the same, it changes every version

#

the api is much more reliable

blazing ocean
#

nms is just minecraft

inner mulch
#

yes

clear elm
#

I watched 10 seconds of the Tutorial and I heard I can modify mobs or smth like that

mortal hare
#

NMS is uncharted jungle of mojang's deprecated code and modern features mashed together, which bukkit api tries to bootstrap together into one package

inner mulch
#

by modifying he is probably referring to, making them invisible or on fire etc. which can be done with api too

mortal hare
#

Spigot's/Paper's implementation of its own command api still on modern versions of MC haunts me till this day, when they butcher Mojang's brigadier to fit into bukkit legacy command api. It literally screams for refactor

clear elm
#

He said thad normally friendly mobs attack players

inner mulch
#

as i said some things arent in the api, but rarely

clear elm
#

Okay

inner mulch
#

if it isnt in the api it would be a usecase for packets

mortal hare
#

yea i believe there's no proper pathfinding bukkit api

#

i believe you can do pathfinding and AI stuff only from NMS

#

Bukkit API is just a safe haven for future compatibility, you usually do not update a plugin if you plainly just use bukkit api just because how backwards compatible API is

mortal hare
#

but when you use NMS, you introduce minecraft server version as a dependency, thus you need to rerelease usually your plugin to support newer minecraft's implementations

clear elm
#

Okay thanks guys

mortal hare
#

If you're lazy and smart, just use bukkit api

inner mulch
#

api > packets

mortal hare
#

if you want fancy shmancy features that are bleeding edge and there's no proper API for it yet in bukkit api, use NMS

clear elm
#

Also I got a question some plugins need protoLib or packet events to create holograms why

inner mulch
#

they only exists on the client

#

therefore are not ticked

mortal hare
#

by spawning packet level hologram (which just fools client that there's a server entity, when in theory it doesnt exist), you can make holograms only exist on the client

clear elm
#

So just for performance reasons

mortal hare
#

kinda

#

i wouldnt say that they're that much performant tbh

inner mulch
#

altough you can also use the new display entities which are basically the same as their tick method is empty

mortal hare
#

the fact that you need to store ids for holograms to remove them properly, handle them in cases where player gets out of entity visibility range

#

it can be even worse for performance, as you would still need to write code to handle those packet level entities anyways, its just that it could be handled independently from the server itself, which you can in theory optimize but its just not worth it

#

i believe nowadays packet entities are obsolete with display entities which were introduced recently i believe in 1.19 or smth

clear elm
#

Okay thanks how do you know all this stuff

inner mulch
#

practice

clear elm
#

Do you have any public plugins?

inner mulch
#

from other ppl on the discord tbh

inner mulch
mortal hare
clear elm
mortal hare
#

not really

#

everything i've developed is for private

clear elm
#

I see

mortal hare
#

it takes a lot of time and patience to develop something for public

#

and then you get bombarded by spigotmc reviews

#

to update that plugin to newest version of minecraft

#

1hr after it gets released

clear elm
wet breach
#

Or a person known to be good or significant like some other devs that are known here lol

echo basalt
#

kody simpson is the guy that makes those wacky spigot tutorial vids

#

on yt

#

not a community member by any means but somewhat popular because he's a gateway to a lot of ppl joining the scene

dawn plover
#

hey, a quick question to resolve my confusion.
With the 1.21.4 we have the new models format for texturepacks

And so i now picked up the spigot api for 1.21.4
And it still has the setCustomModelData method? (with the int, as the old structure)
but it also has the setCustomModelDataComponent for the newer bits and bobs?
if i understand it correctly, does the old one corresponds to the ranged_dispatch, index 0 now?? since the description about this method also doesnt really make sence anymore or am i missing something?

And also, is this method ever going to be depricated?

sullen marlin
#

The old one just puts an int as first item, same as vanilla migration

dawn plover
#

aha okay. makes sence

#

and is the setCustomModelData(int: ) planned to be depricated? or will it stay?

sullen marlin
#

I thought it was deprecated, guess not

dawn plover
#

oh, aha

But it doesnt show for me in my editor then :/

chrome beacon
#

It's not deprecated

dawn plover
#

(bottom method is just example of how it shows when it is deprecated. it doesnt have any other relevance)

chrome beacon
#

(yet)

dawn plover
#

aha

#

okay that makes sence XD

#

i mean, why not make it depricated imidiatly, but it also doesnt really matter

chrome beacon
#

Might have been an oversight 🤷‍♂️

grave depot
#

guys is there a way to automate that when you build your project, the version of your project in your pom and plugin.yml goes up? ( <version>1.0-SNAPSHOT</version>) & *(version: '1.0')

#

or do i need to update it everytime manually

chrome beacon
#

You can make maven put the plugin version in the plugin.yml for you

#

so you only have to change it in one place

dawn plover
grave depot
chrome beacon
#

with resource filtering you can just use the variable ${project.version}

grave depot
#

alright thanks

blazing ocean
true mural
#

Uhhh so when submitting my resource i took out all the license stuff but forgot to remove it from the config updater so when the plugin is run it adds a license feild to the config but the plugin doesn't use a license and well doesn't seem like I can change the jar before its approved??

#

I mean idk if they run the jar to check it or just check the code but well there's no license so shouldn't get rejected or anything

#

whatever i'll just update the jar whenever i can

chrome beacon
#

Will probably be rejected then

#

You'll have to resubmit it after

silver robin
#

how can i browse nms source code specifically for PlayerInteractManager?
I'm on 1.21.1, added spigot dependency in maven pom.xml (it came from build tools) and it doesn't come up when searching for it

#

(to avoid xy i'm wondering how the instaBreak boolean is calculated/determined in the BlockBreakDamage event)

chrome beacon
#

?mappings

undone axleBOT
chrome beacon
#

You're looking for ServerPlayerGameMode

#

PlayerInteractManager is the Spigot mapped name

silver robin
#

oh for some reason i thought spigot mappings didn't exist anymore in modern versions, tyvm

chrome beacon
#

They're only used for class names now

#

so they're still sort of around

silver robin
#

I get it backward compatibility and stuff

chrome beacon
#

I don't think that's why

#

Spigot only maintains backwards compat for the api

#

Internals can break at any time

remote swallow
#

afaik the only spigot mappings that remain are just the old class names, any new classes get mojmapped iirc

mortal hare
#

Welp

#

My phone is blind

#

Almost

#

Glue, holding the screen loosened off

#

Now my screen is held down by molex connector

true mural
chrome beacon
#

Probably fine then but you might still get rejected if the person going through the plugin doesn't notice that it has no behavior

#

Worst case just fix and resubmit

#

No need to worry about it too much

tight compass
#

/tryitandsee

true mural
deft geode
#

Is EntityStorageBlock#releaseEntities not supposed to update the number of entities inside? I see that vanilla, when a bee exits a beehive, the entity count drops, but with the method, it does not

#

Ok, so with that said, it seems to duplicate the entity/bee

#

For however many released using the method

junior geyser
#

If I use the world.playSound(Location) or player.playSound(Location)

How far around this location do players hear the sound? There seems to be no javadocs on this, and there is no radius param

sullen marlin
#

use the overloads with volume if you are about the volume

#

https://minecraft.wiki/w/Sound

"Most sounds can be heard from up to 16 blocks away, with the exception of: "

Minecraft Wiki

Sounds are auditory outputs of the game intended to communicate the happening of certain events, as well as create atmosphere. Different objects such as mobs, weapons or blocks have sounds.

junior geyser
#

Okay this is helpful thanks.

sullen marlin
#

in fact spigot doesnt even have a method without volume

#

so no idea what youre doing

junior geyser
#

Basically trying brodacast an ender pearl sound to all players when it is thrown, no matter the distance

sullen marlin
junior geyser
#

but it prodeses its own sound, so I dont want to send two sounds

#

otherwise sounds weird

junior geyser
sullen marlin
#

no because Player.playSound is that player only

#

there's not really a way to stop sounds in general

echo basalt
#

there's stopsound

junior geyser
#

Right. Ya there is the stop sound method but that would be hacky

sullen marlin
#

might be the best option

echo basalt
#

rip directionality

#

but it works

sullen marlin
#

although it'd have to be after the event so idk

echo basalt
#

you can emulate directionality if you're truly devious

#

(make an entity that follows you at a hardcoded axis)

junior geyser
#

I do not care enough... I just want them to be aware of one.

#

Even if they hear the two from the original location, that might be okay

#

Thanks guys!

hybrid spoke
junior geyser
#

That would super work!

#

Gonna give it a go thanks for the Idea!

lean river
#

Is anyone know if there is a good way to detect when player traded with villager?

junior geyser
lean river
#

okay thx

junior geyser
lean river
#

How to hide players from tab list?

blazing ocean
#

Player#unlistPlayer

lean river
summer scroll
#

I'm trying to optimize my plugin and it seems this code consuming more than 3% for some reason, could anyone identify why please?

    @EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
    private void hopper(InventoryMoveItemEvent event) {
        if (!(event.getDestination().getHolder() instanceof Container container)) {
            return;
        }
        ItemStack stack = event.getItem();
        ChunkCollector collector = ChunkCollectorRepository.getCollector(container.getLocation());
        if (collector == null) return;
        // Try to add the item into the chest
        if (collector.addItem(stack)) {
            // Remove the item from hopper if add item is successful
            event.getInitiator().removeItem(stack);
        }
    }
#

Basically I want to check if item is being transferred to the chunk collector using hoppers, then we handle it differently.

#

But for some reason getHolder is consuming high usage.

chrome beacon
#

Yeah it needs to make a bunch of copies

#

You really don't want to call it unless you absolutely have to

vapid anvil
summer scroll
#

I think I have to call the getHolder method in this case, no?

chrome beacon
#

Not really required

#

Call getLocation directly on the inventory

summer scroll
#

What, that's a thing?

chrome beacon
#

yes

summer scroll
#

Damn, is that new or something? I didn't know that.

chrome beacon
summer scroll
lean river
#

Whic ProtcolLib version should i set if my server is on 1.20.6?

chrome beacon
#

The latest one available

lean river
#

okay so 5.3.0

true mural
#

Yeah

hushed spindle
#

anyone know why this method stopped functioning?

#

because right now im having to do this manually and its a real pain to deal with lol

eternal oxide
#

Probably because items are component based now

sly topaz
hushed spindle
#

ah that's nice

chilly ember
#

since mojang added different wood types for signs , is there a way to check if the block placed is a sign without typing all the varieties out?

eternal oxide
#

Tag.SIGN.isTagged(...

chilly ember
chilly swallow
#

check if the block data is an instanceof WallSign

#

if (e.getBlock().getBlockData() instanceof WallSign)

chilly ember
#

oh thank you

mental drum
#

Whats a plugin people desperately need atm

#

Coming back to the scene and want to give the community something actually useful

river oracle
#

The plugin plugin which creates any plugin I think of its powered with ChatGPT and you pay for all the token requests

#

Oh also it should send money to my bitcoin wallet too

chilly ember
#

can someone recommend me a good recent plugin dev guide

river oracle
chilly ember
#

i literally started today lol

river oracle
#

Spigot wiki is fine given you know java

chilly ember
#

except that one time i tried 2 years ago and quit

river oracle
#

Otherwise gl hf

inner mulch
#

when doing this to /** to write docs, how do i reference classes? so that you can click on it and see the impl?

inner mulch
#

thank

river oracle
#

You could also do @see MyClass but this must be on its own line

ancient plank
river oracle
#

So it's far more limited than link

mental drum
inner mulch
inner mulch
river oracle
#

There's quite a few so I'm not sure how to structure it

mental drum
#

Plugins I’ve Made | blah
Fixes I’ve Contributed | blah
Reviews or Improvements | blah

or in order of cont size or importance

river oracle
#

I feel like that'd get too long though

mental drum
#

Do a creative play on gits commit display

river oracle
#

Oh god no I'm like furthest thing from an artist I'll probably just clump git commit hashes and hyper link them

mental drum
#

Yeah but surely strucutre it or filter per project

eternal night
#

Posting your PR reviews as reference 5Head

river oracle
eternal night
#

The baller move

river oracle
#

I'd never frame my first spigot PR we don't talk about that one

eternal night
river oracle
#

I was a lot dumber 2 years ago or whatever it was

mental drum
#

how do you get smarter?

#

need help

ancient plank
river oracle
#

And to learn you need to fuck up a lot

alpine urchin
#

but not too much 💀

river oracle
#

Some fuck ups could be in an app no one uses and another fuck up could be InventoryView#setTitle fuck ups look different depending what you do.

alpine urchin
#

do you guys have plugins people use

#

if not, what do you guys think about all day

river oracle
#

Anyone can vouch all I think about is inventories

eternal night
river oracle
eternal night
#

I just mindlessly fight against my sisyphus-esque punishment

alpine urchin
#

if you buy my plugin for a million dollars, you’ll have something

ancient plank
#

I have 3 plugins people use, one of em I like and the other 2 cause endless stress to me

eternal night
#

What plugin do you offer for a million dollars xD

river oracle
#

Probably packet events

eternal night
alpine urchin
#

FlyToggler

river oracle
eternal night
alpine urchin
ancient plank
eternal night
#

sounds relaxed xD

alpine urchin
river oracle
ancient plank
#

wait no I have 4 plugins, the 2nd favorite is the one where it's basically a more open and mobile version of minecraft's grindstone

alpine urchin
#

what is it @river oracle

ancient plank
#

just has groups of blocks that you can exchange blocks for, for building

alpine urchin
#

tell us the idea

#

the homeboys

#

bro

#

he ran away with it like its a business idea

#

Bro

#

oh

#

erm

river oracle
ancient plank
#

my coding brainchild is a fishing plugin that reworks fishing in minecraft almost entirely but I hate it because it wasn't meant to be in production and getting shit updated on main is near impossible on this server

alpine urchin
#

@river oracle pr to spigot and paper

#

now

#

kekw

river oracle
#

Haven't decided about that yet tbh

eternal night
#

both 5Head

river oracle
#

I'll probably do paper first and then port it to spigot going forward.

#

I value all the constructive comments like make title not required

eternal night
#

get paper review bombed

river oracle
#

And also rename class to not include Abstract

#

These are the type of difficult hard to swallow things you'll never hear on spigot

#

sorry for the dig but I literally had to

slender elbow
#

non-maintainer being like "you HAVE to change this thing it's ABSOLUTELY CRUCIAL" literally renaming a class

#

like bro chill 😂😂😂😂😂😂😂😂😂😂😂😂😂

river oracle
ancient plank
#

AbstractFishingMechanismHandlerImpl

eternal night
#

HandlerImpl is perfection

ancient plank
#

actually I wonder what the longest class name in my fishing plugin is

river oracle
#

IAbstractRegistryKeyLocationBundlerFactoryBuilderHandlerStructureImplV1_21_4

pseudo hazel
#

🤮

ancient plank
#

oh it's not that bad

#

"ItemPreventDamageListener" is the longest at 25 characters

pseudo hazel
#

thenyou are delusional

#

oh

#

okay

#

thats not impossible

#

now I wonder what mine is xD

ancient plank
#

now that doesn't say anything for my method names

#

I have some long fkin method names

pseudo hazel
#

I would say 4 words is like the max

#

oof

ancient plank
#

off()

pseudo hazel
#

my longest is probably TeamTemplateStorageSerializer

#

which is 30 chars

blazing ocean
#

AbstractIrTransformerForFirCodecifyCompanionObjectGenerator would like to have a word with you (59 chars)

river oracle
#

Longest one in my most recent PR is probably AbstractLocationInventoryViewBuilder

#

Or maybe it's CraftBlockEntityInventoryViewBuilder

pliant topaz
#

Villager#tellWitnessesThatIWasMurdered

#

and yes, that is an official method name from mojang ;-;

smoky anchor
#

I love the very first one in the mappings

#

||There was a bug report about this method not being first, which got fixed||

worldly ingot
ancient plank
arctic briar
#

hello people, im making a rpg plugin for my 1.21.3 server and i was wondering if its a good idea to register custom entities. I assumed from a source i cant remember that I "needed" to register my custom entities, and in my research to figure that out, I also found some people saying that its a bad idea. I havent gotten entity registration to work yet but now im not sure if its even a good idea to have it at all. 🧘🫃

mortal hare
#

am i the only one who doesnt pollute classes with helper methods/constructors and instead puts them under utility classes

#

for example copy constructors

hazy parrot
#

Yes

river oracle
#

^ agreed you are

pseudo hazel
#

for me it depends

#

but usually you would make some kinda method that builds more complicated versions of the same object

#

like a builder or factory I guess

mortal hare
#

i've started to do this because kotlin does this with its function extensions and i do think it produces cleaner code in long term as helper funcs shouldnt belong in the raw logic

viscid carbon
#

Is it bad to use Object instead of making an model?

public class Requirement {

 private final Object objective;
 private final int amount;
 private final Object type;

 public Requirement(Object type, Object objective, int amount) {
     this.type = type;
     this.objective = objective;
     this.amount = amount;
 }


 public Object getObjective() {
     return this.objective;
 }

 public int getAmount() {
     return this.amount;
 }

 public Object getType() {
     return this.type;
 }
}```
chrome beacon
chrome beacon
#

You should instead manage your own entities

river oracle
chrome beacon
#

instead of injecting them in to the server registry

arctic briar
#

gotcha

#

thank you 🤵👍

viscid carbon
pseudo hazel
#

what kinda objects

river oracle
#

unless your a fan of ClassCastException

pseudo hazel
#

I feel like this is too general

#

like wtf is a requirement

#

requirement for what

viscid carbon
#

im just asking a general programming question.

pseudo hazel
#

right now you can only use this class to be a container for a requirement

river oracle
#

they're making a questing system

pseudo hazel
#

but like not doing something with it

river oracle
#

but like in that context such design makes no sense

#

honestly you should probably sparsely ever use Object

#

usually if you're using Object might be a good sign you need some generics

viscid carbon
#
public record Type(String type) {
}```
#

xD

river oracle
#

couldn't you just return a String instead then??

viscid carbon
#

i just was curious what the purpose of Object was.

pseudo hazel
#

the only times I used object was to store data ni some kind of hashmap

river oracle
#

why wrap it in a record

river oracle
worthy yarrow
#

I've only ever used Object as a param for conversions or reading data in a way that's applicable to my system(s)

pseudo hazel
#

the purpose of object is that everything is an object

viscid carbon
#

oop

pseudo hazel
#

i.e. allocated on the heap

#

vs primitive types