#help-development

1 messages · Page 1297 of 1

slender elbow
#

lol, that's almost the exact same code for the default ExecutorService#close

#

which you can just call and forget about it which is really nice

sly topaz
#

it has a timeout of 1 day lmao, that's funny

#

but I do wonder why they don't just suggest to call close, I guess it was before it became AutoCloseable or something

mortal vortex
#

I understand Player is an interface and cant be extended, but if one wanted to create their own player class to store some data for easier access, meaning allowing:

CustomPlayer pl = getCustomPlayer([Player]);
int score = pl.getScore(); // custom
// but also have some way of also interacting with existing Player.# methods?
pl.kick(); // not custom

instead of:

Player pl = <something>.getPlayer();
int score api.getScore(pl.getUniqueId());
pl.kick(); // pl is Bukkit's Player here anyways

How would one do so? Is it better to just make a wrapper where you can convert to custom type and then back?

sly topaz
#

while I hate it, kotlin is better for that kind of thing

#

you can just add extension functions and the problem will seemingly disappear

mortal vortex
#

was just hoping to write an API and not rewrite my whole plugin

sly topaz
#

issue with implementing a custom player is that you have to make the server use it, which isn't all that straightforward and since all API methods return the interface, you'll have to be casting all the time

#

so, in the end it isn't any better than just using a wrapper

pine forge
#

ok ill try that guess i shouldve checked that first

sly topaz
sly topaz
pine forge
sly topaz
#

if close doesn't exist then you're using an old java version

pine forge
#

yes

#

im using the 1.12 spigot api

#

to provide support for all versions

sly topaz
#

then just use the method linked here

#

the issue with just calling shutdownNow is that it will cancel any tasks without giving them time to do whatever they need to do when they're cancelled (aka cleaning up)

pine forge
#

yea alright

#
catch (InterruptedException ex) {
            // (Re-)Cancel if current thread also interrupted
            pool.shutdownNow();
            // Preserve interrupt status
            Thread.currentThread().interrupt();
        }```

Do i also need to interrupt the current thread
#

it says preserve interrupt status but i dont see where its ever interrupted before that

#

ah because of the exception

#

dont understand this

#

😅

sly topaz
#

it won't happen here since spigot almost never interrupts the main thread

pine forge
#

okayu

sly topaz
#

so, if the thread is interrupted, it'll try to cancel tasks first and then just leave it interrupted

pine forge
#

okay ill remove all the future stuff from before then

#

okay seems to work perfectly

#

Thank you! :D

thorn isle
#

one of my pet peeves is that bukkit doesn't interrupt async scheduler task threads on shutdown/plugin disable

wet breach
#

otherwise you could prevent a server from shutting down

#

which a plugin is not allowed to do

tulip mica
#

how do i make setlore work in intellij?

mortal vortex
#

what

tulip mica
#

nevermind i fixed it

thorn isle
#

and prints a warning telling you to nag at the plugin author for "not properly shutting down async tasks"

#

or i'm not sure if it interrupts them, i think they might just get killed

slender elbow
grim hound
#

wtf is this

#

no matter the task I try this shi pops up

slender elbow
#

you should ask in the paper discord

grim hound
#

banned there

slender elbow
#

of course

grim hound
#

and plugin ver

#

persists

grim hound
#

and the build file works just fine with other of my projects

grim hound
pure dagger
#
public class InvitationManager {

    //<Player, <Clan, EndTime>>
    private final Map<UUID, Map<UUID, Long>> playersMap;
    private final long pendingTime;

    public InvitationManager(MyPlugin myPlugin, long pendingTime) {
        this.playersMap = new HashMap<>();
        this.pendingTime = pendingTime;
    }

    public void addInvitation(Player player, Clan clan) {
        UUID playerID = player.getUniqueId();
        Map<UUID, Long> clansMap = playersMap.computeIfAbsent(playerID, k->new HashMap<>());
        clansMap.put(clan.getId(), currentTimeMillis()+pendingTime);
    }

    public boolean hasInvitation(Player player, Clan clan) {
        UUID playerID = player.getUniqueId();
        if (!playersMap.containsKey(playerID)) return false;
        Map<UUID, Long> clansMap = playersMap.get(playerID);
        UUID clanID = clan.getId();
        if (!clansMap.containsKey(clanID)) return false;

        if (currentTimeMillis() >= clansMap.get(clanID)) { // here is the removing part
            clansMap.remove(clanID);
            if (clansMap.isEmpty()) {
                playersMap.remove(playerID);
            }
            return false;
        }
        return true;
    }

    public void removeInvitation(Player player, Clan clan) {
        UUID playerID = player.getUniqueId();
        if (!playersMap.containsKey(playerID)) return;
        UUID clanID = clan.getId();
        playersMap.get(playerID).remove(clanID);
    }
}

this is InvitationManager for managing invitations to clans. so every player can have invitations from many clans at the same time. the invitation expires after 60 seconds. but its actually removed from the map only when you try to access it (hasInvitation() method). do you think this approach is okay? when a player A sends a clan invite request to player B, and then they remove the clan before player B joins or try to join, the id of the clan will just stay in the map and be not accessible

#

until the next reload

thorn isle
#

the code could be cleaner but yes that's fine in terms of approach

#

e.g.

#
    public boolean hasInvitation(Player player, Clan clan) {
        return playersMap
            .getOrDefault(player.getUniqueId(), Collections.emptyMap())
            .getOrDefault(clan.getId(), 0L) < System.currentTimeMillis()
    }
pure dagger
#

but has invntations does more than tahn

thorn isle
#

it also removes it, but only if it's expired, and doing that is unnecessary

pure dagger
#

but you're creating an empty map

#

and when do you remove...

#

the things

thorn isle
#

i'm not

#

it's an immutable singleton

#

they'd be removed in removeInvitation or when the server restarts

pure dagger
#

idk why you dont remove the things from the map

#

if its expired i remove it

grim hound
grim hound
#

and do compute

#

if you wish to remove it when expired

thorn isle
#

you could do that if you really want to remove them from the map, but there'll be no functional difference

pure dagger
#

my clan plugin has Leader, Viceleader and normal members. im looking for a name for a method returning everyone (leader, viceleader and members) but technically leader is also a member. i dont know how to call "any player in clan" and how to call "any player in clan not being leader or vice" ... do you know what i mean?

thorn isle
#

i.e. only really do it if you're worried that the map will grow overly large and cause performance or memory leak-like issues

pure dagger
thorn isle
#

rather that's what i'd do, but you can remove them anyway if you like, just the code gets a bit more hairy

#

you could uh

pure dagger
#

oh wait.. i dont think i iterate

thorn isle
#

you don't iterate, no

pure dagger
#

ooooooookay

pure dagger
#

a name for [anyone in clan] and a name for [anyone except leader or vice - so casual member]

thorn isle
#

everyone is a member, "ranked members" are a subset of members

#

so i'd just call it member and getMembers

pure dagger
#

ok but someone who isnt a leader or a vice is who

thorn isle
#

a member

pure dagger
#

ok... and just anyone in clan... ?

#

its a member too

#

i could call that [member] and [unraked member]

#
public void messageAllMembers(Clan clan, String message) {
        messageAllMembersExcept(clan, message);
    }

    public void messageAllMembersExcept(Clan clan, String message, Player... except) {
        Set<UUID> playerIDs = new HashSet<>(clan.getMembers());
        playerIDs.add(clan.getLeader());
        if (clan.getViceLeader() != null) {
            playerIDs.add(clan.getViceLeader());
        }

        outer:
        for (UUID playerID : playerIDs) {
            Player player = Bukkit.getPlayer(playerID);
            if (player == null) {
                continue;
            }
            for (Player exceptPlayer : except) {
                if (exceptPlayer != null && exceptPlayer.getUniqueId().equals(playerID))
                    continue outer;
            }
            player.sendMessage(message);
        }
    }
ivory sleet
pure dagger
#

match how?

thorn isle
#

record UUIDPair(UUID first, UUID second){} 🤡

#

the downside is that you won't be able to look at all of a certain player's invitations easily, without iterating

#

but it doesn't seem that you do so whatever

ivory sleet
pure dagger
#

yeah i aldready did this this way.. i think ill keep that for now

thorn isle
#

if you want it to be symmetric you could just Set.of two uuids i guess; i don't know if you really want it to be symmetric though since one is the sender and the other is the receiver

#

an invitation from bob to alice should be distinct from an invitation from alice to bob

slender elbow
#

keeping a table-like structure just makes more sense

#

could use a guava Table, even

pure dagger
slender elbow
#

yep

pure dagger
#

yay

#
player.sendMessage(ChatColor.GRAY+""+ChatColor.BOLD+"--------------------");
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"Klan: "+ChatColor.RED+clanName);
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"Lider: "+ChatColor.RED+leaderName);
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"Zastępca: "+ChatColor.RED+viceLeaderName);
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"Punkty: "+ChatColor.RED+ clanConfig.getClanRanking(clan));
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"Zabójstwa: "+ChatColor.RED+ clanConfig.getClanKills(clan));
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"Śmierci: "+ChatColor.RED+ clanConfig.getClanDeaths(clan));
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"K/D: "+ChatColor.RED+ clanConfig.getClanKDR(clan));
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"Członkowie: "+members);
        player.sendMessage(ChatColor.DARK_GRAY+" > "+ ChatColor.GRAY+"Sojusze: "+alliances);
        player.sendMessage(ChatColor.GRAY+""+ChatColor.BOLD+"--------------------");

is this different than sending 1 message with '\n'

slender elbow
#

not really? number of packets sent but like, for that amount it doesn't really matter

thorn isle
#

other plugins sending messages asynchronously (or even player chat i think since that's processed async) can end up interspersed in between the messages

#

kind of rare but happens more often than you might expect

pure dagger
#

oh

slender elbow
#

not that it's an issue but yea

thorn isle
#

this'd be a good place for those string templates

slender elbow
#

how so

agile river
#
  ItemDisplay door = loc.getWorld().spawn(baseLoc.clone(), ItemDisplay.class, disp -> {
            disp.setItem(doorItem);
            disp.setTransformation(new Transformation(
                    new Vector(0, 0, 0),
                    new Quaternion(0, 0, 0, 1),
                    new Vector(0.5f, 0.5f, 0.5f),
                    new Quaternion(0, 0, 0, 1)```

Why is Quaternion and setItem keeping red?
slender elbow
#

i mean we already have sendMessage(String...) and text blocks too

#

because those are not classes that exist or the parameter types for Transformation constructor

pure dagger
#

or is it safer

slender elbow
#

it's just a for loop sendMessage(String) so effectively the same, yes

#

just a lil convenience thing

pure dagger
#

Ok ill just connect it to 1 string and send

fresh timber
#

how can I get the location points between 2 locations to draw a line of particles

chrome beacon
#

lerp?

slender elbow
#

I've lerped this morning already

#

it's gonna take a while if I lerp again

ocean tide
#

Hello, how can I hide this "When on Head" lines from lore, I was trying to use ItemFlag HIDE_ATTRUBUTE but it still apperars

chrome beacon
#

Are you using Paper

ocean tide
#

yes

slender elbow
#

old paper, even

#

outdated

chrome beacon
#

That would be why

#

You need to add an attribute

ocean tide
#

is it possible on paper?

slender elbow
#

read the message directly above yours

ocean tide
chrome beacon
#

Add an attribute modifier to the item

slender elbow
#

you need to add an attribute modifier to be able to hide them

ocean tide
#

it works, thanks so much

agile river
#
        ItemStack doorItem = new ItemStack(Material.STICK);
        ItemMeta doorMeta = doorItem.getItemMeta();
        if (doorMeta != null) {
            CustomModelDataComponent doorCmd = CustomModelDataComponent.builder()
                    .strings(List.of("kluis_door"))
                    .build();
            doorMeta.setCustomModelDataComponent(doorCmd);
            doorItem.setItemMeta(doorMeta);
        }

Does anyone know how this works? I want to add custom models with strings, but how exactly does this work? I have it like this now, but I keep getting errors. I have already tried everything and I must be doing something wrong. I am using paper 1.21.4.

thorn isle
#

getting errors
what errors

worldly ingot
#

Well, for one, there is no CustomModelDataComponent#builder() method

#

or strings() method

#
        ItemStack itemStack = new ItemStack(Material.STICK);
        ItemMeta itemMeta = doorItem.getItemMeta();
        if (doorMeta != null) {
            CustomModelDataComponent data = itemMeta.getCustomModelDataComponent();
            data.setStrings(List.of("kluis_door"));
            itemMeta.setCustomModelDataComponent(data);
            itemStack.setItemMeta(meta);
        }
#

I don't know where you got any of those methods from. Not even Paper has a builder for it, so I'm genuinely confused

lilac dagger
#

i suspect chat gpt halucination

agile river
#

Google :/

thorn isle
#

sure, sure

wooden bay
#

classic

nova notch
#

I mean it could technically be google... that is, google AI summary

echo basalt
#

item.setData(DataComponentTypes.CUSTOM_MODEL_DATA, CustomModelData.customModelData().addString("door").build());

agile river
#

Yes I think I already fixed it 😄 ty

drowsy oriole
#

some have plugin the sell all

#

@worldly ingot

grand flint
#

ah yes

#

choco has nothing to do

#

but respond to ur plugin request in the wrong channel

#

that u couldve found with one GOOGLE search

drowsy oriole
#

do you have plugin the sell all

#

i dont found it on Google

grand flint
#

u need to have a shop to sell all ??

drowsy oriole
#

not just the sell plugin to sell the items I want to sell

grand flint
#

yeah

#

u need a sell plugin

#

?

drowsy oriole
#

yes

#

only plugin

grand flint
#

here this is similar to donut smp if u configure it properly

drowsy oriole
#

but you have the plugin to put it inside this sell

grand flint
#

not to be rude

#

but if u used google translate

#

id understand u much easier

grand flint
#

has /sell and /sellall

#

and gui

drowsy oriole
#

and just put the plugin and it works

grand flint
#

yep :D

drowsy oriole
#

thanks

#

doesn't work

#

you have to write something inside it

#

@grand flint

grand flint
#

then write bro ??

#

its not my problem

#

if u cant be asked to

#

configure a plugin

#

then dont make a esrver

#

lazy shits these days istg 🙏

drowsy oriole
#

@grand flint

#

@grand flint

#

@grand flint

#

@grand flint

grand flint
thorn isle
#

How many reports can we get in the report train

pure dagger
#

That was cute

mellow edge
#

this is not really a spigot question but I think I should post it here instead of in help-server.

I want to run BuildTools through Runtime#exec (some utility), it is working however BuildTools is automatically installing PortableGit. Is it possible for me to somehow provide build tools with an existing version of Git through path variable or smth? I am on windows.

chrome beacon
mellow edge
#

can I run it programmatically through git bash

chrome beacon
#

yeah

fickle mantle
#

can anyone help me open a working anvil inventory?
(MenuType.Anvil doesn't work either)

mellow edge
#

open a casual anvil inventory?

fickle mantle
#

that doesn't work

fickle mantle
#

1.21.4

chrome beacon
#

entries are separated by :

#

should get BuildTools to detect things

mellow edge
fickle mantle
mellow edge
chrome beacon
#

no

#

If you want to be sure you can loop through the environment keys and see the default values that it picks up from the system

mellow edge
#

git is already linked through path

chrome beacon
#

BuildTools wants a bash runtime as well

#

git portable contains both git and bash

chrome bloom
#

question any one getting error Task exited with error code 1

#

when trying to run Buldtools?

mellow edge
chrome beacon
#

That's it

chrome bloom
#

okay

chrome beacon
#

Send the entire log in a paste

#

?paste

undone axleBOT
mellow edge
#

ok

#

I will provide it

chrome beacon
#

from git portable

mellow edge
#

Ok.

chrome beacon
#

I don't really understand why you want to add that via your program when it should already pick it up if on the path

#

do you have your own downloader for it or smth

mellow edge
#

no

#

it's not because of that

buoyant viper
mellow edge
#

I am making some utility for me

buoyant viper
hallow lion
#

Am i crazy or is this a bug?

        Bukkit.getScheduler().runTaskTimerAsynchronously(this, task -> {
            System.out.println("test");
        }, 0L, 20L); // Runs once

        Bukkit.getScheduler().runTaskTimerAsynchronously(this, () -> {
            System.out.println("test");
        }, 0L, 20L); // Actually repeats
#

The consumer version doesnt repeat for some reason, i assume this a bug on spigots end or am i missing something obvious here. I don't see anything related in the javadocs

mellow edge
#

@chrome beacon Thank you so much, it actually seems to have worked. I provided those two files from Portable Git and BuildTools is now happy.

buoyant viper
chrome beacon
#

correctly picks up my system git bash

#

Are you sure you have yours on path

buoyant viper
#

idk tbh

#

i know git is in my path, not sure abt bash

mellow edge
buoyant viper
#

the official one is made with a window builder yeah

#

mine is manual placement lol

wind jacinth
#

im working on an authentication plugin and wanted to know if there is any way to use the new dialog system from within spigot

#

does anyone know?

grand flint
#

yeah

#

the api

#

although authme exists and is open source

wind jacinth
grand flint
#

😨

wind jacinth
#

??

chrome beacon
mortal vortex
#

"how do i serialize an inventory"
"with the api"
🤯

wind jacinth
mortal vortex
#

I think this is for dialoges?

buoyant viper
#

ye

grand flint
buoyant viper
wind jacinth
mortal vortex
#

its contaminated everything

#

my left out cheetos are probably infested

worldly ingot
#

Don't you dare talk bad about cockroaches ever again! They're just doing their job and it's your fault!

#

They're detritivores!

wind jacinth
#

has anyone mapped out the JSON format for the dialog payloads yet?

chrome beacon
#

You don't need to use packets you can just use the api

#

also since Paper has hardforked they have their own api as well so you'll need to handle both cases

mellow edge
mortal vortex
mortal vortex
#

if you ignore the cans of pepsi and cheetos on the floor

young knoll
#

Tbf you sent the Bungeecord api

#

Spigot itself just has Player#showDialog

mortal vortex
mortal vortex
young knoll
#

Yes

#

But the player method is kinda the important part

mortal vortex
#

I thought he got the "showDialogue"

#

my bad G

#

ill shut my mouth

#

i know my place

wind jacinth
#

good boy

#

jkjkjk

potent crescent
#

guys can i test the plugin for multi version without trying version per version?

potent crescent
#

First time I hear about it

ivory sleet
pastel axle
mortal vortex
#

ahh thanks. i skipped over dat

pastel axle
#

I expect in most cases people will build the dialogs using the API so it can be dynamic, but sometimes a static one is all you need.

austere crow
#

Need some help trying to compile a plugin in vs code have it set up in Marvin and i put in the library’s for spogit and the other dependencies in /libs but they still are not being found or what ever by the code it still can’t find bukkit

drowsy helm
#

marvin

upbeat hornet
#

?gui

potent crescent
drowsy helm
potent crescent
#

marvin

drowsy helm
#

🤨

worthy yarrow
#

Yes marvin is a newer build script

#

And would you believe it, it's not even remotely comprable to maven

potent crescent
drowsy helm
#

guess i'm behind on the curve lol

potent crescent
#

lol

worthy yarrow
#

I'm kidding ofc

#

Fyi marvin is a thing

#

I think it's for scripts

#

iirc

potent crescent
#

marvien is easy and better u can summed 40,000 up in one line

worthy yarrow
drowsy helm
#

anyways would you like to send us the error

drowsy helm
worthy yarrow
#

Oh idk the use lol

drowsy helm
#

doesn't seem very applicable here lol

worthy yarrow
#

I just saw some mention of tying up scripts with a main file of sorts

austere crow
austere crow
# drowsy helm show your pom.xml

<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>su.enchants</groupId>
<artifactId>enchantments</artifactId>
<version>5.1.0</version>
<packaging>jar</packaging>

<name>enchantments</name>

<build>
    <plugins>
        <!-- Compiler Plugin -->
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.10.1</version>
            <configuration>
                <source>1.8</source>
                <target>1.8</target>
            </configuration>
        </plugin>

        <!-- Shade Plugin to bundle dependencies -->
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-shade-plugin</artifactId>
            <version>3.5.0</version>
            <executions>
                <execution>
                    <phase>package</phase>
                    <goals><goal>shade</goal></goals>
                </execution>
            </executions>
        </plugin>
    </plugins>
</build>

<dependencies>
    <dependency>
        <groupId>spigot</groupId>
        <artifactId>spigot</artifactId>
        <version>1.21.7</version>
        <scope>system</scope>
        <systemPath>${project.basedir}/libs/spigot-1.21.7.jar</systemPath>
    </dependency>
    <dependency>
        <groupId>core</groupId>
        <artifactId>core</artifactId>
        <version>2.7.10</version>
        <scope>system</scope>
        <systemPath>${project.basedir}/libs/cord-2.7.10.jar</systemPath>
    </dependency>
    <dependency>
        <groupId>annotations</groupId>
        <artifactId>annotations</artifactId>
        <version>24.1.0</version>
        <scope>system</scope>
        <systemPath>${project.basedir}/libs/annotations-24.1.0.jar</systemPath>
    </dependency>
</dependencies>

</project>

worthy yarrow
#

?paste pls

undone axleBOT
drowsy helm
#

how come spigot is a local dependency?

worthy yarrow
#

is md5 still down?

drowsy helm
#

i think so

worthy yarrow
#

shoot

drowsy helm
#

oh nah

#

its up now

worthy yarrow
#

oh noice

drowsy helm
#

also is cord-2.7.10.jar right?

#

shouldnt it be core

worthy yarrow
#

Based on the naming convention it should be

austere crow
buoyant viper
#

AI is a detriment to society and we are reaping the consequences

mortal vortex
austere crow
#

I’m compliing a plugin and I needed bukkit packages so I had to use spogitmc jar it wasn’t working vs code was still saying it didn’t know what bukkit was in the files

mortal vortex
#

also just use the maven repo

worthy yarrow
kind hatch
#

Feel like this is a possible

#

?bootstrap

undone axleBOT
#

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

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

worthy yarrow
#

But gpt wrote it and gpt is never ever ever wrong

kind hatch
#

You right

austere crow
kind hatch
#

my bad

worthy yarrow
#

Smh fr

austere crow
mortal vortex
#

Do you know how to code or are you walking around in the dark rn

worthy yarrow
#

I know how to code and I still be walking in the dark

mortal vortex
#

holy... how many xbox accounts have you stolen?

worthy yarrow
#

Someone hire this guy for web dev

#

Most projects on the linked gh are php projects D:

mortal vortex
#

yes... forked.

#

and in a flipper commmunity too so he might as well be a skid

austere crow
austere crow
worthy yarrow
#

Don't ever say that to a kotlin nerd

austere crow
#

lol

mortal vortex
#

when i push down on my armpits i can feel like a lump under the skin

#

think i have cancer?

worthy yarrow
#

99% it's a swollen lymph node

mortal vortex
#

i thought those were in your throat

worthy yarrow
#

Lymph nodes are all over your body mate

austere crow
worthy yarrow
#

Could get a swollen one pretty much anywhere

mortal vortex
worthy yarrow
#

google says you have 6-800 total

buoyant viper
mortal vortex
#

I think i have some medical problem, my throat is always swollen and my nose is fucked 24/7. I am almost always feeling like I've just recovered (or starting to develop) a cold

worthy yarrow
#

That just sounds like asthma

mortal vortex
#

i mean upper throat, like where the nose connects to the mouth

#

wait thats not throat

#

SINUS

#

those things

worthy yarrow
#

Still sounds like asthma

mortal vortex
#

really? maybe ill go to the doctor

worthy yarrow
#

Yes I am not joking

mortal vortex
#

i feel like i shouldnt bother.

#

i will almost 100% come off as an attention seeker.

worthy yarrow
#

I mean if it gets to a point where your breathing is genuinely being impeded, go to doctor

mortal vortex
#

nah not breathing, its just like this feeling that i've got a swollen throat when i swallow.

mortal vortex
#

could

worthy yarrow
#

how long have you been dealing with it

mortal vortex
#

7 years mayb

worthy yarrow
#

Ever gone to a doctor for it?

mortal vortex
#

nope

worthy yarrow
#

Yeah go get some antibiotics

mortal vortex
#

i have this problem lately where, whenever im standing up, doing something. and my vision will suddenly become impaired... i wouldnt even say "black", but its like turning down the exposure on a cmaera, and i become disoriented.

#

I have too many things to report to a doctor that it would just seem like im trying to get drugs

worthy yarrow
#

That sounds like blood pressure issue, though it is common to standup quickly and feel that way, if it persists/gets worse then it's an issue

worthy yarrow
#

Whether through medical tools or just your description of symptoms, the point of being a doctor is to be a helper so

#

Better to go in and get a checkup at least than never doing so

mortal vortex
#

good idea

#

... now i gotta leave my house.

worthy yarrow
#

ik it's pain lol

#

But i mean better than dying

mortal vortex
#

my heart stopped for like 20 secs when i was a kid

#

lmfao would make up a story about seeing heaven, but i cant remember shit

austere crow
#

I still need help though also I didn’t know I would be completely profiled on my way in to the server lol

kind hatch
#

If you are already using maven, then all you need are the files generated by BuildTools.
Have you done that?

austere crow
#

Yes

#

But the bukkit files are not showing

#

Like it says they were not found

kind hatch
#

?img

undone axleBOT
#

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

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

kind hatch
#

?paste your pom as well

undone axleBOT
worthy yarrow
#

Funnily enough only the stupids get remembered

worthy yarrow
kind hatch
#

I learned today that maven has a <release> tag for the compiler plugin that replaces both the <source> and <target> tags and that it's preferred for Java 9+ usage.

<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-compiler-plugin</artifactId>
  <version>3.14.0</version>
  <configuration>
    <release>16</release>
<!--    <source>16</source>-->
<!--    <target>16</target>-->
  </configuration>
</plugin>

I have also learned that it can be configured via the <properties> tag.

<properties>
  <maven.compiler.release>21</maven.compiler.release>
</properties>

-# Yipeeeee shorter pom files

The only reason I stumbled across this tidbit of info is because I was trying to get rid of compiler warnings without resorting to suppressing the messages.
I will be using this from now on where I can. :P

worthy yarrow
#

And that's why I prefer gradle

mortal vortex
#

any API for doing falling blocks easier?

#

anyways go on @echo basalt

echo basalt
#

already said all I had to say

mortal vortex
#

ohh i thought dere was more

#

allgs

timber eagle
#

is there anyway to make a projectile invisible without remvoing it from the client because then when i add a passenger to it, it will act very weird and it wont look like im mounted to it

timber eagle
#

and then i am mounted to the armorstand

mortal vortex
#

is that a statement or a queestion?

timber eagle
#

thats what i found out

#

so i dont know what to do

mortal vortex
#

okay dont make the armorstand ride the projectile

timber eagle
#

thats what i had before. the player was just riding the projectile

mortal vortex
#

make the armostand become the projectile, the armorstand shouldnt ride the projectile

timber eagle
#

i can't

mortal vortex
#

Why?

timber eagle
#

im using an enderpearl

#

and its velocity is important

mortal vortex
#

How is the projectile being created, is it created in code, or invoked by a player.

timber eagle
#

i've tried with an amorstand

timber eagle
#

player.launchProjectile

mortal vortex
#

You can track its velocity, pitch, and all, from the moment it exists, and simulate it.

timber eagle
#

It's determined by a bezier curve

#

and i use points

brazen tartan
#

moving here because I realized I was in the wrong channel:

I have a blockbench model for a staff and a custom item coded and taged in intelij
i am currently trying to use https://github.com/MagmaGuy/FreeMinecraftModels
to translate my models into packs that can be applied to both items an entities with the end goal of having many custom entity textures to mask over projectiles for spells
using display
but I cant figure out how to get the models applied to my items in my plugin
I will link the resource pack it's making when it finishes uploading
and my namespace for the model is currently this: meta.setItemModel(new NamespacedKey("freeminecraftmodels", "firestaff"));
https://drive.google.com/file/d/1TwuMx1FA4m_fhcwgY_MQyqeNxrKu0_rn/view?usp=sharing

timber eagle
#

and i lerp to each points, but the armorstand is really weird

#

the enderpearl works for resolutions like 10, so 10 points along the curve, its a quadratic

#

but its visible to the players

mortal vortex
timber eagle
#

the problem is the velocity, i want it to be smooth so i cannot tp the armorstand

mortal vortex
#

oh right good point

timber eagle
#

an enderpearl is perfect for velocity so i just use that

#

hypixel has done it

#

its a launcher

#

they also use a projectile

mortal vortex
#

Yeah ik

timber eagle
#

i have access to the spigot src and i can patch it, no worries, but i dont know what does the rendering to the clients and if that is even possible to extract just that from the server

#
int entityId = ((CraftEntity) entity).getHandle().getId();
            sendPacket(player, new PacketPlayOutEntityDestroy(entityId));
#

Unless this packet is not the way to do it for projectiles idk

mortal vortex
#

No you're right, im suree there is some way for it to not be janky.

timber eagle
#

the only thing i can think of is setting the velocity before and then removing it, but that then relies on it being within the curve's arch

#

and im unsure how to do that

#

right now im lerping the velocity through each point of the curve.

buoyant viper
#

could u add the armor stand as a rider to a projectile?

#

can projectiles even have riders?

timber eagle
#

hypixel does it

mortal vortex
#

Itemstands can be invisible and rideable.

timber eagle
#

It still passes on the movement to the player

#

It’s janky because the ender pearl is removed on the client but I just want the rendering to be hidden

mortal vortex
#

if the enderpearl is visually removed, but the armorstand is riding the enderpearl, you wont need to tp the armorstand, the armorstand should follow.

wind jacinth
smoky anchor
mortal vortex
wind jacinth
mortal vortex
wind jacinth
#

im replacing the transformation every tick

smoky anchor
#

These entities can interpolate
which is how you get the smoothness

#

docs will tell you what the entity is capable of

#

the usage should be:
spawn entity with initial transformation (in your case none)
then set the end transformation you want (probably just translation) and set the interpolation value to how long you want the interpolation to last
note that it does have some upper limit iirc

pure dagger
#

why is there no entity move event

#

but there is player and vehicle move event

drowsy helm
#

maybe a lag thing?

#

what are you trying to achieve

mortal vortex
#

A global EntityMoveEvent would fire way too often

wind jacinth
mortal vortex
wind jacinth
#

okay

wind jacinth
mortal vortex
#

shulker heads?

#

lol i commenteed before u turned around

#

nice

wind jacinth
#

xD

#

yeah im using them as an invisible block

mortal vortex
#

is the donutsmp shit legit 😭

wind jacinth
#

but

#

im trying to figure out how to make the shulker entity invisible 💀

mortal vortex
#

PFFF yall get banned?

wind jacinth
#

i didnt want to use barriers cuz it looked bad

wind jacinth
#

yeahhhh

wind jacinth
#

could i just apply invisibility?

smoky anchor
#
  1. do you need to use shulkers ?
  2. update
  3. make shulkers ride some entity so they move smoothly
  4. or just use barriers 'cause who tf cares about how smooth the collision is in this case
wind jacinth
smoky anchor
#

why you using such old version smh

wind jacinth
#

im using 1.21.4

#

oh wait

smoky anchor
#

then how are they not fully invisible think

wind jacinth
#

my client is 1.21.1

mortal vortex
#

i thoguht it was like lead things

wind jacinth
#

not let people play under 1.21.1

smoky anchor
#

under 1.21.2 you mean

wind jacinth
#

yes

mortal vortex
#

bro left his mic connected 😭

#

ive already traced the static in the audio, ik where u at

thorn isle
#

oh neat

#

i completely missed the shulker invisibility change

#

can finally do hard collisions with moving shit like this now

wind jacinth
#

there is that better @mortal vortex 😭

lilac dagger
#

you could do this with block display no?

#

update it every tick for smoothness

thin roost
#

Hi!

I am currently working on a plugin that uses the Adventure API (net.kyori.adventure). I just found out, that this API is only recognized by Paper servers. When I tried to use it on my Spigot server, it showed me the following message:

java.lang.NoClassDefFoundError: net/kyori/adventure/text/Component

Since I am aware that many Servers use Spigot and I plan to release this Plugin, I'm currently looking for a solution to this problem. (It works fine on a paper server)

Does anyone know if there is a way to make this Plugin work for Spigot servers too?

Thank y'all in advance!

thorn isle
#

shade it in and relocate

lean pumice
#

@tender shard

thin roost
# thorn isle shade it in and relocate

I am not really sure how this is done. I tried that already but when I relocated it, the path wasn't recognized in the imports.
Is there any documentation for that?

thorn isle
#

how are you building the project, how did you set up the shade/relocation

acoustic galleon
#

how can i solve

sullen marlin
#

?whereami

thin roost
# thorn isle how are you building the project, how did you set up the shade/relocation

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.5.1</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<relocations>
<relocation>
<pattern>net.kyori.adventure</pattern>
<shadedPattern>de.silver.adventure</shadedPattern>
</relocation>
</relocations>
<minimizeJar>true</minimizeJar>
</configuration>
</execution>
</executions>
</plugin>

This is what I've tried so far

sullen marlin
#

What's the error?

thin roost
acoustic galleon
sullen marlin
#

Post your full pom

acoustic galleon
#

same thing here

#

why help him and no me

sullen marlin
#

Maybe if you read you would see it's not the same thing

acoustic galleon
#

i read

#

he have a maven question

#

and i have a gradle question

#

bc classes are duplicating for me

thorn isle
mellow edge
acoustic galleon
thorn isle
#

isn't that the whole point

acoustic galleon
#

someone know why when i compile my module it is duplicating the classes?

#

my others modules arent duplicating

#

just a module

mellow edge
thorn isle
#

it shouldn't cause this but eyeballing the setup it seems like the first suspect

acoustic galleon
#

plugins {
id("java")
}

tasks.compileJava {
options.release.set(21)
}

dependencies {
implementation(project(":shared"))
compileOnly("org.bukkit:craftbukkit:1.21.4-R0.1-SNAPSHOT")
}

#

aaaaaaaa

#

this is duplicating my classes

thorn isle
#

craftbukkit 🤡

sullen marlin
acoustic galleon
#

what ur problem

quaint mantle
#

Hi, I currently have a problem with an error in my ScoreboardBase class. I updated the plugin from 1.20.4 to 1.21.8. Where can I send you the error without making the entire log public?

sullen marlin
#

Why is your plugin using NMS for scoreboards?

acoustic galleon
#

// EntityArmorStand nmsArmorStand = ((CraftArmorStand) armorStand).getHandle();
// nmsArmorStand.a(x, y, z, yaw, pitch);
((ArmorStand) armorStand).teleport((Location) location, PlayerTeleportEvent.TeleportCause.PLUGIN);

sullen marlin
#

And this is a public discord, everything is public

acoustic galleon
#

whats difference?

sullen marlin
#

One uses nms for no clear reason

acoustic galleon
#

like i cant teleport an armorstand for some reason

#

and then i need use nms

#

but if i use PlayerTeleportEvent.TeleportCause.PLUGIN available on modern versions like 1.19

winter jungle
acoustic galleon
#

then armorstand teleports yk

winter jungle
#

oh thats easy lol
thanks

thorn isle
#

it'll still be pushed by water and explosions i think, if you want to make sure it stays in place you can probably mount it on an armor stand

quaint mantle
# sullen marlin Why is your plugin using NMS for scoreboards?

yes for sure

Caused by: java.lang.ClassNotFoundException: net.minecraft.world.scores.ScoreboardServer$Action
at original-Core-1.0.jar/dev.aklonex.core.bukkit.utils.ReflectionUtil.nmsClass(ReflectionUtil.java:47)
at original-Core-1.0.jar/dev.aklonex.core.bukkit.scoreboard.ScoreboardBase.<clinit>(ScoreboardBase.java:142)

acoustic galleon
#

🤡

sullen marlin
#

Why is your plugin using NMS for scoreboards?

acoustic galleon
#

lmao

quaint mantle
#

The developer developed the system a few years ago, and now I want to update it because I want to use it again.

sullen marlin
#

Sounds like you should switch it for the API and prevent the need for updates

winter jungle
sullen marlin
#

Isn't it Item?

young knoll
#

Item

sullen marlin
#

?jd

undone axleBOT
sullen marlin
acoustic galleon
#

idk why

#

maybe bc have a passager

#

on armorstand

#

and with nms it works

young knoll
#

Yeah that would do it

#

Spigot teleport with passengers when

sullen marlin
#

PR when

winter jungle
young knoll
acoustic galleon
acoustic galleon
mortal vortex
#

md, while you're here, just a quicky... Are account deletion requests possible? How long is data held? and what is erased?

young knoll
#

Sadly it’s a bit dead

sullen marlin
#

Read the faq

winter jungle
young knoll
#

Korea belongs to the nords!

sullen marlin
#

Yeah I don't think that PR was right

mortal vortex
#

if /wiki/faq, i no see.

winter jungle
mortal vortex
#

Thanks!

acoustic galleon
#

if i paste compiled classes can be a problem?

#

on like a package

#

my shadowjar isnt including my module classes idk why

chrome beacon
#

I recommend you troubleshoot shadow

acoustic galleon
#

i alr tried

chrome beacon
#

Not impossible

acoustic galleon
#

just have net.minecraft.world.entity.decoration.ArmorStand.setPos and net.minecraft.world.entity.decoration.ArmorStand.setRot?

#

doesnt have setPosAndRot?

acoustic galleon
#

[13:02:25 WARN]: [org.bukkit.craftbukkit.legacy.CraftLegacy] Initializing Legacy Material Support. Unless you have legacy plugins and/or data this is a bug!
[13:02:35 INFO]: forward: false player.isInsideVehicle(): true
[13:02:35 INFO]: forward: false player.isInsideVehicle(): true
[13:02:35 WARN]: Can't keep up! Is the server overloaded? Running 9826ms or 196 ticks behind

#

when i nteract with first material on my plugins

#

server tps go down

#

how can i fix this?

#

and my plugin is 1.8-1.21

#

idk if this is suppostly happens on 1.21 servers

young knoll
#

Set api-version to 1.13

#

It'll be ignored on lower versions anyway

acoustic galleon
young knoll
#

And you'll probably need something like XMaterial

acoustic galleon
#

im using xmaterial

chrome beacon
acoustic galleon
#

name: vehicles
version: 1.0.0
main: pt.andre.vehicle.platforms.bukkit.BukkitVehiclePlugin
description: Vehicles Plugin
depend:

  • packetevents
  • NBTAPI
    api-version: 1.13
#

@chrome beacon

thorn isle
#

it goes down because the legacy shit gets started up mid-session

#

i don't know what the actual fix for this is but you could just "interact with first material" in onEnable so the legacy shit gets started up during startup rather than mid session

violet blade
#

Is it possible to use "plugin.yml + CommandExecutor" to pass quoted strings as 1 argument and keep tab completion?

#

For something like
/nick "!! User !!" User

acoustic galleon
acoustic galleon
#

XMaterial.matchXMaterial isnt

#

maybe itemStack#isSimilar

#

but idk why this is happening. im using XMaterial

thorn isle
#

i thought the craftlegacy message is supposed to print a stack trace?

#

did you omit it from the logs or are you on a version where it doesn't?

slender elbow
#

it only does so if you enable debug mode in.. spigot.yml?

thorn isle
#

alternatively, plug it into spark and take a profile when you do the call and see the stack trace in the profiler

#

but debug is probably worth a shot first

acoustic galleon
#

i did block#getdata on onEnable

#

to load and avoid future lags

#

public class SoundAPI implements Sound {

@Override
public void applySound(Object location, String sound, int volume, int pitch) {
    Location loc = (Location) location;
    loc.getWorld().playSound(loc, sound, volume, pitch);
}

}

#

this is for resourcepack sounds?

worldly ingot
#

Yes, but the Location parameter there is confusing lol

#

It's cast to a Location anyways so the parameter type might as well be a Location

acoustic galleon
#

is bc my plugin support other apits

#

not just bukkikt

#

like fabric etc

#

but this isnt working

#

im on minecraft 1.8 and server is running 1.21

#

and this isnt playing a sound to me

muted stag
#

I'm curious about this InventoryView. It has to have a top inventory and a bottom inventory, which is normal in Minecraft. But getInventory(int) can return null. Does that mean there can be slots that belongs to no Inventory? Or every slot must belong to either the top inventory or the bottom inventory?

worldly ingot
#

getInventory(150)

#

Where be slot 150?

muted stag
#

Oh

#

I see

acoustic galleon
worldly ingot
acoustic galleon
#

but viaversion do the conversion

muted stag
#

Is it possible that a slot actually belongs to a third Inventory? Will it happen in our settings

worldly ingot
#

No because there is no third inventory. There's a top inventory and a bottom inventory :p

acoustic galleon
#

if server runs 1.8 and im on 1.8 this is playing the sound but i need use NMS public class SoundImpl implements Sound {

@Override
public void applySound(Object location, String sound, int volume, int pitch) {
    Location loc = (Location) location;
    double x = loc.getX();
    double y = loc.getY();
    double z = loc.getZ();
    ((CraftWorld) loc.getWorld()).getHandle().makeSound(x, y, z, sound, volume, pitch);
}
acoustic galleon
worldly ingot
#

Then it sounds potentially like a ViaVersion bug

acoustic galleon
#

nope

#

bc if im on 1.21 and server running 1.21

#

i dont have the sound too

#

i need use nms to display a sound to resourcepack on 1.21???

slender elbow
acoustic galleon
#

in the md5 ass

#

ill be banned

#

😦

#

on really

#

on paper dev ass

#

maybe im not using playsound very well

#

im using like "note.control"

#

need be like "minecraft:note.control" ?

#

on 1.8 was only note.control

thorn isle
#

i hate super reactions

vast ledge
#

They look asd frfr

#

Ass*

thorn isle
#

is there a sane way of writing lengthy content in books without having to worry about line splitting and pagination? afaik the client does line splitting but not pagination, so if your page contents are too long, the end gets split onto a line that isn't even rendered, and some of your content just disappears

#

currently i'm doing this by calculating the width for every character to split lines and paginate the content on server-side

#

but it is incredibly terrible and ass

worldly ingot
#

Yeah I don't think there's a server-sided solution for that

thorn isle
#

it's a shame that books have such uncomfortable limitations on them, they'd really be quite a nice medium for e.g. quest journals

#

but you can barely fit 3 words on a line and maybe 2 sentences on a page

acoustic galleon
#

on really viaversion bug

thorn isle
#

i guess there is the option of using resourcepack bullshit and vertical spaces and a scaled-down typeface to pack a bunch of smaller characters on the page, but that's a lot of work

#

at that point you're almost better off retexturing a chest gui to look like a book

grim hound
#

how do I make an ItemDisplay face what the player is facing

#

(when it's a passenger of the player and has a translation)

#

cuz any rotation seems to also move it

#

for whatever fucking reason

orchid brook
#

is PlayerQuitEvent is fired if the player get kicked ? or only PlayerKickEvent is fired

eternal oxide
#

yes it fires

orchid brook
#

❤️

grim hound
#

rotating an item display, without changing its rendered position

wind jacinth
#

how to fix worldedit bug

grand flint
#

LMAO wtf

#

unrotate it 💀

#

wtf is that

#

that is not a worldedit bug

#

those blocks are litearlly sideways

thorn isle
#

startanimation

#

i don't recall worldedit doing animations

pine forge
#
org.bukkit.command.CommandException: Unhandled exception executing 'list ' in org.bukkit.command.PluginCommand(list, Essentials v2.21.1)```

Im getting this error only on new versions (1.21.7/8) when trying to run this code:
```java
                getServer().dispatchCommand(Bukkit.getConsoleSender(), 'list');
thorn isle
wind jacinth
timber eagle
daring light
#

I'm struggling a bit on how to use BukkitRunnables in Kotlin, anyone have an example?

#

I'm trying to schedule a repeating task

slender elbow
#

any reason why you're trying to use BukkitRunnable instead of the regular BukkitScheduler?

#

in any case, you just make an anonymous object that extends from BukkitRunnable

#

and call the various runTask methods

#

first couple of links are useful

#

or you can just make it a named class too

#

I'm not entirely sure what is it you're struggling with so I'm going blind

timber eagle
#

I'm still struggling on figuring out a solution to my problem where I need a projectile to go invisible but removing it from the client is impossible

#

since I still need physics to work while im mounted on it

glad plinth
#

will the pluginmessenger work when there arent any players on the server? im using it to sync data

timber eagle
#

press f4 if your using intellij on the method

#

and just figure out the impl and look at it

slender elbow
#

plugin messaging works over a player's connection

#

no player = no plugin messaging

worldly ingot
#

im using it to sync data
This is your first mistake :p

buoyant viper
timber eagle
#

anyone know how I can spawn invisible arrows without using packetplayoutentity

wooden bay
potent crescent
#

@sullen marlin Why are the terms for publishing premium plugins difficult and complicated? you talk about 80 post wtf!

buoyant viper
#

just like

#

Post

#

idk

chrome beacon
#

Yeah just help some people on the forums

potent crescent
grand flint
#

well if u dont got 80 posts

#

u are clearly not qualified to post a premium plugin

potent crescent
#

I don't use Google much

buoyant viper
#

thats not Spigotmc

worldly ingot
#

The reason those prerequisites are there is to encourage people to actually be involved in the community before taking advantage of it monetarily. The premium resource section was meant as a reward to those that were very active

timber eagle
#

excuse me guys, what packets can i use to remove an entity from the client's render?

chrome beacon
#

You can destroy the entity

#

but you cannot make it invisible and still be there

buoyant viper
#

Invisible?

potent crescent
#

idk its ok

timber eagle
#

what packets can i use for that?

chrome beacon
#

Do you have a passenger on the entity

timber eagle
#

perhaps

potent crescent
#

isk what i should. post but ill see

chrome beacon
#

Then that's not what you want to do

timber eagle
#

so what do i do

chrome beacon
#

Depends what is the entity?

timber eagle
#

a projectile

#

is there any other entities that i can use, maybe not a projectile, that can go invisible and has physics like a projectile

#

hey?

timber eagle
#

ok i figured out how to make any entity even projectiles invisible without hurting their physics

trim quest
#

how can i solve this

chrome beacon
#

Run BuildTools with the remapped flag

#

for the missing versions

trim quest
#

it runs on locally

#

im trying to upload on it jitpack

eternal night
#

idk if that is possible

trim quest
#

i have 0 issue on local.

eternal night
#

jitpack would need to run build tools

#

before your build

trim quest
#

how ?

eternal night
#

idk

chrome beacon
#

yeah I don't think it allows for that

trim quest
#

mfnalex have api with the same architecture as mine.

chrome beacon
#

Set it up to only deploy the api to jitpack

#

do you really need the nms implementation on there

brazen tartan
trim quest
#

wait

#

look at the nms submodule of JeffLib

chrome beacon
#

JeffLib isn't on Jitpack though

eternal night
#

💀

chrome beacon
#

Alex has his own repo

eternal night
#

the repository isn't the issue. The fact you are trying to use jitpack as CI is the issue

trim quest
eternal night
#

jitpack can not do much beyond run mvm deploy, so running build tools prior is tough. Setup your own jenkins or something. Can probably also do that via github actions

chrome beacon
#

Github actions can run BuildTools

#

There'a premade thing for that

brazen tartan
#

is there any other info that I need to post for the issue

pure dagger
#

can you use spring boot for spigot ?

#

spring boot and spigot.. both

chrome beacon
#

yeah

#

you can

pure dagger
#

but should i ?

chrome beacon
#

up to you

#

Personally I prefer Javalin

sullen marlin
#

Kinda over complicated for 99.9% of plugins tbh

chrome beacon
#

I wrote Spring and Javalin support for it

buoyant viper
grand flint
#

how do u get colored emojis on discord

#

🙏🏻

#

🙏🏼

#

\🙏🏽

#

wtf

buoyant viper
drowsy helm
#

🙏🏾

buoyant viper
brazen tartan
sullen marlin
#

What have you tried and what is the issue?

slender elbow
#

nothing and everything

sullen marlin
#

You can use the old method, setCustomModelData, or the new method, setCustomModelDataComponent

brazen tartan
#

I have tried many different assignments for the namespace and manually compiling the resourcepack from blockbench

sullen marlin
#

For the latter, see, getCustomModelDataComponent

#

Do you have a /give command that works?

brazen tartan
#

i do yes

#

the item is fine I just cant assign the model

sullen marlin
#

What's the give command

#

And what's the code you've tried

brazen tartan
#

its a recipie and I'm trying to set the model component in the plugin

sullen marlin
#

Share the command and code please

brazen tartan
#

that is the full code for the item and I use the persistent data to do things elsewhere

grand flint
#

Use
```
-- code
```

brazen tartan
#

?

grand flint
#
public static void createFireStaff() {

        // calls the getItem() function to help create basic item parameters
        ItemStack item = getItem(new ItemStack(Material.STICK), "Fire Staff", "Use combinations of right and left clicks to cast various unique spells!");

        // assigns the itemStack's metadata to a variable for manipulation
        ItemMeta meta = item.getItemMeta();

        // asserts that the item being created does indeed have metadata
        assert meta != null;

        // adds a unique flag to the item so it can be recognised later
        meta.getPersistentDataContainer().set(castingItemKey, PersistentDataType.BOOLEAN, true);

        // adds other modifiers to the item's metadata
        meta.setMaxStackSize(1);
        meta.addEnchant(Enchantment.INFINITY, 0, false);
        meta.setItemModel(new NamespacedKey("freeminecraftmodels", "firestaff"));

        // adds the manipulated data to the item being created
        item.setItemMeta(meta);

        // sets the global item to the one made in this creator
        fireStaff = item;
    }
grand flint
sullen marlin
#

You said you had a working give command, what's that?

brazen tartan
#

I use a recipie

sullen marlin
#

Ok what's the recipe

grand flint
#

good lawd

#

?paste

undone axleBOT
brazen tartan
#

does that work?

grand flint
#

yup it does

brazen tartan
#

kk

#

sorry lmao

grand flint
#

for code;
```java
-- code
```

brazen tartan
#

ah okay

grand flint
#

but only for short code, for long code use paste

brazen tartan
#

kk

#

thanks

#

but anyways the recipie and custom functions i've made so far work fine in game

#

its just the model im really struggling with

#

i think its because im using the namespace incorrectly

thorn isle
#

didn't you say you had a functioning give command

brazen tartan
#

o-o

#

that is in game

thorn isle
#

that's not a give command

brazen tartan
#

right

#

is there a reason I would need one?

#

im assigning the model data for the item directly to the item's mettadata and crafting an item with those properties

brazen tartan
thorn isle
brazen tartan
#

this is the resource pack im trying to referencehttps://drive.google.com/file/d/1TwuMx1FA4m_fhcwgY_MQyqeNxrKu0_rn/view?usp=sharing

thorn isle
#

and the easiest way to see the data is a give command with the data in it

#

alternatively, /paper dumpitem (or whatever extant spigot alternative) on a functioning item

#

functioning as in renders the model correctly

brazen tartan
#

ok how should I go about making a command for the item

#

I'm struggling with the namespace syntax to assign the texture to the item

#

which is required to make the command

#

the setItemModel() function does the same thing as the command to my knowlege

#

unless there are autofill prompts in game for the pack

sullen marlin
#

What command. Can you please share the command

brazen tartan
#

I dont have a give command with the model data and dont know how to make one, I assumed you guys ment a command in my plugin that gave the item

#

which was wrong of me to assume

#

could somebody help me make one?

potent crescent
#

where can i post

thorn isle
#

the issue here is that there are two areas of knowledge involved in making this happen; resourcepack knowledge (what data an item has to have to get matched with resourcepack predicates), and api knowledge (what api methods to call to get what data on an item)

#

most of the people here have the latter, but i and probably most others don't have the former

#

largely because mojang keeps fucking changing it every other version

#

i could probably see magmaguy knowing the answer, maybe someone else does as well; if not, try asking in a datapack/vanilla discord

#

the redstone nerds are good at resourcepacks

brazen tartan
#

ok thank you

#

sorry for not knowing how to do things

brazen tartan
#

👋

trim quest
#

@eternal night @chrome beacon

name: Build All Supported Spigot NMS Jars

on:
  workflow_dispatch:
  push:
    branches: [main]

jobs:
  build-nms:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        spigot-ver: [
          "1.21.5", "1.21.4", "1.21.3", "1.21.1", "1.20.4", "1.20.2", "1.20.1",
          "1.19.4", "1.19.3", "1.19.2", "1.18.2", "1.18.1", "1.17.1",
          "1.16.5", "1.16.2", "1.16.1", "1.15", "1.14", "1.13.1", "1.13",
          "1.12", "1.11", "1.10.2"
        ]

    steps:
      - name: Checkout
        uses: actions/checkout@v4

      - name: Determine Java version for Spigot version
        id: java
        run: |
          ver="${{ matrix.spigot-ver }}"
          if [[ "$ver" =~ ^1\.(8|9|10|11|12)(\.|$) ]]; then
            echo "version=8" >> $GITHUB_OUTPUT
          elif [[ "$ver" =~ ^1\.(13|14|15|16)(\.|$) ]]; then
            echo "version=11" >> $GITHUB_OUTPUT
          elif [[ "$ver" =~ ^1\.(17|18|19)(\.|$) ]]; then
            echo "version=17" >> $GITHUB_OUTPUT
          else
            echo "version=21" >> $GITHUB_OUTPUT
          fi

      - name: Set up Java
        uses: actions/setup-java@v4
        with:
          distribution: temurin
          java-version: ${{ steps.java.outputs.version }}

      - name: Download BuildTools
        run: |
          mkdir -p BuildTools
          cd BuildTools
          curl -L -o BuildTools.jar https://hub.spigotmc.org/jenkins/job/BuildTools/lastSuccessfulBuild/artifact/target/BuildTools.jar

      - name: Build Spigot NMS
        run: |
          cd BuildTools
          VER="${{ matrix.spigot-ver }}"
          if [[ "$VER" =~ ^1\.(17|18|19|20|21)(\.|$) ]]; then
            java -jar BuildTools.jar --rev $VER --remapped
          else
            java -jar BuildTools.jar --rev $VER
          fi

      - name: Archive output jars
        uses: actions/upload-artifact@v4
        with:
          name: spigot-${{ matrix.spigot-ver }}
          path: BuildTools/*.jar
#
8s
Run cd BuildTools
[--rev, 1.19.4, --remapped]
Loading BuildTools version: git-BuildTools-844940e-193 (#193)
Java Version: Java 21
Current Path: /home/runner/work/EranoAPI-Parent/EranoAPI-Parent/BuildTools
Attempting to build version: '1.19.4' use --rev <version> to override
openjdk version "21.0.8" 2025-07-15 LTS
git version 2.50.1
OpenJDK Runtime Environment Temurin-21.0.8+9 (build 21.0.8+9-LTS)
OpenJDK 64-Bit Server VM Temurin-21.0.8+9 (build 21.0.8+9-LTS, mixed mode, sharing)
Found version
{
    "name": "3763",
    "description": "Jenkins build 3763",
    "refs": {
        "BuildData": "4d9436f7b66190ad21fe4e3975b73a36b7ad2a7e",
        "Bukkit": "5dbedae1cbbc70791dcfc374c4c8da35db309a44",
        "CraftBukkit": "5a5e43ee6bab92419f7a7cfdb39af61a74b226ab",
        "Spigot": "7d7b241e353e86ee90ad025dab0262b050a6fe4a"
    },
    "toolsVersion": 148,
    "javaVersions": [61, 64]
}

*** The version you have requested to build requires Java versions between [Java 17, Java 20], but you are using Java 21
*** Please rerun BuildTools using an appropriate Java version. For obvious reasons outdated MC versions do not support Java versions that did not exist at their release.
Error: Process completed with exit code 1.
chrome beacon
trim quest
chrome beacon
#

what does your plugin solve

trim quest
#

not my plugin i mean like my workflow

#

github actions script i mean

chrome beacon
#

solve what exactly

trim quest
#
step 1: download build tools

step 2: choose compatible java version for specific spigot version
1.8-1.12 -> uses java 8
1.12-1.16 -> uses java 11
1.17 - 1.19 -> uses java 17
1.19+ -> uses java 21

step 3: build -remapped if spigot version greater than 17 otherwise generate obfuscated
#
spigot versions that i use :
spigot-ver: [
          "1.21.5", "1.21.4", "1.21.3", "1.21.1", "1.20.4", "1.20.2", "1.20.1",
          "1.19.4", "1.19.3", "1.19.2", "1.18.2", "1.18.1", "1.17.1",
          "1.16.5", "1.16.2", "1.16.1", "1.15", "1.14", "1.13.1", "1.13",
          "1.12", "1.11", "1.10.2"
        ]
trim quest
#

i want to automate it with only bash scripts/yml configuration , without depending to others.

chrome beacon
#

but why

#

anyways if you really want your own (which will be slower since it doesn't do any caching) you need to add all the java versions

trim quest
#

JDK's you mean right

#

actually im very newbie on this

chrome beacon
#

yes

short pilot
#

how can you use the config.yml config implementation (directly editing the file) without having to do a full check every time you update your plugin to have new config values?

thorn isle
#

what now

opal juniper
molten hearth
#

I think he just wants to know how to make his config.yml automatically pull/add new config values in case he updates his plugin and adds some new fields

short pilot
thorn isle
#

i recommend configurate

short pilot
#

there's a config implementation where you manually create the file using builder classes and strings, and also an implementation im using where you just directly make the config.yml in resources folder

#

but the latter has an issue of having more workaroudns needed for updating

#

Arounds*

chrome beacon
short pilot
#

any links?

#

i have never heard of that oop

chrome beacon
#

Basically they have a migration/transformation system

#

If you don't want to use configurate you can easily replicate that on your own

short pilot
#

hmm ok

timber eagle
#

setting an armorstand's velocity does not work correctly

#

i have gravity off

rotund ravine
#

Did u wait a tick

timber eagle
#

yes

#

its literally not moving

rotund ravine
#

Probably due to gravity being off

timber eagle
#

oh

#

i can't use a marker too

#

how weird

young knoll
#

Huh

#

I knew about marker but not the no gravity one

timber eagle
#

ok i got something to work

#

i had to multiply the speed a bit

#

thanks

short pilot
#

ugh im going through a headache with configs

#

can anyone give an approach that wont use configurate

slender elbow
#

manually replicating what it does? 🤷‍♀️

short pilot
#

hmm using FileConfiguration config = this.getConfig();
?

#

class

rotund ravine
#

What do you even want

#

Oh i see

dapper walrus
#

buildtools gui doesn't work
it opens as if it's a terminal

eternal night
#

|| good ||

dapper walrus
#

lynx

#

I had something to ask you now that I remember

#

Are you maintaining crackshot by any chance?

eternal night
#

no I do not xD tf is crackshot

dapper walrus
#

the guns plugin

eternal night
#

spigot says the author is called Shampaggon

buoyant viper
dapper walrus
#

im wondering because it was done in an entire class (CSDirector), so I am redoing it in a proper structure

buoyant viper
#

WHY ME

dapper walrus
#

i'm trying to download 1.7.2 api

buoyant viper
#

oh thats

dapper walrus
#

i got no clue how to do it using your frontend

buoyant viper
#

not gonna work

dapper walrus
#

why that?

buoyant viper
#

im pretty sure BuildTools only builds 1.8+