#help-development

1 messages · Page 240 of 1

molten hearth
#

and I have stats like strength and crits instead with custom calculations

swift dew
#

what do u use from vanilla

molten hearth
#

nothing lol

swift dew
#

wait

#

i may misunderstood lemme translate

molten hearth
#

I mean I use the knockback i guess

swift dew
#

bru xd

fervent panther
#

So you mean just redo the damage system and since it's not being used anymore use the damage attribute?

swift dew
#

wdym disregard

remote swallow
#
                        try {
                            JsonWriter writer = plugin.getJsonWriter();
                            writer.beginObject();
                            writer.name("gui");
                            writer.beginArray();
                            writer.beginObject();
                            writer.name(args[2]).value(ItemStackGsonUtils.write(itemInHand));
                            writer.endObject();
                            writer.endArray();
                            writer.endObject();
                            writer.close();
                        } catch (IOException ex) {
                            ex.printStackTrace();
                        }

With gson json would anyone know if there is an easier way to type that, for it to appear in the same location with PrettyPrinting applying?

swift dew
#

like you wont do it with vanilla

#

or u will

molten hearth
#

me or miningcow

swift dew
#

you

molten hearth
#

oh no I dont do it with vanilla, I do it with maths

swift dew
#

so with custom variables

molten hearth
#

but that is because I ripped off hypixel skyblock 1:1

#

yeah

humble tulip
swift dew
#

or you use vanilla lnes

#

oh ok

molten hearth
#

I have custom player stats that hold values

fervent panther
swift dew
#

i think thats better

molten hearth
#

and use those and ignore vanilla modifiers

onyx fjord
#

if player looks at light block, what will code say the player looks at?

swift dew
onyx fjord
#

will it be ignored?

twin venture
#

check how many times a player open a specfic chest

molten hearth
#

brb in 5 min

river oracle
quaint mantle
#

Hi, i am having troubles setting up sql storage for my server as it doesnt let me connect to the local .db file for whatever reason

#

is anyone somewhat good at sql spigot implementation ? i hope it's not an oversaturated question

river oracle
#

Are you using jdbc

quaint mantle
#

yes

river oracle
#

And did you follow the jdbc docs for setup

fervent panther
swift dew
#

depends

river oracle
#

Did you shade jdbc into your plugin?

fervent panther
#

I was trying to avoid doing that so I would just have 1 PDC

quaint mantle
#
saveDefaultConfig();
        File f = new File(getDataFolder() + "/main.db");
        if(!f.exists()){
            try {
                f.createNewFile();
                System.out.println(f.getAbsolutePath());
            } catch (IOException e) {
                e.printStackTrace();
            }
        }

        try {
            sql = new DataBase(f.getAbsolutePath());
        } catch (Exception e) {
            e.printStackTrace();
        }

This is my onEnable() function

swift dew
#

you cant do speed only with attributes in 1.9+

#

attack speed

fervent panther
#

I think we should start a thread

swift dew
#

okay

mighty pier
#

how can i add extra flags to an itemstack?

quaint mantle
#
package dev.relismdev.rcoresync.MySQL;
import java.sql.*;

public class DataBase {

    private Connection connection;

    public DataBase(String f) throws Exception {

        this.connection = DriverManager.getConnection("jdbc:sqlite:" + f);
        Class.forName("org.sqlite.JDBC");
        createTable();

    }

    public void closeConnection() {
        if(this.connection == null){
            return;
        } try {
            this.connection.close();
        } catch(Exception e) {
            e.printStackTrace();
        }   this.connection = null;
        System.out.println("Connessione chiusa con successo");
    }

    public void createTable() throws SQLException {

        String sql = "CREATE TABLE IF NOT EXISTS table(Number int, Color varchar(255));";
        Statement st = this.connection.createStatement();
        st.execute(sql);

        System.out.println("Successfully created a table");

    }

}```

This is my DataBase class
swift dew
fervent panther
#

Custom item attributes

mighty pier
#

yes['

river oracle
#

Just use PDC or ItemFlags

twin venture
#

InventoryOpenEvent help!

river oracle
#

?PDC

quaint mantle
river oracle
#

What's ur error

#

?paste

undone axleBOT
river oracle
mighty pier
river oracle
#

you need a space

#

Between table and the arg types

quaint mantle
#

String sql = "CREATE TABLE IF NOT EXISTS table(Number int, Color varchar(255));";

swift dew
#

if u want nbt tags you either need nms or an api for it

ornate mantle
#

i have a value that magically fucking turns null during an InventoryCloseEvent

quaint mantle
#

i think there is a space

river oracle
#

Hold up idk correct syntsx gimme a sec

quaint mantle
#

sure lol

ornate mantle
#

i have 3 checks for that value

#
  1. when its assigned by another method
  2. inventoryclickevent
  3. inventorycloseevent
#

it magically disappears on inventorycloseevent

river oracle
#

Example

river oracle
#

It may be cleared by garbage collector

#

Who knows especially if it's static just learn not to abuse static

ornate mantle
river oracle
#

Can't help more than that without information

tardy delta
ornate mantle
#

probabl not garbage collection because its being used

#

hold up

#

?paste

undone axleBOT
quaint mantle
quaint mantle
#

its just a .db file

#

sqlite

tardy delta
#

its about all types of databases

trail bluff
#

hello i have a problem. if you apply setGravity(false) to an armorstand and setVelocity() to make it move, it won't move. I want to turn off the gravity of the
armorstand and apply setVelocity to them.

I understand that I will need to use NMS and I understand that I will need to create my own custom armorstand.

But how do you turn off the movement block with gravity off and spawn that custom armorstand in the world?

quaint mantle
#

can someone help me? i beg.

tardy delta
#

with

quaint mantle
#

it is saying that my DataBase class is null
Cannot invoke "dev.relismdev.rcoresync.MySQL.DataBase.closeConnection()" because "dev.relismdev.rcoresync.RCoreSync.sql" is null

#
public DataBase(String f) throws Exception {

        this.connection = DriverManager.getConnection("jdbc:sqlite:" + f);
        Class.forName("org.sqlite.JDBC");
        createTable();

}```
rough drift
#

PlayerInteractAtEntityEvent#getClickedPosition() returns the exact position a player clicked on, right?

tardy delta
#

table is reserved

quaint mantle
#

i think that there's something wrong with "f"

tardy delta
#

keyword 'table'

#

change it

quaint mantle
#

from where ?

#

from the statement ?

tardy delta
#

wait wha

quaint mantle
#

where do i need to edit the keyword ?

tardy delta
#

i see two errors

quaint mantle
#
public void createTable() throws SQLException {

        String sql = "CREATE TABLE IF NOT EXISTS table (\n"
                + "    number integer PRIMARY KEY,\n"
                + "    color text NOT NULL\n"
                + ");";

        Statement st = this.connection.createStatement();
        st.execute(sql);

        System.out.println("Successfully created a table");

}```

this is the createTable function
tardy delta
#

and that gives an error?

quaint mantle
#

it gives an error when i start the plugin and when i stop the server

#

the first one says throws org.sqlite.SQLiteException: [SQLITE_ERROR] SQL error or missing database (near "table": syntax error)

#

the second one throws Cannot invoke "dev.relismdev.rcoresync.MySQL.DataBase.closeConnection()" because "dev.relismdev.rcoresync.RCoreSync.sql" is null

tardy delta
#

it reads it assql create table if not exists table (number int, color text not null)

#

and it causes an error when disabling cuz onEnable failed and left some fields unitiialized and thereby causes a npe

quaint mantle
#

it reads it in all lowercase ?

tardy delta
#

no 'table' is a reserved keyword

quaint mantle
#

which means ?

tardy delta
#

change the damn name

quaint mantle
#

OH

#

THAT NAME

#

will table1 do the job ?

tardy delta
#

ye, probably want to give it a meaningful name

quaint mantle
#

mainTable

#

lets test

#

IT WORKED

#

GOD I LOVE YOU SO MUCH DUDE

#

I WANNA KISS YOU EVERYWHERE

tardy delta
#

lets not

quaint mantle
#

just a kiss come on

#

💋

opal juniper
#

lets not

quaint mantle
#

aw man

#

:(

rough drift
#

How can I stop my item frame from being rotated

tardy delta
#

interact event ig

rough drift
#

PlayerInteractAtEntityEvent doesn't seem to work if I cancel

tardy delta
#

are you sure thats the event?

rough drift
#

It's getting called

tardy delta
#

what are your checks

rough drift
#

UUID check, it's passing as it's printing

#

check id -> print -> cancel

elfin atlas
#

Question: When I create a ScoreBoard like this and set it a player how would I remove it from the player?

Scoreboard sb = Bukkit.getScoreboardManager().getNewScoreboard();
Objective obj = sb.registerNewObjective("GOG", "score");
wispy flicker
#

import com.comphenix.protocol.PacketType;
import com.comphenix.protocol.ProtocolLibrary;
import com.comphenix.protocol.ProtocolManager;
import com.comphenix.protocol.events.PacketContainer;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.*;

public class createentity implements CommandExecutor {
    private String Entity;

    @Override
    public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
        ProtocolManager manager = ProtocolLibrary.getProtocolManager();

        if (sender instanceof Player){

            Player p = (Player) sender;

            PacketContainer packet = manager.createPacket(PacketType.Play.Server.SPAWN_ENTITY);
            packet.getIntegers().write(0, p.getEntityId());
            packet.getUUIDs().write(0, p.getUniqueId());
            packet.getIntegers().write(1, 44);

            manager.broadcastServerPacket(packet);
        }
        return false;
    }
}

Hello everyone ❤️
I was told im doing this wrong because im assigning a player instead to things like the UUID, im brand new to packets. what should i put instead?

quiet ice
#

What did "they" exactly say?

humble tulip
quiet ice
#

https://wiki.vg you're packet looks cursed after further inspection, lemme check

#

A) You should not use the player's UUID for this
B) This packet is not complete at all

#

@wispy flicker

rough drift
#

I am bad at maths, so I need some help with: if I have a number between a and b, how can I put it in the range c to d?

#

Example

a = -4
b = 4

c = 0
d = 1

how can I convert like n = 2 into the range?

quiet ice
#

So you have a <= x <= b and c <= x <= d and you want to merge that?

rough drift
#

not exactly

wispy flicker
#

so i just shouldnt bother with the UUID at all?

quiet ice
#

You can use a random UUID, but it may not be the player's UUID given that it is the player's UUID - not the UUID of an item

wispy flicker
#

ah

rough drift
#

I have a number which is between a and b, say 0 - 10 and the number is 5, how can I convert it to another scale such as 0 - 1 (in this case it would be 0.5)

wispy flicker
rough drift
#

The 0 - 1 scale is an example, I kind of need to make it work on more than 0 - 1

rough drift
quiet ice
#

Not only likely but definitely

rough drift
quiet ice
#

I typed it out without thinking too much about it, but it should be right unless my brain fails me. Doesn't look wrong to me at least

rough drift
#

It seems to not be 100% exact (tried 0-128 range as a test and min is 16 and max is 112)

#

Still closer than what I could come up with lol

topaz kettle
#

how could i hire someone to make a plugin with a custom boss

rough drift
#

?services

undone axleBOT
topaz kettle
#

?services

undone axleBOT
rough drift
quiet ice
#

give all five numbers so I can troubleshoot

rough drift
#

I'll give the ones I am testing with

quiet ice
#

Trying it out with
a = 0
b = 10
c = 0.5
d = 1
n = 5
Results in
x = 0.75
Which would be correct

rough drift
#
a = -3.75
b = 3.75

n = 0

c = 0
d = 128
quiet ice
#

I get x = 64. Did you use the correct signs?

#

i.e. you should be evaluating (0 + 3.75) / (3.75 + 3.75) * (128 - 0) + 0

tardy delta
#

hope thats correct

#

yep

rough drift
#

oh I am dumb

#

It's fixed now

#

It was passing in the wrong values ;-;

tardy delta
#

its doubles remember

quiet ice
#

huh, by default that should be an int division

#

non-java moment I guess

tardy delta
#

im using doubles thats why

#

every operator compiles to a DoubleBinaryOperator

onyx fjord
#

ill bump my question, how do i check if player looks at light block?

opal juniper
#

what do you mean "light block"

remote swallow
#

the light block

opal juniper
#

whats one of those

remote swallow
#
Minecraft Wiki

Light blocks (in Bedrock Edition) or lights (in Java Edition) are invisible blocks, primarily intended for map makers, that can produce any light level from 0 to 15. The light block is also the only light-emitting block capable of producing light level 8.

opal juniper
#

huh, pretty cool

remote swallow
#

invisible block that emits light at a customizable level

eternal oxide
#

raytrace from the players eyeLocation

naive bolt
#

How do i get the client version a player joined with?

remote swallow
#

client version as in , 1.17.1, 1.18.2 or client brand

mighty pier
#

how do iadd stuff to the extra attributes of itemstacks

round finch
#

trying to setup visual paragram for design practice and studies

#

not going great

#

installed plugin into eclipse

hasty prawn
#

For Java?

round finch
#

now idk what is is next

round finch
hasty prawn
#

Well that's your first problem

#

Using Visual Studio for Java

round finch
#

what better?

hasty prawn
#

IntelliJ or Eclipse

#

Not sure why you need a plugin for Eclipse

round finch
hasty prawn
#

Yeah why do you need that

round finch
#

the program needs it for some reason

#

i believe

hasty prawn
#

Your class requires Visual Studio plugin? Susge

round finch
#

no no visual paragram requires a plugin on ecplise

hasty prawn
#

No just

chrome beacon
#

We used Netbeans in school

hasty prawn
#

Delete Visual Studio you don't need that

round finch
#

so I had to install the visual studio plugin on eclipse

hasty prawn
chrome beacon
#

That's still better than Visual studio

hasty prawn
#

Netbeans is fine for Swing and Swing only KEKW

chrome beacon
round finch
#

i mean visual paragram

#

REEEEEEE

hasty prawn
#

Oh LOL

round finch
#

ffs

chrome beacon
round finch
#

brain error

round finch
#

so like visual paragram

hasty prawn
# round finch brain error

I mean from their website it looks like all you gotta do is click Eclipse Integration and it does everything for you

round finch
#

i ran the Integration

#

installed the plugin

#

and now i'm here

hasty prawn
#

I mean I don't even really know what Visual Paradigm is

#

I'm just basing this off what their steps say on the website

round finch
#

flowchart

#

it also generate code

#

just experimenting

quaint mantle
#

i am trying to make a function that takes in input a parameter, and it must return the value in double quotes. I found out that to do that in java you need to use this syntax : java String foo = "\"value\"";
My question is, is there a way i can take the parameter by input and put it instead of value ?

dry forum
#
            for(int z = (int) e.getBlockPlaced().getZ() - 11; z <= (int) e.getBlockPlaced().getZ() + 11; z++) {
                e.getBlock().getWorld().getBlockAt(x, e.getBlock().getY() - 1, z).setType(Material.RED_WOOL);
            }
        }```
 makes a square of red wool but i just want to make it a border of red wool, how would i do this
#

that doesnt help...

round finch
quaint mantle
#

like :

public void function(String input){
  String foo = "\"+ input + \"";
}```

doesnt seem to work
#

function that takes a string as input, and returns the string double quoted

hasty prawn
quaint mantle
#

thanks

round finch
zealous osprey
round finch
#

misplaced "

zealous osprey
#

doesnt altering a string also change its reference, cause they are immutalbe?

quaint mantle
#

public String function(...)

round finch
#

yeah it is not

public String function(String input){
String foo = "" + input + "";
return foo;
}
quaint mantle
#

org.sqlite.SQLiteException: [SQLITE_CONSTRAINT_NOTNULL] A NOT NULL constraint failed (NOT NULL constraint failed: mainTable.color)
SQL thinks the string from the function is null ?

round finch
#

it doesn't like "\"

quaint mantle
#
public void pushData(String index, String value) throws SQLException {

        String formatIndex = "\"" + index + "\"";
        String formatValue = "\"" + value + "\"";

        System.out.println(formatIndex);
        System.out.println(formatValue);

        String sql = "INSERT INTO mainTable (" + formatIndex + ")" + "VALUES (" + formatValue + ")";
        Statement st = this.connection.createStatement();
        st.execute(sql);

}```
this is the function that pushes data and it throws `org.sqlite.SQLiteException: [SQLITE_CONSTRAINT_NOTNULL]  A NOT NULL constraint failed (NOT NULL constraint failed: mainTable.color)`
onyx fjord
#

how do i set light level of light item?

wet breach
quaint mantle
round finch
#

maybe discord format is weird

tardy delta
#

use a try with resources

quaint mantle
tall dragon
#

any1 here got an idea on how to efficiently get X blocktype within a region?
like i got a cuboid and have to get a list of all the blocks of a certain block type.

crisp forum
#

I have a function that replaces hex colors:

        fun translateColors(str: String): String {
            if("&#[0-9a-f]{6}".toRegex().containsMatchIn(str)){
                var parsedStr = str
                //println(str.replace("&#([0-9a-f]{6})".toRegex(), "\u00A7$1"));
                for (x in "&(#[0-9A-f]{6})".toRegex().findAll(str)){
                    parsedStr = parsedStr.replaceFirst(x.value.toRegex(), net.md_5.bungee.api.ChatColor.of(x.value.slice(
                        1 until x.value.length
                    )).toString())
                }
                return ChatColor.translateAlternateColorCodes('&', parsedStr)
            }
            return ChatColor.translateAlternateColorCodes('&', str)
        }

It was working on my previous works but I can't use it with 1.19, it just doesn't replace hex colors anymore. Did anything change about Hex colors in 1.19?

tardy delta
#

wwait

#

ah its kotlin

crisp forum
#

yes :d

#

but I don't have any problem with Kotlin, I believe the problem is about Chatcolor.of

tardy delta
#

ChatColor.of("#0f&e84") or smth would work right

round finch
#

\\

remote swallow
#

i thought that you need to convert hex to rgb for it to work

round finch
#

works for java

river oracle
#

No hex works

round finch
#
"\\ " + input + "\\ " 

tardy delta
#

this was it for java anyways

#

dunno kotlin syntax so cant really help

crisp forum
#

looks like that does same thing

#

:d

#

I believe I have some problems :d

dry forum
#
            for(int z = (int) e.getBlockPlaced().getZ() - 11; z <= (int) e.getBlockPlaced().getZ() + 11; z++) {

                if (x == e.getBlockPlaced().getX() - 11 || x == e.getBlockPlaced().getZ() - 11 || x == e.getBlockPlaced().getX() + 11 || x == e.getBlockPlaced().getZ() + 11) {
                    e.getBlock().getWorld().getBlockAt(x, e.getBlock().getY() - 1, z).setType(Material.RED_WOOL);
                }
            }
        }``` i want to make a border of red wool but this only makes 2 lines
wet breach
#

if you managed to make 2 of the lines

#

then all you have to do is get the inverse

quiet ice
dry forum
crisp forum
wet breach
dry forum
#

?

round finch
#

ChatColor bungee component

#

ChatColor.of

#

that what i've been told

#

.

wet breach
# dry forum ?

ok, to get two lines you only need to increase on one axis

#

so increase 1 axis to get 1 line

#

and then on the other axis increase that

#

gets you the second line

#

now, all you have to do is the reverse of what you did with the first, but you can do it at the same time you do the first ones since its just the inverse

humble tulip
#

You know the animation that you get while you are mining a block but before it is broken?

#

As in the block being damaged?

#

What is that even called

#

Idk how to google if it's possible to set it

wet breach
humble tulip
#

Frostalf yk^^

#

?

wet breach
#

yes

humble tulip
#

What's it called?

round finch
#

what a good java flowchart manager and source generator?

wet breach
idle loom
#

Is there a good like API or library for inventory management I can use

#

or like

#

GUI stuff

wet breach
#

correct

crisp forum
quaint mantle
#
PreparedStatement st = this.connection.prepareStatement("INSERT INTO mainTable (?) VALUES (?)");
                st.setString(1, index);
                st.setString(2, value);
            st.execute();```
This wont work why ? first "?" contains index, and second "?" contains value
#

throws : org.sqlite.SQLiteException: [SQLITE_ERROR] SQL error or missing database (near "?": syntax error)

#

by replacing the "?" with the vars, it should look something like : INSERT INTO mainTable ("color") VALUES ("Orange")

crisp forum
#

I would use database ORMs for security etc

quaint mantle
#

ORMs ?

crisp forum
#

database ORM

#

but nvm

wet breach
#

I am going with the latter

quaint mantle
#

the statement INSERTS INTO mainTable (column) VALUES (value)

#

the first "?" is the column and the second is the value

remote swallow
#

last time i checked, you cant have () in sql statement(s)

lost trellis
#

looking for someone to update a plugin for me. will pay, depending on price

wet breach
#

?Services

#

?services

undone axleBOT
quaint mantle
#

this is the syntax i think

#

as you can see, there are parentheses for the column and the values to insert in the table

crisp forum
#

I'm not sure about you can use setString to set indexes

round finch
#

vaule(?)

wet breach
round finch
#

but there is many times of vaules

quaint mantle
quaint mantle
wet breach
#

generally you don't insert onto a specific column like what you are doing

#

now that I looked at what you were wanting

#

so how you would do it, is you would make all other columns to insert into null values except the one you want to add to

#

unless you are trying to update a column

quaint mantle
#

so i need to know how many columns i have beforehand ?

wet breach
#

not sure why you wouldn't know before hand as it would be your DB

quaint mantle
#

i need N columns, every column having an entry

#

and i need a method that takes in input a column and the entry i need to put in, and puts the entry under the desired column

remote swallow
#

that to me sounds like you are trying to update a cell in a pre-existing row

wet breach
#

yeah

quaint mantle
#

PreparedStatement st = this.connection.prepareStatement("INSERT INTO mainTable ('" + index + "') VALUES ('" + value + "')");

#

this worked out really well

#

using 'index' and 'value'

quaint mantle
wet breach
#

sounds like you need to learn db design principles if you have no clue how many columns you are going to have

quaint mantle
wet breach
#

anyways

#

this is the proper way

crisp forum
#

if you are getting value from user

#

you can get SQL injected

quaint mantle
#

how do i prevent that ?

crisp forum
#

using settring :d

quaint mantle
#

i did it and it didnt work

crisp forum
#

you are also getting index from user too?

quaint mantle
mystic terrace
#

Hello, I'm, getting this error all the time and I don't know why, everything looks as the other plugin I did and it doesn't works.

ava.lang.NullPointerException: Cannot invoke "org.bukkit.command.PluginCommand.setExecutor(org.bukkit.command.CommandExecutor)" because the return value of "mrstreeet.simplesetspawn.SimpleSetSpawn.getCommand(String)" is null
        at mrstreeet.simplesetspawn.SimpleSetSpawn.registerCommand(SimpleSetSpawn.java:38) ~[SimpleSetSpawn-1.0.jar:?]
        at mrstreeet.simplesetspawn.SimpleSetSpawn.onEnable(SimpleSetSpawn.java:27) ~[SimpleSetSpawn-1.0.jar:?]

It's giving me error in this lines:

public void registerCommand(){
        this.getCommand("simplesetspawn").setExecutor(new MainCommand(this));
    }
@Override
    public void onEnable() {
        Bukkit.getConsoleSender().sendMessage(name + ChatColor.GREEN + " It's now working correctly!.");

        registerConfig();
        registerCommand();


    }

Anyone knows?

crisp forum
#

and use setString for values

quaint mantle
#

setString doesnt work, it throws errors

wet breach
#
String sql = "INSERT INTO mainTable (?) VALUES (?)";

PreparedStatement st = this.connection.prepareStatement(sql);
                st.setString(1, index);
                st.setString(2, value);
            ResultSet result = st.executeQuery();

@quaint mantle

mystic terrace
#

oh shit I forget

#

tysm

remote swallow
#

np lol

hazy parrot
#

You probably wanted executeUpdate

mystic terrace
wet breach
quaint mantle
wet breach
quaint mantle
#

im pretty sure the only way to specify the column is by using this INSERT INTO mainTable ('" + index + "')

hazy parrot
round finch
#

did you remember to add command into plugin.yml?

remote swallow
#

too late

hazy parrot
wet breach
hazy parrot
#

also reffering from docs

wet breach
#

Even though we are inserting, a result is still returned to indicate its success

round finch
hazy parrot
remote swallow
wet breach
#

because MySQL returns an int upon success of inserting

round finch
#

it makes troubles
easy to forget

hazy parrot
wet breach
#

ExecuteQuery returns whatever MySQL returns

#

doesn't matter if its an int or string or a list

round finch
#

finally fixed visual paragram

#

feck you pc

#

totally not my fault xD

hazy parrot
wet breach
mystic terrace
round finch
#

had to fix every tiny bit

round finch
#

do spigot have a flowchart?

#

curious

#

would be interesting to see the link between classes

wet breach
#

don't think it does

#

but you could generate one though

mystic terrace
#

In commands like this:

}else if(args[0].equalsIgnoreCase("reload")){

                    plugin.reloadConfig();
                    p.sendMessage(plugin.name + ChatColor.GREEN + " Plugin reloaded correctly!");

I have to put return true/false; always? Because I don't know at all the use of it.

remote swallow
#

its a boolean so you need to return true/false, true if its valid and passed through false will send the usage defined in plugin.yml

mystic terrace
#

so it's mandatory

#

to put it right?

remote swallow
#

yeah

mystic terrace
#

so, if this one it's not defined I had to say false?

#

In plugin.yml I mean

remote swallow
#

if your sending a message, return true. If you want it to send the usage on the command in plugin.yml return false

humble tulip
#

Is there any way to get the autoincrement id when i insert a row in mysql?

mystic terrace
#

Understood, ty

#

Can you give an example for false value? @remote swallow

#

please

remote swallow
#

yeah one second

#

If you are returning a message:


public boolean onCommand(@NotNull CommandSender sender, @NotNull Command command, @NotNull String label, @NotNull String[] args) {

    if (args.length < 1) {
        sender.sendMessage("You must have 1 arg for this command to work!");
        return true;
    }
}

plugin.yml looking like

commands:
  mycommand:
    permisson: my.permission

if you want to return the usage in plugin.yml

the class would be

public boolean onCommand(@NotNull CommandSender sender, @NotNull Command command, @NotNull String label, @NotNull String[] args) {

    if (args.length < 1) {
        return false;
    }
}

and plugin.yml would be

commands:
  mycommand:
    permisson: my.permission
    usage: "/<command> arg1

and it would return usage

mystic terrace
#

aaaaa

#

okey okey

#

I would take a ss of it

#

thanks <3

#

Btw, what it's better for optimization

#

having one command per class or creating commands in the same one

#

imagine I want to make a /spawn and /tp command

remote swallow
#

ive got no idea, most people do 1 command per class

mystic terrace
#

I would do that then

#

Easier to understood and in case of bug easy to find where

quaint mantle
#

guys how can INSERT into a column, but UPDATE if it exists ?

#

like if there is no value to insert it, but if there is anything to overwrite it ?

mystic terrace
#

sendTitle it's the class for displaying messages on the actionbar? I can't find it actually

hazy parrot
wet breach
hazy parrot
#

on executeQuery line

quaint mantle
#

imagine i have this db with only one row and N columns

#

what if, in the same row, i want to insert under one specific column, but if there is already a value to update it ?

#

imagine i have the number column and color column, i INSERT "red" under the color column, then with the same method i want it to be white instead of red

quaint mantle
#

but i dont want to make a new row, i want to keep the same row with only the color entry updated

tardy delta
#

hehe constants class

#

annotating them with @Language("SQL") is cool, atleast on ij

quaint mantle
#

how do i give sql an always true condition ?

tardy delta
#

what

wet breach
#

if you wanted to insert but ignore duplicate

quaint mantle
wet breach
#

you would instead use INSERT IGNORE

quaint mantle
tardy delta
#

what db?

eternal oxide
#

Sounds like you didn;t set a unique/primary key

quaint mantle
quaint mantle
quaint mantle
eternal oxide
#

then it all depends on what type of DB you are using

quaint mantle
#

sqlite, a .db file

hazy parrot
#

sqlite have on conflict clause

eternal oxide
#

SQLite supports on conflict

wet breach
hazy parrot
#

insert into Members(discordID, apiID) values (?, last_insert_rowid()) on conflict(discordID) do update set apiID = last_insert_rowid()
example of on conflict ^

tardy delta
#

sqite is like

wet breach
hazy parrot
#

that is not sqlite syntax

quaint mantle
#

INSERT INTO (column) VALUES (value) ON DUPLICATE KEY UPDATE column = value like this ?

wet breach
#

pretty much, what that will do is insert what you are wanting, and if it encounters something already existing, it will update it to whatever you are wanting instead

quaint mantle
wet breach
#

however that is for mysql, if you are using sqlite though you will have to use what Goksi showed

hazy parrot
quaint mantle
wet breach
#

didn't mean to ignore you on that

#

but thanks for testing that out 🙂

hazy parrot
hazy parrot
wet breach
#

you really need to re-structure your DB design

tall dragon
#

any1 here got an idea on how to efficiently get X blocktype within a region?
like i got a cuboid and have to get a list of all the blocks of a certain block type.

quaint mantle
tall dragon
quaint mantle
#

one single row with N columns, and i need the method to insert under a column if its empty, otherwise overwrite it with the new value

wet breach
#

there should not be a scenario where you don't know before hand how many columns or tables you are dealing with or have no clue what the Schema is unless you are coding for foreign DB's

hazy parrot
quaint mantle
quaint mantle
hazy parrot
#

tbh you seem to not understand what column is

wet breach
#

if this how you are making your DB layout then mysql is not what you want or sqlite

quaint mantle
wet breach
#

mysql is not designed to have a single column with an insane amount of columns

#

in fact you will probably reduce its performance or efficiency in this manner lol

#

and with sqlite, your queries will most likely take longer

tardy delta
#

someone has to google how databases work

wet breach
#

believe it or not, mysql and sqlite actually do have a limit in how many columns a table can have

tardy delta
#

:o

hazy parrot
#

seems he is confusing column with data inside of it

wet breach
#

or maybe confusing row with column?

hazy parrot
#

something is happening anyway 😄

wet breach
#

idk, regardless their layout if that is what they are wanting, goes against SQL principles

quaint mantle
#

i know what a row is, what a column is and what the data is

#

just dont assume people are complete idiots ig

#

it sometimes gets offensive, you never know

hazy parrot
#

sorry, didn't mean for it to be offensive

wet breach
quaint mantle
#

missclicked the emoji lol

#

im getting sleepy from this coding shit

#

ive been on this single method for hours now, im losing hope lol

wet breach
#

all I am saying is maybe you might want to look at some other DB system for your layout other then SQL

quaint mantle
wet breach
quaint mantle
wet breach
#

sqlite isn't going to allow that

quaint mantle
#

when the user updates the config values, the values get pushed into mongodb, which then clones the data into a local sql table, which is used by the plugin to work properly

wet breach
#

why clone it?

tardy delta
#

wtf

wet breach
#

you have a mongodb already which the plugin could just use

quaint mantle
#

because in case they pirate my plugin they would just need a db and they could change data by hand easily

quaint mantle
#

this way they would have to reverse engineer every single method and command of the plugin if i use sql

quaint mantle
# wet breach what?

the dashboard would become useless as everyone could just update their data from their mongodb dashboard by hand

wet breach
#

so you want to control everyones plugin?

quaint mantle
#

if the plugin uses sql, they could not change the data as easily

quaint mantle
#

i just want to make it impossible to update the data by hand as that would make it easy to pirate

tardy delta
#

im really confused about why two storages are needed

wet breach
quaint mantle
wet breach
#

no it won't

tardy delta
#

^^

wet breach
#

I don't even need a plugin to change data in a DB

remote swallow
#

DB Browser when

wet breach
#

I can just directly connect and look at it

tired matrix
#
        World world = Bukkit.getWorld(worldname);
        Chunk chunky = world.getChunkAt(x, z); 

        if(!(chunky.isLoaded())){
            chunky.load();
        }```

I am getting a "may produce NullPointerException"  how can I get rid of it
tardy delta
#

id love to see how many sql injections i can do on public plugins :)

wet breach
#

did you think these DB server software didn't allow the ability to inspect and change data or something?

quaint mantle
#

tho i dont think a plugin could use mongo data as a config

wet breach
#

it can

quaint mantle
#

ill try anyways, i just find it weird

quaint mantle
# wet breach it can

do i need the plugin to reload everytime a change is made or is it like hot swappable ?

wet breach
#

But, I don't understand where you got the idea that using a DB would stop someone from doing something

quaint mantle
tardy delta
#

my plugin is using mongo too

wet breach
#

^

tardy delta
#

i dont need a relational database for whatever reason

quaint mantle
quaint mantle
tardy delta
#

thats what you say

quaint mantle
#

wouldnt i need the data from mongo to be put somewhere for the plugin to be used anyways ?

tardy delta
#

gave up on my reflective pojo mapper

wet breach
quaint mantle
wet breach
#

well configs are not going to take up massive memory if that is what you are worried about

quaint mantle
#

i would need some kind of socket that alerts the plugin to reload each time a change is pushed from the frontend

quaint mantle
wet breach
#

So the way you would do it is like so

quaint mantle
#

when the plugin starts, to store in variables all data, or just download one big Document and get the data from there idk

wet breach
#

you create an entry that is a boolean that gets set when a change from front end happens

#

the plugin has a task that checks every so often that entry and if its set, pull the changes and reset that entry

tardy delta
#

is that frontend per plugin instance?

wet breach
quaint mantle
quaint mantle
#

i cant see their mongouri

tardy delta
#

gl implementing that

wet breach
#

that type of system isn't one that will pass the rules I don't think

#

@vagrant stratus you are the expert here

tardy delta
#

should probably go to bed, 12pm

quaint mantle
#

i mean, a lot of services have control over their users data

tardy delta
#

a plugin should work offline in all circumstances right

wet breach
quaint mantle
#

i am not doing mischevious stuff with data that looks like "message" : "You are not allowed to break blocks!"

wet breach
#

but if you are putting it on spigotmc, all plugins follow the same rules

#

otherwise it gets evicted

quaint mantle
#

im planning on selling the plugin and the authkeys directly on my website

vagrant stratus
humble tulip
#

I'm bored

#

Someone give me a challenge

vagrant stratus
humble tulip
#

Something difficult ofc

#

But useful

quaint mantle
quaint mantle
#

in C#.

humble tulip
tardy delta
#

create a reflective pojo mapper

humble tulip
#

What's that

vagrant stratus
# quaint mantle keyword "on my website"

Yes, but if you upload to spigot that's gotta all be removed lmao.
As for your remote DB idea, that can be pirated quite easily. It's just a matter of getting a working copy and the info needed to connect, and then pulling all the tables and shit from it and re-doing it to be local

river oracle
quaint mantle
vagrant stratus
#

and if you link to your site via spigot, the resource will get removed

#

tldr; Your resource will most likely be rejected and/or removed

tardy delta
river oracle
#

Idk how flexible mine is I barely use sql

quaint mantle
vagrant stratus
#

Can't

humble tulip
tardy delta
#

code to map custom types to a database table

wet breach
vagrant stratus
#

You're quite SOL

quaint mantle
# vagrant stratus Can't

ill just do it, if someone's so desperate for my plugin that prefers rebuilding a mongodb schema every single time my plugin updates instead of paying 10 bucks good luck to them

humble tulip
#

Fully reflective? No annotations?

vagrant stratus
#

Sure, but any resource on spigot linking to it will get removed @quaint mantle

chrome ferry
#

does anyone know how to launch a player in a boat properly? It seems like boats are very limited to how velocity and teleporting works.

I've kind of done it, but sometimes it doesn't launch the player all the way up into the sky and launches them half and then glitches straight back down.

        Vector currentVelocity = /*entity.getVelocity*/ new Vector(0.5, 0, 0.5);
        boat.setVelocity(new Vector(0, 0, 0));
        Bukkit.getScheduler().runTaskLater(BoatRace.getInstance(), () -> {
            boat.setVelocity(currentVelocity.multiply(power).setY(1.5D));
        }, 2L);

It works just fine if you're in a minecart by just adding a Y to the current minecart velocity. But unfortunately im creating a launchpad for a boat race.

I was thinking maybe i could trick the player they're riding a boat when they hit the launchpad, and make the server know its actually a minecart until they land again

wet breach
quaint mantle
vagrant stratus
#

That can't be advertised either 🙂

quaint mantle
wet breach
#

like you are free to sell stuff on your own web sites and stuff, just can't use spigot services to help do so

quaint mantle
vagrant stratus
#

You also severely underestimate just how easy it is for people to pirate shit, even more so if they have read AND write access to the DB

wet breach
#

just remember Java was never designed to protect against reverse engineering

quaint mantle
humble tulip
quaint mantle
vagrant stratus
quaint mantle
#

atleast, the db is the user's

vagrant stratus
wet breach
vagrant stratus
#

as long as one can read the database they can just take whatever they've got access too @humble tulip

quaint mantle
wet breach
#

it won't stop pirating per-say just more annoying to do so

quaint mantle
#

the backend then uses the uri to create a database that will store the data that gets read by the plugin and updated by the frontend

vagrant stratus
#

which can then be pirated easily lol

tall dragon
#

any1 here got an idea on how to efficiently get X blocktype within a region?
like i got a cuboid and have to get a list of all the blocks of a certain block type.

chrome ferry
#

any plugin can really be pirated really tbh

tardy delta
tall dragon
#

oops wrong reply

vagrant stratus
quaint mantle
vagrant stratus
#

@quaint mantle can still make those calls manually 🙂

tardy delta
#

mye thats what they say, dunno about the internal impl tho

quaint mantle
vagrant stratus
#

All you need is to reverse engineer a single working plugin and then create a toolkit around that

quaint mantle
vagrant stratus
#

Doesn't mean shit

quaint mantle
humble tulip
remote swallow
#

dont premium plugins on spigot need to work without an internet connection

tardy delta
#

vault isnt a plugin right?

#

just an api

vagrant stratus
#

you just rip the needed code out, throw it in a separate java project, and do as needed @quaint mantle

remote swallow
tall dragon
humble tulip
vagrant stratus
tardy delta
#

so it all depends on the impl

humble tulip
#

If the dev decides ti go rogue he can mess up many servers

tardy delta
#

fuck its already that late

chrome ferry
quaint mantle
#

like you cant pirate it unless you literally hack my api into giving you the data without the need of a fresh token

vagrant stratus
#

Reverse engineer backend via trial/error, modify plugin, leak plugin

humble tulip
vagrant stratus
humble tulip
#

So i can look at what u did

tardy delta
vagrant stratus
#

Fuck, just buy like 10x of them and try to make a token generator

humble tulip
#

Can i see ur progress?

chrome ferry
vagrant stratus
#

Keygens aren't new at all

tardy delta
#

tag me in a few hours and ill send the code

#

have to go to bed

humble tulip
#

Np

quaint mantle
#

tokens are generated when you purchase my plugin, they are not stored in frontend or in the plugin itself

tardy delta
#

ill probably forget otherwise

vagrant stratus
#

Sure, but the client needs it to some degree for a plugin to function

#

and that some degree is just enough for pirates to do pirate things

tardy delta
#

im outta here, gn yall

quaint mantle
#

the client needs a discord account and a valid token

remote swallow
#

night

quaint mantle
vagrant stratus
tardy delta
#

@humble tulip tag me in a minute so ill se tmrw

quaint mantle
vagrant stratus
#

To get a valid token after that process? Also easy

quaint mantle
#

they can login, but unless their discord account has a token linked to it they can see nothing but a page asking them to buy a license

vagrant stratus
#

You'd never even know who the pirate is lmao

quaint mantle
#

how can you pirate something that needs a literal TOKEN that is verified on an API they have no access to ?

vagrant stratus
#

By first buying the product 🙂

quaint mantle
#

unless you have a token you cannot read or edit the DATA

hazy parrot
#

you can pirate everything lol

quaint mantle
river oracle
#

I can even pirate US classified documents

vagrant stratus
quaint mantle
#

it is ip based lol

vagrant stratus
#

Does not matter

#

If anything they'll just re-create the backend locally

quaint mantle
#

for a minecraft plugin

#

again, if thats worth less than 10 bucks then good luck with your self hosted clone of my api lol

vagrant stratus
#

The piracy scene pretty much survives off bragging rights lmao

wet breach
quaint mantle
#

recreating an entire api just for a plugin that is worth 10 dollars

vagrant stratus
#

As a "Fuck you, I can do it"? I can see a pirate being willing to do that lmao

quaint mantle
#

and recreating it every time the plugin gets updated or be stuck in an outdated version

vagrant stratus
#

Pirating groups have done more for less lmao

quaint mantle
wet breach
#

its only configs

quaint mantle
vagrant stratus
#

And? They just look at the change log from that point forward and go from there

quaint mantle
vagrant stratus
#

Not too difficult to create a tool just pull everything

wet breach
#

they don't need to re-create it

quaint mantle
#

gimme a second

wet breach
#

not sure why you believe the code can't be changed? o.O

quaint mantle
#

then i go to sleep cuz im dying

quaint mantle
vagrant stratus
#

lmao, I think they just assume their ideas fool proof like the thousands of others @wet breach

vagrant stratus
#

Only way it's 100% fool proof is SaaS that can't get any code client side

wet breach
#

I mean if you want to know how sophisticated it can get, they don't even need to decompile your plugin to change how it does something I mean a bit much for such little gain but still

vagrant stratus
#

^ I have a tool specifically to deal with DRM attempts just because people think their idea solves piracy entirely lmao

#

I get a lot of enjoyment showing just how shit their idea actually is

river oracle
#

My brand new tool solves piracy I call it

wet breach
#

lol

river oracle
#

Coping

wet breach
#

coping?

#

or copying?

vagrant stratus
#

I don't leak shit, but I'll gladly render your DRM/License system pointless just to prove a point

river oracle
#

Yk my English is bad

#

My tool is called cope

wet breach
#

so far our fastest time was like 2-3 minutes

quaint mantle
humble tulip
#

How do you break obfuscation?

remote swallow
#

really? i would have never known tbh

vagrant stratus
#

Burner account and $10 just to prove a point? No real downsides besides being out 10

wet breach
#

there are ways to reverse that

#

we even had someone use some encryption too

quaint mantle
#

also, the sole fact that you preferred spending 1 hour of your time trying to make me feel and look dumb with arrogance instead of like taking 10 minutes off your being the final coding guru to help me figuring out a secure way to license my plugin shows what your priorities were right there

vagrant stratus
#

You can't

wet breach
#

think the funniest was when someone used a ceasar cipher

vagrant stratus
#

That's the thing

#

There's no "secure" way, license systems are broken all the time

quaint mantle
vagrant stratus
#

They're all 100% pirateable

remote swallow
#

yeah pretty much

vagrant stratus
#

Including those on MCM and PolyMart

quaint mantle
#

goodnight for now

chrome ferry
#

💀

#

ur trying to hard to pirate your plugins instead of adding better functionality

wet breach
#

Java was never designed to be safe guarded from reverse engineering because Java was designed for more server side then client side

glacial yew
#

Quick question is it possible to make an explosion enchant for a sword? If so what will help with this task?

remote swallow
#

i would not surprise me if someone has every plugin on spigot in a db (other than md5 and whoever else can access the spigot db)

vagrant stratus
quaint mantle
remote swallow
#

well

quaint mantle
hazy parrot
remote swallow
wet breach
#

just fyi

chrome ferry
#

no of course not i do not know what you're doing but you're seriously trying way too hard too program an "anti-pirateable" plugin

vagrant stratus
#

Excluding old versions, paid stuff, external links, and some other stuff I've got 34k+ files @remote swallow

quaint mantle
remote swallow
#

i just thought, how big would spigots db be

vagrant stratus
vagrant stratus
remote swallow
#

dafuq

quaint mantle
wet breach
vagrant stratus
#

Spigot's is probably much larger

chrome ferry
remote swallow
#

yeah

wet breach
#

those who pirate were never your customer to begin with

chrome ferry
remote swallow
#

optic do you know how many plugins are currently on spigot

quaint mantle
vagrant stratus
glacial yew
#

Quick question is it possible to make an explosion enchant for a sword? If so what will help with this task?

chrome ferry
quaint mantle
remote swallow
#

i feel like 500k seems reasonable but then there is not enough people for thati would expect

wet breach
vagrant stratus
chrome ferry
#

please, i would love for you prove our points here though

wet breach
chrome ferry
#

and profile picture has nothing to do with the topic

remote swallow
quaint mantle
#

thats my point

wet breach
#

if I remember right, it was like somewhere near 100k at most being on spigot

river oracle
vagrant stratus
#

@remote swallow You've got the resource counts, do the math lol

wet breach
#

or not more then 100k anyways

chrome ferry
quaint mantle
#

also idk whos that chick in the pic but yall made for eachother

chrome ferry
#

so cliche

glacial yew
quaint mantle
remote swallow
#

this is just math and tired brain but idk if its correct but ill say theres 30k plugins, and each plugins has a rough ~10 updates with an average size of like 6mb, thats what 1.8tb?

river oracle
wet breach
chrome ferry
#

Again, you're making assumptions who ever stated i was better? I never said anything to do with anyones skill level, i stated maybe you should focus your time on something else

quaint mantle
glacial yew
tall dragon
vagrant stratus
#

Keep your comments respectful and appropriate, otherwise I'll gladly time you out

wet breach
quaint mantle
quaint mantle
glacial yew
remote swallow
wet breach
#

but we did calculate at the max a plugin could be for all plugins, and you wouldn't need more then a single TB harddrive to fit them all if I remember right

quaint mantle
wet breach
#

I wonder if Discord implemented quiet time

remote swallow
#

theres 58,119 spigot plugins on the website, if they are 2mb each thats 1.16tb

wet breach
chrome ferry
round finch
#

makes inappropriate java method

quaint mantle
#

anyone know how to cancel async task?

quaint mantle
#

good night yall

vagrant stratus
remote swallow
wet breach
vagrant stratus
wet breach
#

so probably $70

remote swallow
#

would it be surprising if spigot stored this on a like 8tb m.2 drive directly in the server

round finch
#

scables the plugins

chrome ferry
vagrant stratus
#

I only have XF2, not 1

remote swallow
#

yeah would guess so

wet breach
# remote swallow would it be surprising if spigot stored this on a like 8tb m.2 drive directly in...
#

I wasn't too far off on price

vagrant stratus
remote swallow
#

would i be correct in saying spigot follows 321

round finch
#

HDD is cheap asf

#

with seagate

#

alot of space

remote swallow
#

3 copies, 2 different types of media and 1 backup elsewhere

vagrant stratus
#

Does remind me though @remote swallow that I need to think of how I'm going to handle the eventual situation of my free tier VPS being filled up lmao

round finch
#

my wish to require that 18 HDD

#

or 20

vagrant stratus
#

Most likely years before it happens, if ever, but you never know 🤷‍♂️

wet breach
remote swallow
vagrant stratus
wet breach
#

that is fine, doesn't mean the benefactor/sponsor doesn't have it covered 😛

remote swallow
#

spigot if it was stored on 1 drive, running a db on site with no backups: ah shit spigots dead, drive died

vagrant stratus
#

I wonder how long I could realistically survive off the free tier VPS if I just moved the attachment storage to a separate server from the start 🤔

wet breach
vagrant stratus
#

Current backup's are only 46.1 MB, and it's like 250-ish GB for a free tier or something like that iirc

#

I wonder if oracle says how much space is taken up 🤔

humble tulip
#

hey optic fusion if i misuse inventory holder in my prem plugin will it get denied?

wet breach
#

just run the du command or whatever it is

vagrant stratus
#

Once I reactivate my phone I might delete my current oracle account and re-do it all proper though lol

remote swallow
#

that reminds me, i still havent paid the money in to see if i can get oracle free tier with debit card

#

i think it wont work with my card because it has like 24p on it

#

and they do temp charge im pretty sure

humble tulip
#

why would what?

river oracle
chrome ferry
#

.getTitle() probably 😭

vagrant stratus
vagrant stratus
remote swallow
#

prob like a dollar or something

vagrant stratus
#

Less I think

humble tulip
remote swallow
#

i just thought of something i dont know how my brain hasnt procced before, you have most likely scanned the only plugin i have on spigot

vagrant stratus
humble tulip
#

the public ones

#

or do you all have some that you use internally

vagrant stratus
#

public

humble tulip
#

yeah it meets all of those

vagrant stratus
#

Then it shouldn't get denied

humble tulip
#

😂

#

if i ever get it done

#

i keep procrastinating

vagrant stratus
#

Definitely gonna have to look into ads and such though @wet breach
Gotta be able to pay for the domain and shit lmao

round finch
#

procrastinating is the most productive thing I do

remote swallow
#

i can agree with that

round finch
#

never miss a beat

#

always on time

vagrant stratus
remote swallow
#

one of my friends wanted a plugin and i spent all day trying to figure out how i could convert itremstacks to json, went through all the different options before i gave up, swapped to a yaml file and i havent touched it since

round finch
#

must suck to get banned and lose all access to all resources

remote swallow
#

no idea

remote swallow
#

i was able to convert an itemstack to b64 and save it but then couldnt read it or parse it back to itemstack

tender shard
remote swallow
#

yeah probably

tender shard
remote swallow
#

could you have told me that earlier smh

tender shard
#

sorry lol

remote swallow
#

its fine lol

#

already swapped from json to yaml because it works and i dont need to spend 9 hours googling while my pc shits itself because bad computer

tender shard
#

check out the toBase64(ItemStack) and fromBase64(String) methods

remote swallow
#

i gave up around the time when i couldnt read from json

wet breach
tender shard
#

your mom is a superset!

#

scnr

wet breach
#

probably

tender shard
#

I dont know her lol

#

she's probably quite friendly

wet breach
#

as long as she doesn't dislike you

tender shard
#

hmmmm

#

great escape, here I come

remote swallow
#

its the 29th

#

one day closer to christmas

river oracle
#

I feel like I'm that one weird guy who will never understand Christmas

tender shard
#

oh

sonic goblet
tender shard
#

sorry for the german beginning

#

lmao

#

that was by accident

remote swallow
#

whats ja ich in english

tender shard
#

"Yes I"

remote swallow
#

yes i i hate it too

tender shard
#

I tried to type into a twitch chat but accidentally typed here

river oracle
#

I don't hate Christmas just don't get it j feel very indifferent to it

remote swallow
#

reasonable

#

to both

tender shard
#

because I always have to go to my parents and that's always... erm... not so nice lol

river oracle
#

Lol

pliant marlin
#

who can help me get a plugin its quite easy but i need help because i dont know how to make plugins

remote swallow
echo basalt
#

went to make my passport today because my parents want to travel for christmas

#

jokes on them I ain't travelling

tender shard
#

where are they going to?

pliant marlin
tender shard
#

?services

undone axleBOT
mystic terrace
#

Anyone knows how to prevent this type of spaces?

tender shard
#

only way to prevent this is to send two messages

mystic terrace
#

brub

tender shard
#

not my fault lol

mystic terrace
#

ik ik

#

btw

#

how can I put comments on config.yml

hazy parrot
#

#

mystic terrace
#

Because when I put them, once the plugin loads it doesn't appear

tender shard
#

so if it already exists, it will not get overwritten everytime

hazy parrot
#

if you use save() on older versions, comments will get removed

tender shard
#

usually you just do saveDefaultConfig()

mystic terrace
tender shard
#

saveDefaultConfig() should save the file exactly as it is

hazy parrot
#

yap, calling save()

#

do as mfnalex say

#

and you don't need copydefaults then

mystic terrace
#

so instead of saveConfig() should be saveDefaultConfig()?

tender shard
#

kinda, yeah

hazy parrot
#

you dont need all of that code

#

saveDefaultConfig will do everything you did there