#help-development

1 messages Β· Page 1066 of 1

eternal oxide
#

error?

tribal sky
#

it doesnt show in /plugins

eternal oxide
#

errror in startup?

tribal sky
#

i dont know console is flooded

shadow night
#

Drop the latest.log here

eternal oxide
#

I'm not running up a server to fix it

#

if you give the error/log I'll take a look but I'm not reading through ChatGPT code to debug

nova notch
#

Just have chatgpt fix it πŸ‘

shadow night
#

Ideal solution

delicate lynx
#

it works

#

I just ran it on a server and it loads

eternal oxide
#

all he has to do is add the commands to plugin.yml then

tribal sky
delicate lynx
#

well then post logs

pseudo hazel
#

or read it I guess

tribal sky
#

the logs mentioned nothing about it

#

like its not there

tribal sky
delicate lynx
#

dunno I just booted it on a test server

#

post your entire server log, it has to say why it's not loading

pseudo hazel
#

make sure you are reading the correct log

#

stop the server and check latest.log

tribal sky
#

yeah

#

1 sec

eternal oxide
#
[19:05:28] [Server thread/INFO]: [minecraftplugin] Loading minecraftplugin v0.0.1-SNAPSHOT
[19:05:28] [Server thread/INFO]: [GroupManager] Loading GroupManager v3.2 (Phoenix)```
#

it loads fine

tribal sky
#

bruh racist plugin?

eternal oxide
#

uh?

pseudo hazel
#

more like chatgpt plugin

eternal oxide
#

I named it minecraftplugin as thats what ChatGPT named it

#

no clue what is racist about it

tardy delta
#

isnt env.build number supposed to be shown?

eternal oxide
#

nah thats just a local build of Vault for debug

tribal sky
#

it works rn

#

the commands doesnt work tho

eternal oxide
#

Now all you have to do is open up the plugin.yml and add all the commands

tribal sky
#

uh

#

guide me

#

if thats fine with you

cedar flint
#

Why is there a limit on teleport duration of 59 or am I missing something?

eternal oxide
#

givelifestealersword,giveendsword,givebowofapollo,giveairtrident,givewardendagger,giveproteinshake,givebowofrhythm,givepresidentcrown,givedragonsoulsword,givewealthgem.

#

those are the commands the commands in your code

tribal sky
#

do i need intella idea

#

or something

eternal oxide
#

no

#

any text editor

#

open the jar with zip or any archiver

tribal sky
#

im in vs code rn

#

wait do i zip it

eternal oxide
#

pull out the plugin.yml

tribal sky
#

how?

#

i have code in front of me rn

eternal oxide
#

with 7zip you can just right click the jar and open with 7zip

#

you don;t need an IDE or anything

#

just a text editor

#

and an archiver that can open zip files

tribal sky
#

opened

#

name: minecraftplugin
main: me.mazen.minecraftplugin.Main
version: 0.0.1-SNAPSHOT
api-version: 1.20

authors:

  • ChatGPT

description: Weapons.

eternal oxide
#

Open Jar with archiver, get the plugin.yml that is inside

#

yes

#

?plugin

tribal sky
#

uh

eternal oxide
#

shoudl be a link for these

tribal sky
#

do i just

#

givelifestealersword,giveendsword,givebowofapollo,giveairtrident,givewardendagger,giveproteinshake,givebowofrhythm,givepresidentcrown,givedragonsoulsword,givewealthgem.

#

copy paste

eternal oxide
#

no

tribal sky
#

im not really a java coding guy

pseudo hazel
#

this isnt even java πŸ’€

eternal oxide
#

add a sectionyml commands: givelifestealersword: description: Gives a Sword. giveendsword: description: Gives an End Sword.

#

etc

#

use spaces to indent

tribal sky
#

no

eternal oxide
#

its literally just text

tribal sky
#

tab

#

use tab

eternal oxide
#

lol

eternal oxide
#

tab will break it

#

yes

#

just add all the commands in the plugin.yml

tribal sky
eternal oxide
#

Then put the plugin.yml back in the jar

quaint mantle
tribal sky
#

givelifestealersword,giveendsword,givebowofapollo,giveairtrident,givewardendagger,giveproteinshake,givebowofrhythm,givepresidentcrown,givedragonsoulsword,givewealthgem.

tribal sky
#

MY NERVES HAVE ENOUGH ANGER

eternal oxide
tribal sky
#

yeah

#

it does

#

thanks

#

wait

#

uh

#

in the description

#

what do i type

eternal oxide
#

uh, a description

tribal sky
#

e

#

any

nova notch
#

or maybe use sentences

tribal sky
#

name: minecraftplugin
main: me.mazen.minecraftplugin.Main
version: 0.0.1-SNAPSHOT
api-version: 1.20

authors:

  • ChatGPT

description: Weapons.

commands:
givelifestealersword:
description: Gives a lifestealer Sword.
giveendsword:
description: Gives an End Sword.
givebowofapollo:
description: Gives the bow of apoll.
giveairtrident:
description: Gives the air trident
givewardendagger:
description: Gives the warden dagger
giveproteinshake:
description: Gives the protein shake
givebowofrhythm:
description: Gives the bow of rythm
givepresidentcrown:
description: Gives the president crown
givedragonsoulsword:
description: Gives the dragon soul sword
givewealthgem:
description: Gives the gem of wealth

#

correct?

eternal oxide
#

looks ok

tribal sky
#

alright

#

i will try now

#

yeah okay doesnt work:/

eternal oxide
#

not workgin is not very descriptive

tribal sky
#

okay

#

/givewhateveritem doesnt work

#

its not a command

#

doesnt exist

eternal oxide
#

are you op?

tribal sky
#

yes

eternal oxide
#

They show up for me

tribal sky
#

uh

#

thats

#

weird

eternal oxide
#

I'm going to bet you didn;t put the plugin.yml back in the jar

tribal sky
#

maybe i can restart the server?

#

how do i check

eternal oxide
#

edit teh jar and look

tribal sky
#

alr if i didnt do it ya gotra fix it now\

eternal oxide
#

you can;t make changes with the server running

tribal sky
#

oh

#

yeah it didnt save

#

restarting server now

#

it works

#

but

#

doesnt work πŸ’€

#

so it gives an item

#

with that name

#

but that item doesnt work

eternal oxide
#

Thats ChatGPT for you

sullen belfry
#

does anyone know why my PlayerInteractEvent is firing twice?

pseudo hazel
#

?interact

#

oof

#

what was the command

#

anyways

eternal oxide
#

add event

pseudo hazel
#

it fires for both hands

blazing ocean
#

?interactevent

undone axleBOT
#

The PlayerInteractEvent may be called once per hand. If you only want code to be executed once, you can check the result of https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/player/PlayerInteractEvent.html#getHand(), then decide functionality.

For example, only executing code if the main hand was used:

@EventHandler
public void onPlayerInteract(PlayerInteractEvent event) {
    if (event.getHand() != EquipmentSlot.HAND) { // * if the hand used is NOT the main hand:
        return; // do not progress past this point  |
    }
    // provide functionality
}
sullen belfry
#

ah

#

okay thanks

eternal oxide
tribal sky
#

yeah

#

some work

#

some dont

eternal oxide
#

is it supposed to work on right click air/block?

tribal sky
#

ye

eternal oxide
#

Good job ChatGPT

pseudo hazel
#

ah yes a nice assert

blazing ocean
#

kek

eternal oxide
#

I'm sure it will be fine πŸ˜„

tribal sky
#

sureeeeee

#

erll

#

it works but acoustic

eternal oxide
robust pebble
#

?paste

undone axleBOT
eternal oxide
#

I did what you requested, to build your ChatGPT source into a plugin. I did say I'm not fixing anything for you though.

tribal sky
#

thanks

keen charm
#

Hey

#

How can I do a multi-module Gradle project with some submodules using a different JDK than the main project?

#

I'm trying to do like NMS_common, NMS_v1_21 etc.

#

1.21 NMS sub-module will be on Java 21, NMS_common will be on main project's JDK version, aka 17 etc.

#

Is there an example project on this?

eternal oxide
#

Spigot is setup to use Maven

keen charm
pseudo hazel
#

yes

#

if you are using paper you could ask in their discord

keen charm
remote swallow
granite night
eternal oxide
#

use the one Spigot already created

granite night
# eternal oxide you can;t create a NEW instance of your plugin

import il25plugin.betterteams_tokenenchantbank_addon.TokenEnchantStuff.YmlReader;
import il25plugin.betterteams_tokenenchantbank_addon.commands.CommandManager;
import il25plugin.betterteams_tokenenchantbank_addon.utils.BankStorageUtil;
import org.bukkit.plugin.java.JavaPlugin;

import java.io.File;

public final class BetterTeams_TokenEnchantBank_Addon extends JavaPlugin {

    private static BetterTeams_TokenEnchantBank_Addon plugin;

    private static YmlReader ymlReader;

    @Override
    public void onEnable() {
        plugin = this;

        saveDefaultConfig();
        getConfig();
        new Messages(this);

        getCommand("TeBank").setExecutor(new CommandManager());
        BankStorageUtil.loadTeams();

        new Placeholders().register();

        File pluginFolder = getDataFolder();
        ymlReader = new YmlReader(pluginFolder);
        ymlReader.readYmlFiles();
    }

    @Override
    public void onDisable() {
        // Plugin shutdown logic
    }

    public static BetterTeams_TokenEnchantBank_Addon getPlugin() {
        return plugin;
    }

    public static YmlReader getYmlReader() {
        return ymlReader;
    }

    public static void setPlugin(BetterTeams_TokenEnchantBank_Addon plugin) {
        BetterTeams_TokenEnchantBank_Addon.plugin = plugin;
    }
}```
granite night
eternal oxide
#

are you extending JavaPlugin elsewhere?

#

and wth is this new Placeholders().register();

keen charm
eternal oxide
#

in which case thats whats doing it

#

I don;t remember placeholder but it's probably something like `PlaceHolderAPI.instance().register...

granite night
keen charm
#

It changed a long time ago

granite night
#

I think I've found the problem

keen charm
granite night
#

Ok ty all, it works now

alpine cairn
#

I'm trying to run a check and if passed stop the player from swimming. I tried detecting the EntityToggleSwimEvent and cancelling it but it didn't seem to work. Then I tried detecting EntityToggleSwimEvent and just doing setSwimming(false) and that managed to crash the server and generate a whole bunch of errors. What is the best way to go about this?

worthy yarrow
#

You made sure the entity was a plyer yes? (probably did just checking)

eternal oxide
#

poor squids head exploded

alpine cairn
#

Yeah, then cast it to a Player

remote swallow
worthy yarrow
#

?paste

undone axleBOT
alpine cairn
#

I registered the listener elsewhere

#

The first bit works fine but you cancircumvent the gravity penalty with swimming so I want to cancel the swimming for players in armor

eternal oxide
#

toggling swim inside the toggle swim event is probably not going to end well

worthy yarrow
#

kek

alpine cairn
#

I tried just cancelling it first

eternal oxide
#

your use of Objects.RequireNonNull is going to blow up on ANY of those armor slots being empty

alpine cairn
#

That was what Intellij suggested so I just clicked it lol

eternal oxide
#

yeah Ij moment πŸ™‚

worthy yarrow
#

I really wanna see a rather streamlined version of the armor checks :p

alpine cairn
#

But I do need to check for null, right?

worthy yarrow
#

I mean if you want to

alpine cairn
eternal oxide
#

actually, you are only checking type so it should be ok

#

unless one of them returns null

#

I think they all return AIR not null. getArmor returns nulls

worthy yarrow
#

That's interesting

alpine cairn
#

Good to know

hollow viper
#

Hey

eternal oxide
#

However, setCancelled is correct, but I would setSwimming 1 tick later

alpine cairn
#

How would I do that?

worthy yarrow
#

yeah I can't really see a reason other than the notnull's to cause an issue with setCancelled here

hollow viper
#

So I was recently trying the image map pluggin, and I want to know can I resize my image like it's now 4x4 but I want it 9x6?

worthy yarrow
alpine cairn
eternal oxide
#

just runTask is enough

worthy yarrow
#

Oh run task yeah

#

Forget the tick delay by default am dumb

hollow viper
#

Pls help me dude

worthy yarrow
#

Is it your plugin?

hollow viper
#

No

worthy yarrow
#

Or are you creating an addon?

alpine cairn
#

Pretty sure I've tested that one before

#

I seem to remember it was quite versatile

hollow viper
alpine cairn
#

oof

worthy yarrow
alpine cairn
#

It's called "aternos" because it gives infinite headaches

worthy yarrow
#

You could also figure if that plugin has a support discord and ask for help there

worthy yarrow
hollow viper
#

No actually it didn't cause any trouble I just wanted to know that weather I can resize or not

worthy yarrow
#

Ok well this is the wrong channel to be asking A, and B, you'd have better chances finding this answer from a discord specifically for this plugin.

#

There might be someone here who knows the answer but I'm willing to bet you'll wait way longer

hollow viper
#

But the pluggin is of spigot s

worthy yarrow
#

πŸ’€

#

That doesn't mean all of spigot devs know this plugin lol

eternal oxide
#

This channel is not for support, this is devs making plugins

alpine cairn
#

@hollow viper I think you can set the size when you run the command to place it

#

One of them

#

iirc there are two ways to do it

worthy yarrow
#

Whew look at psych

hollow viper
#

I did but it didn't worked

worthy yarrow
#

Being knowledgeable

alpine cairn
#

I remember having to watch the video on the page

#

Because it was confusing

hollow viper
#

I did set the size to 9x6 from 4x4 but it didn't worked it again created 4x4 only

worthy yarrow
#

Whats this plugin called?

alpine cairn
#

ImageMaps

hollow viper
#

Dude I am searching the solution for like 4 hours but didn't get any solution πŸ₯²

zenith bobcat
#

Can anyone tell me why this code isnΒ΄t resulting in any clientside funktion

#

import net.minecraft.network.protocol.game.ClientboundSetHealthPacket;
import net.minecraft.server.level.ServerPlayer;
import net.minecraft.server.network.ServerGamePacketListenerImpl;
import org.bukkit.craftbukkit.v1_20_R3.entity.CraftPlayer;
import org.bukkit.entity.Player;
import org.bukkit.event.EventHandler;
import org.bukkit.event.Listener;
import org.bukkit.event.player.PlayerJoinEvent;

public class PlayerJoinListener implements Listener {

@EventHandler
public void onPlayerJoin(PlayerJoinEvent event){
    Player player = event.getPlayer();
    ServerPlayer serverPlayer = ((CraftPlayer) player).getHandle();
    ClientboundSetHealthPacket packet = new ClientboundSetHealthPacket(12f, 0, 4f);
    ServerGamePacketListenerImpl connection = serverPlayer.connection;
    connection.send(packet);
    player.sendMessage("Packet send");
}

}

alpine cairn
#

@hollow viper I tested all the mapart plugins I could find and I found the best one was "ImageFrame"

#

It is updated to 1.21 and supports gifs

humble tulip
eternal oxide
#

either not running your code or you need to send the packet later

#

why send a packet for health?

eternal oxide
#

just set it on the Player

zenith bobcat
alpine cairn
worthy yarrow
zenith bobcat
#

but i am testing packets and stuff

eternal oxide
#

then schedule it for a few ticks later, or do it in a command

hollow viper
zenith bobcat
worthy yarrow
#

Well i'd try it multiple times

alpine cairn
#

/imageframe create <name> <url> <width> <height> - Create a new image map

#

right there on the list of commands

worthy yarrow
#

botta boom botta bang

zenith bobcat
blazing ocean
eternal oxide
zenith bobcat
eternal oxide
#

?scheduling

undone axleBOT
blazing ocean
#

there is zero reason to use a packet for a basic api feature

zenith bobcat
#

I wanna know what is happening behind the Packet creation and so on

worthy yarrow
#
public class PacketEventsListener implements PacketListener {


    @Override
    public void onPacketReceive(PacketReceiveEvent event) {

        if (event.getPacketType() == PacketType.Handshaking.Client.HANDSHAKE) {
            WrapperHandshakingClientHandshake clientHandshake = new WrapperHandshakingClientHandshake(event);
            System.out.println(clientHandshake.getClientVersion());
            System.out.println(clientHandshake.getServerPort());
        } else if (event.getPacketType() == PacketType.Play.Server.UNLOAD_CHUNK);
    }

This was my practice with packets and packet events kek

zenith bobcat
worthy yarrow
#

packet events

delicate gust
#

does anyone know how to prevent items being taken from a gui? i canceled the event but u still able to shift click and close the gui quickly and get the item

nova notch
#

arent those just ghost items?

proud badge
#

they are

delicate gust
#

nop i can drop it/move it after

proud badge
#

like via name, inventoryholder etc

delicate gust
#

the onclick event?

#

metadata

pliant topaz
#

are u in creative?

proud badge
#

metadata?

delicate gust
worthy yarrow
#

yes

delicate gust
#

oh

proud badge
#

and yeah if youre in creative you bypass ghost items

delicate gust
#

so for normal players in survival it'll be fine?

worthy yarrow
#

Creative likes to fuck with inventory related operations

pliant topaz
#

yea, in creative everything kinda breaks

worthy yarrow
delicate gust
#

is it bad to use metadata?

worthy yarrow
#

?pdc

worthy yarrow
#

Modern^

proud badge
worthy yarrow
#

metadata isn't pdc

delicate gust
#

normal metadata

worthy yarrow
#

You put the data into a container ie: the pdc

worthy yarrow
#

Use pdc for this

delicate gust
#

can u explain what it means

#

like what do u mean by persistent items data

worthy yarrow
#

Metadata is what you can consider to be the descriptor data of something in this case the itemstack, the metadata holds things like displayname, lore, etc but with the addition of pdc in 1.13 or wtv, we've been able to create our own custom data structures and apply them to whatever we need

delicate gust
#

oh i meant

#

for the GUI im using metadata not items in it

worthy yarrow
eternal oxide
#

persistant data = data which exists so long as teh object exists.

worthy yarrow
#

If these items are given to players and need to be used later (after like server restarts and whatnot) they wont hold that data unless you explicitly put it into a pdc

#

Obv there are other ways to do this like flat files, but since pdc exists that's just dumb

#

pdc is held by the server anyway so

delicate gust
#

okay

#

i'll check it out thanks

eternal oxide
#

ah already been linked

worthy yarrow
#

hehe

eternal oxide
#

I'll pretend it wasn;t me πŸ™‚

worthy yarrow
#

kek

#

I'll have to pretend as well

cinder abyss
eternal oxide
#

do not call new YourPlugin()

alpine cairn
#

Okay so I have two things: p.getInventory().getHelmet()).getType() can produce null if there is no armor in the armor slot, so what is the best way to check for that so it doesn't throw errors? Also I am detecting and cancelling the EntityToggleSwimEvent as well as setting p.setSwimming(false); but I am still able to swim around just fine, what else can I try to make it stop the player from swimming?

cinder abyss
young knoll
#

p.getInventory().getHelmet() != null

shadow night
worthy yarrow
#

Coll help with the swimming this is so dumb we can't figure it out kek

alpine cairn
#

I even found a post where the legendary Choco said to use setSwimming(); but it seems to have no effect

compact haven
remote swallow
#

what a name

compact haven
#

what's on that line

blazing ocean
#

@shadow night

shadow night
#

what

blazing ocean
compact haven
#

its not his program

blazing ocean
#

it is

cinder abyss
compact haven
#

oh

blazing ocean
#

he wrote it lol

compact haven
#

my bad i didn't see "we"

cinder abyss
#

WEEEEE

blazing ocean
#

kek

compact haven
#

royal we >

cinder abyss
shadow night
#

I don't have source code on me rn

compact haven
#

why do you have a default constructor lmao

shadow night
#

It's decompiled code

compact haven
#

ah

blazing ocean
worthy yarrow
#

You don't ever just put useless constructers in your classes?

cinder abyss
#

line 13 πŸ‘

shadow night
#

Paulem casually dropped in the wrong source lol

#

The source for nmstestproject1122 is.different

cinder abyss
shadow night
#

Now that's the right one probably

cinder abyss
#

yeah, it's the right one

#

I check with PRINTS

shadow night
#

But it calls invalid methods how can there be a different error in it wtf

blazing ocean
#

bro really sent the jar

compact haven
#

jesus christ I can't even open recaf because java incompat

#

give me a minute lmao

cinder abyss
#

Here I go @compact haven

blazing ocean
#

skull

cinder abyss
#

I'M SORRY DOC WRONG PING

#

here's the decompiled's remapped's code πŸ’€

#

(too many 's)

blazing ocean
#

jesus at least remove the comment

shadow night
#

Why it's beautiful

late sonnet
compact haven
#

Just curious, what's the point of DummyJavaPlugin if its not referenced in main?

worthy yarrow
#

@blazing ocean I bet you'll like this one

blazing ocean
#

based

cinder abyss
#

well

#

Idk how to say it in english πŸ’€

#

looks like it's not this, hummm

shadow night
cinder abyss
#

okay

blazing ocean
#

say im france?

shadow night
#

you are france

compact haven
#

surely you dont have this in cvn and in the plugins folder yeah?

cinder abyss
cinder abyss
compact haven
#

I cant see you invoking new xyz anywhere so is it just that CVN and the spigot plugin loader is attempting to init the same main class twice?

cinder abyss
compact haven
#

(disclaimer I have no idea what CVN is)

cinder abyss
shadow night
shadow night
#

This bullfuckery

#

Probably useless

#

But it's funny

compact haven
#

ah this is y'all private project as well?

cinder abyss
#

nah

shadow night
#

It has a repo

#

Org*

#

SpigotCVN is the org name, look it up if you're curious

compact haven
#

ok so you guys coded CVN and this is your first time testing it right?

#

like there's no proof the plugin(class) loader in CVN works yes?

shadow night
#

Class loader doesn't exist

#

Description outdated

#

Paulem dumb

#

It just remaps plugins before loading them

#

And it works on more modern versions (1.19)

#

Atleast it worked, Idk maybe it decided to not anymore

compact haven
#

lmao

cinder abyss
shadow night
compact haven
cinder abyss
compact haven
#

where's your cvn-plugin.yml

#

I dont see it in the jar he sent

shadow night
#

It's already remapped and repackaged for use in spigot

compact haven
#

alright so it got stripped?

shadow night
#

Well, remapping failed miserably, but repackaging worked almost

shadow night
compact haven
#

ight just trying to see if there's any flaws in this ver vs your 1.19 test lmao

shadow night
tribal sky
#

raydan dm

shadow night
#

._.

compact haven
#

wait so you put the CVN plugin in a subdirectory of the plugins folder

#

so the server loads CVN which then remaps every plugin in that subdirectory and repackages it into (another subdir remapped) plugins folder, then calls the PluginManager to load it?

#

πŸ˜•

shadow night
#

We never modify the original jars

#

But basically yes

#

This means we could introduce mixins into other plugins that use cvn but sounds like a shit idea

compact haven
#

checking the JavaPluginLoader src to see if there's any help there

shadow night
cinder abyss
#

Hello, when I run BT with Java 21 for 1.21 with flags --generate-source --generate-docs --remapped, I don't get 1.21-R... in mavenLocal's org/spigotmc/spigot. How to fix this ?

cinder abyss
shadow night
blazing ocean
#

bro forgor

shadow night
cinder abyss
blazing ocean
#

1.21 isn't latest

cinder abyss
compact haven
#

hmm how can I backdate the source LMAO

cinder abyss
compact haven
#

will buildtools spit it out for me?

cinder abyss
#

I put --rev 1.21

blazing ocean
cinder abyss
#

but that looks logical

cinder abyss
shadow night
compact haven
#

since when was there a buildtools gui

shadow night
#

Or run cvn, it pulls the cb repo for the current version

cinder abyss
#

I get smth with this version of specialsource isn't available

worthy yarrow
cinder abyss
#

that's really strange...

#

So I don't think that's a skill issue @shadow night

compact haven
#

I think that you should

#

somehow loop through all loaded plugins and print their jar directory

#

before you call PluginLoader(cvn)#loadPlugin or whatever

#

to figure out why it's already been initialized

#

and if it's not there then your code is running twice and init'ing twice, yeah?

tribal sky
#

Is there like a marketplace channel

worthy yarrow
#

?services

undone axleBOT
tribal sky
#

For commissions

tribal sky
cinder abyss
# cinder abyss

"Loaded Plug" -> Plugins already loaded on the server
"Plug Path" -> remapped plugin's path

compact haven
chrome beacon
blazing ocean
compact haven
#

oh

#

so you already did that and only CVN is loaded before CVN runs?

chrome beacon
shadow night
cinder abyss
chrome beacon
#

It needs to finish successfully

cinder abyss
#

okay, I rebuild

compact haven
chrome beacon
#

You can find the cached failure of special source and delete it from your m2

chrome beacon
#

That should force it to retry

shadow night
#

Originally there is a dummy plugin.yml that has this weird cryptic name and a main: DummyJavaPlugin

chrome beacon
#

Rebuilding won't help unless you wait for the cache to expire

shadow night
#

Repackaging replaces it

cinder abyss
stark sierra
#

What would the best event be for detecting if the player puts on a chestplate?

I've seen different people use/suggest PlayerItemHeldEvent, InventoryClickEvent, etc. but not sure which one would be more effective

worthy yarrow
#

Probably a mix of them all

chrome beacon
cinder abyss
#

yeah

#

I deleted the mavenlocal specialsource

stark sierra
#

ty

worthy yarrow
#

Wait alex made that an event?

cinder abyss
#

I even have a folder category for his blog posts

shadow night
#

Yeah

cinder abyss
shadow night
#

Lol

chrome beacon
#

@tender shard makes a lot of cool posts uwu

worthy yarrow
#

ok but why hasnt that been pr'd

young knoll
#

It has

cinder abyss
compact haven
#

can y'all retest the 1.19

cinder abyss
#

a lot of things

compact haven
#

and if that works u need to check patches from 1.12 -> 1.19

young knoll
#

But the pr is a bit ded atm

shadow night
worthy yarrow
cinder abyss
#

it should not work

#

intuition

shadow night
#

it should work on 1.19 if you use the right nmstest project

young knoll
#

It’s being worked on

#

We’ll have InventoryChangeEvent soonℒ️

cinder abyss
#

OMG MY GOD @chrome beacon BT IS WORKING THANKS I LOVE YOU

worthy yarrow
#

Oh thank god

shadow night
worthy yarrow
cinder abyss
shadow night
cinder abyss
#

okay

young knoll
#

I should have a look at that PR again

shadow night
#

You can use the same cvn jar tho

worthy yarrow
#

Merge when? kek

young knoll
#

See if I can make the old and/or new item a mirror without things exploding

sharp heart
#

Hello, how to get tps with the spigot api ?

shadow night
#

Why do you merge a pull request, it requests to be pulled, and you, the idiot you are, merge it!

cinder abyss
#

wait

sharp heart
remote swallow
#

you cant with the api

cinder abyss
#

humm strange

remote swallow
#

you have to use nms

cinder abyss
#

I know you need to interact with nms

shadow night
remote swallow
#

jankily

shadow night
#

Just manually calculate the tps

#

It works ig

compact haven
#

does Class#newInstance invoke the default constructor?

young knoll
compact haven
#

or do you need to do that manually?

shadow night
remote swallow
#

dom ur a kotlin user arent you

compact haven
#

yeah how'd you know

worthy yarrow
remote swallow
compact haven
#

lmao

remote swallow
#

wanna know something cool, i use kotlin more than java at this point

shadow night
#

Your bio says "kotlin developer" too

young knoll
#

Event gets called for armor -> air when it breaks

#

You cancel it and the armor… unbreaks?

compact haven
#

so constructing PluginClassLoader calls newInstance on the main class which calls initialize (a method) back on PluginClassLoader

#

so is it possible that PluginClassLoader is being initialized twice?

remote swallow
#

oo a stack overflow

shadow night
worthy yarrow
shadow night
#

And why does it not happen with normal plugins

compact haven
#

Im speaking abt CVN

blazing ocean
young knoll
#

This isn’t about the equip event

worthy yarrow
#

oh

compact haven
#

does CVN make two PluginClassLoaders

young knoll
#

This is the InventoryChangeEvent

remote swallow
shadow night
remote swallow
#

which makes you a giant nerd

cinder abyss
blazing ocean
shadow night
#

It uses the PluginManager of spigot

blazing ocean
#

i write my own delegates

shadow night
#

To load the jar

cinder abyss
shadow night
#

Into spigot

#

Spigot does shit itself

compact haven
#

so it does work on 1.19

worthy yarrow
compact haven
#

then it's a spigot problem

cinder abyss
shadow night
stark sierra
shadow night
cinder abyss
young knoll
#

Use maven

remote swallow
compact haven
#

so ig the next step is to check every patch that manages loading plugins from 1.12 to 1.19 LMAO

shadow night
young knoll
#

It’s set up as a maven dependency

cinder abyss
young knoll
#

(Gradle works too)

cinder abyss
cinder abyss
shadow night
stark sierra
#

ah ic, ty

cinder abyss
#

I don't want to build a website to make my plugin works

blazing ocean
# remote swallow i use delegation like this πŸ’ͺ
object Fonts {
    @ChevyFont("beaver_mono", "beaver", 301.0, 1.0, "race_background")
    val RACE_TIMER by font

    @ChevyFont("beaver_mono", "beaver", 313.0, 1.0, "race_background_minimized")
    val RACE_TIMER_MINIMIZED by font

    @ChevyFont("virtue", "virtue", 9.0, 1.0, "duel_background", "flag_red", "flag_blue")
    val DUEL_BOSS_BAR by font

    @ChevyFont("virtue", "virtue", 5.0, 1.0, "elimination_counter_actionbar_background", "elimination_small")
    val DUEL_ELIMINATION_COUNTER by font

    @ChevyFont("virtue", "virtue", 10.0, 1.0, "elimination_counter_actionbar_background", "elimination_small")
    val DUEL_ELIMINATION_COUNTER_MINIMIZED by font

    @ChevyFont("beaver_upper", "chest_backgrounds", 0.0, 1.0, "navigator_background", "paginated_7x3_background")
    val CHEST_BACKGROUNDS by font

    @NotificationFonts(12.5, 15.0, 17.5, 20.0, 22.5, 25.0)
    val NOTIFICATIONS by notifications

    @ChevyFont("virtue", "virtue")
    val VIRTUE by font

    @ChevyFont("beaver_upper", "beaver")
    val BEAVER_UPPER by font
    val SPRITES = registerSpritesFont()
    val REGISTERED_FONTS = mutableListOf<UIFont>()
}
``` hehe
worthy yarrow
#

As far as I'm concerned they all suck

cinder abyss
remote swallow
blazing ocean
#

no

young knoll
#

Yeah you could not use Kotlin

#

Gottem

cinder abyss
#

'cause kotlin iskotlin fun
LMAO

compact haven
#

Maybe you guys can create an automated process to build each version of spigot and test CVN to narrow it down to where it no longer works?

#

might be easier but not sure

remote swallow
blazing ocean
shadow night
blazing ocean
cinder abyss
shadow night
remote swallow
compact haven
#

haha

shadow night
#

I might as well have to finish it because rad is too busy

cinder abyss
#

yeah

blazing ocean
#

sure

shadow night
#

Well, my kotlin skills don't mind getting better

blazing ocean
#

less projects for me

cinder abyss
#

because he's doing musculation

shadow night
compact haven
#

musculation??

cinder abyss
cinder abyss
shadow night
compact haven
#

lmao

cinder abyss
#

HE HAS THE REFERENCE

worthy yarrow
#

What in the hell

chrome beacon
#

Groovy uwu

cinder abyss
#

OH MY GOAAAAD IS THAT A FREAKING JOJO REFERENCE ???

remote swallow
#

why is rad doing masturbation

cinder abyss
#

πŸ—£οΈπŸ—£οΈπŸ—£οΈ

shadow night
blazing ocean
shadow night
#

Nobody ever asks why he is doing manstruation tho

cinder abyss
shadow night
worthy yarrow
#

brother

blazing ocean
cinder abyss
shadow night
worthy yarrow
#

I'm an only child

shadow night
#

mAss test my Ass

remote swallow
#

paulem ur a bit weird

cinder abyss
#

yeah

chrome beacon
#

Rad give me a list of your favorite Kotlin features

worthy yarrow
#

Oh dear

#

here we go

cinder abyss
#

nah seriously πŸ’€

worthy yarrow
#

rad has exactly 4 reasons

cinder abyss
#

BRUUUH

blazing ocean
#
  • ktor
tardy delta
blazing ocean
#

real

remote swallow
shadow night
#

Bro likes his verbosity

chrome beacon
#

Operator overloading πŸ’€

compact haven
blazing ocean
#

it's lovely

cinder abyss
#

nitro classic

worthy yarrow
#

it's almost as if kotlin is somewhat based off java

cinder abyss
#

accurate java

chrome beacon
young knoll
#

Man I wish java had objects

compact haven
#

can I even be called a kotlin dev, I've written so much kotlin but never used coroutines

worthy yarrow
tardy delta
#

doesnt mean cases were it isnt misused shouldnt be allowed

blazing ocean
shadow night
chrome beacon
#

flashbacks to C#

compact haven
#

yall have seen your CVN description yes?

tardy delta
#

glad youre not writing c, the whole stdlib "is miss used so often"

cinder abyss
#

bc you're talking about objects, I want to make a joke but I don't want to be banned of this wonderful server

blazing ocean
#

oh right another point

  • the stdlib
young knoll
#

Who’s miss used

compact haven
#

omg hte kotlin stdlib is to die for

young knoll
#

Is there a Mr used

shadow night
blazing ocean
#

FR

worthy yarrow
#

rad's only reason for hating kotlin: lsp

tardy delta
chrome beacon
blazing ocean
tardy delta
#

go brr?

compact haven
shadow night
compact haven
#

is kotlin-language-server that bad though?

blazing ocean
tardy delta
#

who even needs an lsp

blazing ocean
compact haven
#

to be fair though... why would you want to NOT use intellij

tardy delta
#

my buddy s been coding in vim without theme and syntax checker for years

compact haven
#

just enable vim controls

#

you'll be fine

worthy yarrow
#

Cuz he likes to use neovim

blazing ocean
#

and zed

worthy yarrow
tardy delta
#

zed is a piece of garbage

blazing ocean
#

no it's not

compact haven
#

zed

tardy delta
#

pulls in thousands of dependencies for the sake of why not

blazing ocean
tardy delta
#

havent found anything that i cant achieve with my current neovim setup

worthy yarrow
#

Reminds me of shading WE

blazing ocean
#

adds tokio
+20gb

compact haven
#

you're not talking about the rust editor right]

blazing ocean
#

i am

tardy delta
#

we are

compact haven
#

that's disgusting

#

why would you want to use zed vs IJ

blazing ocean
#

i don't use it for kotlin

#

i use it for FE and rust

tardy delta
#

imagine not being able to do :e ~/.config/nvim/init.lua and edit some lua nahh we got json πŸ€“

compact haven
#

Jetbrains also has an editor for both of those

worthy yarrow
#

Please

#

We're not doing lua again

compact haven
#

namely Webstorm (I just use IJ) and RustRover

blazing ocean
compact haven
#

is it? tbh havent used

tardy delta
#

lua is only good for neovim πŸ€“

compact haven
#

but I feel like JetBrains is more capable at making editors than the creators of Atom

blazing ocean
worthy yarrow
#

I remember some guy in here who was making a plugin with lua kek

blazing ocean
#

zed is extremely fucking fast and is great when it comes to rust

compact haven
#

okok

tardy delta
#

what you need rustrover for when you have vsc?

chrome beacon
#

But ok πŸ€·β€β™‚οΈ

compact haven
#

though this isn't relevant to the original topic of, why neovim for Kotlin lmao

blazing ocean
compact haven
#

like what mods have you done that you cant replicate in IJ

tardy delta
#

wha..

blazing ocean
#

tried a clean install and everything

#

works in any other editor

tardy delta
#

vsc errors with rust analyzer?

blazing ocean
#

yea

#

i only see those after saving

tardy delta
#

only issue i ever had is that it hung for hours

compact haven
#

is rust that cool

blazing ocean
compact haven
#

what is it worth learning for

blazing ocean
compact haven
#

like I feel like I'd never use it since I do backend mostly

#

and who acc writes backends in Rust

tardy delta
#

rust forces you to design your code in some way i dont like

blazing ocean
compact haven
#

isnt it too low level though

blazing ocean
#

it works great with actix

worthy yarrow
#

Rad's just different man

chrome beacon
#

I did some backend with Axum

#

Though just very basic stuff

tardy delta
#

i write all my backends in c# but ig noone asked about c#

compact haven
#

my go-to atm is kotlin with javalin, pretty simplistic

blazing ocean
#
#[delete("/server/{id}")]
async fn delete_server(path: web::Path<String>) -> impl Responder {
    let client = Client::try_default()
        .await
        .expect("failed to create client");
    let game_servers: Api<GameServer> = Api::namespaced(client.clone(), "mire");
    let pods: Api<Pod> = Api::namespaced(client.clone(), "mire");
    let services: Api<Service> = Api::namespaced(client, "mire");
    let name = &*path.into_inner();
    game_servers
        .delete(name, &DeleteParams::default())
        .await
        .expect("failed deleting game server");
    pods.delete(&*format!("{name}-pod"), &DeleteParams::default())
        .await
        .expect("failed deleting pod");
    services
        .delete(&*format!("{name}-svc"), &DeleteParams::default())
        .await
        .expect("failed deleting service");

    HttpResponse::Ok().json(Response {
        code: 200,
        message: None,
    })
}
``` fucking love it
tardy delta
#

too much .expect tbf

chrome beacon
#

Javalin is nice

blazing ocean
#

i don't unwrap

compact haven
#

ktor was nice but I found myself in the slack channel every so often with a problem

#

it wasn't as barebones as I wanted I guess

tardy delta
#

i wrote a discord backend in rust πŸ’€

#

well

compact haven
#

tf u mean a discord backend

tardy delta
#

not really backend but you get it

#

backend for client

#

partially working

#

😳

worthy yarrow
#

Someone explain to me the difference between backend/frontend I've always had a very vague definition

tardy delta
#

if im not here tomorrow you gonna know why

compact haven
#

(for someone whos never programmed in Rust)

blazing ocean
#

what is

tardy delta
#

looks pretty simple though

compact haven
#

so what is Api::namespaced, just curious

tardy delta
#

i probably wouldve thrown a service layer underneath it

blazing ocean
blazing ocean
#

it works (somehow)

compact haven
#

ight thought so because I saw Pod but wasn't sure

#

why is it like Api<XX> though

#

why is the actual type a generic

tardy delta
#

i took my api offline cuz someone tried ddossing it πŸ’€

blazing ocean
#

generic

blazing ocean
#

but yeah with generics that's much easier

compact haven
#

so is the implementation the same for every type of Api?

#

GameServer, Pod, etc?

blazing ocean
#

well

compact haven
#

there's just that few methods, CRUD?

blazing ocean
#

idek

compact haven
#

and why is client cloned for the first two invocations then not

#

I mean it makes sense

blazing ocean
#

borrow checker

compact haven
#

oh its a rust memory thing?

blazing ocean
#

yea

compact haven
#

gotcha

#

Im assuming auth is done somewhere else?

blazing ocean
#

what auth

compact haven
#

for the endpoint

blazing ocean
#

sir

#

this is an internal api

compact haven
#

oh

blazing ocean
#

it runs within k8s

compact haven
#

token gives access to all endpoints?

#

or literally no auth because its interal k8s space

blazing ocean
#

no auth

compact haven
#

I forget what its called bruh

#

what's the network layer inside of kubernetes

blazing ocean
#

cluster?

compact haven
#

hmm

compact haven
#

yep just the cluster

#

is that standard practice?

blazing ocean
#

pretty sure

compact haven
#

just seems dangerous, like if the ingress is compromised and allows outside traffic to access the internal api

#

albeit probably not likely with proper setup

blazing ocean
#

if something is compromised you're already cooked

compact haven
#

true

blazing ocean
#

you've got much bigger shit to worry about then

compact haven
#

what are you writing this internal api for, may I ask?

blazing ocean
#

my mc network

compact haven
#

just curious because I have yet to find an excuse to learn kubernetes

#

ah that seems overkill

#

LMAO

blazing ocean
#

and just for the average k3s cluster you don't need to worry about all that shit

blazing ocean
compact haven
#

minigames?

blazing ocean
#

yes

compact haven
#

nevermind then

#

that's fucking sick

#

lmk if you ever want to let me dig into ur shit lmfao

blazing ocean
#

lmao

keen charm
#

Hey!

#

Is there no UPDATE_LISTED packet in 1.18.2?

alpine cairn
#

alr I spent way too long on this so I figure I'll share if any one is interested: Cancelling the EntityToggleSwimEvent doesn't work because a lot of swimming is client side. So my solution? Just set the hunger to 6 if it was above 6. A simple solution but it works well.

worthy yarrow
#

Really weird that setSwimming / e.setCancelled didn't work tho

alpine cairn
#

It also goes well with a message like "Your armor weighs you down. You feel exhausted"

alpine cairn
worthy yarrow
#

So was this function to make players not able to swim if they are wearing some armor

alpine cairn
#

Yeah I set their gravity to 0.5 but sprint swimming was allowing me to bypass it

worthy yarrow
#

odd

#

I'm thinking that issue is caused because theres two parts to isSwimming being in water as the movement physics are already a bit different and the fact that sprint swimming is a thing

alpine cairn
#

Is checking playerMoveEvent a potential source of lag?

worthy yarrow
#

Depends what you do

alpine cairn
#

Just checking it everytime any player moves

#

is that inneficient?

worthy yarrow
#

calcs are quite slow when it comes to playermove event

#

I think conditionals might be fine

#

Considering like just 15 players, that's still 15 different events you have to deal with in most cases within seconds of each other

#

You may have 6 incoming event calls one tick, 12 more the next

keen charm
#

Hey

#

Is it okay to send packets sync?

worthy yarrow
#

I would think so

#

depends on the packet

alpine cairn
worthy yarrow
keen charm
#

It's what SkinsRestorer sends

worthy yarrow
keen charm
#

Remove, add & respawn packets and then resetting stats etc.

worthy yarrow
#

Should be fine

#

It's a ?tas question to be fair

alpine cairn
worthy yarrow
#

Me either, just saying

#

I've also seen it before

keen charm
#

Hey!

#

How do we listen to packets in newer versions like 1.19.4?

#

I want to get the pipeline but I couldn't find where I'd get it

young knoll
#

Should be the same

#

Except I believe it’s private now

keen charm
#

Do I just make it accessible then?

young knoll
#

Yea

keen charm
#

How does this look like?

hazy parrot
#

Is it actually called connection during runtime ?

#

If so,it's ok

viscid carbon
#

Doing this would be bad huh 🀣

        config.set(path, object);
        this.saveConfig();
    }```
#

Weird, putting it in the file class fixed the problem i was having. so problem solved

viscid carbon
#

i removed saveConfig()

#

it fixed my problem i was having yesterday.

#

which was it wasn't storing stuff setting values. so its something to do with my fileUtils class.

keen charm
#

Hey

#

Is it better to listen to tab completion using packets or TabCompleteEvent?

eternal oxide
#

Always API if you can

shadow gazelle
#

Not sure where else to ask this, what are the bank accounts in Vault when you're implementing an economy?

#

boolean hasBankSupport()

eternal oxide
#

many don;t implement bank accounts

shadow gazelle
#

I know but what are they?

eternal oxide
#

bank accounts are for when it is not player backed

#

like an account for a nation/clan

shadow gazelle
#

oh

eternal oxide
#

I don;t know of any plugins which use bank accounts

shadow gazelle
#

Why do most people not support that?

#

oh, that's probably why

eternal oxide
#

iConomy 5 used to have bank accounts but it was dropped

shadow gazelle
#

huh

sand spire
#

This works: player.getWorld().playSound(player.getLocation(), sound, volume, pitch);
This doesn't: player.getWorld().playSound(player, sound, volume, pitch);

How???

eternal oxide
#

is your sound a default MC sound?

sand spire
#

yeah

eternal oxide
#

no clue then, the underlying code is identical on those

sand spire
#

It's only for 1 of my accounts, maybe somehow the player was set to silent but I doubt that that stays over restarts

#

welp that was the issue πŸ’€

viscid carbon
#

omg i'm an idiot. I put my file creation in my FileConfiguration getConfig() πŸ’€

#

that was my whole problem

keen charm
#

Hey

#

I can't use UPDATE_LISTED in 1.19 Spigot

#

What seems to be the problem?

snow swan
#

!verify

undone axleBOT
#

Usage: !verify <forums username>

snow swan
#

!verify Shortaholic

undone axleBOT
#

This account is already verified!

snow swan
#

..

#

!help

slender elbow
#

you already have the role

worthy yarrow
#

His spigot name changed, he wants it reflected here

slender elbow
#

xd

#

leave and rejoin

#

idk

topaz cape
#

whats the disguised chat packet used for?

echo basalt
#

πŸ€” am I tripping or can't I reset firework stuff after the first detonation attempt

floral belfry
#

For 1.21 Is org.bukkit.ChatColor deprecated in favour of net kyori adventure?

echo basalt
#

?paper

#

bruz

#

?whereami

echo basalt
#

help I can't type

eternal oxide
#

I'd send you some new fingers but my parole officer said I had to stop doing that

worthy yarrow
#

What did you always put your real address as the return address?

floral belfry
#

guessing ChatColor is not depricated for Spigot?

worthy yarrow
#

no

floral belfry
#

ok

cedar flint
#

Why is there a limit on teleport duration of 59 or am I missing something?

echo basalt
#

okay what the actual fuck

#

firework code is so cursed

#

This causes the firework to fly forever (FireworkExplodeEvent)

#

setting the meta on the same tick causes the change to not happen

#

okay lmfao so setFireworkMeta does absolutely nothing

cold charm
#

Howdy howdy,
I've had an idea for a long while and before I jump in on it, I would like to ask if is possible with a plugin or if it would have to be a mod.

The idea is setting up a GUI for a custom item exchange.

Custom item in, Custom item out.

What I foresee being an issue is how the plugin would tell the exact item or if it would only read the parent item its attached to. Such as something being attached to the item type of a stick.

worthy yarrow
#

Since 1.13 pdc exists, so you should be able to just .clone any item that goes through this inventory?

cold charm
#

So it's possible?
That's such a relief to hear.

Thank you for your time, now I can hop on this!

worthy yarrow
#

Very possible, pdc is held by the server not the plugin, so like I said you can simply just .clone the items you need

spice burrow
cold charm
#

I was concerned it might have some limitations. But it sounds straightforward. At least much moreso than I was considering.

worthy yarrow
#

I really don't think you have to do much else but clone the input item and use that clone for the output item

cold charm
#

Originally I thought to just change it out every now and then, but I should be able to get it to read the item in and put a different item out depending, right?