#help-archived

1 messages · Page 72 of 1

fleet burrow
#

It is throwed when I try to start the runnable again

#

but I've cancelled it

#

Do I need to create a new runnable?

naive goblet
#

Might be the case.

wanton delta
#

Is that kotlin

fleet burrow
#

Yeah

naive goblet
#

yes

wanton delta
#

Or what

#

Ok

naive goblet
#

obv

wanton delta
#

sorry idk

naive goblet
#

Yeah it's pretty similar

fleet burrow
#

I am making a scheduler that can iterate of an iterable at a given speed

#

So I need to be able to cancel the runnable inside it's context

#

That's why I need a runnable, I believe

oak stump
#

what do u lot use for ur ide??? just want recommendations cuz im currently using Eclipse which is great but syntax highlighting is a meh which is a tad annoying. If anyone knows how to do custom syntax highlighting in eclipse plz dm me and lemme know 🙂

fleet burrow
#

intellij

naive goblet
#

heknon BukkitScheduler takes a Consumer<BukkitTask>

red kernel
#

I'm still getting the error even though I'm not even using §

naive goblet
#

And BukkitTask should be cancellable

oak stump
#

@red kernel show me ya code

fleet burrow
#

yup, it is

#

darn

oak stump
#

and show me ur utils class

#

and ill dm u a few solutions

fleet burrow
#

But does it matter which I use?

red kernel
#
            String message = event.getMessage();
            if (player.hasPermission("earth.chat.colours")) {
                message = ChatColor.translateAlternateColorCodes('&', message).replace("%", "%%");
            } else {
                message = message.replace("&", "").replace("%", "%%");
            }

            String format = Methods.chat(PlaceholderAPI.setPlaceholders(player, config.getString("modules.chatsystem.format")));

            event.setFormat(format.replace("%message%", message));
fleet burrow
#

Any advantages to using a BukkitTask

#

well, it might fix my issue 🤷‍♂️

naive goblet
#

BukkitRunnable is deprecated, no actual usage over than it's still in API because many plugins would break if it got removed

#

I mean BukkitTask is a better BukkitRunnable in the way it integrates with the BukkitScheduler

oak stump
#

@red kernel wut r the errors?

red kernel
naive goblet
#

Pixlie

#

dump your entire class in a bin

#

so we can refer lines

red kernel
#

Aight

oak stump
#

^^^^

runic wadi
#

i'm taking my CTRL key out of retirement so I can quickly steal this code

#

I'm ready when you are

naive goblet
#

ok

red kernel
oak stump
#

make a whole to package for your utils and create a Utils class in it

naive goblet
#

oof pastebin

#

also rename the utils package to utility

oak stump
#

yeah

red kernel
#

Hastebin was not working for some reason

#

so i used pastebin

oak stump
naive goblet
red kernel
#

I already have a utils class

naive goblet
#

should work

red kernel
#

called methods

naive goblet
#

Nono

oak stump
#

use it

naive goblet
#

That's missleading

red kernel
oak stump
#

then if you import Utils.chat like this, you can use & for colour codes

naive goblet
#
event.setFormat(format.replace("%message%", message));

^
use event.setFormat(String.format(format.replace("%message%", messages)));

red kernel
#

Okii

wind dock
#

is /lpb editor used for bungeecord wide permissions?

red kernel
wind dock
#

so if i want to give myself owner accross all servers i give myself group.owner in /lpb editor not /lp editor?

naive goblet
#

I doesn't matter Geometry

#

Just specify server=bungee

oak stump
#

Still the same @naive goblet
@red kernel have you changed all of the § to & cuz when i looked at ur code a second ago, it hadnt changed

naive goblet
#

^

wind dock
#

?

#

server=bungee?

oak stump
#

and when you have make sure that if you are gonna do that do this to import the colour coeds

p.sendMessage(Utils.chat("&6Your message here"));```
bleak osprey
#

allow only bungeecord ip addres to connect to spigot
@bronze marten i did, and i enabled the firewall... but they still can use my acc

wind dock
#

The thing is, when i got the other 2 servers, I used the same plugins folder and just copied eveyrthing over

red kernel
#

The thing is, that it works everywhere with § except for that chat thing

naive goblet
#

lp user Conclure perm set permission.node server=bungee

lpb user Conclure perm set permission.node

wind dock
#

oh

#

ohhhh

naive goblet
#

Pixlie remove all §

wind dock
#

So i need to do the server=bungee to make it bungeewide?

naive goblet
#

replace it to &

oak stump
#

ye

naive goblet
#

geo if it's executed in a fallback server I believe

oak stump
#

and when you have make sure that if you are gonna do that do this to import the colour coeds otherwise your message would display as "&6You message here"

p.sendMessage(Utils.chat("&6Your message here"));```
red kernel
#

But that's not my error, my error is in event.setFormat();

subtle blade
#

(1) Using a fork - seek support there next time
(2) How are you using format because it seems to me, based on that error, that you're misusing it.

oak stump
#

^

red kernel
#

Wait what, I'm using spigot on my server

naive goblet
#

I believe you would get a better knowledge of Formats if you print out e.getformat

red kernel
#

On my other plugins it works, only here it seems to give me this error

naive goblet
#

Wait what, I'm using spigot on my server
@red kernel False PaperSpigot

subtle blade
#

I can assure you that you're not

#

Your events are ASM generated which is not something Spigot does

red kernel
naive goblet
#

/ver

subtle blade
#

It can be named whatever you want, it's not Spigot lol

oak stump
#

redownload it

#

FROM SPIGOT

#

xD

subtle blade
#

re-compile* it

oak stump
#

just get a whole new version of spigot if thats what he wants

#

instead of re-compiling

subtle blade
#

BuildTools compiles the jar, so the term "compile" the server jar is appropriate here

#

It's not a download

hoary parcel
#

Or go to paper discord and get actual help

oak stump
#

^

subtle blade
#

(1) Using a fork - seek support there next time
but this is because of a misuse of chat formats

hoary parcel
#

Fun fact, if you Google spigot discord, papers discord shows up 😂

fading owl
#

Lol

subtle blade
#

In incognito?

#

Because your search history will dictate which shows up first

oak stump
#

whatever he just said xD

subtle blade
#

For me it comes up with a bunch of mirror and leak sites so

#

y'know

oak stump
#

🤣

hoary parcel
#

Choco using leak sites confirmed

subtle blade
#

😦

bronze marten
#

@bronze marten i did, and i enabled the firewall... but they still can use my acc
@bleak osprey What happens is that your spigot server is running in offline mode because it runs under Bungeecord, this is required. Since it runs in offline mode, and another player found your spigot server port, he directly connected to it using IP:spigotPort (while setting up his own bungeecord proxy, with your spigot servers in their bungeecord config). While he did that, he used an cracked launcher to use mc with any name and logged in under your name.

The thing is: you should ONLY allow bungeecord IP+port to your spigot port. You can either do that by reading this thread https://www.spigotmc.org/wiki/firewall-guide/ (if you have access to the machine) OR use a plugin like https://www.spigotmc.org/resources/ipwhitelist.61/ and read the setup.

bleak osprey
#

i already followed the firewall guide, but no succsess.

bronze marten
#

wdym no succes

#

ufw or iptables?

bleak osprey
#

he can still use my account

#

ufw

bronze marten
#

list $ ufw status?

bleak osprey
bronze marten
#

it says everywhere allow from anywhere

#

so you didnt do it yet

bleak osprey
#

yeet lol

#

get no repsonse from the server if iam usinf this

iptables -I INPUT ! -s $BUNGEE_IP -p tcp --dport $SERVER_PORT -j DROP
#

and yes i replaced Bungee_IP and Server_port

tiny dagger
#

try again but in icognito mini

#

🕵️

#

google loves to give you results that thinks you're more interested in

bronze marten
#

@bleak osprey you dont have iptables installed, you just said you had ufw xd

#

you should do this:

#

ufw allow from 127.0.0.1 to any port 25565,25566,25567,... proto tcp

#

where the ports are ur spigot servers

bleak osprey
#

ok, but if iam installing IP_tables i get kicked out and need to restart the server

bronze marten
#

its because iptables doesnt have the ssh rule yet

#

dont enable it until you added ssh

#

or just use UFW

#

you just need one lol not both

bleak osprey
#
root@v2202004118956114910:~# ufw allow from 127.0.0.1 to any port 25565,25566,25567,25568 proto tcp
Rule added
#

gg?

bronze marten
#

check sudo ufw status verbose

bleak osprey
bronze marten
#

ufw still contains rules ALLOW IN Anywhere on your spigot servers.

#

you should delete those

bleak osprey
#

delete server ports?

bronze marten
#

do this:

#

$ sudo ufw status numbered

#

and delete the ones where you can see your spigot port and ALLOW IN with Anywhere

#

with:

#

$ sudo ufw delete <number>

fleet burrow
#

@naive goblet I got it working with the BukkitTask, thanks 🙂

wind dock
#

how do i mkae luckperms use mysql?

oak stump
#

hey u lot, i know u probs know how to hook into Vault easy af but can anyone give me a good link that will gimme a quick tutorial into hooking into vault, been searching but i cant find one 4 some reason. Lol 4 years of Java developing and 3 years of spigot and yet i dont know how to hook into vault 🤣

subtle blade
#

I think Vault itself has a copy/paste example on it on GitHub

oak stump
#

thanks choco

bronze marten
#

hehe VaultAPI has 69 commits

oak stump
#

couldnt find it, with or without incognito mode

#

damn sonn

wind dock
#

what do i need to do to make luckperms use mysql?

subtle blade
bronze marten
subtle blade
#

Otherwise, API is how you get an interact with it

bleak osprey
#

@bronze marten did, now is just the root@v2202004118956114910:~# ufw allow from 127.0.0.1 to any port 25565,25566,25567,25568 proto tcp left

bronze marten
#

ok

#

then it should be ok now

#

try if anyone can log in on your acc

#

or any offline acc

bleak osprey
#

thx 👍

wind dock
bronze marten
#

yeah?

#

it says Connected: false xd

#

then its prob not connected :P

wind dock
#

wait how does myql work?

#

@bronze marten what do i need to do to connect it

bronze marten
#

fill in these values haha

frigid heath
bronze marten
#

mbe remove them

wind dock
#

wait

#

so

#

What is mysql?

#

Do i need to download anything or sign up for anything?

bronze marten
#

if you dont have mysql dont bother with it haha

#

then the default luckperm setup will do just fine

wind dock
#

@bronze marten I need to sync permissions accross all bungee seervers

bronze marten
#

i'd suggest looking a bit what mysql is and what it does

#

before hooking something with it

#

check with your hosting plan if they have mysql or anything

#

or if on dedi find a nice tutorial on how to install and secure mysql

bleak osprey
#

@bronze marten now i cant connect to my server xp

bronze marten
#

wdym

#

is your bungeecord IP open

bleak osprey
#

25565,25566,25567,25568/tcp ALLOW IN 127.0.0.1

#

nope

#

sry...

#

lol

bronze marten
#

$ ufw allow to any port BungeePort proto tcp

#

also allow ssh

#

$ sudo ufw allow ssh

bleak osprey
#

bungeeIP replace with serverIP?

bronze marten
#

yeah

#

oh sorry port

#

Bungeeport

#

likely its 25565

bleak osprey
#

hm still cant connect

oak stump
#

hey so, basically choco suggested the vault api "docs" 4 me and i am already stuck on like first line, what is the "Name of Permission Method"

bleak osprey
bronze marten
#

what is your bungeeport

oak stump
#

@subtle blade any ideas???

hey so, basically choco suggested the vault api "docs" 4 me and i am already stuck on like first line, what is the "Name of Permission Method"
@oak stump

bleak osprey
#

25565

bronze marten
#

then it should work..

#

try restarting mc?

#

mh wait try just $ sudo ufw allow BungeePort

#

more isnt needed

#

and remove the other 25565 rulesfrom the UFW status list

subtle blade
#

You are just trying to get an existing supplier from Vault, right Sym? Not registering your own?

bleak osprey
#

ok

oak stump
#

You are just trying to get an existing supplier from Vault, right Sym? Not registering your own?
im editing it for my own needs

subtle blade
#

Yea but what's your goal? Are you trying to get an economy instance or register one?

oak stump
frigid ember
#

Is there a 1.16 spigot snapshot

bronze marten
#

no

bleak osprey
#

nope.. wont let me go

subtle blade
#

afaik it's just a unique identifier, Sym

#

Never created my own Permission implementation for Vault though

oak stump
#

oh so lol wut

bronze marten
#

@bleak osprey no connection or connect error?

oak stump
#

neither

#

lol k

#

im no longer confused

bleak osprey
bronze marten
#

ok so your bungee appears in the mc server list as online?

bleak osprey
#

yes

bronze marten
#

ok

bleak osprey
#

ufw allow from 127.0.0.1 to any port 25565,25566,25567,25568 proto tcp

bronze marten
#

are you hosting all your spigot servers on the same machine btw?

bleak osprey
#

but this isnt the prob?

#

are you hosting all your spigot servers on the same machine btw?
@bronze marten jupp

bronze marten
#

mh

#

then you could leave the rule out technically

#

but I think the problem is that it only allows incoming and not outcoming connections

#

try this

bleak osprey
#

😄

bronze marten
#

just delete the rule then if its on your local machine

#

and make sure only your bungeecord ip (of all spigot/bungeecord) is open in the ufw list

#

if its all localhost it doesnt even matter configuring localhost rules

#

only your bungeecord IP should be public

bleak osprey
#

still cant connect

bronze marten
#

sudo ufw allow 25565

bleak osprey
#

di

#

d

#

it cant downstream to the server

bronze marten
#

whats the config in bungeecord

#

can you show?

#

you should have the spigot servers there with connections via localhost not via public ip

bleak osprey
bronze marten
#

yeah i think thats your problem

#

replace your public IP with 127.0.0.1

bleak osprey
#

the 172.18.0.1 is not my public ip

i typed 127.0.0.1 and the ip 172.18.0.1 are the local ip of the docer

#

there are the servers running

bronze marten
#

ah yeah true its a private ip space

#

but still, nothing is wrong with the firewall now

#

now its just your bungee cant connect to your spigot servers inside the machine

bleak osprey
#

now its just your bungee cant connect to your spigot servers inside the machine
@bronze marten right

quick prism
#

hello yes uh i need the big help
I have a command that "works"
you can type it in chat and all
but it just says the command again.
any idea why it isn't running what it should?

keen compass
#

@quick prism would help if you showed some code

bronze marten
#

@bleak osprey try to find out the bungeecord private IP

keen compass
#

?paste

worldly heathBOT
bleak osprey
#

eu

bronze marten
#

and run this command again

ufw allow from 127.0.0.1 to any port 25565,25566,25567,25568 proto tcp
@bleak osprey

#

but then instead of 127.0.0.1 your bungeecord private ip

keen compass
#

not entirely sure why you are messing with firewall rules for localhost o.O

#

or private ip's

bronze marten
#

he has some weird docker setup thats blocking localhost connections somehow

heady jolt
#

Can you specify which version your plugin will works on spigot?
Like in Bukkit website, the version column show beside the file name

keen compass
#

@bronze marten its because docker binds to the host nic

#

you need to do complex filtering for docker stuff and if you don't know how to implement that it is best to leave your docker instances on private ip spaces

bleak osprey
#

but then instead of 127.0.0.1 your bungeecord private ip
@bronze marten still not working

keen compass
#

I recommend removing your firewall rules from your host system

clever hornet
#

how do I play a sound to a single player in the console on 1.8.8, it says too far away

bronze marten
#

there are no firewall rules, only port thats open to the outside is 25565 now

#

plus some other mysql etc I saw

bleak osprey
#

si

quick prism
#

import org.bukkit.command.CommandExecutor;
import org.bukkit.event.Listener;
import org.bukkit.plugin.java.JavaPlugin;

import me.Crystallized.CrystallizedPowers.command.CommandFire;

public final class Main extends JavaPlugin implements Listener {
    @Override
    public void onEnable() {
        getCommand("fire").setExecutor((CommandExecutor) new CommandFire());
    }
    @Override
    public void onDisable() {
    }
}``` this is my main file
keen compass
#

I think you are missing the point I am trying to state, while although docker has a private ip space, normal firewall rules will not affect it the same way, because the rules apply to the host nic as a whole.

#

need to disable the filtering driver if you want to filter on the docker ip and even then it starts to get complex

quick prism
bleak osprey
#

I think you are missing the point I am trying to state, while although docker has a private ip space, normal firewall rules will not affect it the same way, because the rules apply to the host nic as a whole.
@keen compass and how to work around?

bronze marten
#

so, maybe move away from the private ip space docker assigns those spigot servers to?

#

let docker use the host?

keen compass
#

Easiest way I have found to filter is using a hardware firewall as opposed a software one on the host system

frigid ember
#

I have a server and for some reason get non responding on my account I’ve tried every other account and it works fine

subtle blade
#

log, actually implement CommandExecutor on your command class

#

Just casting it isn't going to make it a command executor

quick prism
#

** that would make sense **

bleak osprey
#

let docker use the host?
@bronze marten good idea, but i dont know how to change the IP

keen compass
#

it is hard to implement firewall rules, when you have a virtual machine that utilizes the hosts nic as opposed to creating a virtual nic for itself

#

which might be easier if docker allows that

spark venture
#

Hello

#

Choco, i have question. Can i ask you ?

keen compass
#

I would recommend creating a virtual nic on the host, and have docker use that instead for your firewall rules whoever is having the docker issue

bleak osprey
#

what means nic?

keen compass
#

network interface card

subtle blade
#

the thing you use to connect to the internet

#

;P

keen compass
#

there is physical NIC's and then there is virtual ones

bleak osprey
#

xD

subtle blade
#

Pain you're more than welcome to ask any question here and I'm sure more people than just myself can answer

bleak osprey
#

ok ok

keen compass
#

virtual ones are still tied to the physical nic, but at least you can distinguish the connection on the host

bleak osprey
#

🤔

keen compass
#

but if the application uses the host nic and nothing else you can't distinguish the connection even though it has a different ip, because the nic being used is the same

spark venture
#

Well, can i ask you about plugin Essentials ?

keen compass
#

but if you create a virtual nic instead, and had docker use that virtual nic to be bonded to

bronze marten
#

@bleak osprey do you expose ports from the docker container to the host?

keen compass
#

you could more easily apply your firewall rules because your host can distinguish between itself and the virtual one

bronze marten
#

Whats the command you run your docker containers with?

bleak osprey
#

yes

#

ääääh

spark venture
#

Choсo, can you please add me as a friend and I will write you personally?

bronze marten
#

Choсo, can you please add me as a friend and I will write you personally?
Thats scary

keen compass
#

Choco is making friends 😄

spark venture
#

Why?

bleak osprey
#

systemctl enable docker

#

lol

bronze marten
#

No lol, the docker container run <> stuff

#

Or the Dockerfile for your servers

keen compass
#

Hopefully what I said wasn't too confusing

bleak osprey
#

you could more easily apply your firewall rules because your host can distinguish between itself and the virtual one
@keen compass ok which rules do you mean?

keen compass
#

well, I noticed in here you were messing with UFW for whatever reason for docker

bleak osprey
#

yes

keen compass
#

and experiencing odd results from what you would normally expect

#

I am explaining why you were experiencing the odd results

#

and how to resolve it

#

the problem is that the host system can't distinguish docker from itself

#

because only 1 nic instance exists

bleak osprey
#

yes, but i thought you got an option for this 😄

keen compass
#

yes, create a virtual nic

#

and have docker use the virtual nic

#

your host system can distinguish the real nic from the virtual

#

and treat them as separate

bleak osprey
#

hm ok.. but how do i change the nic of the docker?

keen compass
#

Idk, I don't use docker enough to know the config options for it, but you can easily have docker bind to different nics from what I do know

quick prism
#

Uh im still facing the same problems as i had before : <
https://pastebin.com/iHihAu1Q


import org.bukkit.command.CommandExecutor;
import org.bukkit.event.Listener;
import org.bukkit.plugin.java.JavaPlugin;

import me.Crystallized.CrystallizedPowers.command.CommandFire;

public final class Main extends JavaPlugin implements Listener, CommandExecutor {
    @Override
    public void onEnable() {
        getCommand("fire").setExecutor((CommandExecutor) new CommandFire());
    }
    @Override
    public void onDisable() {
    }
}```
these are my files ** *again* **
ebon charm
#

Am I able to spawn an item which never despawns?

frigid ember
#

hmmm, how would I detect the domain that someone joined? so someone could connect to x.domain and go to server x and someone goes to y.domain and goes to y server?

keen compass
#

use forced_hosts in bungee

#

unless you are trying to implement this in your plugin yourself

subtle blade
#

Well, can i ask you about plugin Essentials ?
I literally hate essentials and have wanted it to die since I started making plugins lol

frigid ember
#

what do you mean by forced hosts? is that x => y?

#

it needs to still be inside the network so I can run bungee utils on the user

bleak osprey
#

unless you are trying to implement this in your plugin yourself
@keen compass nope

tiny dagger
#

why do you hate essentials?

bronze marten
#

It has cool stuff

sudden parrot
#

anyone uses Spartan Anticheat?

keen compass
#

@bleak osprey I was referring to @frigid ember on that last comment

spark venture
#

:(
@subtle blade

bleak osprey
#

ups 😄

keen compass
#

I already told you how to resolve your problem, just up to you to figure out how to change Dockers settings

subtle blade
#

You're fine to ask your question here. I'm certain someone will answer

#

?ask

worldly heathBOT
#

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.

frigid ember
#

@keen compass I don't mind learning Bungee's api but I just need to forward player x to server x if they connect to x.domain

sudden parrot
#

can anyone help me

bleak osprey
#

thx to you guys!

spark venture
#

Okey, Choco, what i will do with this? [19:41:32 ERROR]: The server has stopped responding!
[19:41:32 ERROR]: Please report this to http://www.spigotmc.org/
[19:41:32 ERROR]: Be sure to include ALL relevant console errors and Minecraft crash reports
[19:41:32 ERROR]: Spigot version: git-Spigot-dcd1643-e60fc34 (MC: 1.12.2)

keen compass
#

@frigid ember Bungeecord already does this natively

#

use the force_hosts section of the config to do it

frigid ember
#

hmm, are they linked inside the network?

spark venture
#

servers?

sudden parrot
#

when someone can someone help me please @ me :/

keen compass
#

how bungeecord knows which domain is because of the TLS message just fyi, so implementing yourself isn't going to be easy as you would need to listen for the connection at the same time bungee is.

#

but you could just setup up bungeecords configs to do it for you though

#

so no need to try to implement it

frigid ember
#

hmmmmmm, cool

keen compass
#

let me link you to documentation

frigid ember
#

ok

keen compass
#

look under forced_hosts

#

define your servers, and then under forced_hosts define your domains to go to which ever servers

frigid ember
#

ok

subtle blade
#

Oh well Pain that's a crash! lol. That's nothing to do with Essentials as far as we know currently

#

?paste us over your crash log

worldly heathBOT
keen compass
#

lol

subtle blade
#

We can then direct you to the correct line of support

keen compass
#

either that or someone just might know exactly what is causing the crash 😛

#

but in either case the error logs are essential

bleak osprey
#

ok i figured it out... iam just dumb xD

thx for help @keen compass @bronze marten

subtle blade
#

but in either case the error logs are essential
hungryTHINK

spark venture
#

I have quetion about essentials, and about this crash, and i will ask you, hove i can fix it. Can you help me ?
@subtle blade

subtle blade
#

Fair

#

Crash log would be handy though

bronze marten
#

@bleak osprey what was the issue tho? Now im curious lol

bleak osprey
#

just used the serverip

bronze marten
#

Ah

#

But not the public ip right? Otherwise you will still have the connection problems

#

Does one of your spigot servers show up in the server list?

bleak osprey
#

now i got the problem, i cant switch between the servers

#

everyone

oak stump
#

so i have made a fully working permissions plugin but im not sure how to hook it into vault so other plugins can use it, and yes i have googled it

vernal spruce
#

try this maybe

hoary parcel
#

Vault isn't meant to be extended

#

You would need to modify vault

oak stump
#

damn it

hoary parcel
#

Just one of the many shortcomings of that plugin

#

You can hack around it tho

keen compass
#

@oak stump Vault works in the opposite direction. Vault hooks into permission plugins, not the other way around. What you could do is submit a pr to vault to include your permission plugin as one of the many that vault will hook into

tranquil yoke
#

How do i sort players by money on Tab i mean player 1 have 100 money so he is up player 2 have 50 money so he is down i need to sort it like this i am using PlayerListPlus somebody can help me?

oak stump
#

@oak stump Vault works in the opposite direction. Vault hooks into permission plugins, not the other way around. What you could do is submit a pr to vault to include your permission plugin as one of the many that vault will hook into
So basically I will have to use my permissions plugin as a build path for my other plugins

#

@keen compass ??? ^^^

exotic narwhal
#

I need help with stopping duping. When they place a piston and a chest and they click a button. Then they take the item out of the chest before the piston retracts. Any addins(I’m on a realm)

vernal spruce
#

Well dont think you can modify realm servers

#

They dont run on spigot

bitter vine
#

Hi, I sent you an email 2 days ago, can someone reply?

wanton vine
#

after Updating to spigot 1.14, the server starts but nobody can join, They get this error:

11.05 17:30:27 [Disconnect] User ZNChano has disconnected, reason: Internal Exception: java.lang.IllegalStateException: EvtPacket cannot be triggered asynchronously from another thread.

bitter vine
#

I know that md_5 think about emails and account deletion

#

help me plz

oak stump
#

So basically I will have to use my permissions plugin as a build path for my other plugins
@subtle blade any ideas

#

Okay so, ima make this easy to understand. Basically, do I have to use my permissions plugin as a build path so that I can hook into the permissions in it

keen compass
#

shouldn't need to depending on how you coded it

torn robin
#

yeah @oak stump ideally you should just be able to use Player#hasPermission

#

your permission plugin should have integrated itself within the player's permissionmanager

wind dock
#

how do i make it so whenever people come to a world they spawn in a specific place?

#

so they cant just spawn wheerever they left off

subtle blade
#

Writing a plugin or are you a server owner?

dire horizon
#

how do i give admin permissions ????? in vehicle plus?

subtle blade
#

See #general, you were answered

dire horizon
#

i don't know how to put the admin in the vehicle plus

wind dock
#

@subtle blade ?

chrome edge
subtle blade
#

Geometry,

Writing a plugin or are you a server owner?

chrome edge
#

or find a plugin from spigot

wind dock
#

@subtle blade I am the owenr

#

owner

subtle blade
#

There are world managers to do this

#

If you have Multiverse by chance, they have a force spawn option in the config iirc

#

(the world config, that is)

wind dock
#

I have mutiverse

#

@subtle blade where in teh config?

#

i dont see it

#

the worlds.yml?

subtle blade
#

Haven't worked with plugins in a long while, but yea I believe it's in worlds

#

It's a per-world option

wind dock
#

I dont see it

dire horizon
#

How do I administer the vehicle plus plugin?

subtle blade
#

PES_Think I remember there being an option for this, Geo

#

Looking now

wind dock
#

thanks

subtle blade
#

Looks like maybe it doesn't. A lot of people used HomeSpawnPlus in conjunction with it (which I also did back when 1.8 was the latest release lol)

wind dock
#

Oh ok i see

dire horizon
#

How do I administer the vehicle plus lite plugin?

subtle blade
#

Just because you continue to copy paste your question doesn't mean we're going to change our answer

#

Speak to the author or read the documentation

#

We will not read the manual for you

marsh nova
#

@oak stump Actually, I believe you can just register your implementation of Permission with the Bukkit services manager, since that's how other plugins use Vault permissions.

#

I'm pretty sure you can just implement Permission

#

Although be sure to add the softdepend/depend in the plugin.yml as well as load at startup

tiny dagger
#

what about loadbefore vault then listening to the pluginenableevent

marsh nova
#

No, not loadbefore

#

You have to load after Vault

#

in order to avoid NoClassDefFoundError

tiny dagger
#

no

marsh nova
#

otherwise Permission.class will not be resolved

tiny dagger
#

i'm talking about listening for vault

#

for when it enables

marsh nova
#

why do that when you can just use a normal softdepend?

tiny dagger
#

well

#

a normal softdepend would still fight with other plugin at race

marsh nova
#

No it wouldn't, unless those plugins are poorly made

#

There's a Vault issue about this

vernal spruce
#

best way to replace %player in a dispatch command? tablistname or getName

#

wich one is more accurate

marsh nova
#

getName

#

otherwise you'll get a bunch of prefixes and formatting

molten whale
green oasis
#

Does Anyone know a plugin for a queue for full and whitlisted Servers For free?

karmic socket
#

Hi, i have a stange problem.
I have instelled Tablist and Infinite Scoreboard.
If the Tablist is refreshing (updating prefixes/suffixes), the scoreboard are flash once every time.
If the scoreboard refresh rate is not the same as tablist, the scoreboard get weird, losing some lines...etc.
Do anybody know what can be the problem?

twin ingot
#

How can i make an /fly command in a Bungeecord plugin? ProxiedPlayer p = (ProxiedPlayer) sender; p.allowFly arent exist

Sorry for my Bad Englisch im German

subtle blade
#

That's something you do on the server side, not the proxy

tiny dagger
#

@karmic socket yea, they are using different scoreboards

twin ingot
#

OK Thx

karmic socket
#

@karmic socket yea, they are using different scoreboards
@tiny dagger And what can i do with that? Should i search for a pack?

tiny dagger
#

something like that

silk bane
#

how can I get a player's true UUID from a server behind bungeecord?

marsh nova
#

What's wrong with player.getUniqueId? I thought that a properly configured BungeeCord setup will forward online-mode UUIDs

silk bane
#

oh is that the case? i was under the impression that servers would get name uuids

marsh nova
#

ensure that your users IP address shows the true value and that your spigot servers get online-mode UUIDs.

#

So just ensure you have IP forwarding on, I guess

green oasis
#

Does Anyone know a plugin for a queue for full and whitlisted Servers For free?

vagrant widget
#

?

frigid ember
#

Hey guys when players join my server they arnt given A rank
only default
and i have ezrankspro.a in there permissions

vernal spruce
#

what permission plugin you use?

vagrant widget
#

You need to set A rank as default rank

astral flower
#

Hi i bought a plugin in spigot and dont appear in purchased resources PLEASE!

#

Help me

#

@atomic rapids

#

@mild nest

latent drum
#

Same here ^^"

astral flower
#

Omg

vernal spruce
#

Just wait a bit,paypal can have up to 24hr payment gateway

#

if the time passed and the money was taken contact the author

#

to look in up

latent drum
#

It's all good now, first time i waited this long with spigot ^^

vernal spruce
#

is mostly paypal holding it back

#

rather than spigot

vagrant widget
#

That’s weird

#

Last time I bought a plugin it was instsnt

vernal spruce
#

alot of things can affect the buy time

frigid ember
#

You need to set A rank as default rank
@vagrant widget ?

#

Default is default rank

#

and i put ezrankspro.a in there

vagrant widget
#

Oh, on PEX you can change the default rank

frigid ember
#

im on luckperms

vagrant widget
#

That plugin is very complicated

#

I just don’t understand it

frigid ember
vagrant widget
#

So I stay on PEX

frigid ember
#

@vernal spruce luckperms

vernal spruce
frigid ember
#

paying someone 5 dollars to fix my group issue
When players join for the first time they arnt giving A rank they are only given default rank and i have the permission node for A set in that group
but its still not giivng them the group

tiny dagger
#

i always hated permissions

#

thank god group manager was still active

#

nowdays this wouldve been a torture

vagrant widget
#

Hey fr33styler

tiny dagger
#

hey

vagrant widget
#

Hry

tiny dagger
#

why do you greet me?

#

do i know you from somewhere?

marsh nova
#

you hate permissions?

#

Permission are the best

#

I love permissions

#

Also I find it funny to pay $5 to configure default player groups

sturdy oar
#

LuckPerms 💗

tiny dagger
#

i hate the current perm plugins

#

groupmanager was my gem

pastel basin
#

I used to hate every permission plugin and was stuck with groupmanager but when I used luckperms I just couldn't use groupmanager again

#

You should give it a try @tiny dagger

sturdy oar
#

LuckPerm is just beautiful

tiny dagger
#

i'm no server owner anymore

#

but back when i was

sturdy oar
#

There's like one of the best documentations and so many features

tiny dagger
#

it was my number 1 choice

tepid aurora
#

would this be an ok place to ask for help on a plugin?

#

nvm, i kinda figured it out

pure canopy
#

what plugin do you recommend for a tab

echo crypt
#

ive been looking into redis and was looking thru the wiki and it says your bungee's need a synchronized system time for it to work, does that have to do with the timezone of the server?

marsh nova
#

You mean the Redis documentation?

#

You should have correct system time for any database, really, otherwise weird things can happen

#

What does "synchronised system time" mean besides "every program sees the same unix time"?

echo crypt
#

I meant redisbungee

#

"Properly synchronized time between all your Bungees. RedisBungee will have problems when your system time is around 27 seconds earlier than another Bungee's. "

#

Is from the wiki

bitter vine
#

I sent you an email 2 days ago, can someone reply?

#

for delete my account

#

but noone replied!!

#

@fleet crane

#

I know that you think about account deletions.. please help me

marsh nova
#

RedisBungee and Redis are completely different... no wonder

regal cloak
#

it tells me in intellij that the class main is not allowed to be public, what should i replace public with, as im not sure

frigid ember
subtle blade
#

I mean it's not terribly difficult. Iterate along the z axis of your shape, pick certain intervals (say every 10 blocks). Once you've reached that point, go up and to the right by 1 pixel, place a block. Continue until you reach the top axis again

regal cloak
#

should i make it private or somthing else

radiant pollen
#

@regal cloak The main class is fine being public. You probably have something setup wrong.

regal cloak
#

oh ill redo it for the 5th time

#

ah i found the problem, they added a yello file instead of a class file, i now just need to work out which one is yellow

hallow surge
#

I'm wondering if its possible to check for a string value from a config file and make that your command For example in the config if the user inputs hi the command is now /hi.

viral herald
#
Error:(3, 30) java: package org.bukkit.plugin.java does not exist
Error:(5, 27) java: cannot find symbol
  symbol: class JavaPlugin
package me.faintcamo;

import org.bukkit.plugin.java.JavaPlugin;

public class Main extends JavaPlugin {
}
#

Does anyone know how to fix

#

Im using intellij

hallow surge
#

um did you import spigot correctly

viral herald
#

i think so

hallow surge
#

clearly not

marsh nova
#

Dynamic command registration is possible but requires you to use the server's command map. You will need to access it via reflection (Also, Paper has an API patch to expose the command map, but then your plugin won't be compatible with Spigot)

tiny dagger
#

paper seems amazing

#

but you shouldn't cut spigot from it imo

errant cove
#

I do get I can do it with ProtocolLib (I'm doing that now), just wondering if there is a spigot event for it I'm missing (and why there isn't, as this is really useful for realtime search UI's)

marsh nova
#

I originally thought I was in the Paper discord sorry 😂

pure canopy
#

anyone know about a plugin to lengthen the name in both tab and tag

rugged viper
#

hello

pure canopy
#

hi

rugged viper
#

where can i find the download for the luckperm 1.8 version

#

for bukkit

rugged viper
#

thanks

echo crypt
#

does anyone know how you can synchronize the time of two different location bungee servers to support redisbungee

marsh nova
#

configure your system time properly

frigid ember
#

how do I report a plugin on Spigot as fraudulent?

nimble solar
#

click the report button at the bottom of the overview

frigid ember
#

that only gives a small text box, I wasnt sure if that was correct. Do I need to provide any specific information in that field?

nimble solar
#

yeah just put report reaosn

frigid ember
#

alright, thanks

spark girder
#

I need some help

#

I bought 2 premium plugins like 8 hours back and it said it would take an hour for me to receive it?? Its been 8 hours tho..

exotic narwhal
#

Scam

spark girder
#

its featherboard and playervaultsx tho ?

exotic narwhal
#

Use the /tag command

#

You can add and remove tags for certain tags

#

Ex: /tag @p add Team1

#

/tp @a[tag=Team1] ~ ~ ~

#

Could do that

frigid ember
#

@exotic narwhal I'm using my own Team class, not the scoreboard teams. Sorry should have clarified.

exotic narwhal
#

Wdym

#

It’s not scoreboard adding tags to each player then use a chain command to remove the tag

spark girder
#

Is it normal for me to not have recieved my plugins or ?

#

And if not does anyone know what to do

exotic narwhal
#

Not really

#

I don’t know b/c I don’t use plugins but it’s probably only able to be used by Java

spark girder
#

who do i contact because the payments still went on

exotic narwhal
#

Idk

#

Did you ask them

frigid ember
#

@exotic narwhal Lol I haven't ever used the Tag command. Oops brb

spark girder
#

idk who to ask

exotic narwhal
#

If you did and they are telling you bull crap then call your bank and say it was a scam

#

Then how did you buy it

#

Wth who a bot

#

B/c on the bottom of a page or something it should say “About” or “Contact Us”

#

Or something along those lines

#

Or give me the name of the website

golden vault
#

Give it a day or so, some authors manually approve their purchases. If you still don't have it then contact them and/or paypal.

nimble solar
#

@exotic narwhal Please don't respond if you know absolutely nothing about the topic or what the user is asking... I get that you are trying to help but randomly throwing answers at them and giving the incorrect information doesn't help.

viral herald
#

Someone who use intellij a lot and codes with 1.8.9 dm me pls

marsh nova
#

I use Eclipse

red zenith
frigid ember
#

i try to organize my class, and on my server this pl dosent work properly, did i do it wrong ? please tell me

red zenith
#

Do you have an error message you can share?

lilac wasp
#

Well let's talk about the naming of packages

frigid ember
#

no, but on that plugin i create, i have command like a /rankup but says, command not found

marsh nova
#

yea...

#

package names should be reverse domain names

lilac wasp
#

?

#

Not only that

#

but

red zenith
#

I thought you were asking about why your plugin doesn't work, and about the organization, you didn't mention a command earlier

frigid ember
#

mustbe?

marsh nova
#

and also lowercase

lilac wasp
#

just be consistent if you are at least not going to follow Java's standards

frigid ember
#

so how i rename that package

red zenith
#

What does your plugin do, primarily?

lilac wasp
#

Should be all lowercase names

frigid ember
#

its gui's for 1.15.2, if im using the script my console spamming InventoryClickevent bla bla bla thats why i create plugin

lilac wasp
#

It tells you the error

red zenith
#

Well, I can see this organizational problem extends beyond your package name 😛

marsh nova
#

yeah

#

"bla bla bla" is what you need to read

red zenith
#

This sounds like you're using skript improperly when retrieving the name of an Inventory/Gui

frigid ember
#

im research in google, dev skript says in java 1.14+ shows like that

marsh nova
#

wait

#

no way

#

do you actually research at Google?

#

(sarcasm)

frigid ember
#

just look at the github threats

marsh nova
#

github threats??

red zenith
#

some people are just really committed to hating github, I guess?

frigid ember
#

hmm

#

i hope not.

red zenith
#

You mean the issues for the Skript repo on github? when you say 'threats', I assume you meant threads.

#

also did you mean java 1.14 or MC 1.14+

old elk
#

Does anyone here have a bungee cord server i am going to set 1 up and i just have a few basic questions before I do

#

If I am starting up a bungee cord server do I need to pay for a 1gb server as the bungee cord host for people to join through? also does it matter how many gbs of ram it has if so

chrome heron
#

how to remove drops in a certain time? any plugin?

old elk
#

Clearlag

chrome heron
#

ty

old elk
#

np

chrome heron
#

@old elk I am using bungeecord

#

for the bc doesnt take lot of ram

#

about 500 is enough

old elk
#

mbs?

red zenith
#

Is that guide I linked correct regarding the Ram recommendations?
It recommends 512MB of ram for 500 players

chrome heron
#

ys

frigid ember
#

so back to my problem, can i rename the package ?

red zenith
#

I don't think you've fully described your problem.

old elk
#

yeah I meant like from what i saw i need to pay for a server then set it up with bungeecord and it will not be used other than to redirect to my other server

chrome heron
#

on localhost or...

old elk
#

I am using a hosting site

red zenith
#

look at the guide I linked, QB

#

It has a section that covers that

chrome heron
#

so the bungee and the spigot are on the same server?

red zenith
#

Important Security Notice

chrome heron
#

100mb per person on the server (about)

old elk
#

it said on the link that it is like500mb for 500 players

chrome heron
#

including bungee and spigot

red zenith
#

That's for bungeecord, the 512 -> 500

lilac wasp
#

??????????????

chrome heron
#

2^n

lilac wasp
#

100mb per player?

chrome heron
#

ys on spigot

old elk
#

is that for the main bungee server or the individual severs?

orchid sigil
#

What would I need to do for the --rev with build tools for a snapshot build?

lilac wasp
#

How is this still a thing where we categorize players with how much RAM we need.

red zenith
#

Aren't you talking about two seperate things? Ram for the Bungeecord server, and ram for each of your spigot servers?

lilac wasp
#

There are a multitude of factors that can contribute to the numbers and it can also be different parts of the server

chrome heron
#

no,if you using bungeecord,ram need 500mb

#

but bungeecord will not let you play minecraft

#

You need to add spigot server

old elk
#

so if im not getting confused if my bungee server had 1gb of ram and they connect to a 1gb paper server through the bungee server it would host like 900 ppl?

lilac wasp
#

No

#

900 people on 1 server?

chrome heron
#

and 1 gb ram?

lilac wasp
#

Even really optimized stuff with enough resources has problems surpassing 1,000 people

chrome heron
#

impossible

lilac wasp
#

1GB won't get you near.

old elk
#

no I meant like the network could host 900 ppl not like on the 1 server

chrome heron
#

10 person per 1 gb ram(about)

lilac wasp
#

omh

#

the 5th person I've seen say that

#

and i'm just done lmao

red zenith
#

Typically you connect a number of spigot servers to your bungee cord server, it's a proxy or standin for connecting to all of your spigot servers

#

each spigot server is only going to be able to handle a fraction of the total your bungeecord indicates

old elk
#

ok thx

red zenith
#

If you could really manage a lot of players on one spigot server, you wouldn't even need bungee

chrome heron
#

But bungee can prevent ddos

#

but 1 gb ram

#

i dont think you need

#

just add whitelist

red zenith
#

how many players would you typically try to handle on one spigot server? 50?

chrome heron
#

no his server will not possible for handling 50 just 10 or below

red zenith
#

I mean if you were going to have your bungee cord say the limit is 500, how many spigot instances would you need, with how much ram per each?

#

Out of curiosity

chrome heron
#

100mb...

red zenith
#

per player per spigot server?

#

so 5gb of ram to support 50 players?

#

roughly

keen compass
#

@red zenith depends really. Are we talking custom servers or what?

#

because custom server you can easily handle thousands if you know what you are doing

red zenith
#

I was just trying to get a ballpark number based upon what QB was saying

old elk
#

just wondering if I have a 4gb server and i offer like 50 player slots or so would the other players go into que automatically or would i need to set that up separately?

keen compass
#

queue would have to be implemented by you, and you would still need a server for them to enter for them to wait

#

with a 4gb server you can easily host 50 players

red zenith
#

Have things improved with 1.15 versus 1.14?

#

in terms of requirements? It seemed like 1.14 had issues that were increasing the amount of resources you needed in comparison to 1.13

upper hearth
#

Depends on the server type, a survival / factions server there's no way you could have 50 players with 4GB

keen compass
#

you can have 50 players with 4gb with a factions/survival server.

#

just don't use shitty hardware or VM's

red zenith
#

on a dedicated machine, then?

keen compass
#

that is what I use. Can't expect VM's to perform the way you want if you are renting from terrible hosters

old elk
#

I mean I have gone on servers with 100 players and 4gb and it ran decent and servers with 40 players and 4gb and it ran like crap I am planning on using mysql and minimal plugins and clearlag to reduce the impact on the server

keen compass
#

everyone expects these MC server softwares to magically perform on less then par hardware

#

which isn't realistic

red zenith
#

Of course the trade off is a bump up in the cost though?

keen compass
#

how much you think a dedi costs to run a 100 player survival server?

red zenith
#

I would expect a dedicated to be fairly expensive, in most cases?

old elk
#

i mean 4gb is only like $10

red zenith
#

4gb dedicated?

old elk
#

yeah

keen compass
#

I pay for Quad core Xeon 3.7ghz hyperthreaded, 64GB of ram, 4x 2TB HDD's, 13 IPV4 addresses, /64 IPV6 and a gigabit connection all for $71 a month

old elk
#

damn

keen compass
#

and its from ovh too 😉

red zenith
#

yeah I was just looking at something else, I know a lot of people recommend OVH

keen compass
#

there is OVH, soyoustart and kimsufi, all the same company, just different hardware for different budgets

old elk
#

I dont understand how ovh works

red zenith
#

I see a hosting server called Bisect offers a similar package to yours, in terms of ram

keen compass
#

soyoustart is older hardware that OVH main had, and the kimsufi is the old hardware from soyoustart

red zenith
#

I dont know how good their cpu's are though

keen compass
#

just because it is old doesn't mean it doesn't perform

#

soyoustart has decent prices on slightly older hardware

#

which is where my dedicated box is from

#

but I mean, when you compare my specs for how much I pay vs your VM or VPS and how much you are paying. Kind of hard to say that my slightly older hardware underpeforms in that comparison 😛

red zenith
#

I guess it really depends upon what kind of setup you're going for

true anvil
#

Quick question, for inventoyclickevent .getCursor() is the item you are hoverig over and getCurrentItem() is the item you have picked up?

red zenith
#

how many servers, game modes, players

keen compass
#

I can probably run 4 servers pretty decently with an average player base on each of around 60-70

#

just depends what exactly you do. However I have the advantage that I do programming

#

so I have no problems running custom servers that fit my needs

#

for instance, you don't need a server that knows about a hundred entities when your hub is only using like 4-5 entities

#

so remove all the others 😉

#

now the hub is running a bit more efficient

red zenith
#

I program as well, my understanding, in terms of profiling or resources needed, isn't as complete.
Sure, I was using one server, with multiple worlds, instead of bungee and splitting the load.
But the principle is the same, disable a lot of features on the hub world.

keen compass
#

Well my point is, you can't always expect public offering software to perform like enterprise software out of the box even if you have decent hardware. Also can't expect any kind of software to perform decently if you are using subpar hardware either.

#

So you want that better performance, need to learn how to make that happen then 😉

red zenith
#

Well, I know virtualization has come a long way, but it won't ever be the same as a dedicated machine.

#

But in terms of managing, I would think that utilizing containers/vms would be easier?

keen compass
#

the problem with renting VM's from hosters is they tend to overload their boxes

#

or you end up with randoms who can in theory overload the box and cause problems for everyone else

#

you also lose a lot of the control you should have like SSH

#

no reason you shouldn't have ssh on a VPS XD

red zenith
#

Sure, and of course a lot of those shared hosting services can oversell a machine.

keen compass
#

yes, however I can use VM's on my dedicated box and as long as I don't overload it, will work out in my favor to segregate my services

#

So I can have a VM for the DB server and Web, which keeps the MC servers separated but they are all on the same hardware

#

performance isn't going to be hurt by that either

#

at least unlike others, you have a pretty good idea of how it works @red zenith but some of these people that come in here, expect some enterprise server software out of the box and to magically work on sub-par machines XD

red zenith
#

I mean, I was able to configure spot instances via AWS to run a server for a fraction of what a dedicated VM would cost. But ultimately that's still a VM. Even though you can customize the ram, cpus/cores and drives, it's probably more cost effective and practical to use OVH.
I ended up moving to a shared host because I didn't have the time to spend doing all the sysadmin stuff, even though I know enough about setting up and maintaining it.

#

I just don't see the typical person who wants to start up a server being able to go the dedicated route, at least not initially.

keen compass
#

if you are referring to kids sure

#

but these kids want to make a business out of it too

#

and unfortunately it takes money to make some money

#

XD

red zenith
#

Sure, and I would expect anyone, including kids, that dedicate enough time to move in that direction.

keen compass
#

yes it is doable to start from a lower end and work your way up

#

but as you said, dedicate enough time

#

but not only dedicate time, but actually learn the stuff you are running

red zenith
#

That's the advantage of someone else managing some aspects of it, but it's a crap shoot.

frigid heath
#

question: what should i use for asynchronous functions? a Thread()?

keen compass
#

You can either make use of bukkits runnables and schedulers if you want it to run in sync with the tick loop

#

or if you don't need it to run in sync make use of Threads

frigid heath
#

thanks :)

red zenith
#

anything that interacts with the spigot/bukkit api needs to do it on the main thread, sync though, right?

keen compass
#

no

#

Well yeah

red zenith
#

If you're going to save data to a backend, it can be async?

keen compass
#

But if you know what you are doing though you can do some things async

#

just the API as it stands is not thread safe, so have to do additional stuff to make it thread safe

frigid heath
#

well im doing a vein miner and tree chopper so i can probably either do runnables or save it to a list then work through it on the next tick

keen compass
#

even with bukkits async runnables, not wise to use the api async

#

many problems happen unless you modify your code to make it thread safe

red zenith
#

Sure you can schedule it to run the task sync on the next tick or a later tick

keen compass
#

start learning about some async methods and the synchronization key word. ConcurrentHashMap exists fyi

red zenith
#

You just don't want to schedule a really long or complicated task to be done all at once in the main thread at the same time, because it will block

keen compass
#

^

red zenith
#

I use A ConcurrentHashMap to cache my player data

#

which gets loaded from configs, at least for now.

#

Was considering using mysql or database to store that info, but, for my case, the configs were fine.

frigid heath
#

well for this specific case its likely to just add a few locations to a hashmap or synchronised list so it shouldnt be too out of the world to implement

red zenith
#

well if you schedule the action that's supposed to be performed when you use one of your tools, then I don't know if the HashMap is necessary?
I guess you could calculate the blocks that should be harvested, and then perform the operation?

frigid heath
#

yeah thats option 2

keen compass
#

you can hold location coords async, just don't try to use those locations to do actions async

frigid heath
#

option one is to just use a runnable

red zenith
#

I have tools like that as well, an axe that can cut down an entire tree with one swing.

frigid heath
#

the look algorithm is something i'll have to experiment with though

red zenith
#

and I could probably optimize that. I know the tools in WorldEdit work very responsively

#

like the super pickaxe

frigid heath
#

for vein miner ill probably do recursive 3x3x3 searches

red zenith
#

so they must be doing something like that

keen compass
#

no need for recursive searches

#

use a bounding box

#

it exists in the API already

red zenith
#

in the spigot api?

keen compass
#

yes

frigid heath
#

as in draw a assumed box on where a vein should be? i dont like that approach because it might clip other veins

#

albeit a tiny chance

keen compass
#

if they are all 3x3x3 boxes, then I don't see how that would be possible

upper hearth
#

I assume you're just checking for nearby blocks of the same type, yes?

red zenith
#

I think the idea is to only remove certain blocks within that 3x3x3 area?

frigid heath
#

oh you're saying to make 3x3x3 bounding boxes?

upper hearth
#

You mine coal -> the entire coal vine is mined?

frigid heath
#

yep

upper hearth
#

Try using a flood fill algorithm

#

It probably isn't more efficient than a 3x3x3 box, but it'll work better

red zenith
#

the super pickaxe tool in WorldEdit works like that

#

or it can, whatever block type you're hitting, and whatever radius you configure, it only removes blocks within that radius. So not 100% what you're going for (only blocks connected to the same vein)

frigid heath
#

flood fill confuses me

#

it looks the same as 3x3x3 cube

keen compass
#

just use bounding box, define how large a vein is, then all you have to do is check if the similar blocks are near each other with a simple loop

red zenith
#

I suppose you could use some kind of ADT to store blocks as you recursively parse, so you don't need to revisit them or add more than once?

upper hearth
#

How are you supposed to define how large the vein is?

frigid heath
#

i can use a thread safe queue

red zenith
#

check for contiguous blocks of the same type

upper hearth
#

That's what flood fill is

keen compass
#

doing only that misses out on the diagonals.

red zenith
#

up,down,left,right; maybe diagonally? after all they did say 3x3x3.

upper hearth
#

Why even make the bounding box if you're gonna do that anyways 🤔

#

You can floodfill diagonally.

frigid heath
#

my only concern with my approach is performance

keen compass
#

but bounding box is way better, because you can just do a contains check to see if its in the box

upper hearth
#

Yeah but how do you define the box

red zenith
#

well, if you can search through the selected region off the main thread

frigid heath
#

bounding box does solve that but it isnt very exact

red zenith
#

and then perform the operation on the list you generate on the main thread

keen compass
#

you get the upper most x,z,y and the lowest, xyz two opposite corners

#

however as I posted earlier BoundingBox exists in the API already

upper hearth
#

How would you know the corners? lol

keen compass
#

base it around where the digging is happening

#

then define how large of a box you want

frigid heath
#

then it can clip other veins or not mine the whole vein

upper hearth
#

I agree that a bounding box is more efficient, but Frost, I don't understand how you're getting the box definitions. If you're mining a randomly generated vein, there's no way you could know the corners or the size of the box.

fair abyss
#

its a paradox .D

frigid heath
#

yeah its not a very good approach functionally but it is performance-wise

keen compass
#

sure you can, you can arbitrarily put limits

upper hearth
#

Without using floodfill, and at that point, the box doesn't matter

keen compass
#

and then you can extend those limits

frigid heath
#

magic numbers are not great

keen compass
#

based on pre-requisites

red zenith
#

I guess you would have to check the algorithm for the vein generation, to get a rough idea of the typical layout, and make an assumption? You could just use a bigger bounding box, and then only include ones that are adjacent to the original block you break, within a certain distance

keen compass
#

its not magic numbers

upper hearth
#

So you're saying if it's a coal vein, just make the box massive?

red zenith
#

well by magic numbers, I think they mean constraints

upper hearth
#

And if it's diamond make it smaller?

keen compass
#

just because its a bounding box, doesn't mean you can't make exceptions when it is ok to check outside of the box

#

for instance, at most the blocks will be 1 block apart in either direction if its part of the same vein

#

but you are going to have to define how large a vein is anyways since veins can sometimes be large

frigid heath
#

there are oddball generations where there are veins on veins which make them bigger as a whole in which case fixed bounding box might not work

upper hearth
#

That's what I'm saying, you have NO IDEA how large the vein is, so you have NO IDEA how large to make the box.

red zenith
#

Now you're starting to sound really demanding, first you have to think about the box, then you have think outside of it. 😉

keen compass
#

fixed bounding box does work, just probably shouldn't let your methods get out of ahead for such cases lol

keen wing
#

Is there any way to change my name on the forums?

upper hearth
#

Donate

keen compass
#

last thing you want is a super large vein and then be waiting on it to process that entire thing

keen wing
#

how much

upper hearth
#

$10 I think

red zenith
#

Well, you could also add another limit; set a max number of blocks that can be mined with one swing

keen wing
#

I made my name when I was too young and it's racist as fuck

frigid heath
#

just make a new account lol

keen wing
#

I bought a plugin D:

keen compass
#

@red zenith that is essentially defining how large a vein can be lol

frigid heath
#

well its probably cheaper than $10

red zenith
#

well, but you mentioned overlapping veins

keen compass
#

yes, my point is you are going to want limits anyways to prevent the odd exception where the method can get out of hand due to overly large veins

#

or what the plugin interprets as a large vein

upper hearth
#

How large of veins are you expecting? lol

red zenith
#

schwarzenegger sized

keen compass
#

Does it account for player placed silked blocks?

fair abyss
#

the perfect way to finding correct vein is
just getting relative blocks unless current block hasn't have any same type relative

but for 2x2 solid vein it will 16 check
if you made a 2x2 bounding box it will check 4 times

but it has stones in the vein
it can be nearly same

upper hearth
#

Fair I suppose, but with flood fil you can put limits too ¯_(ツ)_/¯

frigid heath
#

honestly at this point i dont think any implementations are that laggy because at most you're processing around 40 ores asynchronously

keen compass
#

yes so we are back to imposing limits and bounding box already having said limits already 😛

#

and bounding box, you can still check outside of the box too

red zenith
#

Well, just create a couple of different implementations and test them out?

fair abyss
#

but time can be problem at this time .D

keen compass
#

bounding box is going to be the fastest way over then loops

#

just fyi

upper hearth
#

Sure, but the problem with bounding boxes is what is the vein is longer than the bounding box, but the vein is relatively tiny in size

frigid heath
#

yeah ill probably go with 3x3x3 not that the other implementations are bad but it sounds like the most reasonable to me

red zenith
#

so just program the night/day cycle to stand still when you're using your mining tool?

frigid heath
#

flood fill may be better but i dont understand it

keen compass
#

who said you can't check outside of the box @upper hearth

#

point of the bounding box is doing all the checks in a manner that is quick and efficient

keen wing
#

@frigid heath u smart

keen compass
#

for the outside box checks, you can make your methods based on the box

fair abyss
#

they are talking about a vein can be bigger than max bounding box size

frigid heath
#

@keen wing wrong until yesterday 11pm i thought there was 100 ms in 1s

keen wing
#

Anyone know of anyway of getting Plots Squared to enable mobs hurting players?

keen compass
#

I know @fair abyss but, you can still check outside of the box to see if the vein extends past its boundaries

fair abyss
#

@keen wing plot squared has a discord server, ask there for "better" help

keen compass
#

if it does, extend the box in that direction

keen wing
#

Lol @fair abyss you know the "help" I'll get

fair abyss
#

@keen compass you cant know which vein is big than bounding box

keen wing
#

Just asking out, thanks though :p

upper hearth
#

@keen compass but you'd have to check for EVERY vein if it's outside the box?

#

So what's even the point of the box lmao

keen compass
#

you can't check if a block is outside of a boundary?

#

o.O

frigid heath
#

how about i make a compromise and do recursive 3x3x3 bounding boxes lmao

keen compass
#

@upper hearth because a contains check is faster then a loop

fair abyss
#

not talking about a block is STILL in box's area

#

talking about a block that isn't in are of boundin box

frigid heath
#

im aware recursive 3x3x3 bounding boxes have no benefit btw

upper hearth
#

@keen compass Sure, but how's is supposed to know if there's an ore outside the box? Now you're checking outside, and what if 2 ores are outside?

fair abyss
#

a normal coal ore will be bigger than 3x3x3

frigid heath
#

@fair abyss thats why i said recursiv

#

e

#

for each following coal ore found if its not already in the list it will perform the check again

keen compass
#

look if you don't know how to build code off of a bounding box, then I guess that isn't my problem then 😛

red zenith
#

shots fired

upper hearth
#

Lmao alr

keen compass
#

you can check outside of the box

#

nothing says everything must be inside it

upper hearth
#

I know you can check outside the box omfg

#

Not what I'm saying

#

You're gonna have to check outside the box for every single vein

keen compass
#

yes, which is much faster when you can exclude blocks you already know about

red zenith
#

generate a vector that approximates the direction the vein goes within the bounding box and check in that direction, outside the box? 😛

fair abyss
#

"area" is a "square" you cant just say "much faster"

frigid heath
#

this channel is just 5 people arguing about the best implementation to search through voxels in a block game

keen compass
#

contains check is always faster then a loop

#

can try and prove that wrong but it won't be

red zenith
#

Just create five methods, one implementing each approach and test them?

#

or 2 or 3 🤷

fair abyss
#

probably you will get nearly same results

frigid heath
#

cba tbh if my first implementation doesnt cause major performance issues ill stick to it

fair abyss
#

for testing with one player

frigid heath
#

yeah and i dont really have friends

keen wing
#

Turns out PVE is a flag and disabled by default.

keen compass
#

kind of random there o.O

red zenith
#

sure, ultimately you're just trying to give the player the impression of efficiency, or a big boost from what they normally expect

keen compass
#

not just that, you don't want your code to bog down the server

upper hearth
#

How is contains faster when it uses a for loop anyways

keen compass
#

multiple loops running for a bunch of players will cause performance problems

#

@upper hearth because it doesn't use a loop for the contains check

red zenith
#

so even if it doesn't do it in the ideal way, getting all possible blocks, and it performs well, then it's not worth worrying over the perfect approach.

frigid heath
#

funny how this conversation revolves around the arguably easier part of the vein miner, the next part is processing each ore and determining what to give them based on fortune, silk touch, and my cutclean scenario

keen compass
#

Bounding box already has a known locations

red zenith
#

Why can't you schedule the determination of which blocks to break async?

#

and actually break them sync?

frigid heath
#

already doing that

keen compass
#

contains checks if the block is within the limits of the coords, simple math, but still a contains check

red zenith
#

then whats the issue with the looping bogging down the server?

frigid heath
#

might take minimally longer and cause it to skip a tick ¯_(ツ)_/¯

fair abyss
#

so can you tell me, how about "creating bounding box" and "dedecting and removing veins from box" without looping?