#help-development

1 messages · Page 1361 of 1

sharp bough
#
@EventHandler
    public void onUseOfSyringe(PlayerDropItemEvent e) {
        e.setCancelled(true);
        Player player = e.getPlayer();
        if (player.isSneaking()) {
      
            player.setItemInHand(new ItemStack(Material.STAINED_GLASS_PANE));
  }
}
sharp bough
#

hm

#

you must be adding another glass pane somewhere in your code

#

does it keep adding?

#

or just up to 2?

quaint mantle
#

try this:

@EventHandler
    public void onUseOfSyringe(PlayerDropItemEvent e) {
        e.setCancelled(true);
        Player player = e.getPlayer();
        if (player.isSneaking()) {
            if (!player.getItemInHand().equals(Material.STAINED_GLASS_PANE)){
                player.setItemInHand(Material.STAINED_GLASS_PANE);
            }
        }
    }
gusty notch
quaint mantle
#

oh sorry

gusty notch
quaint mantle
#

set the player.setItemInHand(//item);

gusty notch
#

yup

quaint mantle
#

ohh i may know why already

gusty notch
#

oh?

quaint mantle
#

bcz when u get the grass then theres grass in hand

gusty notch
#

mhm?

quaint mantle
#

what do you btw want to do?

#

with the event

#

like when player drops item you want to only give the glass and remove the grass?

gusty notch
#

yup

#

exactly that

quaint mantle
#

okay

gusty notch
#

but only when shifting as you can see in the code

quaint mantle
#

and by remove grass you want to remvoe any blocks

gusty notch
#

yes

quaint mantle
#

okay

#
@EventHandler
    public void onUseOfSyringe(PlayerDropItemEvent e) {
        Player player = e.getPlayer();
        Item dropItem = e.getItemDrop();
        
        if (player.isSneaking()) {
            e.setCancelled(true);
            
            dropItem.setItemStack(null);

            player.setItemInHand(item);
        }
    }
#

try

wide dune
#
@EventHandler
    private void onDeposit(InventoryClickEvent e) {
        if (e.getCurrentItem() != null) {
            if (e.getCurrentItem().getItemMeta().hasDisplayName()) {
                if (e.getCurrentItem().getItemMeta().getDisplayName().contains("God Sword")) {
                    if (e.getInventory().getType() == InventoryType.CHEST || e.getInventory().getType() == InventoryType.ENDER_CHEST) {
                        e.setCancelled(true);
                    }
                }
            }
        }
    }```
Simple bit of code to not allow the "God Sword" to be placed in a chest/echest, cancels every inventory click event in the echest except hotkeying it in.
Is this a minecraft glitch??
crude charm
#

second dont check for an item meta check for an nbt tag

wide dune
#

its not the point

#

the rest of it is working

crude charm
#

its not clean

#

at all

wide dune
#

Ik, I've been working on a lot of things to test why this is an issue

quaint mantle
wide dune
#

But InventoryClicks are still being cancelled always except when hotkey'd in

crude charm
#

oh wait ur checking for an item in an inv

crude charm
#

then check for the slot

wide dune
#

even tho e.getAction() has has InventoryAction.HOTBAR_SWAP

crude charm
#

use a switch

#

and check for the slot

wide dune
#

You talking to me??

crude charm
#

yes

wide dune
#

I'm not

#

I am just trying to cancel the placement of the "God Sword" into a chest/echest

#

It works perfectly, except hotkeying in

#

Which makes no sense

crude charm
#

oh

#

make a loop that checks if it is in

quaint mantle
#

try InventoryMoveEvent ig?

crude charm
#

cause the event wont check for it

#

the one ur using

wide dune
#

Ik what that is, problem is I need to be able to get the player from it

#

and with that you cant

crude charm
#

why not

#

u can check the inv

#

and if type is chest

wide dune
#

thats exactly what I do

#

it makes no sense, InventoryClickEvent is supposed to trigger on a HotKey swap

quaint mantle
quaint mantle
#

i would've said

quaint mantle
wide dune
#

You cant get a player from that

crude charm
#

first off

@EventHandler
    private void onDeposit(InventoryClickEvent e) {
                if (e.getCurrentItem() = null)  return; 
                if (!e.getCurrentItem().getItemMeta().getDisplayName().equals("God Sword")) return; 
                if (!e.getInventory().getType() == InventoryType.CHEST || !e.getInventory().getType() == InventoryType.ENDER_CHEST)  return; 

                        e.setCancelled(true);
                    }
                }
#

remove the nesting

#

@wide dune

wide dune
#

Okay

quaint mantle
#

"{ return; }" bruh

wide dune
#

Thanks, I'll try that

crude charm
wide dune
#

yeah you wouldnt need the {} in that btw haha

crude charm
#

and Im not in an ide

#

ik

wide dune
#

1 min

#

might not have

crude charm
#

ok

#

can someone help me?

I have everything in the right place and it is working for my friend yet when I do "mvn package" it doesent add any of the configs nor plugin.yml (anything in the resources folder) into the compiled jar.

wide dune
#

Once again ZoiBox, same thing

#

every action is blocked except hotkey swap

#

I think its a MC glitch

crude charm
#

ik my way is just cleaner

#

but

#

u might be able to use a loop

gusty notch
crude charm
#

while (player is in chest inv) {
e.setCanceled
}

#

idk if that would work

#

but u can try

wide dune
#

tbh

#

they can put in chests but not take out

crude charm
#

also

#

alot

#

of the time

#

its a local host issue

#

and works fine on the actual server

wide dune
#

Nah not this one haha

crude charm
#

oh ok

wide dune
#

I'm not on local

crude charm
#

cause ive had it alot I cancel moving in invs and stuff and it doesnet work on local but works on vps

wide dune
#

yeye

#

tested that one earlier

#

its such a weird issue

crude charm
#

ye

#

can someone help me?

I have everything in the right place and it is working for my friend yet when I do "mvn package" it doesent add any of the configs nor plugin.yml (anything in the resources folder) into the compiled jar

quaint mantle
#

hey my bungeecord and spigot server dont communicate together through plugin messages the bungee dont do actions idk why i did debugs and the debugs dont send idk why

humble stirrup
#

do you have a player connected?

quaint mantle
#

yes i do

#

and when i try to do player.sendData doesnt do anything when player.getServerInfo.sendData it returns null

#

like sends npe to console

crude charm
#

please its 4am Im not going to bed till this is fixed

eternal oxide
#

line 28 is commented out on your bungee. It will alwasy return at that point

#

ah block comment

#

You are sending a FORWARD packet from yoru bungee. Thats a client message

#

comes from client to bungee

quaint mantle
#

nevermind it got sent

humble stirrup
#

lose the casts

#

item.setDurability(item.getDurability() - 1);

#

if you dont know what a cast is you need to go and learn more java

paper viper
#

Why do you cast it to int/short?

oak mica
humble stirrup
#

well something in that function is null

#

send the full stacktrace

oak mica
#

[Server thread/WARN]: [Elementals] Task #213 for Elementals v1.5.1 generated an exception
java.lang.NullPointerException: null
at net.Plugins.Elemental.ManaSystem.addMana(ManaSystem.java:38) ~[?:?]
at net.Plugins.Elemental.ManaSystem$1.run(ManaSystem.java:66) ~[?:?]
at org.bukkit.craftbukkit.v1_16_R1.scheduler.CraftTask.run(CraftTask.java:81) ~[minecraft_server.jar:git-Spigot-0287a20-7560f5f]
at org.bukkit.craftbukkit.v1_16_R1.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:400) ~[minecraft_server.jar:git-Spigot-0287a20-7560f5f]
at net.minecraft.server.v1_16_R1.MinecraftServer.b(MinecraftServer.java:1061) ~[minecraft_server.jar:git-Spigot-0287a20-7560f5f]
at net.minecraft.server.v1_16_R1.DedicatedServer.b(DedicatedServer.java:354) ~[minecraft_server.jar:git-Spigot-0287a20-7560f5f]
at net.minecraft.server.v1_16_R1.MinecraftServer.a(MinecraftServer.java:1009) ~[minecraft_server.jar:git-Spigot-0287a20-7560f5f]
at net.minecraft.server.v1_16_R1.MinecraftServer.v(MinecraftServer.java:848) ~[minecraft_server.jar:git-Spigot-0287a20-7560f5f]
at net.minecraft.server.v1_16_R1.MinecraftServer.lambda$0(MinecraftServer.java:164) ~[minecraft_server.jar:git-Spigot-0287a20-7560f5f]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_281]

#

it is the addManaPerSecond run causing problem but actual problem stems from addMana line 38 which is bossbar.get(p.getUniqueId()).setTitle("Arcane Power: " + getPlayerMana(p));

paper viper
#

for one thing

                bossbar.get(p.getUniqueId()).setTitle("Arcane Power: " + getPlayerMana(p));
                bossbar.get(p.getUniqueId()).setProgress(getPlayerMana(p)/ MAX_ArcanePower);
                bossbar.get(p.getUniqueId()).setVisible(true);
                bossbar.get(p.getUniqueId()).addPlayer(p);

please use variables. And

        Double original = getPlayerMana(p);
        Double now = original + amount;

why are you using Double? Use the primitive double instead. It is much faster and uses way less memory.

#

Java has autoboxing and unboxing. So it should be able to cast that Double to double

#

Plus, the nullpointerexception probably means the key doesn't exist in the map

cinder thistle
#

Public Class main_class() {
Public Void Main(new string() {} args[]) {
Return Console.log{"Hallo, world"}:
}
}
Why is this not working

oak mica
paper viper
#

then it may be something else

#

we don't know what the heck you are talking about without a full stacktrace

paper viper
#

send your full error

paper viper
#

oh

#

lmfoa

#

i didnt see that

oak mica
#

I get spammed

#

every second

quaint mantle
#

then fix it

deft helm
#

Debugging time boy!

oak mica
#

for 2 hours straight

#

Why else would I come here

quaint mantle
#

to tell us you’re getting spam

oak mica
quaint mantle
#

lime 38 of mana system has a null value

#

debug

#

line*

oak mica
deft helm
#

Show the line

quaint mantle
#

dude there’s a null value, there’s not much else to help you with

#

either the boss bar being returned is null or the mana is null

deft helm
#

Show line 38

quaint mantle
#

i’m going to assume it’s the mana because you’re not using primitives

#

hence if you’re gonna do that then check if the mana “Double” (notice i didn’t say “double”) is null first

quaint mantle
#

it means it’s null because you’re working with number objects and not primitives

#

check if original is null before working with it or else change the number type(s) to primitives

humble stirrup
#

even the code is social distancing

oak mica
#

Ok but I don't know what a primitave is and how to change type to primitive

quaint mantle
#

lookup java primitives

idle pike
#

_lucyy haha

sullen dome
#
if (!(amount == 0))```
instead use 
```java
if (amount != 0)```
oak mica
sullen dome
#

doesnt fix it, but better

humble stirrup
#

no im joking with you

quaint mantle
#

🧍‍♂️

#

Bruh

oak mica
#

ok

deft helm
sullen dome
#

i wrote it here

#

obv in code i use auto-formatting lmao

quaint mantle
#

damn rivex

#

u gonna take that from him?

#

sheeesh

deft helm
#

Not that hard to type a space though

quaint mantle
#

LOL

deft helm
#

Don’t need formatting for that

sullen dome
#

who cares in discord

idle pike
sullen dome
#

then go into you ide, and use your spaces dafuq
have fun with it

deft helm
#

It’s Google’s style of coding

sullen dome
#

and dont trash me with such dumb shit

quaint mantle
#

** mortal kombat voice ** finish him

deft helm
#

I didn’t trash you lol

#

I was js

humble stirrup
#

And add a fucking space between if and the bracket !!!

#

looks like trashing to me

#

¯_(ツ)_/¯

sullen dome
#

^

deft helm
#

Biased

quaint mantle
#

it’s not that deep guys

humble stirrup
#

yeah but bitching at people is fun lmao

quaint mantle
#

yeah it is

deft helm
#

If you couldn’t tell that was sarcastic/ironic you have issues

humble stirrup
#

ikr :P

quaint mantle
#

i don’t think it’s anyone’s fault let’s all be friends

sullen dome
quaint mantle
#

i think the issue is that text online can be perceived the way it wasn’t meant to

#

❤️

deft helm
sullen dome
#

6666*

#

wonder how long it takes, until i get the first

you spelled it wrong

unreal kayak
#

how do i public Javadocs of my plugin? and put it in subdomain (my domain is bluetree242.tk)

#

its a private repo btw

humble stirrup
#

.tk

deft helm
#

Lol

sullen dome
#

so you just wanna link your repo to your domain?

unreal kayak
#

.tk might be free but its what I can get now

unreal kayak
humble stirrup
#

just copy the generated html to somewhere in your webroot

sullen dome
#

it's 6€ per year lol

#

for a german .de

paper viper
#

uhh, javadocs but closed source?

deft helm
#

Yea it’s mw bro .tks are lit

unreal kayak
#

this thing

paper viper
#

that doesnt seem like a great combination

#

lmao

#

@unreal kayak you have to manually write javadocs then

#

Then generate it either using the plugin or one in ide

deft helm
#

Lmao no

unreal kayak
#

I can write them in ide

#

but I want the website that show docs like that

deft helm
#

Have you tried googling?

paper viper
#

it auto generates the web content files for you

paper viper
#

if you use the built in ide tool

#

or a plugin

#

(maven/gradle)

humble stirrup
#

if youre using maven you want the javadoc:javadoc goal

deft helm
#

Maven 🤮

paper viper
#

i honestly use both

deft helm
#

😮

humble stirrup
#

whats wrong with maven

#

it does the job fine

deft helm
#

Gradle > maven

humble stirrup
#

sure its a little verbose but it works

deft helm
#

Bloated

humble stirrup
#

youre bloated

paper viper
#

meh i mean its not bad, but some people just prefer gradle over it cause its faster and has better codelike integration in it

deft helm
#

Lmfao

sullen dome
#

dude you're not even verified

#

no one cares about your opinion

deft helm
#

I joined 49 mins ago

paper viper
#

lmao

sullen dome
#

verifying is one command

#

doesnt take 49 min imo

deft helm
#

Plus I came here for a question

#

Which hasn’t been answered

eternal oxide
#

If you are experienced with Gradle use it. If you are not Maven is simpler and its perfect for plugin development.

sullen dome
#

what is your question

deft helm
#

Why you haven’t stopped talking to me 🤔

sullen dome
#

because i wonder what you're shittalking about all the time

deft helm
#

Shittalk?

sullen dome
#

looks like you need attention

so i gave it to you

real vapor
#

Let's keep conversation civil.

sullen dome
#

because i'm a nice person

paper viper
#

aiyo chill

deft helm
sullen dome
paper viper
#

chill

sullen dome
#

i'm chilled

#

just asking for his question lol

deft helm
#

First message I sent is my question

sullen dome
#

you think i search in 200 messages?

deft helm
#

This

deft helm
sullen dome
#

and i dont work with packets in no way, so no clue.
if your question goes under messages, just ask after like 15 minutes again

deft helm
sullen dome
#

dunno

deft helm
quaint mantle
#

hey how can i hide the score numbers in the scoreboard ?

bleak shard
#

No way

quaint mantle
#

frick xd

bleak shard
#

You can only set them to 0

#

If they are really disgusting

quaint mantle
#

okay

deft helm
deft helm
#

Hardcoded to have numbers

eternal oxide
#

you can't hide them, but you can set them all to zero

quaint mantle
#

okay ty

eternal oxide
paper viper
#

thats pretty hot

quaint mantle
#

thats cool

bleak shard
#

Pitch and volume

eternal oxide
#

reversed

bleak shard
#

Don't remember the order

paper falcon
#

guys can someone DM me and help with code :D

#

I'm beginner of beginners

eternal oxide
#

?ask

queen dragonBOT
#

If you have a question, please just ask it. Don't look for staff or topic experts. Don't ask to ask or ask if people are awake or available. Just ask the question to the channel straight out, and wait patiently for a reply.

paper falcon
#

oh

deft helm
paper falcon
#

?guys can someone DM me and help with code, it's simple (not for me tho)

#

bruh

#

?ask guys can someone DM me and help with code, it's simple (not for me tho)

deft helm
#

Bro

paper falcon
#

?ASK

deft helm
#

Click the link

#

just ask

scarlet path
#

So I have a plugin which Im putting into multiple servers which are connected by bungeecord. Is it possible for them to send eachother data?

paper falcon
#

lol

deft helm
eternal oxide
scarlet path
#

Thanks

deft helm
paper falcon
#

I coded it so that when u type /kit in-game (if u have perm) you will be granted kit, so i wanted to improve it by adding more kits, so before creating another kit (let's play /kit god for example).. I wanted to change the command from /kit to /kit default... BUT I CAN'T I did everything and I can't change basecommand from /kit ONLY to /kit default HELP

deft helm
#

The base command cannot contain a space

paper falcon
#

wut?!

sage dock
#

Can I send packages from the spigot plugin to bungeecord?
I'm sorry if I wrote something wrong, because English is not my native language

eternal oxide
#

the command is /kit.

#

you can add extra args in the onCommand

paper falcon
eternal oxide
#
if (args.length >= 1) {
  switch (args[0].toLowerCase()) {
  case "god":
    //code here
    break;
  case "team":
    //code here
    break;
  default:
    //code here
  }
}```
cinder thistle
paper falcon
eternal oxide
#

you add whatever sections you want. Each one would be a kit

paper falcon
#

oh, thought it was sum else

#

you made it so simple

#

thank you sooo much elgar

#

ur best

#

@eternal oxide

eternal oxide
#

np

ivory sleet
eternal oxide
#

better than what?

quaint mantle
eternal oxide
#

Sorry I have no idea what you are asking

quaint mantle
#

I know many who use a switch case with the args

paper falcon
#

hey elgar, now when I do random letters like /kit sfafda it still gives me kit default

#

/kit god works tho

eternal oxide
#

yes, anything unknown will enter the default

lost matrix
# quaint mantle

You should create a method that takes the seconds left and evaluates the String to display.

paper falcon
lost matrix
# quaint mantle why?

So your code is modular and can react to arbitrary input instead of hard coded cases.

quaint mantle
#

kk

#

ty

#

but what is better? a switch case or else if args[0].equals... ?

eternal oxide
#

if you actually want a kit called default ad a section case "default":

paper falcon
#

ohh

#

yayy it works now tysm

lost matrix
#

But switch case with default is fine.

#

Same goes for if else

lost matrix
# quaint mantle ty

But i would def create new methods for each case so my onCommand method has only one responsibility.

paper falcon
eternal oxide
#

if its an unknown kit it will enter the default: section

paper falcon
eternal oxide
#

no

#

default: is still called for unknown kits

paper falcon
#

no

#

when I type /kit adiofnadfo

#

nothing happens

#

but /kit default

#

and /kit god

#

are only ones that work

eternal oxide
#

then you removed default:

paper falcon
#

I changed it into case "default" as u told me to

#

and it worked

scarlet path
#

whats the difference between using Bukkit.getLogger().info() and System.out.println()?

eternal oxide
#

I didn't say change it. I said add a case

paper falcon
#

yeahh that

#

I did it

#

and it worked

lost matrix
# scarlet path whats the difference between using Bukkit.getLogger().info() and System.out.prin...

System.out.println() just prints using stdout for the current jvm instance and Bukkit.getLogger().info() will use the slf4j logger implementation for proper logging.
The benefit of logging is that you can have a ton of different logs in your code and if you need to print them out you can change the log level of your logger.
So you can deploy your code with all the debug messages (The higher the log level the more verbose the messages should be) without having to remove your logging messages.
You just need to adjust the log level when you deploy you plugin before uploading it to Spigot. You could even provide a config entry for the user to specify different log levels
based on how verbose the user wants it console output to be.

eternal oxide
# paper falcon https://prnt.sc/1154ahg

you need both case "default": and default:. case "default": is called when you actually type /kit default. default: is called when anything that is not known is typed.

paper falcon
#

ohhh

#

so I should use case "default": for specific kit, and default:for unknown kits?

eternal oxide
#

Anything in a case statement is a kit type, everything else is sent to default (no case statement).

paper falcon
#

ok, thanks man

#

I'll try to add some error msg to default:

#

and prevent it from giving any kit to play

#

er

#

do I have to use break; before default:too?

#

BRO i actually did it

unreal kayak
paper falcon
#
                    default:
                        player.sendMessage(ChatColor.DARK_RED + "" + "This kit doesn't exist!");```
humble stirrup
unreal kayak
#

go to Arena u will find some docs

humble stirrup
#

yeah these arent docs

#

just a list of functions

unreal kayak
#

there are docs

humble stirrup
#

yeah these are far too vague

unreal kayak
humble stirrup
#

every method has a comment stating exactly what it does and details of each parameter

solemn shoal
#

is there a way to detect the items dropped when a specific player mines a block?

humble stirrup
#

oop they havent updated properly, ill have to rebuild them

humble stirrup
unreal kayak
#

@humble stirrup I have all api that people can use with comments, and what they return, bc only Arena and ArenaBuilder can be used as the api, others are gonna be given comments later

humble stirrup
#

if you can't use them then dont publish them as part of the javadocs

unreal kayak
#

u can use them

humble stirrup
unreal kayak
#

but rarely because they are only used for me to get stuff, no addons will need them

humble stirrup
#

event listeners have no reason to be part of your javadocs

unreal kayak
#

intellij put it not me

humble stirrup
#

no you put it

#

you built them

unreal kayak
humble stirrup
#

you still built them

#

split your api and impl into separate submodules

unreal kayak
#

oh wait forgot xd I'm stupid

humble stirrup
#

well this is fantastic, i rewrote some javadocs but they've all disappeared

silk hamlet
#

yikers

quaint mantle
#

Is there a way to kick players when getting their name from an array? Not by player.kickPlayer ?

outer crane
#

anydesk code... ouch

humble stirrup
#

what's wrong with kickPlayer

#

also please use a pastebin

#

?paste if you hate yourself

queen dragonBOT
quaint mantle
#

Sure hold on 🙂

humble stirrup
#

what are you trying to achieve by this

unreal kayak
#

@humble stirrup can you pls send your pastebin files? I wanna make my own

solemn shoal
humble stirrup
#

gh/lucyy-mc/haste-server

solemn shoal
#

lol

outer crane
#

still some kind of remote software... it hurts

humble stirrup
#

is my wifi card being crap or did that take forever to load

outer crane
#

i do that when i'm waiting for school to open

quaint mantle
humble stirrup
#

if it's a valid player name then it'll work

#

should be uuid based tho

quaint mantle
#

yea indeed ill swap that up thanks ill check if player kick works was not sure

outer crane
#

if you use CLOUD or brigadier and set the type to string you wont have issues

#

source: i develop velocity plugins and that uses brigadier

quaint mantle
unreal kayak
humble stirrup
unreal kayak
#

hmm, I really wanted it but its my pastebin sorry

#

im gonna put the about#md back -> I feel u should be mentioned as the creator

ivory sleet
#

lol

humble stirrup
#

its my pastebin

#

yeah no its not

unreal kayak
#

its on my website thats what I mean

humble stirrup
#

please read

#

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

wraith fractal
#

guys can i make alot of money from minecraft server with my own unique plugins??

unreal kayak
#

I'm gonna keep title but I'm sure to keep the about#md

#

because u worked hard

#

🙂

humble stirrup
#

profit is not our main goal, nor should it be yours

unreal kayak
#

@humble stirrup I'm about to get ur about.md back

#

done

#

people gonna laugh that I couldn't make my own but whatever

wraith fractal
#

and spigot is a library

humble stirrup
wraith fractal
#

??

humble stirrup
#

no

#

i write plugins

unreal kayak
#

where do I change this?

wraith fractal
#

i love minecraft but idk should i enter it or no cuz iam afraid to not make money after all of that effort

humble stirrup
#

you will not make money

#

period

daring sierra
#

You know most people write plugins as a hobby here?

unreal kayak
humble stirrup
#

that's left as an exercise to the syadmin

#

:P

wraith fractal
humble stirrup
#

because theyre hypixel

#

you are not hypixel

eternal oxide
#

I've been writing MC plugin for 7-8 years (ish). The amount you make wouldn't even cover the electricity cost to host a server.

daring sierra
#

I wouldn't trust giving my monies to some "Pro_Dev_Yeah" guy tbh

unreal kayak
#

😢 tell how to remove

quaint mantle
#

"Pro_Dev" yikes

humble stirrup
#

yeah!

daring sierra
#

YEAH

humble stirrup
#

lmao

quaint mantle
unreal kayak
#

(yet)

humble stirrup
#

its stupidly simple if you know anything about websites

#

no js

unreal kayak
#

I can't find it in the html

#

still

humble stirrup
#

then you need to go to Specsavers

unreal kayak
#

tell steps to remove .-.

humble stirrup
#

no

#

why would i tell you how to remove my credit from my own work

unreal kayak
#

I left it

humble stirrup
#

removing my name from the meta is removing my credit

daring sierra
unreal kayak
#

not even there and still shown

wraith fractal
cunning cloak
#

How do I make PLAYER_HEAD work in a 1.12 GUI, whenever I put Material.PLAYER_HEAD it doesn't recognise it, any ideas?

humble stirrup
daring sierra
unreal kayak
#

😦

humble stirrup
#

go read the license again

#

it states very clearly that i don't have to help

quaint mantle
humble stirrup
#

not if they're not premium B)

daring sierra
wraith fractal
daring sierra
humble stirrup
#

what reda is trying to say is that you look and act 12

wraith fractal
wraith fractal
quaint mantle
#

hey, everybody needs a little self confidence boost, dont they?
i thought internet has outgrown moking online nicknames since runescape fell off the radar.

daring sierra
sturdy patrol
quaint mantle
#

im curious. what's the last thing you people coded? is it plugins or spigot issue fixes?

humble stirrup
#

been working on a new css sheet for my javadocs

sturdy patrol
#

In my case, plugins. never fixed spigot issues. At most unmade some papermc patch for my personnal use x)

daring sierra
humble stirrup
#

css is what makes websites do the pretty

daring sierra
#

ooo

#

coolio

humble stirrup
#

yeah

#

javadocs are kinda ugly by default

unreal kayak
#

im just gonna keep it for you, its ur work, until i learn js

humble stirrup
#

completely removing an authors name from something is a bit scummy ngl

quaint mantle
#

javadocs style is preference. i only once saw a differently styled javadoc and it wasn't much of a good 1st experience. everything in some weird place and looking different from usual. lol

humble stirrup
#

yeah im keeping the general layout, just changing the font and colours to fit my personal branding

#

function comes first

unreal kayak
#

anyway its very good server

#

does it have api?

humble stirrup
#

its just hastebin

#

only the frontent is my work

quiet hearth
#

Im having an issue with what appears to be the plugin.yml Could not load 'plugins\CraftableMonsterEggs.jar' in folder 'plugins' org.bukkit.plugin.InvalidDescriptionException: Invalid plugin.yml at org.bukkit.plugin.java.JavaPluginLoader.getPluginDescription(JavaPluginLoader.java:162) ~[patched_1.16.5.jar:git-Paper-570] at org.bukkit.plugin.SimplePluginManager.loadPlugins(SimplePluginManager.java:148) ~[patched_1.16.5.jar:git-Paper-570] at org.bukkit.craftbukkit.v1_16_R3.CraftServer.loadPlugins(CraftServer.jav

#

a:389) ~[patched_1.16.5.jar:git-Paper-570] at net.minecraft.server.v1_16_R3.DedicatedServer.init(DedicatedServer.java:251) ~[patched_1.16.5.jar:git-Paper-570] at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:1055) ~[patched_1.16.5.jar:git-Paper-570] at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$a$0(MinecraftServer.java:289) ~[patched_1.16.5.jar:git-Paper-570] at java.lang.Thread.run(Thread.java:832) [?:?] Caused by: java.io.FileNotFoundException: Jar does not contain plugin.yml

humble stirrup
#

are you using maven or gradle

quiet hearth
#

if someone could help me out, id appreciate it, no rush

humble stirrup
quiet hearth
#

me?

humble stirrup
#

yes

quiet hearth
#

no

humble stirrup
#

ah

unreal kayak
#

he probably using the ide

quiet hearth
#

yes

humble stirrup
#

ij or eclipse?

unreal kayak
#

lmao

quaint mantle
#

Caused by: java.io.FileNotFoundException: Jar does not contain plugin.yml

quiet hearth
#

ij

unreal kayak
#

lol

#

use maven or gradle

quaint mantle
#

included plugin.yml in the build?

quiet hearth
#

yes

sturdy patrol
#

Is it in the root of the jar?

stone sinew
#

Screen shot your IDE/project

quiet hearth
#

you can post images here..?

sturdy patrol
#

And if you open the jar with an archive manager, can you find the plugin.yml inside?

humble stirrup
#

you need to verify to post images

quaint mantle
#

@humble stirrup Have you ever done anything with vue.js?

humble stirrup
#

nope

quaint mantle
#

kk

humble stirrup
#

i don't really work with frameworks

quiet hearth
humble stirrup
#

take plugin.yml out of your package

#

just put it in src

quaint mantle
humble stirrup
#

yeah i have been meaning to

quiet hearth
quaint mantle
#

Is using craftbukkit api faster than using spigot api

humble stirrup
#

neither are apis

#

both implement the bukkit api

#

in general use spigot

quaint mantle
#

isnt craftbukkit lighter

unreal kayak
quaint mantle
#

"your"

#

kekw

daring sierra
quaint mantle
#

spigot isnt an api?

#

i need performance for my plugin

#

i mean it does have its functions added to the bukkit

daring sierra
#

spigot ftw spigot

humble stirrup
#

not what the api is

quaint mantle
#

@unreal kayak in my eyes u are scum

#

that is good right

#
                if (isCrashSkull(item)) {
                    return true;
                }
                SkullMeta skull = (SkullMeta) item.getItemMeta();
                if (skull.getOwner() != null) {
                    if (skull.getOwner().length() > 16 || skull.getOwner().contains("\u00A7")) {
                        return true;
                    }
                }
            }```
humble stirrup
#

depends on what you're trying to do

#

I would early return if possible

quaint mantle
#

get skull owner length

humble stirrup
floral flare
#

Is there any plugin or method to make a command that stores the CMD error of a server?

humble stirrup
#

what do you mean by a CMD error

unreal kayak
humble stirrup
#

yeah that's bs

#

it's literally the exact same code

floral flare
humble stirrup
#

I do not check what people put

unreal kayak
#

but my data aren't stored on ur server

dusty herald
#

hypixel premium plugin DogKek

humble stirrup
#

why does it matter

unreal kayak
#

maybe u steal my code (will not happen but alot of people do it)

humble stirrup
#

if you think people give a shit about your code then you are very wrong

dusty herald
#

oh my god

#

no one wants to steal your code here

#

we're here to help

unreal kayak
#

ik

humble stirrup
#

someone screenshot that and pm please

unreal kayak
#

and I want to help people too but I have no time

humble stirrup
#

going straight in the meme folder

unreal kayak
#

ik my code is useless and bad but still valuable to me

humble stirrup
#

clearly you have time to steal my pastebin tho :P

floral flare
unreal kayak
#

I wanted to ask u to learn js and html but can't :/

dusty herald
#

what?

humble stirrup
quaint mantle
# quaint mantle get skull owner length

so that skull.getOwner()returns a string if you need that. string.length() ... how do you use it later on?
maybe i dont see the point in the overall scheme.
I'd go with OfflinePlayer getOwningPlayer()
and then it would be a bit more readable. and the cached value make some operations faster later.

paper viper
#

lmao

quaint mantle
dusty herald
#

open source is only for cool people

unreal kayak
humble stirrup
#

no lmao

paper viper
#

1 whole project

dusty herald
#

no one puts that many in one class

paper viper
#

what do you think

#

dumbass lol

dusty herald
#

if you're putting all of your code into one class, you're doing it wrong

unreal kayak
paper viper
#

Ah yes 130k in one class

unreal kayak
#

fixed

floral flare
unreal kayak
#

let me remove everything about "Lucy"

paper viper
#

lmfao

dusty herald
#

the fact you're using .tk is hilarious

paper viper
#

^

humble stirrup
#

that's technically illegal

#

you know that?

unreal kayak
#

I think the license say I can edit code, not sure

paper viper
#

who the hell is going to use ur paste

unreal kayak
#

me only

paper viper
#

i think lucy wants your paste to open source

unreal kayak
#

and my friend

humble stirrup
#

I host it myself for a reason

dusty herald
#

what license is your project under lucy?

humble stirrup
#

it's based on hastebin so mit

dusty herald
#

👀

#

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

unreal kayak
#

anyway Lucy you made the pastebin from bad to super good

#

I swear

paper viper
#

you have to open source it

quaint mantle
#

i knew this one dude who would just write 14k lines of html css js in index.html and got paid good for it.
his lates qoute "now everybody wants a damn shop and databases, nobody wants to recieve a customer call or email anymore"

humble stirrup
#

and you're violating the license

#

please correct this or I will issue takedowns

dusty herald
unreal kayak
#

what?

paper viper
#

You didn't even read the license carefully Blue_Tree

unreal kayak
#

its usefull

#

and its ur design

#

everyone know

humble stirrup
#

it doesn't follow the terms of the license

paper viper
#

"mostly hacked together"

#

literally you just copied it

quaint mantle
#

I mean lucyy technically has every right to take your site down if you do not follow the MIT license as well, so open up github and put the source there

paper viper
#

^

unreal kayak
#

I clonned the repo and used it for my own, also I can do these changes on my fork

humble stirrup
#

I will do it

dusty herald
#

is your fork MIT?

paper viper
#

but it must be open source Blue_Tree

#

and it must be MIT

humble stirrup
#

yes it is, inherits from upstream

unreal kayak
#

what must be open source? my edits?

paper viper
#

whole thing

humble stirrup
#

yes

#

go read the license

unreal kayak
#

its simple I forked already

paper viper
daring sierra
#

FBI OPEN SAUCE

paper viper
#

"Copyright © 2011-2012 John Crepezzi"

#

whos that

#

is that Lucy or Blue_Tree

humble stirrup
#

hastebin author I imagine

#

my upstream

paper viper
#

Oh

unreal kayak
#

if u could fork it from hastebin, I can fork It from you

dusty herald
paper viper
#

you were talking about it being closed source Blue_Tree

unreal kayak
dusty herald
#

me

humble stirrup
#

I at least had the dignity to maintain the license and appropriately credit the upstream

paper viper
dusty herald
#

ah

unreal kayak
#

its the api for spigot resource info

dusty herald
#

you couldn't just use the updated api from spigot?

unreal kayak
#

hmm it show stuff we can't get

humble stirrup
#

your changes are literally just removing my name from everything anyway

paper viper
#

kekw

unreal kayak
#

except

paper viper
#

Blue_Tree just use lucy's paste

unreal kayak
#

i respect your code

paper viper
#

oMg WoW oNe fIlE

humble stirrup
#

clearly you dont

dusty herald
#

what more info do you need?

#

what does spiget give you the api doesn't thonk

paper viper
#

spiget is prolly outdated

unreal kayak
#

no I'm serious I just don't want people to tell me that I don't know how to remove you from the files

#

I do

#

but I wanna leave it

humble stirrup
#

just don't remove me

#

simple

dusty herald
#

drags __lucyy towards the trash can

humble stirrup
#

I leave names of authors all over the place

unreal kayak
#

anyway I'm leaving you in the pastebin

quaint mantle
#

If u remove lucy i remove your site. Easy.

unreal kayak
#

reason: your hard work

humble stirrup
paper viper
#

Blue_Tree you don't understand the point of forking

humble stirrup
#

:D

paper viper
#

forking isnt to relabel everything

#

lmfao

#

it is to contribute

unreal kayak
#

ye true

quaint mantle
paper viper
#

you arent contributing

#

you are just relabeling everything

#

there is no different between using lucy's hosted site

#

and yours

#

safe yourself some bandwith

#

lmfao

unreal kayak
#

I'm gonna make the description configurable lol

daring sierra
humble stirrup
paper viper
#

have you even see his discordsrv plugin?

#

he literally complained why it isnt premium yet

humble stirrup
#

nope

unreal kayak
#

anyway I leave the name

unreal kayak
paper viper
#

yes you did

unreal kayak
#

I wanna delete it from spigot it cause lag

quaint mantle
#

this looks sweaty

#

so sweaty

humble stirrup
#

imagine writing premium plugins

unreal kayak
#

i was talking about my new plugin

paper viper
unreal kayak
#

TheBridge242

dusty herald
#

should I make my awesome plugin premium? DogKek /s

humble stirrup
#

iml files in the repo 👀

#

looks like someone doesn't know how to git

paper viper
#

have you seen the class names?

humble stirrup
#

nope

unreal kayak
#

I made this plugin when I was a super begginer, forgot about CompletableFuture and everything is on main thread, and alot of lag happen, I just wanna recode or no longer update the plugin

paper viper
dusty herald
#

I was doing joke, I'm probably not going to make anything premium

quaint mantle
paper viper
#

yes i learned naming conventions 2 months

#

lmfao

dusty herald
#

at most I will but still post it as a release on git too

unreal kayak
paper viper
#

sir.. it was 2 months ago

#

look at the commits

dusty herald
#

JESUS CHRIST

unreal kayak
#

it was on november

paper viper
#

yes

humble stirrup
#

also you publish javadocs for your impl code

paper viper
#

3 months ago is november

#

lol

unreal kayak
#

that was last update

paper viper
#

??

unreal kayak
#

not first commit

paper viper
#

still bad code

#

lol

unreal kayak
#

ye its bad code

#

and I will recode

paper viper
#

WTF

humble stirrup
#

feel free to destroy my code tho

paper viper
#

WTFFFFF

#

LUCY LOOK AT THAT CLASS

unreal kayak
paper viper
#

DOES ANYONE SEE THAT

dusty herald
#

yes

#

i saw that

unreal quartz
#

no i'm illiterate

humble stirrup
#

static much lmao

unreal kayak
#

idc if my code is bad, I was a begginer whan i started, and spigotmc discord is full of people worse than me

paper viper
#

damn

#

you think of that mindset eh

unreal kayak
#

he is right its bad code

humble stirrup
#

my code is shite

dusty herald
#
if (!this.getDescription().getName().equals("DiscordSRVUtils")) {
            setEnabled(false);
        }``` the good old anti-fork
daring sierra
#

I'm on phone and my screen was just IMPORT IMPORT IMPORT

humble stirrup
#

why?

unreal kayak
#

idk gonna remove later

paper viper
#

no im being serious, that isn't bad code. It's horrific

humble stirrup
#

you seem to like renaming other people's stuff

paper viper
#

^

#

I'm sorry but you just suck at coding

unreal kayak
#

but... this plugin is no longer maintained (don't tell anyone people in my discord server will be mad)

humble stirrup
#

it's still your code

paper viper
#

it was updated last 2 months ago

#

and still ur code

unreal quartz
#

brb gonna tell everyone in your discord

daring sierra
#

What's a This Coard?

unreal kayak
unreal quartz
#

idk i can't read

dusty herald
quaint mantle
#

Where is the meme Channel...

dusty herald
humble stirrup
#

literally any channel

quaint mantle
dusty herald
daring sierra
wary harness
#

any one know what packet is sent to server

#

when player craft with auto recipe book

#

we are having problem

#

people usuing spam bot

#

and lagging server

#

with auto crafting thing

dusty herald
#

no idea but you might look there

wary harness
wary harness
#

ok thanks

#

so what would u suggest

#

how to solw this

#

do runnable

#

and check for every player

#

if they are clicking more then some number which is set

paper viper
#

lol

lost matrix
# wary harness if they are clicking more then some number which is set

Listen for incoming packets and track the time between each sent. Then throw away each packet that does come earlier than N ms relative to the last one.
You could also create a function that increases the delta time when a high frequency is detected so that dt(t1) is directly proportional to f where f is the packet frequency measured over dt(t0).
Or in simple words: If ony boi spams then you increase his time between accepted packets.
So the first 5 packets come in normally and after that you start increasing the time.

eternal oxide
#

If they are spam crafting it shoudl trigger a crafting event

#

even if they are just spamming packets

lost matrix
#

I also thought that the craft event is probably the heavy part and not the amount of packets. Because those should be handled pretty easily.

eternal oxide
#

If that's the case just detect the last 10 crafts per player and average the time between first and last.

wary harness
#

ok thanks

eternal oxide
#

If you get 10 crafts in a VERY short time, kick the player

#

Are you sure its a spam crafter and not some automated crafting machine?

opal sluice
#

Hi, how could I calculate chunks corners with chunks coordinates ?

wary harness
#

some guy recoreded it how he is crashing

#

it is auto clicker

#

made to click

#

every 20 ms

eternal oxide
#

just track events then

wary harness
#

I already made protocollib

#

code

#

so will go first with that

eternal oxide
opal sluice
#

Yeah, for example, 1 -15

#

so the x and the z of the chunk

eternal oxide
#

from chunk multiply by 16, +15 to get opposite corner

opal sluice
#

Oh.. that make sense 😂

quiet hearth
#

java.lang.IllegalArgumentException: Invalid key. Must be [a-z0-9/._-]: creeperEgg It is probably some dumb mistake, but I do not see any issue

lost matrix
#

By "last hit" you mean the killing blow? Then yes.

quiet hearth
eternal night
quiet hearth
lost matrix
eternal night
#

Okay 😭

lost matrix
#

Yes. The death event is only fired if the entity received damage and its health is at zero.

#

I dont think you should manually fire the EntityDeathEvent. It will be called when the health is set to zero...

#

I think the cause is specified when the event is created. I dont see a way of changing that.

#

Unless you fire the event yourself

lost matrix
wide dune
#

https://paste.md-5.net/zamahakeyo.js
Just making an Inventory serializer/deserializer but theres issues with ItemStack.deserialize(map) - double being casted to an int
Could anyone help please?

stiff tulip
#

yo i have no ideas for what kind of plugin i should make, any ideas?

sage swift
#

?services

queen dragonBOT
sage swift
#

lol

quaint mantle
#

how is that requesting or offering a service 🤔

sage swift
#

he's requesting ideas

#

but i was meaning that he could look at what people are asking for there

#

get some ideas from that

patent ice
quaint mantle
patent ice
#

?

quaint mantle
#

make me a plugin that orders shrooms to my house when I think about them

#

thanks

vapid thorn
#

Question. I noticed getting the locations BIOME in any form of datapack custom biome gives a NPE. is there a way around this or is this just a thing to deal with?
Edit: Nevermind ran across a thing from engine hub talking about bukkit not supporting the custom biomes and thats why. eh hmm work around it is for that annoyance.

covert urchin
#

omg @vapid thorn you're alive!!

vapid thorn
#

yes i am alive

#

been busy

covert urchin
#

😄 Haven't seen you in ages!

vapid thorn
#

hi @covert urchin

#

yea forgot bukkit didnt support the custom biomes. so yea it broke wayshrines

#

lol

covert urchin
#

I just got back into the joys of deving spigot plugins 😄

#

😮

vapid thorn
#

so i had to do a NPE check on the biomes and replace with "Custom Biome"

#

lol

covert urchin
#

why are you running on Bukkit?

vapid thorn
#

paper

#

tbh

covert urchin
#

o.O

vapid thorn
#

bukkit base shows in #biome all the vanilla biomes in keyed

covert urchin
#

so paper/spigot/bukkit don't support custom biomes?

vapid thorn
#

apparently not

#

for example

#

warped plains

#

they are actually named custom biomes

under the namespace starmute:<biomeName>

covert urchin
#

interesting 😮

#

so if these things don't support the thing that your plugin runs on... how is this even a thing?

vapid thorn
#

probably because bukkit the base api doesnt even know what biome the location is in because its not a keyed item

#

voice?

covert urchin
#

sure

young knoll
#

Spigot only recognizes the default biomes in the biome enum, unfortunately

vapid thorn
#

yea figured that

#

is it because these arent actually listed in the enum list?

young knoll
#

Correct

vapid thorn
#

possible to then add it in a custom instance or inject it maybe?

young knoll
#

I mean you can probably inject new entries into an enum

#

Not easily though

#

You’re probably better off just using NMS

candid galleon
#

doesn't injecting stuff into an enum sort of get rid of the point of the enum

covert urchin
#

hey @vapid thorn I'm not sure you're even still around but I'm here again.

vapid thorn
#

hi

covert urchin
#

trying to figure out how to build my plugin in this IDE. I'm trying out a new java IDE called paint.exe but whenever I export the project I just get a png?

covert urchin
#

oh I see, is png a plugin name generator? I'm thinking that I have to convert this with Excel in order to generate names for my plugin objects to make them more perpendicular?

austere spade
#

@covert urchin make sure you're using https://ms-paint-i.de/ and it's updated

#

paint won't work without that installed

#

you should get correct exporting then

quiet ice
#

That IDE is developed by someone on the paper server (they might be even here too)

austere spade
#

Rubba

#

hes a friend of mine

#

would recommend

alpine urchin
#

thats my fav IDE

daring sierra
alpine urchin
#

github previews the png

#

go fix ur browser

daring sierra
#

fone

alpine urchin
#

LICENSED UNDER MIT

#

are u following the license

#

give credit

#

for that code

daring sierra
#

what?

alpine urchin
#

license notice and copyright holder notice

#

if you use my code

daring sierra
#

im not using your code lmfao

alpine urchin
#

better not be

daring sierra
#

chill idgaf wht ur doing

humble stirrup
#

are we bluetreeing again

quiet ice
#

spigot is strange today

alpine urchin
#

isnt it alwats strange

#

alwayts

#

always

quiet ice
#

there are days where it isn't

alpine urchin
#

rarely#

quiet ice
#

maybe

alpine urchin
#

md_5
🙏

#

🦵 🍗

#

karate md5

#

masta md5

daring sierra
#

looks more like a dick than karate imo