#development

1 messages · Page 48 of 1

river solstice
#

ok waiting

icy shadow
#

the whole concept of dan is so fucking funny

spiral prairie
#

Good that you haven't seen any hentai written by it

#

Those are worse than your worst nightmare

river solstice
#

🫡

#

easy gpt4 access

icy shadow
#

lmao

hoary scarab
#

Didn't someone use "grandmother" and get the recipe for thermite or some shit lol

icy shadow
#

napalm

#

my grandma used to work in the napalm factory

hoary scarab
#

ah

spiral prairie
#

Yeah shits crazy

#

Love it

#

Lemme get my laptop

river solstice
#

waiting

spiral prairie
#

What your waiting for

icy shadow
#

You

#

Hurry up

#

Haven’t got all day here

spiral prairie
#

What should i do?

icy shadow
#

Get your laptop

river solstice
#

did you get it yet

#

@ me when laptop

spiral prairie
#

yes

#

got it

icy shadow
#

awesome

#

now what?

spiral prairie
#

idk what

#

publish GPTReflectionUtil

icy shadow
#

go on then

spiral prairie
#

ok

spiral prairie
#

this issue is that those maps arent stateless, wouldnt that be static abuse or sum?

icy shadow
#

technically yes

#

but

#

i think you could probably get away with it in this case without angering too many people

#

maybe

#

alternatively turn it into a class

#

i'd do that

#

but it's annoying to deal with without guice

spiral prairie
#

yeah

#

ill just keep it that way

#

should befine

#

lemme just ask GPT for javadoc

river solstice
spiral prairie
#

welp

#

cant modify final fields it seems like

minor summit
#

yes you can

#

not static final tho

spiral prairie
#

how?

minor summit
#

get field
set accessible
set field value

dense drift
#

i guess you need to make it non-final first?

minor summit
#

no

spiral prairie
#

dont work

minor summit
#

sigh

#

is it a record class?

dense drift
#

🥁

spiral prairie
#

nope normal

#

just java restrictions after 12 afaik

minor summit
#

it's most definitely possible

spiral prairie
#

yeah got it to work with unsafe

icy shadow
#

yeah i had to use unsafe on modern java

minor summit
icy shadow
#

You are lying

minor summit
#

your mother

icy shadow
#

SetInt? Since when is that a thing

minor summit
#

since forever?

icy shadow
#

WHAT

#

Oh right for primitives

#

yeah

minor summit
#

javadoc doesn't even have a @vagrant kernelce tag so yeah lol

#

epic ping

sterile hinge
minor summit
#

speak for yourself

#

i have ALL the nice things

icy shadow
#

@vagrant kernel

#

Sorry pal

minor summit
#

not really sorry, are ya

sterile hinge
#

I have nothing

dense drift
#

that's what Sir said, you have them all smh

icy shadow
#

Anyway yeah fields didn’t work for me approximately 1 week ago

#

i blame you Emily

#

And i do not forgive you

minor summit
#

i took all your accessibility modifiers

icy shadow
#

why…. why????

minor summit
#

but anyway, @spiral prairie it most definitely does work as you can see, can't really help more without any more context and info than "it doesn't work"

#

i'd like to know more about your situation

spiral prairie
#

works with unsafes

#

fine with that

minor summit
#

i am not trying to help you

#

i want to know your situation

#

you already solved your problem so idrc what you do from now on OMEGALUL

cloud panther
#

Im using sendPacket for my "SendTitle" but for some reason the message only stays for 5 seconds

#

    private void sendTitle(Player player, int fadeIn, int stay, int fadeOut, String title, String subtitle) {
        IChatBaseComponent titleComponent = ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', title) + "\"}");
        IChatBaseComponent subtitleComponent = ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', subtitle) + "\"}");
        PacketPlayOutTitle titlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.TITLE, titleComponent, fadeIn, stay, fadeOut);
        PacketPlayOutTitle subtitlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.SUBTITLE, subtitleComponent, fadeIn, stay, fadeOut);
        CraftPlayer craftPlayer = (CraftPlayer) player;
        craftPlayer.getHandle().playerConnection.sendPacket(titlePacket);
        craftPlayer.getHandle().playerConnection.sendPacket(subtitlePacket);
        }
  }
dense drift
#

Is there any specific reason why you are using packets?

shell moon
#

Can I register a listener using a papi expansion? (in my code)

#

I mean, I know I can do it by getting papi plugin instance, question is more like

#

any way to do it using PlaceholderAPI api?

#

for example: quit event, to remove the player from a map or list, etc

shell moon
#

Someone?

dense drift
#

yes you can

#

simply implement listener and papi will register/unregister it iirc

minor summit
#

true

#

it does

shell moon
#

wow!

#

that's really good

#

btw, when is clear() from Cacheable called?

#

on /papi reload or also?

dense drift
#

yeah

shell moon
#

only there?

spiral prairie
#

Just gotta fix my reposilite instance

icy shadow
#

beautiful

dense drift
spiral prairie
#

there we go

#

the better reflection library ill spam everybody with

#

even has tests

icy shadow
#

wow

#

this is so convenient and easy to integrate in my project! i'll be sure to use this

spiral prairie
#

yes it is! the new GPTReflectionLibrary!

#

only one repo! and one implementation!

#

and you always know it works!

shell moon
stuck hearth
#

How does it works

minor summit
#

well

stuck hearth
#

Thank you Emi, you're the best

shell moon
cloud panther
#

its annoying

dense drift
#

Use adventure

cloud panther
#

wdym ?

#

game mode adventure?

#

now the title stopped showing up

#

;///////////////////

river solstice
#

Game mode adventure 🥴

stuck hearth
west socket
#

I appreciate adventure for being the only functional 1.8 bossbar lib

limber hedge
#

Would it be difficult to allow for player_heads to be encated as well like a diamond_helmet?

limber hedge
#

enchanted* sorry

dusky harness
#

ah

#

I assume so

#

although u have to set it true as unsafe

#

or addUnsafeEnchantment

limber hedge
#

ok ty

dense drift
#

Heads can be enchanted but the glow doesn't show.

dusky harness
minor summit
#

ask mojang

dense drift
#

Indie Team

stuck hearth
#

Starving Indie Team*

proud pebble
dense drift
#

Poor Indie Team

forest jay
#

Using Next.js, I have a div that is scrollable, and I want to save the scroll level when the page is reloaded. Currently I am doing this: ```js
const element = document.getElementById("sidebar");
if (element) {
const scrollPosition = Number(localStorage.getItem('sidebarScrollPosition')) || 0;
console.log(scrollPosition)

// Scroll to the stored position
element.scrollTo(0, scrollPosition);

}
And then save it: js
const handleUnload = () => {
localStorage.setItem("sidebarScrollPosition", element.scrollY.toString());
};

window.addEventListener('beforeunload', handleUnload);
```I am doing this all inside a useEffect(). Currently, it saves a scroll value that does vary, but when I put it into element.scrollTo it just puts it like 1/5 down the container, no more, no less. It doesnt scroll if the value is 0 tho. What am I doing wrong?

spiral mural
#

hey, not sure why this happen but shouldn't this send a clickable message?

    ```String message = Messages.chatMessage("queue_invite").replace("%this%", player.getName());
    TextComponent textComponent = new TextComponent(message);
    textComponent.setClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/cc join " + player.getName()));
    invited.spigot().sendMessage(textComponent);```

or is the fact that I'm intergearing with the message doing something strange.

cloud panther
#

if i use jetpack what will the dependency be for "actionbarapi"

#

and TitleAPI

dark garnet
#

hi, im implementing (using shadowjar) bstats and itemnbt-api into my plugin. when i first added them, i also had their packages relocated, i completely forgot y i did this and i wanna know if its even needed 🙃 ping if reply

dark garnet
dusky harness
dark garnet
dusky harness
#

also make sure ur using java-library plugin instead of java

dark garnet
dark garnet
dusky harness
dark garnet
dusky harness
#

i think jitpack uses publishToMavenLocal anyways which I assume should still work for transitive

#

🤔

#

¯_(ツ)_/¯

#

whats ur library github?

dark garnet
#

😭

#

ok gtg to bed gn

dusky harness
#

gn

daring moss
sonic nebula
#
        double dx = distance * Math.sin(-Math.toRadians(yaw)) * Math.cos(Math.toRadians(pitch));
        double dy = distance * Math.sin(Math.toRadians(pitch));
        double dz = distance * Math.cos(-Math.toRadians(yaw)) * Math.cos(Math.toRadians(pitch));
        double nextX = x + dx;
        double nextY = y - dy;
        double nextZ = z + dz;
#

i tried to play a bit with the math formula but calculatons output is not must correct

#

but still not correct

lyric gyro
#

What would be the best way to change the color of World Border

#

as i have never done it and cant find anything useful on google

dusky harness
sonic nebula
lyric gyro
lyric gyro
sonic nebula
#

pretty sure the game has only 2 colors that are presentable which are blue and red im correct?

sonic nebula
#

and see what it does probably texturepack thing

versed carbon
#
    @Override
    public String getName() {
        return "name";
    }

    @Override
    public String getDescription() {
        return "description";
    }

    @Override
    public String getSyntax() {
        return "/command name";
    }

    @Override
    public void perform(Player player, String[] args) {
        
    }

    @Override
    public void perform(Player player, String[] args, Command command) {
        if (command.getName().equalsIgnoreCase("name")) {
            if (args.length == 1) {
                player.sendMessage("Test 1");
            }
        }
    }
}```
*Sorry miss clicked enter and it sent without being organised*

~~Whenever I remove~~

@Override
public void perform(Player player, String[] args) {

}
~~Due to not needing it, it keeps asking to either implement it again or change it to an abstract.
I've done this before and had no problem.  Why the sudden issue?~~

Nevermind, I was stupid and forgot about something I forgot to remove.
My bad.
dark garnet
dark garnet
cloud panther
#
    private void sendTitle(Player player, int fadeIn, int stay, int fadeOut, String title, String subtitle) {
        IChatBaseComponent titleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', title) + "\"}");
        IChatBaseComponent subtitleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', subtitle) + "\"}");
        PacketPlayOutTitle titlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.TITLE, titleComponent, fadeIn, stay, fadeOut);
        PacketPlayOutTitle subtitlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.SUBTITLE, subtitleComponent, fadeIn, stay, fadeOut);
        CraftPlayer craftPlayer = (CraftPlayer) player;
        craftPlayer.getHandle().playerConnection.sendPacket(titlePacket);
        craftPlayer.getHandle().playerConnection.sendPacket(subtitlePacket);
    }

```,

for some reason the text doesnt stay for more than 5 seconds
#

even if i set the "stay" to like 1000

#

meaning it should stay for 50 seconds ^

signal grove
#

might have to send it every few seconds

#

people keep saying you cant change the time through the server, so you have to repeatedly send

spiral prairie
#

Yeah

cloud panther
#
private void sendTitle(Player player, String title, String subtitle, int duration) {
        IChatBaseComponent titleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', title) + "\"}");
        IChatBaseComponent subtitleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', subtitle) + "\"}");
        PacketPlayOutTitle titlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.TITLE, titleComponent);
        PacketPlayOutTitle subtitlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.SUBTITLE, subtitleComponent);
        CraftPlayer craftPlayer = (CraftPlayer) player;
        craftPlayer.getHandle().playerConnection.sendPacket(titlePacket);
        craftPlayer.getHandle().playerConnection.sendPacket(subtitlePacket);

        Bukkit.getScheduler().runTaskLater(getInstance(), () -> {
            PacketPlayOutTitle clearTitlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.CLEAR, IChatBaseComponent.ChatSerializer.a(""));
            craftPlayer.getHandle().playerConnection.sendPacket(clearTitlePacket);
        }, duration * 20L);
    }

dense drift
cloud panther
#

its for spigot 1.8.8 not paper

dense drift
#

so?

cloud panther
#

i tried adventure yesterday, it just won't work at all

dense drift
#

adventure is available in paper by default since a certain version, but it can be used with spigot as well, just just need to shade it

signal grove
#

that will only send it one time later

#

in the runTaskLater, you should call the sendTitle function again

#

and decrement some value so it eventually hits 0 and stops repeating

dense drift
cloud panther
#

umm now the title was working, 3 minutes later stopped working ;/

#

i havent changed anything

#

even went back to the original,
was working, now it doesnt send it, i put strings through out this function it does run but no message is being shown to the player

    private void sendTitle(Player player, int fadeIn, int stay, int fadeOut, String title, String subtitle) {
        IChatBaseComponent titleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', title) + "\"}");
        IChatBaseComponent subtitleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', subtitle) + "\"}");
        PacketPlayOutTitle titlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.TITLE, titleComponent, fadeIn, stay, fadeOut);
        PacketPlayOutTitle subtitlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.SUBTITLE, subtitleComponent, fadeIn, stay, fadeOut);
        CraftPlayer craftPlayer = (CraftPlayer) player;
        craftPlayer.getHandle().playerConnection.sendPacket(titlePacket);
        craftPlayer.getHandle().playerConnection.sendPacket(subtitlePacket);
    }
signal grove
#

not sure

proud pebble
#

or atleast that should work

dense drift
#

I think you sre confusing title with action bar

proud pebble
#

the guy said it worked so i just kinda assumed it would

dark garnet
#

Just make it so that the title stays longer than the repeating task

#

So if u have a 20 tick repeating task, send the title and have it stay for 30 ticks

#

@cloud panther ^

dense drift
#

Does anyone know why this works https://github.com/gigobyte/HLTV/blob/master/src/endpoints/connectToScorebot.ts#L218 but when I try to use a similar code I can not connect to socket?

const { io } = require("socket.io-client");
const socket = io("https://scorebot-lb.hltv.org");

var initObject = JSON.stringify({
    listId: 2364909
});

socket.on('connect', () => {
    console.log("Connect");

    socket.emit('readyForMatch', initObject);

    socket.on('scoreboard', function (data) {
        console.log(new Date(), " Scoreboard: ", JSON.stringify(data));
    });
});```
On hltv.org `data-scorebot-url` is `https://scorebot-lb.hltv.org`
icy shadow
#

also p2w L

proud pebble
#

create a group with the permissions of that upgrade if its got multiple permissions then give the player the group

#

then just check for the group if they attempt to click it and deny if its true

dense drift
#

Don't reply here to config questions

proud pebble
#

was kinda hoping they had already reposted in general plugins

dense drift
dark garnet
stuck hearth
#

Tldr; what's the issue

#

You need the library at compile time and not Runtime and compileOnlyApi isn't working?

dense drift
#

I think you have to use api() from the java-library plugin if you want to shade a dependency and expose it to projects that use your api

stuck hearth
#

If they need it at runtime too then api should work

dark garnet
stuck hearth
#

It should

dense drift
#

if you use compileOnly(Api) you also need to add these libraries manually in all your projects iirc

dense drift
#

compileOnly is for when the said library is provided at runtime, e.g. spigot

pulsar ferry
#

You don't, it behaves exaclty like api but for compile time only

stuck hearth
#

You might try using gradle clean to see if that clears up the issue as well.

stuck hearth
#

So what exactly are you doing to test that this is working, just so we're on the same page?

dark garnet
#

then when i try to use a jetbrains annotation and build it gives me "package org.jetbrains.annotations" does not exist

neat pierBOT
#
📋 Your paste: Walter
https://paste.helpch.at/niquqolive

A member of staff has requested I move your message to a paste,
Most likely because it contains a config/error/code snippet.

stuck hearth
dark garnet
stuck hearth
#

I don't know too much about annotations, as I recall I had to use implementation on a set of google annotations for some weird reason, I don't know if that's the case here, I'm just not knowledgable enough.

Otherwise, it looks like it should work.

#

Your code fucking scares me Walter

#

True

cloud panther
#

relax, i swore at my self smh bots

#
    private void sendTitle(Player player, int fadeIn, int stay, int fadeOut, String title, String subtitle) {
        IChatBaseComponent titleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', title) + "\"}");
        IChatBaseComponent subtitleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', subtitle) + "\"}");
        PacketPlayOutTitle titlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.TITLE, titleComponent, fadeIn, stay, fadeOut);
        PacketPlayOutTitle subtitlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.SUBTITLE, subtitleComponent, fadeIn, stay, fadeOut);
        CraftPlayer craftPlayer = (CraftPlayer) player;
        PlayerConnection playerConnection = craftPlayer.getHandle().playerConnection;

        // Send initial title and subtitle packets
        playerConnection.sendPacket(titlePacket);
        playerConnection.sendPacket(subtitlePacket);

        // Repeatedly send title and subtitle until "stay" time is over

        int repeatDelay = 20; // Delay in ticks between sending title/subtitle packets (1 second = 20 ticks)
        int repeatCount = stay / repeatDelay; // Number of times to repeat sending the packets

        Bukkit.getScheduler().runTaskLater(getInstance(), () -> {
            for (int i = 0; i < repeatCount; i++) {
                playerConnection.sendPacket(titlePacket);
                playerConnection.sendPacket(subtitlePacket);
            }
        }, repeatDelay);
    }

#

this atleast repeats it for 1 second than it stops ;/

#
                    sendTitle(player, 0, 400, 0, getMessage("fishingTitle"), getMessage("fishingSubtitle"));```
dense drift
#

runTaskLater runs the task once after a delay

cloud panther
#

is there anything that can keep running the task, until "stay" time has passed

dusky harness
#

since you don't want to include example-plugin

stuck hearth
#

no

west socket
#

Does anyone know how to decipher a bungee spark profiler?

#

It's not displaying very much and doesnt have the correct cpu percentage adding up

cloud panther
dark garnet
dark garnet
# dusky harness wdym
include("api", "example-plugin")

project(":api").name = "AnnoyingAPI"
project(":example-plugin").name = "AnnoyingExample"
dusky harness
#

ye but im not sure if that's supposed to be part of the actual api

dark garnet
dark garnet
cloud panther
dark garnet
dense drift
#

I still suggest to use adventure LOL

cloud panther
dark garnet
dense drift
#
        Bukkit.getScheduler().runTaskLater(getInstance(), () -> {
            for (int i = 0; i < repeatCount; i++) {
                sendTitle(player, fadeIn, stay, fadeOut, title, subtitle);
            }
        }, repeatDelay);

This will send the title repeatCount times after repeatDelay, for sure not what you want.

dark garnet
cloud panther
#

good point

cloud panther
dark garnet
cloud panther
#

it was 1000

rigid mountain
#

Anyone know how to fix this error when trying to register enchants in 1.19.3? No longer accepting new enchantments (can only be done by the server implementation)

signal grove
#

are you making a mod?

rigid mountain
#

plugin

dark garnet
dusky harness
#

i think thats the command format for specific module?

#

¯_(ツ)_/¯

dark garnet
dusky harness
#

ok

#

wait

#

hold up

#

whats ur base module/project called?

dark garnet
cloud panther
#
    private void sendTitle(Player player, String title, String subtitle) {
        IChatBaseComponent titleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', title) + "\"}");
        IChatBaseComponent subtitleComponent = IChatBaseComponent.ChatSerializer.a("{\"text\":\"" + ChatColor.translateAlternateColorCodes('&', subtitle) + "\"}");
        PacketPlayOutTitle titlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.TITLE, titleComponent);
        PacketPlayOutTitle subtitlePacket = new PacketPlayOutTitle(PacketPlayOutTitle.EnumTitleAction.SUBTITLE, subtitleComponent);
        CraftPlayer craftPlayer = (CraftPlayer) player;
        PlayerConnection playerConnection = craftPlayer.getHandle().playerConnection;

        // Send initial title and subtitle packets
        playerConnection.sendPacket(titlePacket);
        playerConnection.sendPacket(subtitlePacket);
        int repeatDelay = 80; 
        int repeatCount = 5;
        for (int i = 0; i < repeatCount; i++) {
            Bukkit.getScheduler().runTaskLater(getInstance(), () -> {
                sendTitle(player, title, subtitle);
            }, repeatDelay);
        }
``` now there is still a "blinking" happening"
dark garnet
#

u should be using:

uneven lanternBOT
#
@Deprecated @NotNull
BukkitTask runTaskTimer(@NotNull Plugin plugin, @NotNull BukkitRunnable task, long delay, long period)
throws IllegalArgumentException, IllegalArgumentException```
Deprecation Message:

Use BukkitRunnable.runTaskTimer(Plugin, long, long)

Returns:

a BukkitTask that contains the id number

Parameters:

plugin - the reference to the plugin scheduling task
task - the task to be run
delay - the ticks to wait before running the task
period - the ticks to wait between runs

Throws:

IllegalArgumentException - if plugin is null
IllegalArgumentException - if task is null

dark garnet
# dusky harness interesting

i dont even know where my api is getting the annotations cause it still works even when i remove it from the build file bruh (and its also using an older version that whats in the build file [23.0.0])

#

isnt that going to cause an infinite loop?

#

yeah but it will just keep creating new tasks cause ur recalling the method

cloud panther
#

would that work

dark garnet
#

yeah just have 1 method to send a title normally and another to send a repeated title (which calls the normal title method)

dark garnet
dusky harness
#

🤨

#

oh ur relocating

#

what if that's the issue

#

¯_(ツ)_/¯

#

maybe shadow messes with the transitive IDkkkkkkkkkkkkkkk

#

maybe tmr ill fork ur repo and try some stuff out

dark garnet
dusky harness
#

if you haven't solved it by then

dusky harness
#

¯_(ツ)_/¯

sonic nebula
#

i think you should learn java first and not use chatGPT or what ever wrote u that shit...

stuck hearth
#

No need to beat a dead horse

sonic nebula
#

because i clearly can see that you have no clue or know eldge in general who the fk makes a ul in pr instead of st, code make no sense gib , xy problem people here are not meant to be spoon feed but give pseudo code.

sonic nebula
spare marsh
#

Would a dev help me modify an existing plugin? It’s a public plugin on GitHub.

sonic nebula
sonic nebula
#

creative way to delay a loop?

#

like without making it depending on server ticks

#

oh wait

#

actually yeah

#

i mean still same question lets say i loop now my goal is too loop once every 20 ticks now since its bukkit ii cant put theard on sleep server will freeze or blow up or somethng single theard shit software anyway, and as well without using

#

hmm bukkit scheduler

#

yeah so any suggestions?

#

without recalling method after X seconds using bukkit scheduler as well

#

like updating for next check

river solstice
#

schizo rant

sonic nebula
#

u ok?

river solstice
#

are you

sterile hinge
#

idk what you're trying to achieve but it's most likely a non-issue

sonic nebula
#

i can do it via creating theards and using them or bukkit tasks

#

now i think of other way

#

or even using runnable and list to performe it

#

but i want to make inside the self method a delay

sterile hinge
#

well that's not how programming works

dense drift
#

Thread.sleep kek

sonic nebula
#

anyway i do async task later after each check and re running method with new values

sonic nebula
#

so classic

sonic nebula
#

hok me up

proud pebble
sonic nebula
proud pebble
#

and each tick is 50ms, i doubt you will need to have it run more then that

proud pebble
#

and set the delay to whatever you wan

dark garnet
#

What the heck happened did someone delete all their msgs??

icy shadow
#

?

minor summit
#

?

forest jay
#

?

dark garnet
sonic nebula
dark garnet
spare marsh
spiral prairie
#

You need to have all the required tags

#

Barry should have sent them

#
#

Here

forest jay
#

If I do inventory.removeItem(), and input an itemstack with an amount of 1, will it remove 1 item from any stack in the persons inventory, or will it search for a stack of 1?

dense drift
#

It will try to remove 'as much as possible' from the types and amounts you give as arguments.

#

It probably ignores the amount and compares the items with ItemStack#isSimilar

forest jay
#

I read that, but it isnt actually doing that

#

I am trying to remove an item from a stack, and it just ignores it

forest jay
#

I was wrong, it actually does remove 1 from a stack

#

I was just stupid and not actually running the inventory.removeItem() method

sonic nebula
dark garnet
#

@dusky harness i forgot to ping u yesterday 🙃

dusky harness
dark garnet
dusky harness
#

seems like u removed a bunch of stuff such as the group id, version, and name of the root project
it seems like you also disabled the build tasks of all of the projects (root and modules)?
I re-added them, added ```kt
publishing {
publications {
create<MavenPublication>("maven") {
groupId = "com.github.dkim19375"
artifactId = "annoying-api"
version = project.version.toString()

        from(components["java"])
    }
}

}

#

oh and also

#

implementation("com.github.dkim19375.annoying-api:api:57d8aade4e")

#

this is what i did

#

or I can try and PR

#

actually can I PR

dark garnet
# dusky harness this is what i did

what about com.github.dkim19375:annoying-api tho? cause i dont need com.github.dkim19375.annoying-api:example-plugin, so it'd just be easier to have the prior

dusky harness
#

so I can become contributer

#

😃

dusky harness
#

lemme see

dark garnet
dusky harness
#

including the api module

#

I also removed shadowjar but you might want to add it back and experiment?

#

idk

dark garnet
dusky harness
#

personally I just make them compileOnly

#

and so if the user wants to use nbtapi features of the api

#

then they include nbtapi manually

#

its kinda messy but im the only one that uses my api so

#

¯_(ツ)_/¯

dark garnet
#

same with me, and i just wanna have the least amount of stuff i gotta do for each project

dusky harness
#

it'll also include example-plugin

#

but thats a minor issue

#

i think

pulsar ferry
#

Don't shadowJar libaries/api unless absolutely needed, the maven system uses transitive dependencies for that, it publishes paths to find the included dependencies and it all gets resolved when including your lib/api

dusky harness
#

actually it might include plugin.yml and that stuff too

thick shadow
#

Does anyone know how to use an oraxen item as icon in deluxemenus?

dusky harness
#

wait

#

yeah I agree with matt

#

@dark garnet can I try to PR

#

i want contributer status pleading

#

lol

dark garnet
#

wait im confused, y exactly should i not shadowJar?

dark garnet
#

but then i have to have the things installed separately no?

#

or have them declared in each project

dusky harness
#

yes

dark garnet
#

that'll be so annoying tho cause all of my plugins use bstats Sadge

dusky harness
#

make a gradle plugin 😌

#

lol

#

or more seriously

dark garnet
#

how 😭

dusky harness
#

theres like this gradle thingy

#

feature

#

that lets u do smth

#

idk

#

i haven't used it

#

i just made DkimGradle™️ instead

dark garnet
#

what

dusky harness
#

¯_(ツ)_/¯

#

documentation was required in order to post to gradle plugins repo 🥴

#

but like

#

ik some people here use it

#

ik matt does

#

not dkimgradle

#

the other gradle thing i was talking about

dark garnet
dusky harness
#

i cant find

#

idk if it exists

dark garnet
dusky harness
#

i might be mixing it up

dark garnet
#

also not shading means i'll have to relocate in every project

dark garnet
dusky harness
#

u sure?

dark garnet
#

yeah ur not even using the root project one when using com.github.dkim19375.annoying-api:api

#

then change the api module one to "com.github.dkim19375:annoying-api

#

so basically ur solution is to just not shade 🙃

dusky harness
#

disabling tests is fine

#

but not the classes and jar

#

prob

#

i haven't tested

#

¯_(ツ)_/¯

dark garnet
#

i really really really dont wanna have to declare dependencies in all of my projects r u sure its required 😭

dark garnet
dusky harness
dusky harness
#

so to prevent any future issues

#

¯_(ツ)_/¯

dark garnet
dark garnet
#

@dusky harness i figured out the main issue, it was literally just the disabling of tasks in subprojects in root build.gradle.kts 😭

dusky harness
#

💀

dusky harness
#

ye id remove all that

#

it would likely only save milliseconds of build time (or less)

dark garnet
#

yeah upon removing it, the dependenices r now added to the pom

#

also removing the root level disabling thing too

dusky harness
dark garnet
#

@dusky harness so is there a way to create a gradle plugin to automatically include some repositories?

#

or would i have to do something like u have using enums

dark garnet
dusky harness
#

currently 24 repos in the enum

#

🙃

dusky harness
#

especially ones that don't actually modify anything besides run extra code (which is what mine does)

#

hardest part is uploading them to gradle plugins repo

dusky harness
#

but I mean you dont need an enum

#

what i used to do is just copy and paste a whole list of repos throughout my projects

#

some of my projects still have that probably

dense drift
dusky harness
dense drift
#

I wouldn't be surprised if they can be published to a normal maven repo

dusky harness
#

oh yeah maybe

#

hm

dark garnet
#

why is implementation being transitive 🙃

#

or at least runtime transitive

dusky harness
dusky harness
#

huh

#

jetbrains has tutorials on this?

#

interesting

dense drift
#

Yeah they have for a lot of things

#

Wait nvm, thats for a normal java lib

dusky harness
#

wdym

#

oh

dark garnet
dusky harness
#

well

#

if u dont want to shade it

#

then it shouldn't be implementation, i think?

#

or do you just mean not to be transitive

dark garnet
#

oh 💀

dusky harness
#

bc then i dont think u can with shadow

dark garnet
#

i removed shadow

dusky harness
#

oh

dark garnet
#

wait no i need shadow

dusky harness
#

wut

#

alr

dense drift
#

Does implementation() make dependencies accessible? I thought only api() does that

dark garnet
#

very strange

dusky harness
#

ohhh

#

yeah thats intended

#

my brain wonky

#

im gonna go to bed

dense drift
#

Whats the problem with them being transitive though? Isnt that why you shade them?

dark garnet
dark garnet
dusky harness
#

we dont talk about that

#

lol

dark garnet
dark garnet
dusky harness
#

oh

#

wait

#

which versions

dark garnet
#

all of the X.X.0 and more

dusky harness
#

oh

#

well

#

too lazy to type all that out 🥲 🥲

dark garnet
#

ill just add them 🙄

dusky harness
#

lol

dark garnet
#

i guess u wont be getting that contributor status after all, and i will!!! 😈

dusky harness
#

😭

#

the tables has turned

#

the tides has turned?

#

idk

#

something has turned

#

!

dark garnet
#

the turns have tabled i think

dusky harness
#

(╯°□°)╯︵ ┻━┻

dark garnet
#

┬─┬ノ( º _ ºノ)

dusky harness
#

i forgot discord's new font messed those up

#

¯_(ツ)_/¯

dark garnet
#

whats the downside of having tons of repositories (including unused ones)?

dusky harness
#

but other than that i dont think theres other downsides

#

since dependencies are cached and the speed of finding the dependency shouldn't be impacted too much

sharp hemlock
#

Sign#setEditable is is only strictly on restricted in the event and nothing else?

hoary scarab
#

So I am copying the code from the allowBuild method in GriefPrevention but I get this error on the event...
The constructor Claim.CompatBuildBreakEvent(Material, boolean) is not visible

hoary scarab
#

Anyone know a method that doesn't require async and can just take the params Player and ClaimPermission? (GriefPrevention API)

tired olive
#

what

hoary scarab
#

GriefPrevention runs an event when checking perms... I want an immediate answer.

#

Wait... I think Claim.hasExplicitPermission(Player, ClaimPermission) will work...

tired olive
#

u coulda at least said what the method u were looking for did lmao

hoary scarab
#

Discord's API is lagging again lol

hoary scarab
tired olive
#

u still never said what u wanted method u were looking for but ok

hoary scarab
tired olive
#

?

hoary scarab
tired olive
hoary scarab
#

I already found the method @dense drift I don't think sparky is reading though

hoary scarab
tired olive
#

that's just where you coppied the event constructor call from

hoary scarab
#

🤷 I already figured out the method I need. I'm not repeating myself again.

minor summit
signal grove
#

Async permission checks would be god awful

#

The event is not the check itself, it’s the event that is prompting the check

#

Not sure why it does that though

minor summit
#

yeah but none of that is async lol

hoary scarab
#

"Can't" be ran async. I thought my checks were sync but forgot I switched them.

#

ClaimPermissionCheckEvent may only be triggered synchronously.

marble heart
#

all you smart ppl here is it possible to change the actions of the buttons in esc?

proud pebble
marble heart
#

ye i was hoping for something server-side cause having the players to install a mod is meh

proud pebble
#

well the buttons can only be modified using a clientaide mod

dusky harness
#

The most u can do server side is use a resource pack

proud pebble
#

it cant change the function of the buttons but can change the look of them somewhat

marble heart
#

ye ik i ve changed it that's why i was wondering :/

worn jasper
#

Uhm so you can use ItemStack.serialize() to serialize an item and store it in a yaml, but how would you get it from the yaml and deserialize it? I know there's the method but how do you get the map require from the yaml? Should I just get it as an object and cast it?

minor summit
#

config.getItemStack("blah")?

worn jasper
#

I am not using the bukkit configs

#

so, that method doesn't exist

proud pebble
worn jasper
#

I know there's the method but how do you get the map require from the yaml? Should I just get it as an object and cast it?

proud pebble
#

oh i see

dusky harness
#

you'd probably have to make your own ConfigurationSerializable serializer

dusky harness
#

only spigot lib recognizes ConfigurationSerializable serialize() and deserialize() methods

proud pebble
#

id assume you'd have to recreate the map yourself

worn jasper
#

Like, if I get it and cast it to the map the deserialize method uses, wouldn't it work?

worn jasper
dusky harness
#

it can't just serialize the fields

worn jasper
#

what? I am confused...

#

wdym it wouldn't know?

dusky harness
#

like

dusky harness
worn jasper
#

serializing legit works and is perfectly fine in yml

#

lol

worn jasper
#

it's what I have been speaking about

dusky harness
#

other than spigot config, it won't know how to serialize those Objects

proud pebble
#

if your using itemstack's seralize then you would know how your saving it, which then it probably wouldnt be difficult to do the opposite

worn jasper
#

my brain is not braining right now

dusty frost
worn jasper
#

the what now

dusky harness
#

its yml so I assume they want it to be editable

#

or

worn jasper
dusky harness
worn jasper
#

since it's only one thing

dusky harness
#

using the nbt thingy

dusty frost
worn jasper
#

no need for db or anything

dusty frost
#

which is easier to store

#

and more efficient

dusky harness
#

oh then yeah use what star said

#

if ur on paper

#

if not then either some reflection into nms (?) would be required ig

dusty frost
#

or just copy paste the methods from Paper and put em in your plugin lol

worn jasper
#

is that on 1.18.2 paper?

dusty frost
#

yes

dusky harness
#

yeah

dusky harness
#

does it not require any nms?

worn jasper
#

hmm, would I go about storing the byte array though?

dusty frost
#

don't think so

dusky harness
#

does spigot have a method already

dusty frost
worn jasper
#

Using SimplixStorage, which only provides getByte and getByteList which I could convert to an array? maybe?

dusty frost
#

yeah byteList sounds perfect

worn jasper
#

or I could convert the itemstack to base64?

dusty frost
#

eh

worn jasper
#

although that doesn't sound efficient

#

right?

dusky harness
#

oh yeah it uses Bukkit.getUnsafe().deserializeItem

#

and serializeItem

dusty frost
#

it's not great

worn jasper
dusky harness
#

which is ironically less unsafe than spigot's own serialize method I'm pretty sure?

#

¯_(ツ)_/¯

dusky harness
worn jasper
#

bruh

dusty frost
#

oh yeah huh I guess it uses an internal thing

#

well not big deal if you're not supporting spigot

dusky harness
#

well i mean

dusky harness
#

so

dusty frost
#

It uses net.minecraft.nbt.NbtIo

dusky harness
#

oh u mean the bukkit method?

worn jasper
#

bruh moment

dusty frost
#

bro discovers wrapper types

dusky harness
#
@NotNull
public static ItemStack deserializeBytes(@NotNull byte[] bytes) {
    return org.bukkit.Bukkit.getUnsafe().deserializeItem(bytes);
}

@NotNull
public byte[] serializeAsBytes() {
    return org.bukkit.Bukkit.getUnsafe().serializeItem(this);
}
```bc this is what paper uses
worn jasper
dusky harness
#

which i think is accessible on spigot

dusky harness
#

has to eventually lead into CB and NMS

dusty frost
#

i mean not necessarily

#

you can get all data about an ItemStack through public API methods

dusky harness
#

oh

#

ye

dusty frost
#

could always use the old BukkitObjectInputStream

#

this was my inspiration when I was making a data synchronization plugin

worn jasper
#

Think we just found out paper needs someone to PR a better way to do this lol

dusty frost
#

well they have PR'd a better way to do this, it's called ItemStack#serializeAsBytes or whatever

worn jasper
#

an even better one

dusty frost
#

what could be better lol

worn jasper
#

idk

#

lol

#

but, there's always better

#

😉

dusky harness
#

it uses minecraft's own nbt serialize method 🥲

river solstice
worn jasper
#

^^

#

fr

#

instead of bytes, bits

#

xD

dusty frost
#

wait until you find out what bytes are made out of

worn jasper
#

sadly very aware that 1 byte is 8 bits

#

or 2 nibbles

dense drift
#

Serialize as 1s and 0s

worn jasper
#

wait is it nibbles or nipples?

#

feeling I am mixing two different words

#

confusion

signal grove
#

7 byts make 1 bites

river solstice
#

1 bite of what

signal grove
#

🍪

river solstice
#

🦧

worn jasper
#

uhhhh can I add an itemstack to a players inventory with an amount bigger than 64?

#

Will it separate it into different stacks automatically? or....

proud pebble
worn jasper
#

how would I add like 1k items to my inv then?

#

would I have to use a loop or smt?

dense drift
#

1k items is about 15.5 stacks

worn jasper
#

yeah so loop it and give 15.5 stacks?

dense drift
#

loop what?

#

You can create a stack with amount = 1000 and the game will split it accordingly

dusty frost
#

oh it will? that's wild

worn jasper
#

Oh, Luna said it wouldn't

#

so I was confused

#

lol

dusty frost
#

Try It And See™️

worn jasper
#

true

#

but valorant first

dense drift
#

I've actually never tried an amount that big, but I would expect it to work

forest jay
sonic nebula
#

Is there such a thing moving a particle?

cerulean birch
#

am i the only one experiencing a minecraft development intellij plugin problem

spiral mural
cerulean birch
#

my issue is that the plugin throws an exception within intellij every time i attempt to use it to make a new project, i feel like this would be pretty noticeable if i wasnt the only one

spiral mural
#

not sure, seem strange to me.

cerulean birch
#

agreed

spiral prairie
spiral prairie
dusky harness
spiral prairie
#

always

#

maybe try updating the plugin

sonic nebula
#

api

#

how about making it diissapear after x ticks

#

is there such a thing?

#

im using packets.

spiral prairie
#

No

sonic nebula
#

shit god damn

fading stag
#

I was reading some open source vanish plugin's source code and I saw these lines:

val prePlayerVanishEvent = PrePlayerVanishEvent(player, onJoin)
        Bukkit.getPluginManager().callEvent(prePlayerVanishEvent)

if (prePlayerVanishEvent.isCancelled) return

does callEvent waits for all of the event listeners do their job if any listener wants to cancel the event let it done and then continue?

dense drift
#

Everything is done sync, so it will wait

forest jay
#

Minecraft Development is updated for the latest version of IJ though

spiral prairie
#

¯_(ツ)_/¯

#

im not using the plugin

#

kind of sucks, except fabric for mixins

mellow pond
#

i dont think it sucks

hazy nimbus
#

It's kinda useless if you're developing plugins

#

It's maybe useful for creating new projects, but then I can't think of a use for it

tight junco
#

if you're just starting to make plugins its aight i think

#

but there's a certain point where that plugin will not generate things the way you need it to so its not worth

minor summit
#

your mother

sudden sand
#

Hey guys

#

I'm seeking a way to save a lot of data at a fixed rate

#

does anyone have an idea of the algorithm I should follow ?

#

because if I run a timer of every 15 sec and it saves 403 things into database even if it's async it will consume a lot of CPU

sterile hinge
#

you can't do work without doing work, not sure what you're trying to achieve here

icy shadow
#

you can keep a track of which objects are "dirty" (have been modified) to avoid needing to persist all the entries

#

but i think given that you can upsert 403 objects in a single query i dont think you need to worry about it too much

#

or even if you did it across multiple queries

dense drift
#

Does anyone know if there's a method on the ItemsAdder API that I can use to set a texture to an item? I know I can simply set the CustomModelData, but I kinda prefer names ("fire-sword") over magic numbers

mellow pond
#

magic numbers are cooler

#

change my mind

#

69420, 69421, 69422

#

etc

grave thorn
#

Hi Im trying to set up a custom GUI in PaperMC, and I have a custom resource pack with a gui image thats been applied to a font, but I was wondering how I add the font to the menu. I make it into a component but menu titles can only be strings right?

worn jasper
#

how do people display "hats" models with plugins? is it an entity?

dusky harness
stuck hearth
#

When the psychedelics wear off and you realize you've been wearing a slightly damaged sword the whole time

versed carbon
#

I was trying to set the color of a leather chestplate but for some reason isn't letting me use
chestplateMeta.setColor();

ItemMeta chestplateMeta = chestplate.getItemMeta();
chestplateMeta.addEnchant(Enchantment.MENDING, 1, false);
chestplate.setItemMeta(chestplateMeta);```
I checked [https://hub.spigotmc.org/javadocs/spigot/org/bukkit/inventory/meta/LeatherArmorMeta.html] and a couple of tutorials on YouTube and I can't see anything wrong. Any one able to help?
shell moon
#

show current code where you use the setColor

sour thistle
versed carbon
#

Thanks I'll give that a try tomorrow 🙂

worn jasper
#

What's better in theory, having one event handler handling everything or several event handlers (listening to the same thing) but doing different things?

#

In theory wouldn't several add boilerplate if they all had similar checks

torpid raft
#

imo its just a matter of preference

#

i think there's a benefit to having multiple event handlers where you don't have to modify existing code to add an additional thing

#

but you can also make your own system for managing that well with only a single listener

worn jasper
#

hmm true, will see, thanks

river solstice
#

Anyone familiar with git ci/cd?

name: Node.js CI

on:
  push:
    branches: [ "main" ]
  pull_request:
    branches: [ "main" ]

defaults:
  run:
    working-directory: DiscordBOT

jobs:
  build:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        node-version: [14.x, 16.x, 18.x]
    steps:
    - uses: actions/checkout@v3
    - name: Use Node.js ${{ matrix.node-version }}
      uses: actions/setup-node@v3
      with:
        node-version: ${{ matrix.node-version }}
        cache: 'npm'

    - name: Install dependencies
      run: npm install
      working-directory: ./DiscordBOT
      
    - name: Build with TypeScript
      run: npm run build
      working-directory: ./DiscordBOT
#

This is the structure of the project

#

for some reason I get an error:
Dependencies lock file is not found in /home/runner/work/KoridoriusCore/KoridoriusCore. Supported file patterns: package-lock.json,npm-shrinkwrap.json,yarn.lock

#

KoridoriusCore is the repo name

icy shadow
#

I mean

#

Is there a lock file present?

river solstice
#

/home/runner/work/KoridoriusCore/KoridoriusCore is the wrong dir
it should look in /home/runner/work/KoridoriusCore/DiscordBOT, no?

#

even though working-dir is defined

#

ok, cool, found the issue

#

turns out the problem with setup-node, it had wrong cache-dependency-path, fixed with:
cache-dependency-path: DiscordBOT/package-lock.json

icy shadow
#

Epic

versed carbon
#
@EventHandler
    public void LichKingsCrownEvent(PlayerToggleSneakEvent playerToggleSneakEvent) {
        Player player = playerToggleSneakEvent.getPlayer();
        PlayerInventory inventory = player.getInventory();

        ItemStack itemStack = new ItemStack(Material.GOLDEN_HELMET, 1);
        ItemMeta itemMeta = itemStack.getItemMeta();
        itemMeta.setDisplayName(ChatColor.translateAlternateColorCodes('&', "&cLich Kings Crown"));
        List<String> lorelist = new ArrayList<>();
        lorelist.add(ChatColor.GRAY + "Boosts the wearers processing speed, making the world around you seem like it's in slow motion.");
        lorelist.add(ChatColor.GRAY + "To activate the effect sneak.");
        lorelist.add(ChatColor.translateAlternateColorCodes('&', "&7[Dropped from &cLenny The Lich King&7]"));
        itemMeta.setLore(lorelist);
        itemMeta.setUnbreakable(true);
        itemMeta.addEnchant(Enchantment.PROTECTION_ENVIRONMENTAL, 4, false);
        itemMeta.addEnchant(Enchantment.WATER_WORKER, 1, false);
        itemMeta.addEnchant(Enchantment.OXYGEN, 3, false);
        itemMeta.addEnchant(Enchantment.DURABILITY, 3, false);
        itemMeta.addEnchant(Enchantment.MENDING, 1, false);
        itemMeta.addItemFlags(ItemFlag.HIDE_UNBREAKABLE);
        itemMeta.addItemFlags(ItemFlag.HIDE_ENCHANTS);
        itemMeta.addItemFlags(ItemFlag.HIDE_ATTRIBUTES);
        itemStack.setItemMeta(itemMeta);


        if (player.isSneaking()) {
            if (!inventory.getHelmet().equals(itemStack)) {
                return;
            }
                    if (lichKingsCrownEventCooldown.containsKey(player.getName())) {
                        if (lichKingsCrownEventCooldown.get(player.getName()) > System.currentTimeMillis()) {
                            long timeleft = (lichKingsCrownEventCooldown.get(player.getName()) - System.currentTimeMillis()) / 1000;
                            player.sendMessage(ChatColor.GRAY + "Your brain has been overworked! Wait another " + timeleft + " seconds before you can overclock again!");
                            return;
                        }
                    }
                    lichKingsCrownEventCooldown.put(player.getName(),System.currentTimeMillis() + (30 * 1000));
                        for (Entity entity : player.getNearbyEntities(10, 256, 10)) {
                            if (entity instanceof LivingEntity) {
                                LivingEntity livingEntity = (LivingEntity) entity;
                                livingEntity.addPotionEffect(new PotionEffect(PotionEffectType.SLOW, 200, 0));
                                livingEntity.addPotionEffect(new PotionEffect(PotionEffectType.SLOW_DIGGING, 200, 0));
                                player.addPotionEffect(new PotionEffect(PotionEffectType.SPEED, 200, 0));
                                player.addPotionEffect(new PotionEffect(PotionEffectType.FAST_DIGGING, 200, 0));
                    }
                }
            }
        }
    }```
I've been getting this error in console and I finally got round to looking at it.
Basically 
```Where the issue is:
if (!inventory.getHelmet().equals(itemStack)) {
                return;
            }```
Always seem to be returning null. I've tried a few different things and all it's achieved it shortening and simplifying my code (which is great but still not what I need).
Can someone give me a nudge in the right path to fix this?
hoary scarab
versed carbon
#

Thanks a lot! 🙂

hoary scarab
versed carbon
#

it should only effect anything when a player shifts tho? or am I wrong?

hoary scarab
versed carbon
#

It shouldn't be creating the item? It's only looking to see if that item is in the helmet slot. Atleast that's how I meant it to be.
Or do you mean When it's looking for that item it 'makes it' and then compares?

proud pebble
hoary scarab
proud pebble
#

something that might be better is adding an nbt tag to the item to identify the item instead of checking if the item is the same as that

hoary scarab
#

Should do something like

ItemStack crown = null;
public ItemStack getCrown() {
    if(crown != null)
        return crown;

    //Create item
    crown = item;
    return crown;
}
versed carbon
#

I was using enchants before. but it didn't feel reliable.
Is there a way of adding some invis text or something that I can check for.

hoary scarab
versed carbon
proud pebble
#

pdc == persistent data container btw

#

if your trying to look it up on the javadocs

versed carbon
#

I'm going to have to do some googling then 🙂 Thanks for all your help. This'll be fun.
Also last question. Would it be possible to create one big document for all my items using persistent data container?
Part of my plugin is a 'kit' feature. and that class is so messy looking.

#

ah no. I think I misunderstood something when reading about this before.

proud pebble
#

if your writing kits you might be better off creating json files or smth for each kit

#

instead of hardcoding it

versed carbon
#

I'll look into that too then 🙂
Would it be better efficiency wise? or is it just better looking? Because I've already almost finished.

proud pebble
#

well it means you dont have to hardcode a bunch of kits

#

thats if you want to write something to parse the kits or not

versed carbon
#

I don't need it to be changeable 🙂 not yet anyway. This is for personal use for now. Thanks 🙂

proud pebble
#

well its still something to consider in the future, even on personal projects creating and parsing files instead of hardcoding is usually a good idea depending on what you are changing

#

with your on disgression of course

upbeat pawn
#

Hi, I'm a setup creator and I use the DeluxeChat plugin for one of my setups.
Is there a problem uploading that plugin inside the /plugins folder because it is no longer possible to buy it?

proud pebble
#

deluxechat is dead for a reason

plain glacier
grave thorn
#

Nah I didnt

plain glacier
#

LUCKY i am also on the quest to figure this out

#

i got that working but my question is what if I wanted to make more of them, what font characters do i use? : ' )

grave thorn
#

I think its possible in Paper 1.20 because the API supports Components in menu titles

#

But in 1.19 and below i think you need to use some NMS stuff for sending packets to the user

plain glacier
#

its all so complicated

grave thorn
#

Wdym, you can use any character

#

Oh so ur using Deluxemenus?

#

Yeah theyll be using NMS i assume

plain glacier
#

i had it workin before and now its just "?????"

wind tapir
#

Is there anyone that knows how to show more than 16 characters in the prefix ? I used the prefixes with scoreboard but it's blocked to 16

#

( in the nametag )

dire flint
dire flint
#

im confused

wind tapir
dire flint
#

i dont know where put what

wind tapir
#

what are you using ?

dire flint
#

ye

#

but i want to use external plugin

wind tapir
#

ok so you got the pom.xml, right ?

dire flint
#

i want to have on 2 plugins

wind tapir
#

look

dire flint
#

1 plugin
1 core plugin

wind tapir
#

if you're using a local lib
<dependencies>
        <dependency>
            <groupId>org.example</groupId>
            <artifactId>whateveryouwant</artifactId>
            <version>whateveryouwant</version>
            <systemPath>PathToPlugin</systemPath>
            <scope>system</scope>
        </dependency>
    </dependencies>
if you're using a lib from internet ( it can be found on the docs of the plugin you want to use )
    <repositories>
        <repository>
            <id>spigot-repo</id>
            <url>https://hub.spigotmc.org/nexus/content/repositories/snapshots/</url>
        </repository>
    </repositories>

    <dependencies>
        <dependency>
            <groupId>org.spigotmc</groupId>
            <artifactId>spigot-api</artifactId>
            <version>1.8.8-R0.1-SNAPSHOT</version>
            <scope>provided</scope>
        </dependency>
    </dependencies>
dire flint
#

local lib means in project folder .jar?

wind tapir
#

C:/Users/varii/Desktop/Java Spigot/plugin.jar

dire flint
#

so i cant make like plugin takes methods from another plugin in server

wind tapir
#

you put the libs in the pom.xml

wind tapir
#

than you initialize the main variable

dire flint
#

how it works

wind tapir
#

if it's a minecraft plugin you do just that:

#

( you have to put the plugin in your server )

#

MainClassOfPlugin main = Bukkit.getPluginManager().getPlugin("PluginName");

dire flint
#

then it will worK?

#

but i need add static?

wind tapir
#

then to use the methods of the plugin you have to do

#

main.method

wind tapir
dire flint
#

but i i don t have methods from that main method

#

only like "default" not my own

wind tapir
dire flint
#

in main class i have registerCommands method but in another plugin when i get from pluginmanager i dont have the method

dusky harness
#

i haven't checked combatlogx yet

#

so you don't need to download the jar or anything

dire flint
#

so i add core plugin jar file to my website then i download through maven?

dusky harness
dusky harness
#

you don't have to download anything

#

maven handles it for you

dire flint
#

ye

#

maven downloads all things to use jar file

#

right?

dusky harness
#

uhhhhhhhhhh

#

if u want u can send me ur pom.xml

#

and I can edit it and show you what I changed

dusky harness
dire flint
#

i cant send file

dusky harness
#

?paste

neat pierBOT
#
FAQ Answer:

Paste Services
When asking for help with a config/menu/code issue please use our paste bin:
(we prefer it over pastebin.com)
HelpChat Paste - How To Use

dire flint
dusky harness
#

but first, copy and paste this repository into the <repositories> section

#

like how you have spigotmc-repo, sonatype, and placeholderapi repos

#

then add these two dependencies

#

like how you have spigot-api and placeholderapi

#

then once you do that, it shows you how to use the api if you scroll down further

dire flint
#

okkkk thanks

dire flint
#

?

wind tapir
dire flint
#

i want make dependency

shell moon
#

so others use your dependency?

dire flint
#

yes

#

or i can make local

broken elbow
#

there's also the option to host on other repositories like maven central. not sure what the requirements are to get on there tho.

dusky harness
#

requires a VPS though

#

u can also use maven central buttttttttt

pulsar ferry
#

Reposilite is very light, you can run it on very cheap vps

dense drift
#

Talking abot reposlite, update it @pulsar ferry smh

pulsar ferry
dense drift
broken elbow
dusky harness
#

oh

broken elbow
#

if only you could read. I mentioned that as well

dusky harness
#

yeah

#

i can't read

#

👍

dire flint
#

and how to send compiled jar file to ftp server

broken elbow
#

you use the maven publish plugin. there's one for maven and one for gradle

dire flint
#

how to install

#

i use maven

hazy nimbus
# pulsar ferry Reposilite is very light, you can run it on very cheap vps

I love it, I've used nexus before and I always felt like I was working against it, not with it. Few examples of issues I encountered in the few days of using it:

  • cannot upload anything not ending with -SNAPSHOT to maven-snapshots, can not be configured
  • if you click on an archive in the browser, you can see the IP of the uploader. This can not be disabled in the config. It's not much of an issue for CI, but it's quite an issue when I'm manually uploading API JARs for plugins that do not have repos.
dusky harness
#

if you click on an archive in the browser, you can see the IP of the uploader.
wait what

#

why 💀

worn jasper
#

guys... help?

#

gotta replicate this armorstand

#

so kinda need help with the eulerangles used in it

#

I do have the plugin but it's totally obfuscated lol

#

(rewriting a custom plugin for a client)

hazy nimbus
#

of course, the issue is behind their JIRA instance login

#

And also, it was laggy and slow as hell (and also consuming several GBs of RAM on my server)

#

On the other hand, reposilite

#

Quick and snappy UI, only eats 300MBs of RAM on my server.

dusky harness
#

in maven central it seems to not show IP even though though it uses sonatype

#

🤔

hazy nimbus
dusky harness
#

¯_(ツ)_/¯

hazy nimbus
#

do you know some other publicly available nexus instance?

#

Yup, it shows the IP there

pulsar ferry
#

Well they kinda own both so I'm assuming doing special things would be easy

hazy nimbus
#

Yep, could have merged it into OSS while they were at it.

#

Well anyway, I'm glad I switched

wind tapir
hazy nimbus
#

What version are you on?

wind tapir
#

1.8.8

hazy nimbus
#

I think the solution was to use Teams

#

or whatever it's called

hazy nimbus
wind tapir
#

I'm using it, just it's blocked to 16 prefix, 16 name and 16 suffix, but I want more, look my code:

#

public void setNametag(Player player) {
        ScoreboardManager scoreboardManager = Bukkit.getScoreboardManager();
        scoreboard = scoreboardManager.getNewScoreboard();
        team = scoreboard.registerNewTeam("_" + player.getName());
        team.setPrefix(main.getPrefix(player.getUniqueId()));
        team.addPlayer(player);
        player.setScoreboard(scoreboard);
        player.setPlayerListName(main.getPrefix(player.getUniqueId()) + player.getName());
    }

hazy nimbus
#

Yeah, I'm afraid you can't really expect support with a 8yo version

#

But I think it is not bypassable

wind tapir
#

ik it's hard but the thing is that most popular servers did it, like hypixel for example

#

so it's not impossible

hazy nimbus
#

If you mean names above the player, they solved it by spawning an armor stand above the player.

wind tapir
shell moon
#

they use teams? they could probably use armorstand as TAB (for name tag, not tab name)