#help-archived

1 messages · Page 111 of 1

final osprey
#

also when i take the domain controllers offline the server is unable to verify playernamess

frigid ember
#

jetbrains made it possible to use kt

#

i just wanted to know if you knew sth better

opal marsh
#

@final osprey windows has trouble deleting files that have other open file handles

frigid ember
#

not many know kotlin for scripting

sturdy oar
#

You can use Ruby 🤷‍♂️

frigid ember
#

to support other scripts for modding in my game

daring crane
#

oh youre suddenly telling us what you want

final osprey
#

@opal marsh i know that but why does it cause the server to hang and restart?

zinc ingot
#

graalvm is the new thing

opal marsh
#

@final osprey so if anything else is opening the files while the server is running, it could mess with stuff

frigid ember
#

i mentioned already

zinc ingot
#

idk if u checked that out yet

frigid ember
#

this is second time i mentioned

opal marsh
#

@final osprey here, I'm gonna take it to dms lol

final osprey
#

@opal marsh i agree

wanton delta
#

Hey does anyone know if there is a way of setting the view distance per world? I've tried ((CraftWorld) world).getHandle().spigotConfig.viewDistance = 3; but it seems to cause some wonkyness and chunks have a hard time loading

outer meteor
#

Why doesn't it let me make premium resources?

wanton delta
#

?premium

worldly heathBOT
azure finch
#
public void Corazon(PlayerInventory playerInventory){
        if (playerInventory.contains(Material.getMaterial("minecraft:structure_void"))){
            
        }
#

Which variable shoud i put to put player.setHealth(24)?

#

Like
Player player = (Player) ..... ;

opal marsh
#

@azure finch I'm confused on what you're asking. Where are you calling the function from?

azure finch
#

?

opal marsh
#

this is a function you've written, yes?

azure finch
#

I want to give more health if a player has an structure void

opal marsh
#

you can add a Player parameter to the method

azure finch
#

How i do that?

ashen stirrup
#

Are you able to have an Asynchronous task with 2 Task Timers within?

opal marsh
azure finch
#

Ty im literally starting srry

opal marsh
#

@ashen stirrup do you have an async task and within that task you're registering two task timers? I'm confused

#

@azure finch no problem. I don't know of any off the top of my head but I'm sure there are many members here who can direct you do a good Java book

ashen stirrup
#
countdownRun = true;
new BukkitRunnable(){
    @Override
    public void run() {
        new BukkitRunnable(){
            Location animation = location.clone().add(0.0, 33.0, 0.0);
            @Override
            public void run() {
                if (countdownRun){
                    animation.subtract(0.0, 4.0, 0.0);
                    animation.getBlock().setType(Material.CHEST);
                    animation.clone().add(0.0, 4.0, 0.0).getBlock().setType(Material.AIR);
                } else {
                    this.cancel();
                }
            }
    }.runTaskTimer(MineTropicalSupplyDrop.getPlugin(MineTropicalSupplyDrop.class), 0L, 20L);
    new BukkitRunnable(){
        int countdown = 0;
        @Override
        public void run() {
            if (countdown != 8){
                location.clone().getWorld().spawnEntity(location, EntityType.FIREWORK);
                countdown++;
            } else{
                countdownRun = false;
                this.cancel();
            }
        }
    }.runTaskTimer(MineTropicalSupplyDrop.getPlugin(MineTropicalSupplyDrop.class), 0L, 20*4);
}        }.runTaskAsynchronously(MineTropicalSupplyDrop.getPlugin(MineTropicalSupplyDrop.class));
opal marsh
#

the syntax is a little hard to read with discord's formatting and wrapping but as far as I can tell, that should work fine

#

is it not working for some reason?

azure finch
#

@opal marsh I don´t know how to make the parameter 😦

opal marsh
#

@azure finch I'll dm you

tiny pebble
#

What do I put for api-version? IDE says it needs to be a string, though forums say it needs to be an integer (1.13, 1.14, or 1.15). Just confused

opal marsh
#

1.13, 1.14, and 1.15 are not integers. can you link to the forums you're referencing?

#

to directly answer your question, put the version of the api you're using in your pom.xml

#

so for "1.15.2-R0.1-SNAPSHOT", I'd put "1.15"

tiny pebble
torn robin
#

do both of those links say 1.13 is a number

#

@Nullable String getAPIVersion​() Gives the API version which this plugin is designed to support.

tiny pebble
#

I'm saying that my IDE is saying that it's a number. My IDE is yelling at me so I'm basically just asking if this is right

torn robin
#
api-version
The version of the API you want to use.
1.13, 1.14, and 1.15 are the available versions.
This will signal to the server that your plugin has been coded with a specific server version in mind, and that it should not apply any sort of backwards compatibility measures. As a result you will also need to make sure that you have programmed your code to account for reading of older configurations, data, etc... .Each server version can decide how compatibility is achieved, unknown or future versions will prevent the plugin from enabling. As of the 1.14 release, the api-version 1.13 is still allowed - however future versions may drop backwards support based on this version.
Example:
Code (YAML):
api-version: 1.15
#

I imagine either works

opal marsh
#

don't worry about the message but if you want, I think you can probably just wrap it in quotes so it's a clear string

torn robin
#

assuming the number can be cast to a string and that's how it works

#

1.15 and '1.15' probably both work, i'd stick to just using the number format

fickle surge
#

i have a kit plugin, but i need to give player a way to redeem money
i have vault

fickle surge
#

i just need the command

opal marsh
#

can you elaborate on what you mean by "redeem money"?

fickle surge
#

sorry i am italian, not very good at english. i mean some sort of paper sheet and when you right click on it, it gives you money

opal marsh
#

if you're using Essentials, you can modify the worth.yml file to enable selling paper

#

though that would enable selling of all paper, not just the paper from the kit

fickle surge
#

i am not talking of paper, it could be every block

#

ok, whatever, i'll use commands.

torpid field
#

How would I go about making a sort of pets-plugin where you can spawn and get a mob to follow you around?

opal marsh
#

you may need to either use NMS (or reflection) or the Paper api to do pathfinding

hoary parcel
#

pls use my api

#

its nice

timid valley
#

you mean my api 😛 I did the pathfinding one lol

opal marsh
#

is it just me (I'm almost undoubtedly doing things wrong) or is the persistent metadata api really obtuse to work with?

#

I can't find a way to make a string list serialize directly to the string list nbt tags

#

and yeah, I know, I can just serialize it as a byte array and use that

#

it's also pretty annoying being unable to query keys and unable to check if a removal was successful

strange grove
#

hey does anyone know how to detect an item frame?

opal marsh
#

in what context? in a chunk?

strange grove
#

are you talking to me?

opal marsh
#

yes

strange grove
#

well in a radius

#

and i want a hologram placed there but i do not know how to do that

#

and i've tried multiple times

#

and scoured the internet in search of an answer

#

so

#

I would appreciatte the help

#

🙂

opal marsh
strange grove
#

oh I will check this

#

thx for the help @opal marsh

opal marsh
#

np

strange grove
#

I will tell you if I have any problems or errors many thanks!

ripe ledge
#

Someone knows a plugin or something the make the players on server in like 1.15.2 to be able walk into other players? (Like most of the serveres)

opal marsh
#

if you're using paper, you can set enable-player-collisions: false in the paper.yml

hoary parcel
#

you mean my api 😛 I did the pathfinding one lol
@timid valley I mean, he would use both apis, but am still infected with the bad spigot names, when I hear pathfinding I still think of mob goals...

wanton delta
#

Hey i dont mean to ask for the 3rd time but is there a nice way to set a view distance per world

opal marsh
#

did you check out the source code I linked?

timid valley
#

by api no, config file yes

wanton delta
#

Its not really what i need

#

I just need to do it in world load

timid valley
#

well spigot doesnt have an api for that

wanton delta
#

When i use that method aikar, the chunks seem to have trouble loading

#

If u look at my msg

#

I try to alter the config when creating a wod

timid valley
#

but, there is a method deep in the nms source you can call to change view distance

#

changing what you linked isnt the right way

wanton delta
#

Yea, i figured

#

It works but causes a lot of issues

timid valley
#

check ChunkMapDistance

#

theres a method in there to change view distance

wanton delta
#

Where can that be found?

#

How to obtain

timid valley
#

you do have a copy of the server source code right... ?

wanton delta
#

yea

timid valley
#

open the file ChunkMapDistance

#

and inspect the methods to find the one

#

im not at code i cant find it for you 😛

#

its going to be a one letter method name with a single int parameter

wanton delta
#

no i meant like is that gotten from world or smth

timid valley
#

no its literally a function that "changes view distance"

wanton delta
#

i think youre not understanding me

timid valley
#

no I am, your not understanding me

#

you want to change view distance, you need to call the function to actually change the view distance

wanton delta
#

correct

timid valley
#

the spigot config is NOT the source of truth

#

a method deep in nms internals is

wanton delta
#

i was just confused if ChunkMapDistance was a variable you got from a getter

timid valley
#

world.getChunkProvider().playerChunkMap.distanceSomething

#

actually it might live in player chunk map

wanton delta
#

yea thats what im seeing

timid valley
#

oh, the method is literally setViewDistance

wanton delta
#

yea i noticed that lol im testing it out

#

that works perfect

#

thanks

tiny pebble
#

is there a way to do notes in my config.yml file?

bronze marten
#

notes

pallid turret
#

I'm new to working with Bukkit worlds in plugins, would the Bukkit.getWorld() parameter be the filename or the world name inside MC?

#

Also do I have to load it before teleporting?

torn robin
#

world name

#

ideally the file name should also be the world name

#

and if it's not loaded yes

pallid turret
#

Ok thanks

#

How would I load it?

torn robin
#

new WorldCreator("world").createWorld();

pallid turret
#

Ok thanks!

torn robin
#

👍

strange grove
#

does anyone know how to get entities within a radius?

#

I would welcome the help!

#

😐

#

anyone there?

pallid turret
#

I think you can make BoundingBoxes, not sure if they're in Bukkit though

#

Yeah don't do that

strange grove
#

@pallid turret are you talking to me??

pallid turret
#

Yes

strange grove
#

ok

#

how can you get entities in a radius of a few blocks

pallid turret
#

Looks like there's this:

#
entity.getNearbyEntities(x, y, z);
strange grove
#

hmm

#

question how would you exactly define an entity variable

pallid turret
#

Well how do you want to check the entities?

strange grove
#

well i want to check

pallid turret
#

By another entity or a location in the world?

strange grove
#

if there is an itemframe in a radius of a few blocks

pallid turret
#

Ok

strange grove
#

because i'm using the animated frames plugin

pallid turret
#

What do you want to use to check the radius?

strange grove
#

well the player

pallid turret
#

A player it sounds like?

#

Ok

strange grove
#

yeah

#

because they're executing the afcreate command

#

a straight line from the center to the circumference of a circle or sphere.

pallid turret
#

Ok, I'm not sure if an itemframe is an entity

strange grove
#

i think it is

#

tho i'm not sure

pallid turret
#

It is yeah

#

I just checked and it looks like it is

strange grove
#

yeah

#

i was wondering how I could gert it

pallid turret
#

Let me make an example

strange grove
#

because i'm using the animated frames plugin

#

and want to make a hologram for an item frame

#

because the image needs a name

#

so they know which image they're deleting

#

or replacing

#

this is the last part

#

of my editing for now

pallid turret
#
for(Player player : Bukkit.getServer().getOnlinePlayers()) {
    for(Entity entity : player.getNearbyEntities(x, y, z)) {
        if(entity instanceof ItemFrame) {
            ItemFrame itemFrame = (ItemFrame) entity;
            //Do your code here for the itemframe
        }
    }
}
#

@strange grove

strange grove
#

thx

#

lemme see if it works in the plugin

pallid turret
#

You're welcome, good luck

#

It should

strange grove
#

@pallid turret

#

I have a problem!

#

(Player player : Bukkit.getServer().getOnlinePlayers()) {
for(Entity entity : player.getNearbyEntities(1, 1, 1)) {
if(entity instanceof ItemFrame) {
ItemFrame itemFrame = (ItemFrame) entity;
ArmorStand holograph = (ArmorStand) ((ItemFrame) Entity).getWorld().spawnEntity(((ItemFrame) Entity).getLocation(),EntityType.ARMOR_STAND);
holograph.setVisible(false);
holograph.setCustomNameVisible(true);
holograph.setCustomName(ChatColor.BLUE+"hello!");

            }
        }
    }
pallid turret
#

Ok, I don't think I can really help you with the ItemFrames though what is it?

strange grove
#

well

#

the hologram isn't spawning!

#

and i'm confused why it isn't

#

``(Player player : Bukkit.getServer().getOnlinePlayers()) {
for(Entity entity : player.getNearbyEntities(1, 1, 1)) {
if(entity instanceof ItemFrame) {
ItemFrame itemFrame = (ItemFrame) entity;
ArmorStand holograph = (ArmorStand) ((ItemFrame) Entity).getWorld().spawnEntity(((ItemFrame) Entity).getLocation(),EntityType.ARMOR_STAND);
holograph.setVisible(false);
holograph.setCustomNameVisible(true);
holograph.setCustomName(ChatColor.BLUE+"hello!");

            }
        }
    }`
pallid turret
#

Ok, I haven't messed with Holograms, sorry!

strange grove
#

it's all good

#

if you don't know

#

how to do holograms

#

i'm a newb myself

#

but thx for your help for most of the way!

#

hey does anoyne know what is wrong with my hologram?

#

I would apprecciate the help thx!

#

@anyone?

#

hmm

lusty basin
#

Our small server suddenly started lagging due to CPU. We think it's too many turtles from a turtle farm. When just one person on the server, we're seeing frequent "Can't keep up! Is the server overloaded" messages. Installed spigot and looking for any tuning docs. Also, the commands like /whitelist <username> aren't working with spigot. Known issue?

opal marsh
#

if there's many turtles in a small area, you can try decreasing max-entity-collisions in spigot.yml

keen compass
#

@lusty basin
whitelist add (username)

ebon charm
#

Am I able to hide entities from other player? -> I am the only one, who can see them

lusty basin
#

Thanks for the suggestions! Can I edit spigot.yml and reload without restarting server jar?

velvet halo
#

I recommend restarting instead of reloading

pallid turret
#

Can anyone help me find out why I can't copy a world and load it? Here's my code so far:

#

I'm trying to copy it to the main directory so I can load it, the problem is I have a map and want it to reset after each event

#

Or before

#

If there is a way to make a world not save when created again that would also work I think

remote ore
#

Good evening, I was told that with AuthMeReloaded I could hide the password at the time of / login by * in a way a streamer mode. Except that I've been looking for a day and I can't find it. Does anyone have the solution?

opal marsh
#

@remote ore as far as I'm aware, that's not possible without a mod. I don't think it can be done with packets alone

frigid ember
#

I'm only using citizens and plugins that are my own, but I don't send any messages out like this

tiny dagger
#

the entity is removed

remote ore
#

@opal marsh
I don't understand because a lot of big servers have this security except that there is no need to launcher to join their servers so there are no mods?

tiny dagger
#

did you player.remove()? 🤔

frigid ember
#

No

opal marsh
#

@remote ore can you give an example? I've never seen this before and I'm almost completely certain a plugin can't modify the chat box (without the chat/command suggestion fancy chat)

remote ore
#

@opal marsh I haven't played crack for a long time and therefore I no longer type my password. In this case, could you explain to me how to do so that the premiums do not need / login and that the cracks login as before?

#

It's a plugin?

opal marsh
#

that's just saving the session, nothing special there

remote ore
#

Yes but on my server the premium always have to /login

#

I don't want that

opal marsh
#

that's a completely different issue than hiding the password when /login is typed

frigid ember
opal marsh
#
    sessions:
        # Do you want to enable the session feature?
        # If enabled, when a player authenticates successfully,
        # his IP and his nickname is saved.
        # The next time the player joins the server, if his IP
        # is the same as last time and the timeout hasn't
        # expired, he will not need to authenticate.
        enabled: false
        # After how many minutes should a session expire?
        # A player's session ends after the timeout or if his IP has changed
        timeout: 10```
#

you have to enable sessions

pallid turret
#

Seems like it @remote ore

#

Can anyone help me find out why I can't copy a world and load it? Here's my code so far:
https://hastebin.com/atazosobof.java
I'm trying to copy it to the main directory so I can load it, the problem is I have a map and want it to reset after each event
Or before
If there is a way to make a world not save when created again that would also work I think?

remote ore
#

It works thank you very much

#

I have another problem, all the players see that when I connect : > [01:52:38 INFO]: [AuthMe] The user iFlyf_ has 2 accounts:

[01:52:38 INFO]: [AuthMe] §7§aiFlyf_§7, yungsoul_.

opal marsh
#

it looks like by default, sessions will expire after 10 minutes so you may want to bump that number up

#

I'm not familiar enough with AuthMe to know for sure but I suspect your other problem might be caused by a name change

remote ore
#

My brother and me are the admin of the server. We have the same IP and it write that always when me or my brother connect

opal marsh
#

in that case, you need to increase the max accounts per ip setting

remote ore
#

I've already changed "maxRegPerIp: 3
"

#

but it keeps putting it

opal marsh
#

it's probably just a regular notification

#

try toggling this: # Should we display all other accounts from a player when he joins? # permission: /authme.admin.accounts displayOtherAccounts: true

remote ore
#

It works perfectly thank you !

subtle blade
#

Hey guys, what causes this?
@frigid ember you have chat disabled on your client lol

frigid ember
#

Oh alright, md_5 thanks

#
        for (ItemStack item : p.getInventory().getContents()) {
        if (item == null)
            continue;

        ItemMeta meta = item.getItemMeta();
        List<String> lore = meta.getLore();

        if (lore == null) {
            continue;
        }

        if (NBTEditor.getItemTag(item, "price") == null) {
            p.sendMessage("no price");
            continue;
        }

        for (int i = lore.size() - 1; i > 1; i--) {
            lore.remove(i);
            p.sendMessage("lore changed: 1");

        }

        p.sendMessage("lore changed");
        meta.setLore(lore);
        item.setItemMeta(meta);
        }

        p.updateInventory();

Hey guys, I have this in inventory close event, but when I close the inventory the items only update the lore if I click then and put it back into my inventory

#

The last picture is after I click it and put it back into my inventory

gloomy thorn
#

Hi! I'm trying to make a Bungee plugin, so I need help to execute a command in the BungeeCord console from another server, because I'm making a plugin with a GUI and click events, so I need when the player clicks an specify item, plugin gets the BungeeCord console and execute a command in it. Rather, I'm making a BanGUI

timid valley
#

@remote ore the plugin you are looking for is FastLogin

#

I only learned about that plugins existence when we broke it lol ;3

#

gotta love the hacks some plugins do

#

it like hooks the login process to try to authenticate as an online-mode=true session for offline mode servers, so if a real mc account joins they auto login

remote ore
#

@timid valley you talk about the "streamer mode" or when I don't have to write /login for connection?

timid valley
#

login thing

#

to let legal accounts bypass authme and only make illegal players have to /login

torn robin
#

“illegal”

timid valley
#

yes, stealing software is illegal

remote ore
#

It works I just have to switch false an option

torn robin
#

Not all offline players are illegal

timid valley
#

yes they are

torn robin
#

🤔

timid valley
#

if you own the game, why wouldnt you login to your legal account?

lusty vortex
#

Not illegal to use your own auth servers 👀

subtle blade
#

You bet your ass it forcibly injects its own entity tracker implementation into the server!

pastel condor
#

for some reason this: public void openInventory(final Player player) { Bukkit.getScheduler().scheduleSyncDelayedTask(plugin, new Runnable() { public void run() { final Inventory inv = worldsAddedToGUI(player); player.openInventory(inv); } }, 1L); } is returning this [19:13:27] [Server thread/ERROR]: Could not pass event InventoryClickEvent to FreeBuildTools v1.0 java.lang.NoClassDefFoundError: com/voidcitymc/plugins/freebuildtools/WorldsAddedToGUI$1 at com.voidcitymc.plugins.freebuildtools.WorldsAddedToGUI.openInventory(WorldsAddedToGUI.java:95) ~[?:?]

fleet crane
#

run a clean build of your plugin

pastel condor
#

oh okay

#

oh thanks! That fixed so many bugs.

frigid ember
#
private final static HypixelSkyblock main = HypixelSkyblock.getPlugin(HypixelSkyblock.class);

Hey guys, is this correct use of static if I only want to use it once?

plush river
#

Why would you make it static when you could just call the function and make it a variable, and why would you only want to call it once?

#

It’s a very efficient/fast method

#

@frigid ember

frigid ember
#

@plush river when I get the Rank I'm using rank manager

    public Rank getRank() {
    Rank rank = main.getRankManager().getRank(rankKey);

    if (!rank.getKey().equals(rankKey)) {
        rankKey = rank.getKey();
    }

    return main.getRankManager().getRank(rankKey);
    }

https://paste.md-5.net/meligoqiho.cpp

plush river
#

It doesn’t look like it needs to be static in that context @frigid ember

frigid ember
#

alright, so @plush river would this be correct?

    private final HypixelSkyblock main = HypixelSkyblock.getPlugin(HypixelSkyblock.class);
plush river
#

Yeah, that should work

frigid ember
#

Anyone know how to fix a corrupted chunk

timid valley
#

Region Fixer

#

and restore from backup

frigid ember
#

Hey guys, why don't people use private constructors on main classes? I thought there weren't supposed to be multiple instances?

#

@frigid ember doesn't seem like it

#

Some websites even offer completely free web hosting with custom domains and free certification, so I wouldn't be surprised if they offer $0.75

#

some websites offer complete web hosting?

#

could you tell me those websites

#

most free websites have a lot of issues with them

silver glade
#

Hey guys I have a somewhat "complicated" question. I am running a modded 1.12.2 server using sponge and sponge plugins. Since I started a vanilla server and using spigot for plugins I've ended up purchasing some plugins that I really love and would like to run them on my modded server.

How would I go about running spigot on a forge server legally? I'm asking because I've made sure to follow the EULA and being a server owner during the Mojang bukkit DMCA debacle I don't want to jeopardise my server(s).

kind crow
#

What is the best way to display current world size to players? I mean the most optimized way in terms of performance

#

...and also players count

ripe ledge
#

There is an event when someone set the command inside command block?

pastel fox
#

I'm getting a super strange error!

#

Null pointer exception on this line:

#
OfflinePlayer[] offlinePlayers = Bukkit.getOfflinePlayers();
#

Is this possible in any context at all>

#

I mean

undone narwhal
#

Why do you need the Offline Players list?

pastel fox
#

That means Bukkit is null right?!

#

Oh

#

I made a lib for commands

#

I use it for player auto completes

undone narwhal
#

Bukkit can't be null, we have to chec khow the getOfflinePlayers works

#

Oh, then I'm going to do some search

pastel fox
#

Oh, you're right, there is a line on the stack trace above that

#

at org.bukkit.craftbukkit.v1_15_R1.CraftServer.getOfflinePlayers(CraftServer.java:1622) ~[patched_1.15.2.jar:git-Paper-273]

neat oxide
#

Anyone know the NMS call to get the preferred tool to break something

undone narwhal
#

@pastel fox Bukkit#getOfflinePlayers calls server.getOfflinePlayers and this method has a @NotNull annotation ^^

#

Can you please give me the whole error stack trace?

pastel fox
#

@undone narwhal sure, just trying something

#

It could also be SlimeWorldManager because it patches the server jar

#

In fact, now that I think about it

#

It doesn't save player data soo

vocal maple
#

damaged model tag isn't working on 1.13+?

#

I've tried it on 14 15 and snapshots, game just ignoring it

ripe ledge
#

There is an event when someone set the command inside command block?

silver glade
#

Hey guys I have a somewhat "complicated" question. I am running a modded 1.12.2 server using sponge and sponge plugins. Since I started a vanilla server and using spigot for plugins I've ended up purchasing some plugins that I really love and would like to run them on my modded server.

How would I go about running spigot on a forge server legally? I'm asking because I've made sure to follow the EULA and being a server owner during the Mojang bukkit DMCA debacle I don't want to jeopardise my server(s).
Any help on this?

fleet crane
#

not aware of anything past 1.7.10

silver glade
#

oof that sucks 😦

timid valley
#

@pastel fox for the love of everything great please never use that method!!

#

md_5 can we deprecate/spam console warnings for getOfflinePlayers() 😦

tiny dagger
#

getOfflinePlayers?

#

jeez

#

wait

#

how does that even work

timid valley
#

aka, load every player data file off disk blocking for long time

tiny dagger
#

oh

#

playerdata lol

#

big no

timid valley
#

if you got a long lived server with literally over 100k files there, bye bye server using that

tiny dagger
#

might be useful for imports tho

timid valley
#

imports?

tiny dagger
#

i dunno

#

like plugins doing something to old playerdata or something like that

timid valley
#

its better to keep record of players in an external db, even sqlite on disk is fine

#

like i have tab completion for "give me offline players who's played in past 90 days who's name starts with Ma"

tiny dagger
#

using a bubble sort

#

👌

bronze marten
#

bogo

velvet halo
fleet crane
#

nope Id open a bug report

velvet halo
#

I will make a video to show when it happens.

#

You can kind of see that I am sliding weirdly when I die.

frigid ember
#

Hey guys, what's the best plugin to stop flying in a vanilla server?

#

I mean the flying module from stuff like impact, WWE

glacial jetty
#

Hi everyone. Im kinda new to plugin dev and OOP coding in java (few mounth), same to git.

I am interested in question related to version control itself. I can't find anything that will help me how to understand what kind of changes affect your version. Like, in minecraft you have versions, like 1.15.2, 1.6, snapshots, beta, alpha...

So, my question is that I simply don't understand what kind of changes makes you understand how exactly to change version identifier. For example, I have version 1.0 and I made some changes and I don't understand is it 1.1 or 1.0.1 now.

I will be grateful for answering my question. May be there is some literature about it or document also.
Sorry if I wrote to wrong channel.

undone narwhal
#

You should start with version 1, unless you know that the first version you "release" is incomplete in some way.

As to how you increment the versions, that's up to you, but use the major, minor, build numbering as a guide.

It's not necessary to have every version you commit to source control as another version - you'll soon have a very large version number indeed. You only need to increment the version number (in some way) when you release a new version to the outside world.

So If you make a major change move from version 1.0.0.0 to version 2.0.0.0. If you make a smaller change move from 1.0.0.0 to 1.1.0.0. If you make a minor change then go from 1.0.0.0 to 1.0.1.0 (you fixed some bugs).

From StackOverflow

bronze marten
#

There are guidelines you can follow for major minor patch versions

#

Etc

glacial jetty
#

thank you

#

You should start with version 1, unless you know that the first version you "release" is incomplete in some way.

As to how you increment the versions, that's up to you, but use the major, minor, build numbering as a guide.

It's not necessary to have every version you commit to source control as another version - you'll soon have a very large version number indeed. You only need to increment the version number (in some way) when you release a new version to the outside world.

So If you make a major change move from version 1.0.0.0 to version 2.0.0.0. If you make a smaller change move from 1.0.0.0 to 1.1.0.0. If you make a minor change then go from 1.0.0.0 to 1.0.1.0 (you fixed some bugs).

From StackOverflow

But where minor ends and major starts? xD

bronze marten
#

I mean theyre guidelines

#

Its still up to you to decide

glacial jetty
#

Okay. Thank you very much!

torn robin
#

is it necessary to check item != null && item.getType() != Material.AIR

#

I use it a lot

#

(more accurately item == null || item.getType() == Material.AIR)

fleet crane
#

its probably not a bad idea

#

the API is a bit inconsistent

#

most things should just return null

#

but a couple things return air

#

I will say though if the method changes it will be a change from AIR -> null

torn robin
#

niceeee, good to know

fleet crane
#

so if it works at the moment with just null, you can leave it at that

torn robin
#

👍

plush river
#

@fleet crane change from air to null or null to air? It seems like the inventory API was changed from null -> air recently

#

in 1.8.8 you can get null items from the inventory but in 1.15.2 it was changed to return non null items and return AIR items

#

unless I'm mistaken

#

oof it looks like I'm wrong, I seem to remember somewhere giving back non-null items which used to give back nullable items 0.o

#
    /**
     * Gets the ItemStack at the given equipment slot in the inventory.
     *
     * @param slot the slot to get the ItemStack
     *
     * @return the ItemStack in the given slot
     */
    @NotNull
    public ItemStack getItem(@NotNull EquipmentSlot slot);``` it was this, looks like md was right, my bad
floral isle
#

hi everyone i am developing a plugin for holograms and i would like to add the possibility to create floating heads like floating items but i don't know how to do with usernames instead of base64 encryption

undone narwhal
#

You want to set textures with usernames ?

proven lotus
#

base64 encryption

#

what

iron nebula
#

Ah yes the famous base64 encryption

tiny dagger
#

best encryption too

floral isle
#

ok I give you an example so you understand better

#

you see that there is a holographic item and I would like to do the same with custom heads

#

@undone narwhal yes

frigid ember
#

Shut up all

undone narwhal
#

Marc have you tried searching online how to change player_skull owner? If I well remember there is a simple method to set texture with player name

#

What kind of plugin are you making btw? Just a basic hologram system?

floral isle
#

@undone narwhal no this is a custom made plugin for my server

undone narwhal
#

Okay :)

proven lotus
#

ummm

#

Could you send code @floral isle ?

#

AHHHHHH

#

I think I know what you want

#

Uhhh

#

That's quite hard

#

You need to find the class for custom skull

#

Or create the itemstack

#

And use SkullMeta

#

And create a dropped item from that ItemStack

undone narwhal
#

Or just set the skull in the helmet slot of an armorstand

proven lotus
#

Or just set the skull in the helmet slot of an armorstand
@undone narwhal He would then need edge cases for that,

#

So for regular items he would use dropped items

#

Or

floral isle
#

ok i want to create a comand like this /dh addline stone item:head %player_name%

proven lotus
#

@floral isle Okay

#

How do you display items?

#

Do you put it in the armor stand's head?

floral isle
#

no i using packet

proven lotus
#

Ahhh

undone narwhal
#

@proven lotus Edge case ?

proven lotus
#

Then use packets to create an armor stand

#

@proven lotus Edge case ?
@undone narwhal im dumb don't mind me

undone narwhal
#

@floral isle I tried last month tons of methods for spawning no gravity dropped items with nms. This is really really hard (i never succeed)

#

So i stronly recommand you using armorstand head

floral isle
#

@undone narwhal i need only a method for give a texture to floating head

undone narwhal
#

Just take your Itemstack instance

#

Get the ItemMeta cast it to SkullMeta

#

And search for a method like setOwner, set Player or smth like this

floral isle
#

ok i must go thx for the help

undone narwhal
#

K

floral isle
#

bye

undone narwhal
#

Have a nice day

frigid ember
#

Shut up

humble pier
#

????

#

@atomic rapids can I have your attention here please

#

@frigid ember keep screaming and saying "shut up" without any reason

#

He is being rude

remote socket
#

Where is the plugin prefix set? I'd like to change it

undone narwhal
#

You can change it in the plugin.yml if you're talking about the log console

#

Or if it is in the chat, depending on the plugin you're talking about

arctic hound
#
                 packet4.setEntityID(entityID);
                 packet4.setHeadYaw((byte) 150);
                 packet4.sendPacket(player);
                 
                 
                 WrapperPlayServerEntityLook packet5 = new WrapperPlayServerEntityLook();
                 packet5.setEntityID(entityID);
                 packet5.setPitch(270);
                 packet5.setYaw(150);
                 packet5.sendPacket(player);```
 Hello someone can help me and I have a fake ArmorStand for the player and the problem is now, I want to turn the ArmorStand head yaw and pitch, but they are not rotated
remote socket
#

You can change it in the plugin.yml if you're talking about the log console
@undone narwhal ty

#

Does anyone know why this is an error

undone narwhal
#

Go to your "Project Structure" > "Module" and check the language level.

remote socket
iron nebula
#

You can c the language level on the bottom left.. lmao

remote socket
#

where?

#

And even if I read that it wouldn't mean anything to me

#

None of my plugins have had this issue before

#

But i'm new to java

undone narwhal
#

Change it to your current java version level

#

(11 in your case)

unreal furnace
#

anyone here know how to skript?

bronze marten
#

just write english sentences

sturdy oar
#

Does someone know how to make the plugin work when using tab completion but the user loads it on older versions? (1.12.2)

#

I get errors from Brigadier when I try to load my plugin into 1.12.2

undone narwhal
#

Do you use the TabExecutor service ?

#

I implement CommandExecutor, TabCompleter for all of my commands

sturdy oar
#

I use Commodore

#

from Lucko

#

but the thing is that I'm not loading the completions

#

if the version is higher than 1.13

#

although i get stuff like that when one of the commands get executed

undone narwhal
#

Oh, it's not a basic commands, okay sorry

sturdy oar
#

I think i'll prob. have to contact Lucko discord if nobody knows here

undone narwhal
#

If you use Commodore service yes.

hoary parcel
#

Well, duh

#

1.12 doesn't have brigadier

#

So you are SOL

#

Don't support 1.12

#

I mean, could try shading brigadier and invoking it manually and shit

#

But that seems like a giant hassle

median swift
#

Hey, my server started running out of memory and players started to get kicked to the lobby. Ram usage issue until I restart. Any ideas how to make this clean?

undone narwhal
#

Maybe a plugin causing this memory loss

median swift
#

Sure, but it sounds like its storing useless data

undone narwhal
#

Is it caused by one of your plugin or a sownloaded plugin?

median swift
#

No.

fossil shoal
#

How can you be sure it isn't?

median swift
#

It displays something like Internal Exception . . failed to allocate 229376 bytes of direct memory ( used 1028154858)

undone narwhal
#

When? Some other errors lines ?

fossil shoal
#

Most likely one of the plugins causes memory leaks

median swift
#

How can I find wich ones

vernal spruce
#

oh boy.. is it possible to return a boolean from a bukkitrunnable?

tiny dagger
#

not outside the scope

#

ie same method

#

you can however trick it by using an array

vernal spruce
#

hmm?

undone narwhal
#

@vernal spruce If you want to get the result of a task, use a callable object

sturdy oar
#

@hoary parcel the thing is that I don't get why it's not working on 1.12.2

#

I'm not calling the method that uses brigadier on 1.12.2 i think

vernal spruce
#

jeez i hate jumping from async to normal

hoary parcel
#

You include a class that tries to load brigadier

sturdy oar
#

oh

hoary parcel
#

@vernal spruce check out taskchain

sturdy oar
#

yeah definetively not going to support <1.12.2

#

it's just not worth my time

hoary parcel
#

It's designed to remove all the fricton of jumping between sync and asking

undone narwhal
#

Minecraft players should really consider updating their game to the last game version...

#

@sturdy oar Still the bible stuff?

sturdy oar
#

ahah no

#

the bible doesn't work as well with older versions tho

#

because Bukkit is missing GSON

undone narwhal
#

Ohw :/ Can't you add it in your plugin?

#

Too heavy maybe

sturdy oar
#

I don't know how many KBs it is

#

it's weird how they only started adding GSON after 1.12.2

#

there are so many things wrong with trying to support older versions

hoary parcel
#

So just don't

undone narwhal
#

I don't understand why there are so many people always using 1.8 1.9 etc

hoary parcel
#

^^

#

The majority uses 1.15 so all fine

undone narwhal
#

Thx Hypixel and all these big networks not "updating" their servers

hoary parcel
#

Not really

#

You don't write plugins for hypixel, do you?

#

So no reason to follow what they do

undone narwhal
#

I didn't mean that. Just meaning that keeping 1.8 supports discourage the users to update and all the new minecraft features post 1.8 can't be used so why the players would like to update?

tiny dagger
#

it was a while till people moved from 1.7.10 but we managed to move on

undone narwhal
#

All changed since the pvp update right?

tiny dagger
#

well

#

i feel like this is an issue that we offer support

#

just like with 1.7.10

#

devs moved on because it had good additions

#

so did the servers

undone narwhal
#

Yep right

tiny dagger
#

and tbh the pvp is amazing

#

no more m1 spam

undone narwhal
#

Yes I actually like this new pvp, even if I was an old school soup pvp player ^^

tiny dagger
#

I really hope we give up on old versions already

#

i'm bored of them

undone narwhal
#

And making plugin all versions compatible becomes really tiring

sturdy oar
#

ehy, how do I get to display the usage of a command (the one stored in plugin.yml)?

#

I remember there was some bukkit command to do it

tiny dagger
#

i dunno how that works

bronze marten
#

Return false

#

In onCommand

sturdy oar
#

no...

#

i don't mean from the code

#

i mean like /usage <command>

#

something like that that should be in bukkit

#

i can't seem to find it on the wiki

bronze marten
#

Are you maybe thinking of a plugin? Plugman?

#

That shows info about plugins

sturdy oar
#

no...

undone narwhal
#

./help <Plugin> <command> ?

#

dunno if that works actually

sturdy oar
#

help plugin works

#

but it does not display the usage

#

it only sends the message

#

with the available commands

undone narwhal
#

Oh I see

#

Are you sure it still exists?

sturdy oar
#

yeah i don't

sudden osprey
#

Is someone here familiar with the TerrainControl plugin?

ashen stirrup
#

Does anyone have like an image to help with InventoryActions?

frigid ember
#

the new combat system is better for server performance as there is less hits to register

wind dock
#

does anyone know how to edit the messages of a plugin without there being a messages.yml file? I dont see one generated, and there is no way to edit the messages in the config.

kind crow
#

How is this possible that my server gets below 13 tps when cpu usage is only 20% and I have 4-6 gb of unused ram?

tiny dagger
#

single thread power?

kind crow
#

single thread power?
@tiny dagger I have i7 2600k on my server with 40-60 players online

#

Is that really single thread issue?

wind dock
#

2600k????

#

no wonder

kind crow
#

Isn't it enough for 40-60 players?

wind dock
#

no

#

it goes up to 3.8ghz

#

3.8

tiny dagger
#

it might be enough for 40-60 players but not normal abusing ones

wind dock
#

anyways, anyone know how to edit messages without their being an actuyal messages.yml

kind crow
#

But it's using 20% of the cpu. Is there a way to split things into threads?

wind dock
#

what

tiny dagger
#

tuinity

wind dock
#

what tuinity

tiny dagger
#

not sure how stable it is tho

sturdy oar
#

if you want to use more threads , you'll probably want to get off spigot

kind crow
#

if you want to use more threads , you'll probably want to get off spigot
@sturdy oar is there any good alternatives?

bronze marten
sturdy oar
#

you can always try it

#

🧻 is good

tiny dagger
#

it's used to cry on because low tps^^

kind crow
#

I'm already using paper

frigid ember
#

@wind dock I know a website for editing strings in a plugin without config

sudden osprey
#

Is someone here familiar with the TerrainControl plugin?

wind dock
#

Really?

#

what is it?

frigid ember
wind dock
#

wait so what do i do in there

pallid turret
#

Can anyone help me find out why I can't copy a world and load it? Here's my code so far:
https://hastebin.com/atazosobof.java
I'm trying to copy it to the main directory so I can load it, the problem is I have a map and want it to reset after each event and I'm not really sure how to use Bukkit's File management to do it, I think that would work though it doesn't
Or before
If there is a way to make a world not save when created again that would also work I think?

wind dock
#

@frigid ember Can I change the commands in there as well?

frigid ember
#

I haven't tried, try it

wind dock
#

arligth

ashen stirrup
#

Does anyone have experience with the LuckPerms API?

obtuse rose
#

API doc does

ashen stirrup
#

Already looked 🥱

obtuse rose
#

They have nicely written API documentation, what else do you expect 🤷‍♀️

ashen stirrup
#

My question was does anyone have experience with the LuckPerms API not where is the API documentation though..

cursive flax
#

Hello, i'm trying to make a Bedwars minigame plugin, and i'm currently creating my item generators, and it behaves kinda strange :
The generators in each team's base all generate the first resource, but only one generates the second resource
There is only one of the 4 diamond generators (in the corners of the map) that is working
There is only one emerald generator at the center that is working

Ater searching why for almost 2 days I still don't know why some are working and others not :/
I'm using Spigot 1.15.2 if it can help

frigid ember
#

is there a better way to manage timed tasks that don't consume an entire thread?

fiery scroll
#

Ok, quick query - can you run 2 bungeecord networks on the same machine?

frigid ember
#

Actually, nevermind. When you sleep a thread it is freed up to do other stuff. It doesn't sit there & wait for the sleep timer to finish.

#

Stupid

cerulean musk
#

Guys help please, i have a FFa server. But My sprint stops for a moment when someone hit me

#

some called this with sprint bug

hallow surge
#

any code to do with sprinting

cerulean musk
#

there are only plugins on the server

#

And they basic plugins world edit multiverse, ...

hallow surge
#

what version?

undone narwhal
#

Spigot or fork?

remote ore
#

Hello, I have a problem on my server. The Builder can not destroy or build in the map. I don't have Essentials AntiBuild and don't have WorldGuard. I don't knwo why anybody can help me please

cerulean musk
#

@hallow surge 1.12.2

hallow surge
#

Spigot

#

or fork

cerulean musk
#

Spigot

remote ore
#

@frigid ember I have : AntiCheatReloaded ; AuthMe ; bStats ; ClearLag ; CrazyAuctions ; Essentials (only EssentialsX ; EssentialsXChat ; EssentialsXSpawn) ; LuckPerms ; NoFall ; NoHunger ; NoWeather ; PlaceHolderAPI ; PluginMetrics ; ProtocolLib ; Shop ; SkinsRestorer ; TAB ; UltimateKits ; Updater ; Vault ; ViaVersion ; WorldEdit ; zChat

cerulean musk
#

İ have 20 plugins but they are known

remote ore
#

@frigid ember I only delete the .jar but it don't works. In the file Essentials I don't know what I have to delete
to just remove EssentialsSpawn

#

Okay it doesn't works

#

I cannot destroy if I'm de-opped and not Admin

#

I don't know the permission to let my Builder destroy or build in the map

arctic hound
#

this is not working

#

CraftWorld cannot be resolved to a type

#

is imported

#

i use version 1.12.2

ashen stirrup
#

Does anyone know how to set groups with LuckPerms? There's very little information on how to do so, from what I've seen, from what I've found directly from the LuckPerms API usage documentation, it doesn't seem to work.

Group group = api.getGroupManager().getGroup(nextRank);
user.setPrimaryGroup(group.getName());
api.getUserManager().saveUser(user);

This doesn't seem to be working for me.

#

?

#

Why not?

#

Why though, there's an API.

#

Oh, why

lament wolf
#

Hello everybody, I have a little question about the infrastructure: I have several mineraft servers with bungeecord and everything is fine. With this a database.

Do you think it's better that each of my servers connect to the DB via spigot, or that my servers send message plugins to Bungee who will take care of retrieving the info in DB?

Also the caching, is it better that I do this under Bungee or via Redis?

ashen stirrup
#

I'm setting a group

#

And using dispatchCommand is unreliable - with the API, you can check if the group exists etc.

#

But then it just becomes unreliable

#

How would you check if a group exists or not?

#

Without using the API

#

How would you know if a group exists or not

magic tangle
#

Could try and use the Vault API

ashen stirrup
#

Apparently LP is different to GroupManager and PEX etc.

#

I'll give it a go

#

And just use dispatchCommand to set groups

#

While using the API for checking groups existance

cerulean musk
#

Luckperms-citizens-worledit-HubThat-PlaceHolderApi-ClearLag-AdvancedBan-Viaversion-worldborder-commandpanels-holographicdisplays-viabackwards-multiversecore-,worldguard-citizenscmd-luckpermschat-deluxehub-essentials-kitpvp-simplefreeze-tab
Guys i have SPRİNTBUG on my 1.12.2 spigot server. How can i Fix it ?

frigid ember
#

Is there away I could override default Minecraft mobs with my custom ones (1.15.2)?

red kernel
#

Yes, you can create a Class that extends the Mob's class, then you can use the @Override annotation to override the methods/properties.

worthy forge
#

Hello, does anyone know if it's possible to have coloured command arguments like minecraft default commands? I haven't seen a plugin do it and found nothing on the api or forums

red kernel
#

Yes, you can just use § sign to colour the TabCompletion

#

@worthy forge

hoary parcel
#

Wat

worthy forge
#

wow that's sick thanks!

hoary parcel
#

@worthy forge that's done via brigadier, mojangs command lib

#

Spigot doesn't allow you to use it

#

Cause reasons

#

The fork that shall not be named has a nice API for it

red kernel
#

For me the TabCompletion did it

hoary parcel
#

And there is commodore, a lib by luck that allows you to use brigadier in spigot

#

That's really not the point pixlie

#

Brigadier is so much more than just color

#

Like, it turns red if you enter a Boolean where it expects a number

red kernel
#

Oh that's sick man thanks

worthy forge
#

And there is commodore, a lib by luck that allows you to use brigadier in spigot
@hoary parcel thats nice, it has the other feature I was looking into which was this sort of suggestion on how to fill the argument but it's not an actual valid value that you can use

hoary parcel
#

That's brigadier too

#

Commodore should handle that

#

Acf does too btw, but brigadier support for acf isn't in master yet

#

Reeeeee at aikar for that, he took over my PR ^^

serene ether
#

guy im having a problem with animals in my 1.13.2 bukkit server

#

it always despawn even the tamed and nametaged animals

#

this happen when i restart the server

trim gull
#

i'm trying to install BuildTools but getting this error message, what should i do?

#

$ java -jar BuildTools.jar
BuildTools requires at least 512M of memory to run (1024M recommended), but has only detected 247M.
This can often occur if you are running a 32-bit system, or one with low RAM.
Please re-run BuildTools with manually specified memory, e.g: java -Xmx1024M -jar BuildTools.jar

cerulean musk
#

@frigid ember disable-sprint-interruption-on-attack

default: false

description: Determines if the server will interrupt a sprinting player if they are attacked.

#

What is this settings ?

#

Can it help me ?

grave narwhal
#

$ java -jar BuildTools.jar
BuildTools requires at least 512M of memory to run (1024M recommended), but has only detected 247M.
This can often occur if you are running a 32-bit system, or one with low RAM.
Please re-run BuildTools with manually specified memory, e.g: java -Xmx1024M -jar BuildTools.jar
@trim gull looks like you're out of ram

#

lol

trim gull
#

how do i free up ram lol

grave narwhal
#

Close background processes

#

lol

trim gull
#

okay

#

like in task manager? lol

grave narwhal
#

how much ram

#

does your system have

#

if u dont mind me asking

trim gull
#

13.9 gb usable

grave narwhal
#

wtf

#

what do u have open?lol

trim gull
#

ight so there are 99 background processes running so thats probably my problem

grave narwhal
#

hold on

#

if u go into task manager

#

youll see multiple tabs on top

#

labeled

trim gull
#

yea

grave narwhal
#

"CPU" "Memory" "Disk" ETC

#

whats the % of "memory"?

trim gull
#

39

grave narwhal
#

thats weird

trim gull
#

yea

grave narwhal
#

do u have anything like eclipse open

#

?

trim gull
#

i'm just running chrome and task manager rn

grave narwhal
#

ok

#

try closing all java processes in task manager

#

those Java SE Executable processes or whatever they're called

trim gull
#

is there a way to do that all at once or do i have to individually?

grave narwhal
#

a neat trick

#

is it u go into task manager

#

and

#

just type in "java" on ur keyboard

#

theres no actual text box in task manager bit it will take you to the first process that is named "java"

#

so if i went into task manager and typed "discord" on my keyboard it would automatically take me to the discord process

#

and u can just press the delete button on ur keyboard to close them

trim gull
#

okay

#

i have to go, thanks for the help!

serene ether
#

guy im having a problem with animals in my 1.13.2 bukkit server
it always despawn even the tamed and nametaged animals
this happen when i restart the server

native vault
#

Where can i ask a question about permission, to know if i can do something ?

#

Like an email address to ask question

cerulean musk
#

Guys how can i write on spigot forums ?

native vault
#

Create an account ?

cerulean musk
#

İ have

#

But i didnt see anything to create a New post

calm shoal
#

"Post new thread"

#

But do it in the correct category.

white kite
#

Hello, How I can get Sound about a block ?
In Spigot 1.13.2 I do this but isn't fonctionnaly in 1.15.2

  public Sound getSound(Block block) {
        try {
            WorldServer nmsWorld = ((CraftWorld) block.getWorld()).getHandle();
            net.minecraft.server.v1_13_R2.Block nmsBlock = nmsWorld.getType(new BlockPosition(block.getX(), block.getY(), block.getZ())).getBlock();
            SoundEffectType soundEffectType = nmsBlock.getStepSound();

            Field breakSound = SoundEffectType.class.getDeclaredField("q");
            breakSound.setAccessible(true);
            SoundEffect nmsSound = (SoundEffect) breakSound.get(soundEffectType);

            Field keyField = SoundEffect.class.getDeclaredField("a");
            keyField.setAccessible(true);
            MinecraftKey nmsString = (MinecraftKey) keyField.get(nmsSound);

            return Sound.valueOf(nmsString.getKey().replace(".", "_").toUpperCase());
        } catch (IllegalAccessException | NoSuchFieldException ex) {
            ex.printStackTrace();
        }
        return null;
    }```
cerulean musk
#

Oh thanks

torn robin
#

@white kite i'd recommend just manually doing it

#

@native vault depends on the question

white kite
#

@torn robin For the context,
I change the block with AIR but i want play the break sound but lot of blocks use BLOCK_METAL_BREAK

torn robin
#

yep, so I would recommend just doing it manually for the most common blocks

native vault
#

@native vault depends on the question
@torn robin it's to know if i'm authorized to post a specific ressources

calm shoal
#

If you wanted to play the sound you could do Block#breakNaturally() and then place the block straight after. This is a bad way of doing it, but its also good to avoid reflection.

torn robin
#

@native vault would you mind asking here? I don't think that's really necessary to email about

#

but Please only use the support email address, tmp-support@spigotmc.org for questions that require admin intervention. Typical wait times for a response are on the order of one week. would be the email

native vault
#

Ok thanks you for info

#

Ok, i will ask it here.
I have CasualProtector (premium plugin). But, the plugin need Protocollib.
I want to remove the dependency.
Such as the plugin author is banned from everywhere, the plugin isn't continued.
So: can i post it, even if i'm not the first author ? Can I sell it ?

torn robin
#

no

#

it's someone else's work

#

you wouldn't even be allowed to give it away for free because it's a premium plugin

native vault
#

Even if i edit the code, like a reload ?

torn robin
#

yes, even if you edit the code

native vault
#

😭

#

So the plugin will never be available again ?

torn robin
#

mhm

#

unless you can get into contact with the author

#

?services

worldly heathBOT
native vault
#

unless you can get into contact with the author
@torn robin i will try to contact him

white kite
#

@torn robin Yep but I can't do this manually for all blocks

torn robin
#

good luck Elikill

#

I know paper cough has a smexy feature to get the block break sound

lament wolf
#

Hello ! I try to do

            String requete = "INSERT INTO playerstable (name, rank, coins, firstconnection) VALUES (\""
                    + player.getName() +"\", \"player", 0, " + new Timestamp(System.currentTimeMillis());

            Statement statement = connection.createStatement();
            statement.executeUpdate(requete);```
But i get a syntax error ;-;
torn robin
#

nice SQL injection attack right there

lament wolf
#

Don't worry about that

torn robin
#

you have a few "'s that aren't 'd

#

are you sure that's intentional

#

(also does this even compile?)

lament wolf
#

wait I found my error omg

torn robin
#

yay

lament wolf
#

Yes this compile

torn robin
#

plz used PreparedStatement

lament wolf
#

No

#

evil

torn robin
#

pft who needs security

#

i got mah string concatenation 😎

lament wolf
#

Well sir,

#

except if the player name contains # or something like that, there will be no SQL injection

#

Futhermore

#

it can't cuz

#

Mojang

#

You know.

torn robin
#

offline players 👀

#

also just in general

#

should probably be safer than sorry

lament wolf
#

Yes

trim gull
#

@grave narwhal I'm back, and i'm still having the same problem and getting the same error message

#

$ java -jar BuildTools.jar
BuildTools requires at least 512M of memory to run (1024M recommended), but hasonly detected 247M.
This can often occur if you are running a 32-bit system, or one with low RAM.
Please re-run BuildTools with manually specified memory, e.g: java -Xmx1024M -jr BuildTools.jar

torn robin
#

java -Xmx1024M -jr BuildTools.jar

#

have you tried doing that?

trim gull
#

what?

calm shoal
#

Instead of doing java -jar BuildTools.jar do java -Xmx1024M -jar BuildTools.jar as build tools needs more memory.

trim gull
#

okay

#

i think that worked

#

Loading BuildTools version: git-BuildTools-975b734-112 (#112)
Java Version: Java 8
Current Path: C:\Users\kathe\OneDrive\Desktop\Minecraft Server Spigot.
Please do not run BuildTools in a Dropbox, OneDrive, or similar. You can always copy the completed jars there later.

#

is that what it's supposed to say?

twin sparrow
#

no

#

run it on your cumputer

#

not onedrive

trim gull
#

thats weird i thought i uninstalled one drive

#

the folder is just on my destop

#

strange

#

maybe because onedrive backs everything up?

bronze marten
#

Does anyone how to escape emoji's in bbcode lol

trim gull
#

one drive has been uninstalled, ill restart my laptop to see if that keeps it out of the way

torn robin
#

@bronze marten [plain][/plain]?

trim gull
#

it still say onedrive

bronze marten
#

ah nice that worked :)

#

ty

lament wolf
#

When I do:

            String requete = "INSERT INTO playerstable (name, rank, coins, firstconnection) VALUES (?, ?, ?, ?)";


            PreparedStatement statement = connection.prepareStatement(requete);
            statement.setString(1, player.getName());
            statement.setString(2, "player");
            statement.setInt(3, 0);
            statement.setTimestamp(4, new Timestamp(System.currentTimeMillis()));
            statement.executeUpdate();```
I have no error, but it doesn't add the player
calm shoal
#

is your connection to the database valid?

tawdry blaze
#

did u set your connection to manual commit?

calm shoal
#

Also i suggest you using a UUID instead of a name.

lament wolf
#

manual commit ? And yes the connection is valid

#

Yeah, but i'll begin with name

tawdry blaze
#

ye u can store uuid as BINARY(16) and then just UNHEX `uuid.toString().replace("-", "");

hoary parcel
#

Pls don't store player names as primary key

#

You can store a uuid as two longs

tawdry blaze
#

why would you do that if u can just use binary(16)

lament wolf
#

whatever of this currently

hoary parcel
#

Cause binary data in databases is often meh

tawdry blaze
#

its more efficient though

hoary parcel
#

Well, ideally your DB would support an 128bit integer

ebon charm
#

How can I change the passenger of a armorstand for seconds without getting dropped?

remote ore
#

Hello I have a problem :

[21:29:21 WARN]: [Essentials] Task #625 for Essentials v2.17.2.0 generated an exception
java.lang.NullPointerException

#

I don't know why

tawdry blaze
#

could you post a full stacktrace?

chilly eagle
#

you talking to me? Any plugin that lets enchant sword with books of shaarpness 6?

remote ore
#

Anybody know how to correct this fail?

torn robin
#

remove XMPP

remote ore
white kite
#

@torn robin With your thread, I have this error

java.lang.ClassCastException: java.lang.Float cannot be cast to net.minecraft.server.v1_15_R1.SoundEffect

torn robin
#

full error?

white kite
upper hearth
#

PlayerInteract line 114

white kite
#

it's that

twin sparrow
#

and what is SoundEffectType.y?

torn robin
#

breakSound.get is returning a float

#

incase that wasn't obvious

frigid ember
#

Yes, you can create a Class that extends the Mob's class, then you can use the @Override annotation to override the methods/properties.
@red kernel This is the way to create a new custom mob but how do you override default mobs?

opal marsh
#

any idea how to get the primed TNT entity that breaks a hanging entity? I'm using HangingBreakByEntityEvent and the event remover is of type player which is really odd

torpid field
#

in discord you can metion people, any idea of how to achive that effect with a plugin? Example: "Hello @cakelover24" where cakelover24 would be in a diffrent color than the rest of the message.

gloomy thorn
#

hey, is posible use Bukkit methods in a BungeeCord plugin or vice versa?

opal marsh
#

@torpid field you can use the AsyncPlayerChatEvent to get the message and modify it

torpid field
#

ok ill look into that AsyncPlayerChatEvent @opal marsh ty

torpid field
#

if another plugin sets the chatcolor of the player to something like &a will chatcolor.reset reset the chat color back to &a?

opal marsh
#

@torpid field are you talking about the message content or the message formatting?

remote ore
#

Why my Builder can not build the spawn help me please. I give his role all the essentials.build perm but he can not build! Damn help me please

subtle blade
#

if another plugin sets the chatcolor of the player to something like &a will chatcolor.reset reset the chat color back to &a?
It uses the reset colour code (r), which is basically white with no formatting as a regular message would be

opal marsh
subtle blade
#

You can use ChatColor's #getLastColor() method to find the last colour code used

lusty basin
#

Trying to address poor server performance under spigot. Getting lagged on CPU, not memory. With just one player, server can even crash. I think we have too many turtles and farm animals. Do these specs look sufficient for a 4-person server?

-- System Details --
Details:
Minecraft Version: 1.15.2
Minecraft Version ID: 1.15.2
Operating System: Linux (amd64) version 4.14.173-137.228.amzn2.x86_64
Java Version: 1.8.0_252, Oracle Corporation
Java VM Version: OpenJDK 64-Bit Server VM (mixed mode), Oracle Corporation
Memory: 1681218136 bytes (1603 MB) / 2418540544 bytes (2306 MB) up to 2863661056 bytes (2731 MB)
CPUs: 2
JVM Flags: 2 total; -Xms1G -Xmx3G
Player Count: 1 / 20; [xe['Speed707'/728, l='world', x=-36.35, y=69.00, z=-206.51]]
Data Packs: vanilla
Is Modded: Unknown (can't tell)
Type: Dedicated Server (map_server.txt)

opal marsh
#

@lusty basin nothing looks wrong with the specs (missing cpu type I think) but a timings report would be more helpful

remote ore
#

@opal marsh I don't understand, look : spawn-protection=16 but my Helpeur is a weight of 18 but he can not build

#

wtf

opal marsh
#

@remote ore when you say "weight" I assume you're referring to ranks in a plugin. This is a vanilla setting, it knows nothing about plugins. Read what it says on the wiki: "Determines the side length of the square spawn protection area as 2x+1. Setting this to 0 does not disable spawn protection, but protects the single block at the spawn point. A value of 1 protects a 3×3 square centered on the spawn point. 2 protects 5×5, 3 protects 7×7, etc. This option is not generated on the first server start and appears when the first player joins. If there are no ops set on the server, the spawn protection is disabled automatically."

#

Set it to 0 and you should be good to go

remote ore
#

@opal marsh That's good but I want that a "normal" Player can not destroy but a Builder can build

opal marsh
#

@remote ore so make sure normal players don't have "essentials.build perm" if you're using essentials protect or get a more advanced plugin like WorldGuard

remote ore
#

Thank you @opal marsh

lusty basin
opal marsh
#

@lusty basin in a console, commands aren't preceded with a "/", you just type them out without the /

odd ermine
#

Hello guys, my newest 1.15.2 SpigotMC server seems to disconnect players connecting to the server after like 24 hours with the message [User Authenticator #50/WARN]: Exception verifying Player java.lang.IllegalStateException: AsyncPlayerPreLoginEvent cannot be triggered asynchronously from primary server thread. Any clue what causes this and how to debug this?

#

When killing the main thread using Ctrl+C a Thread 2 spawns to save the world saves and gets stuck and unresponsive as well.

#

Is this due to the fact that it's still a snapshot?

lusty basin
#

Cool. Thanks, @opal marsh . The timings report suggests lowering view distance. I think that could help a small amount, but a week ago we didn't have lag and view distance was the same as it is now. The main thing that has changed is we have like over a hundred turtles now.

odd ermine
#

@lusty basin I would lower the xmx to 1G if I were you though, that solved the issue for me, I have similar specs

opal marsh
#

@lusty basin yep, the server tick definitely appears to be overloaded by entities, likely turtles. Can you grab the latest version of paper and try? I believe it has several pathfinding optimizations (turtles pathfind to their beach I think) and it has a newer timings version that gives more details

lusty basin
#

Thanks @odd ermine & @opal marsh -- I'll lower XMX memory value and also look into paper. I set the default view to 4 and even with nobody connected to the server, I'm seeing:

[21:00:04] [Server thread/WARN]: Can't keep up! Is the server overloaded? Running 29477ms or 589 ticks behind

opal marsh
#

@lusty basin are the turtles in spawn chunks? that would explain why it's still lagging with nobody online

#

for small, vanilla~ish servers, I typically disable spawn chunks

lusty basin
#

I'm not sure how many chunks the turtles are from spawn. Could be fewer than 200 blocks away.

#

Nobody on and both processers are bouncing up to 99% utilization.

#

This is an AWS Medium EC2 instance, btw.

tiny pebble
#

when accessing an inventory how would i make it so if someone tries to click on the item, it just goes back to its spot?

pastel condor
#

public void gui (InventoryClickEvent event) {
if (inventory clicked equals my gui inventory) {
event.setCancelled(true);
}
}

#

thats the sudo code

tiny pebble
#

thanks! and ya i got it

pastel condor
#

then you can do like event.getRawSlot()

#

to see what slot they clicked

trim gull
#

when installing spigot, i've put that start.bat file into the same folder as the spigot.jar, but when I double click it I get this message : Error: Unable to access jarfile spigot.jar
Press any key to continue . . .

odd ermine
#

@trim gull did you rename from spigot.1.15.2.jar to spigot.jar?

trim gull
#

no, i'll do that

#

i think that fixed it, thank you so much!

red kernel
#

How can I find out how many players are online in the bungee through a Spigot plugin?

#

Please ping me/@ me when you answer :D

trim gull
#

oh, now it says "failed to load properties from file: server.properties" and "failed to load eula.txt". Does it need to be in the same folder as an already set up vanilla server?

#

nevermind

#

thats my fault

odd ermine
#

Anyone have any clue on the "Exception verifying Player java.lang.IllegalStateException: AsyncPlayerPreLoginEvent cannot be triggered asynchronously from primary server thread." error? It's bugging me out

red kernel
#

yes, but it only says hwo to get the count of a specific server, I need the global count

opal marsh
#

or ALL to get the global player count

red kernel
#

oh thank you

tiny pebble
#

is there a way to send a player a message in like, the middle of their screen?

#

might be a dumb question haha

opal marsh
#

player.spigot().sendMessage(ChatMessageType.ACTION_BAR, new ComponentBuilder("Title to send").color(ChatColor.AQUA).create());

fickle surge
#

who can help me rn?

opal marsh
#

you're gonna have to be a lot less vague than that

tiny pebble
#

ah thank you!
another question i have is if there is a way to get the next message sent by a player? to check for it?

maybe an event?

opal marsh
#

you can store a flag either on the Player object using the bukkit metadata api or internally using a HashSet of uuids and check if that flag is set when the next chat event occurs, then reset it

fickle surge
#

hm hey?

subtle blade
#

Support what you need to use. Don't bend over backwards for CraftBukkit support, especially because it in and of itself is not supported

wanton delta
#

is there a way to make the tropical fish upright

#

if its not in water

#

packets or anything else or if there is a pose for it

subtle blade
#

I have a feeling that's a client-sided thing

#

Kind of like the parrots and dancing

#

Would be happy to be wrong, but PES_SadShrug

wanton delta
#

i was afraid it would be that way 😭

opal marsh
#

any idea how to get the primed TNT entity that breaks a hanging entity? I'm using HangingBreakByEntityEvent and the event remover is of type player which is really odd
to anyone searching and coming across a similar problem, I "solved" it by finding the nearest tnt entity with a fuse of 0 ticks

frigid ember
#

is there a way to disable grass

opal marsh
#

in what context? during worldgen?

frigid ember
#

like i have a big area and the grass looks super ugly; so yes after worldgen

wanton delta
#

worldedit....?

opal marsh
#

if it's after worldgen, worldedit would he helpful

frigid ember
#

ty

opal marsh
#

any way to get the keys stored in a PersistentDataContainer?

subtle blade
#

No, but it probably should have a getKeys() method

opal marsh
#

dang :(

subtle blade
#

Working on a PR right now

tiny pebble
#
private static final Configuration config = TankuPlugin.getInstance().getConfig();

@EventHandler
public void onPlayerMessage(AsyncPlayerChatEvent event) {
  String warpName = event.getMessage();
  String str = "warps." + warpName;
  config.addDefault(str + ".x", event.getPlayer().getLocation().getBlockX());
}

Anyone know why this isn't writing to the config? This could be a java error, I don't know. FYI I'm not an expert at Java 😛

opal marsh
#

I think you may want to use config.set instead of addDefault

#

following that, call saveConfig()

lusty basin
#

Solved my performance problem, btw. Ran this command:

/kill @e[type=minecraft:turtle]

tiny pebble
#

Thanks, that worked!

lusty basin
#

CPU is back down to max of 10% on either CPU.

#

And that performance problem was triggered by 96 turtles alone.

tiny pebble
#
Material air = Material.Air;
ItemStack block = createWarp.getItem(11);

if (block.getType().equals(air)) {
// stuff
}

The if statement always results in a NullPointerException.
I'm just trying to check to see if a space in the inventory has nothing in it. How would I do that?

remote ore
#

Hello why my players can not use enderchest in spawn? In don't use spawn-protection they can break blocks in spawn

opal marsh
#

@tiny pebble we'd need to see the createWarp.getItem(11); method

#

@remote ore what protection plugins are you using?

tiny pebble
#

It's an Inventory.

public static Inventory createWarp = Bukkit.createInventory(null, 27, "Choose Item Type");
remote ore
#

@opal marsh I use all EssentialsX plugin and WorldGuard but I don't configurate for protection any of them

opal marsh
#

@tiny pebble iirc, Inventory objects return null when there's no item. I'm not completely sure

#

@remote ore remove essentials protect and stick to worldguard. make sure the "use" flag is set to allow

tiny pebble
#

I could try if (block.getType().equals(null)) although my IDE always says it's false?

#

That didn't work, still NullPointerException hmmm

subtle blade
#

Null check block

#

if (block != null && block.getType() == Material.AIR)

#

Or ||, depending on what you want

tiny pebble
#

Same problem still with the entire line even after changing it

remote ore
#

@opal marsh I don't use essentials protection. I have to make a zone with WorldGuard?

#

Like spawn protection with worldguard?

opal marsh
#

@tiny pebble what does the full stack trace look like?

#

@remote ore yes, create a worldguard region and ensure the "use" flag is set to allow

tiny pebble
#

ah hold on let me redo the code lol i was screwing with it

opal marsh
#

what's at WarpInventories.java on line 75?

tiny pebble
#

if (block != null || block.getType() == Material.AIR) {

subtle blade
#

Whole class would be nice

#

Both Listeners and WarpInventories

#

I'm calling the use of fields before they're initialized

frigid ember
#

so i gave default the essentials.warp perm but it says i have no warps which isn't true

opal marsh
#

the || is the problem. if the block is null, it will check the type

#

@frigid ember make sure they have the essentials warp list permission

subtle blade
#

Yea, it should be block == null || block.getType() == Material.AIR. The != null before was for an && condition

frigid ember
#

essentials.warp.list?

opal marsh
#

yes, I believe so

frigid ember
#

ty

tiny pebble
frigid ember
#

it still says no warps avaliable

opal marsh
#

do they have access to the warps? essentials.warps.*

subtle blade
#

Yea, it should be if (block == null || block.getType() == Material.AIR)

frigid ember
#

do they have access to the warps? essentials.warps.*
@opal marsh do i need the star?

tiny pebble
#

Alright, then when I put an item in said slot it's checking, how do I have it enable the else statement since before it didn't? If this is a simple Java question sorry about that

opal marsh
subtle blade
#

If an item is in that slot, the else will fire

tiny pebble
#

Didn't last time though I'll try again, maybe I did something wonky before

subtle blade
#

The else will be called if block != null or if block.getType() != Material.AIR

frigid ember
#

it says essentials.warps.* isn't a option

#

essentials.warps. is though

#

and yes i want everyone to have perms to all warps

opal marsh
#

what says it isn't an option?

remote ore
#

@opal marsh WorldGuard on my plugin file is in .jar but he don't create a config file

frigid ember
#

essentials.warps.* is red

#

sorry im kinda a noob lol

tiny pebble
#

else didn't fire so it must've been something else I've done wrong. Thanks for the help though! I'll try and see what I did

opal marsh
#

send a screenshot of "/pl" please

#

or the server startup log

opal marsh
#

you still have essentials antibuild and protect. make sure the worldguard jar file is in the plugins directory

#

since it's 1.8, make sure you have the right version

trim gull
#

if I am setting up a spigot server, do I need to configure the bukkit.yml file? Are CraftBukkit and Spigot servers different?

opal marsh
#

you can if you want to but it's not required

#

bukkit and spigot are different. spigot is a fork of bukkit and bukkit plugins should be compatible with spigot

trim gull
#

alright thank you

#

i'm getting a failed to bind to port error message when I run the start.bat file

opal marsh
#

what port? are you sure there's not already a server running on that port?

trim gull
#

i was running a vanilla server before but i've deleted all the files from that