#dev-general

1 messages · Page 37 of 1

obtuse gale
#

are you in it? if so can you send in my dms

drifting aspen
#

you can get to the paper's via their website

brittle leaf
#

you will have to loop over the list then call Block.getType()

#

what are you actually trying to do?

obtuse gale
#

Stop specific blocks from exploding, i figured out a way

rain maple
#

Hi, how I can create large tablist in my plugin ?

brittle leaf
#

using list index is probs the easiest way to do so

brittle leaf
half harness
rain maple
brittle leaf
#

using packets

#

protocollib, packetevents or good old nms can do it

#

you could also look at bungeetablistplus's source and find out what they do

#

tho id assume the exact same thing that i said

brittle leaf
half harness
#

Idk but either way

#

He found a solution 🤷

#

Hopefully it uses blocklist()

#

And not some hacky method

#

¯_(ツ)_/¯

rain maple
brittle leaf
#

bed is a block type

#

its just a material with directional data

half harness
#

Only if it was the one being exploded

#

I think

brittle leaf
#

thats still exactly what i said

half harness
#

Then I guess I clarified 🤷‍♂️

brittle leaf
half harness
#

Yes, that was what my message intended
Either way, once again, he got his solution (which he didn't post ☹️)

brittle leaf
#

fair

#

would be nice to have clarification if they said exploded by or was use to explode, like if they wanted to prevent certain blocks from being exploded in the explosion blast radius or wanted the block that caused the explosion to not be destroyed during said explosion, like beds in the nether or primed tnt exploding

#

their message was a tad vague

#

such fun

half harness
#

Yeah
Also I forgot that beds only explode in the nether so hopefully I didn't cause further confusion 🥲
(also minor note but primed tnt is an entity, confused me for a bit but makes sense)

drifting aspen
#

So, does TNT trigger the BlockExplodeEvent tho?

half harness
#

I don't think so
On phone so can't really check

#

Since it turns into a primed tnt entity

brittle leaf
#

but the primed tnt would trigger the event since its blocks being exploded event, rather then Block that caused explosion event

half harness
#

💣 🧨

crude cloud
#

🛫

ornate nimbus
queen saffron
#

🛫

half harness
#

(╯°□°)╯︵ ┻━┻

obtuse gale
#

and i found a way by watching the interact event

crude cloud
#

classic

slate elk
#

lmao i saw this

#

in showcase

#

very embrassing

#

just checking for strings

#

so if my resource is not leaked

#

but contans

#

cracked

#

LOL

#

it will flag

#

actually when i think about it t here no other way

#

for resources they u r not familier with their stracture

#

how ever

#

useless resource.

pallid gale
#

Not exactly useless, we use a similar thing here for Barry's automated resposnes to common issues

#

If barry scans a paste/error and sees something he knows, he'll respond

#

Similar to how that showcase works I'd imagine

wind patio
ocean quartz
#

Flagged yes, as long as it's not automatic punishment that is fine
A very common false flag we get is CRACKED_STONE_BRICKS for example

drifting aspen
#

I thought the skin had to be signed by mojang

solid spoke
#

hey, is a support of kyori minimessage is planned?

half harness
solid spoke
past eagle
jagged frigate
past eagle
#

For applying the skin, yes, and MineSkin to generate the actual signature and texture

#

The process to actually generate the manipulated image is still much more different than just applying a skin, so the system itself basically puts everything together (set-up overlays), creates the full skin png, generates signature+texture based off the manipulated skin png image and lastly applies it using SkinsRestorer to avoid having to re-log to see the skin-changes cat2

drifting aspen
#

Don't you abuse the API doing this?

past eagle
#

Not by much honestly, haven't ran into an issue, although I am definitely planning to set-up soon enough a better caching system so it directly applies the same skins from the cache instead of using the api all over again to generate the skin from zero

drifting aspen
#

I think the API pool isn't really that large

#

So if this were to be pushed into a real plugin I think it would probably overload it

past eagle
#

There's already around 7-8 users now of this system along with other private servers using the exact same system for their skin generation, hence why I'll definitely set-up the caching to avoid future overload issues from it

#

Could always setup a usage limit as well so it doesn't allow usage abuse

past eagle
#

Does anyone know whether there’s a direct way to make NPCs only visible to the user that created them? Or something such sort

pastel crow
#

can anyone write me the proper code line for reducing the default armor stats ( for example: iron armor be reduced to half of its effectiveness ) PLEASE and thank you.

feel free to @ me

distant sun
distant sun
pastel crow
distant sun
#

What json? Are you making a data pack?

#

This channel wont be very useful for data packs

pastel crow
pastel crow
#

also where would i be able to talk to people about this

keen wing
#

Hello how can i parse this as console PlaceholderAPI.setPlaceholders(null, "%%bungee_total%% oyuncuyu")

remote goblet
#

Bukkit.dispatchCommand(Bukkit.getConsoleSender(), PlaceholderAPI.setPlaceholders(null, "<command>"));

half harness
#

I'm pretty sure it accepts a nullable OfflinePlayer

keen wing
slate elk
#

really no reason thing to do

final scroll
#

I have a custom enchantment, glow. It's sole purpose, as you can imagine, is just to make an item glow. Before the item is added, the enchantment is applied, however, after it is added the enchantment is removed. Any idea why?

player.getInventory().addItem(ITEM);
System.out.println(ITEM);

for (ItemStack i : player.getInventory().getContents())
  if (i != null)
    System.out.println(i);
[11:43:44 INFO]: ItemStack{DIAMOND_SWORD x 1, UNSPECIFIC_META:{meta-type=UNSPECIFIC, enchants={glow=1}}}
[11:43:44 INFO]: ItemStack{DIAMOND_SWORD x 1, UNSPECIFIC_META:{meta-type=UNSPECIFIC}}
fading pagoda
#

how you apply it... (enchantment)

blissful sluice
#

Does anyone know the proper name for using a like queue/tracking based push system for database writes?

Like when you save a changes in-memory and bulk-writing/saving to DB on a timer etc?

cinder flare
#

Batching?

final scroll
fading pagoda
#

try add unsafe

#

addenchantment

#

or hashmap adding

final scroll
#

I'll try unsafe, hold on :)

#

Noop, it still gets removed

inner umbra
#

Try adding it to the itemmeta

#

@final scroll show the whole code. There shouldn't be a reason based on that code the enchant gets removed.

blissful sluice
cinder flare
#

Yeah I mean I would call that a batching strategy

#

Computerized batch processing is a method of running software programs called jobs in batches automatically. While users are required to submit the jobs, no other interaction by the user is required to process the batch. Batches may automatically be run at scheduled times as well as being run contingent on the availability of computer resources.

#

@blissful sluice

blissful sluice
#

Ig it's just because of the terminology/language being so different from what I'd expect it sounds off

cinder flare
#

i mean yeah idk, that's just what I'd call it in general lol, doing jobs in batches as opposed to individually

final scroll
# inner umbra <@298069648144990208> show the whole code. There shouldn't be a reason based on ...

This is all really, there has to be some event that's affecting it I assume? But I can't think of what that can be though.

public class TEST extends AbstractCommand {
  private static final ItemStack ITEM;

  static {
    ITEM = new ItemStack(Material.DIAMOND_SWORD);
    ITEM.addUnsafeEnchantment(Enchantment.GLOW, 1);
  }

  @Override
  public void call(CommandSender sender, String[] args, CommandSendEvent event) {
    ((Player) sender).getInventory().addItem(ITEM);
    System.out.println(ITEM);

    for (ItemStack i : ((Player) sender).getInventory().getContents())
      if (i != null)
        System.out.println(i);
  }
}
blissful sluice
cinder flare
final scroll
# inner umbra Hmmm. Yeah try itemmeta

I also have an ItemFactory class where I do this:```java
for (Entry<Enchantment, Integer> e : enchantments.getEnchantments().entrySet())
m.addEnchant(e.getKey(), e.getValue(), true);

Same result
inner umbra
#
ItemMeta meta = ITEM.getItemMeta();

meta.addUnsafeEnchantment(<glow>);
ITEM.setItemMeta(meta);
```Or something similar.
final scroll
#

That does not exist, ItemStack#addUnsafeEnchantment calls ItemMeta#addEnchant(Enchantment, int, boolean)

inner umbra
#

Yeah not on PC so can't check the code. I wonder if the final modifier is causing an issue...

final scroll
#

I doubt it, as the enchantment is applied to the meta it should be fine. Also neither ItemStack or ItemMeta are immutable

#

I can try

#

Noop, no difference

#

I guess there must be a Listener causing some trouble somewhere

inner umbra
#

Yeah. I'm not seeming to be able to replicate it removing the enchant.

public class BaseCommand implements CommandExecutor {

    public static ItemStack sword = new ItemStack(Material.DIAMOND_SWORD);
    static {
        sword.addUnsafeEnchantment(Core.glow, 1);
    }
    
    @Override
    public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args) {
        if (cmd.getName().equalsIgnoreCase("test")) {
            if (!(sender instanceof Player p))
                return true;

            p.getInventory().addItem(sword);
            return true;
        }
        return false;
    }
}
final scroll
inner umbra
final scroll
#

I could, if I knew where they all were lol. I'm too lazy to initialize them manually, so I do it via reflections when the plugin boots. So I have to find all the Listeners first lol

inner umbra
#

... hmmm well let me know if you find the issue.

wind patio
#

ctrl shift f "implements Listener"? 🥴

soft umbra
#

Guys i need help So i got cutom sharpness 12 sword that i enchanted with essentials it does the same damage like sharpness 5 sword? How and why?

#

I have these plugins is any of them blocking the sharpness 12 or something?

#

oh cant upload image here

lost river
#

unsafe-enchantments in EssX config

soft umbra
#

which is weird

brittle leaf
#

also post an image of the item itself

#

continue there

#

it doesnt look like sharpness has a damage cap

obtuse gale
#

who can help me with one easy config?

oblique heath
#

just post the exact issue so others can see it and help, that way we don't have to back and forth a bunch

final scroll
remote goblet
#

stop using eclipse, use intellij ;3

final scroll
#

I'm way too used to Eclipse, it works well for me. The only problem is some small inconveniences every now and then :>

remote goblet
#

find god

final scroll
#

💀

#

I can code in it, it's fine lol :)

#

I can't miss what I don't know exists. I didn't know you could search like that in Intellij, so I'm not missing it heh

inner umbra
final scroll
#

WHAT

#

omg

#

That's crazy ||I was crazy once||

prisma wave
#

convinced some of you are legit masochists

distant sun
#

man I have to use eclipse at work to edit some internal tool BECAUSE IT DOESN'T USE A BUILT TOOL AND THEY HAVE EXAMPLES ONLY FOR ECLIPSE and I hate every second spent in it

half harness
#

Actually it's prob better to just use eclipse

distant sun
#

yeah idk, the project is so weird, ive tried to import it in IJ but it didn't recognise the libraries and shit so I quit

#

I might try again though, using eclipse is not good for my mental health kek

final scroll
potent nest
#

it works fine until you open the code in IntelliJ and every line has a warning

final scroll
#

xd

potent nest
#

I've seen it so many times, you can tell from the code quality whenever someone was using eclipse

jagged frigate
#

What language should I learn to make plugins?

#

Other than Javascript

potent nest
#

if you want to write minecraft plugins, java would be the best I guess

final scroll
#

No

#

Java

jagged frigate
#

How about Kotlin?

final scroll
#

Kotlin works, but most guides and forums and whatnot will be Java

jagged frigate
#

I already learned Html and css, I think I want to further my knowledge to make plugins.

distant sun
potent nest
final scroll
jagged frigate
potent nest
#

I'd say Kotlin is actually more difficult than Java, but easier than Scala

jagged frigate
#

I see

#

What the different tho?

distant sun
#

Java and JavaScript are not the same thing/similar, it is easy for a beginner to mix up the both (or for a recruiter kek)

jagged frigate
#

Can I use C+ or C++ to make plugins?

distant sun
#

Java or other JVM languages (idk how, I've only used Kotlin besides Java)

jagged frigate
#

I am confused, what you mean by other JVM languages

potent nest
#

In theory: yes. Is it practical: no, not at all. You'd make your life very terrible

distant sun
#

Ywell, can you explain what JVM is?

jagged frigate
#

Sorry.. I am beginner D:

potent nest
#

JVM languages are languages than can be run by the JVM, i.e., they can be compiled to Java bytecode. This includes languages like Java, Kotlin, Scala, Clojure and more

#

the JVM (=Java Virtual Machine) "understands" java bytecode and can execute it then

jagged frigate
#

Should I use Linux to learn Java?

potent nest
#

no, you can develop with Java on windows just fine

prisma wave
#

It’s kinda the equivalent of an artist using ms paint

#

Sure it works, but it’s limiting you and indicates you’re not super serious about the projects you make

#

Also this is more subjective but eclipse UI is fugly

distant sun
#

Exactly

#

I can barelly tell they are still updating eclipse kek

#

The flat IJ ui is not so bad think I like that gradient at the top and other things

prisma wave
distant sun
#

What plugins do you use? I only got material theme and atom icons
Talking ab icons, I hate how most stuff are flat / minimalistic in comparison to the original ui, yet the buttons at the top are so fucking big (like run, build) and why is there one for plugins in the main ui??

prisma wave
#

yeah just those two really lol

distant sun
potent nest
#

Rainbow Brackets is nice

prisma wave
#

oh yeah that ones good too

long dagger
#

Github Copilot too

#

and then Minecraft Development makes developing plugins / mods far quicker

drifting aspen
#

how so?

#

It only creates the base project

#

nothing else

#

And it still does not support gradle kotlin DSL CLd_Madge

long dagger
#

it has support for some Mixin stuff along with NBT data, and it can do MCP mappings

drifting aspen
long dagger
#

yeah, I meant just minecraft in general

pastel imp
#

y'all speaking about eclipse & intellij? I use netbeans at school, ngl quite like it in someways...

wind patio
#

IJ plugins I personally use:

  • CodeGlance Pro
  • Copilot
  • Rainbow Brackets
  • Statistic
  • String Manipulation
  • Key Promoter X
half harness
#

after an eternity of figuring out why passkeys did not work on my (android - samsung) phone (the "setup passkey" button just didn't do anything but freeze the screen for a split second), I figured it out

Google Chrome had to be installed 🥲

#

you don't even have to set up chrome or anything

#

it just needs to be there

#

welp
just gonna leave this here in case someone else has chrome uninstalled

#

don't know why that's a requirement though

ornate nimbus
#

And codeglance pro

wind patio
#

string manipulation gives you a variety of options for selected text:

ornate nimbus
#

What about key promoter X?

wind patio
#

if you click a thing manually with your mouse, such as 'build', if there's a keybind for it, it shows you what you could've pressed instead

potent nest
#

though it sadly only promotes the stuff that is easy to do with your mouse anyway. The really powerful things can't be really promoted because there's no equivalent operation

#

But IntelliJ has the Productivity Guide where you can see which feature you're using how much (and which one you don't!)

#

this is what it looks like

wind patio
potent nest
#

yeah but for example syntax aware selection is what really speeds up your coding (at least for me)

wind patio
#

that's like double-clicking a part of text?

#

or CTRL (+ shift) + W (default)?

potent nest
#

here's a quick example how it extends the selection depending on the syntactical structure

wind patio
#

yeah, I'm aware of that, been using this a lot lot

potent nest
#

It's probably one of my favorite features together with Alt + J

wind patio
#

another cool IJ thing is CTRL + Right click

#

(though maybe that's rainbow brackets feature, I'm not sure)

ornate nimbus
#

That's actually so nice wtf

#

I feel like I'm not using any of the features that intellij or my plugins have

sly sonnet
crude cloud
#

esc

ornate nimbus
#

What are some other plugins you would recommend other than the ones previously mentioned

crude cloud
#

Nyan cat progress bar

#

system critical

wind patio
#

usually depends what you need or like, other ones I use is jsondiff, One Dark Theme, Grep Console, SonarLint, CSV Editor, Extra ToolWindow Colorful Icons

distant sun
crude cloud
#

default git plugin

wind patio
#

um, no, it's the block marking

#

the inline messages are from git

ornate nimbus
crude cloud
crude cloud
wind patio
ornate nimbus
#

I think I know you from somewhere

#

Are you ehh

#

Argentinian?

crude cloud
#

eyeah

ornate nimbus
slate elk
#
        double totalChances = droptable.values().stream().mapToDouble(Double::doubleValue).sum();
        double randomChance = new Random().nextDouble() * totalChances;
        double currentSum = 0;
        DropItem closestItem = null;
        double minDifference = Double.MAX_VALUE;
        for (Map.Entry<DropItem, Double> entry : droptable.entrySet()) {
            currentSum += entry.getValue();
            double difference = Math.abs(randomChance - currentSum);
            if (difference < minDifference) {
                closestItem = entry.getKey();
                minDifference = difference;
            }
        }
        return closestItem;
    }
#

i feel like it doesnt work currectly

ornate nimbus
#

What doesn't work

pastel imp
#

now, any good person would ask "why doesn't she love you?" or "why do you feel that?"

#

anyways, be specific xd, a lot can not work

distant sun
potent nest
pastel imp
#

💀

#

I don't even understand what that code is supposed to do

brittle leaf
#

converting the chances into like a stacking value composition,

#

you end up with values like
0.5
0.8
1
and youd going through the list from lowest chance to highest chance and seeing if the random value is bigger

#

the values would only be different then their chances if theres more or less then 100% chance total for all items in said drop table

#

doing the composition that way means you dont have to input a single value between 0 and 1 and end up getting something from the droptable list

pastel imp
#

uhm random question, what's a good framework/library to use for a very fast rest api? In terms of latency, requests per second, etc. Performance in general

potent nest
#

that's extremely hard to tell and depending on where the data comes from, the framework might not even matter at all

wind patio
#

than saying 'uh yeah it's the if statement at the line 175 and the end at 189'

#

not a big life-saver but still

slate elk
#

But I feel that I wrote the code not in right way

#

Since the chances seem not work

#

Like low chance items appear pretty often

#

Which is weird

slate elk
potent nest
#

yeah every time you call that code

slate elk
#

Well yeah

#

But still it doesn’t work as I plan it on paper

#

Like not really paper as it was in my head lol

potent nest
#

I don't know what you're trying to achieve

#

but you should reuse a random instance

#

or just use ThreadLocalRandom

slate elk
#

Hmm maybe I’ll change not to be really random

#

What do u think about it

#

Let’s say we have a lootFactory which uses the sum and just pushes next number every time that way

#

I’ll make map that stacks the num of each item

#

As time when it should appear and then

#

Random won’t be random

#

Like random doesn’t exist it probably uses system time or something

#

To return me a diff num every time

#

😂

potent nest
#

what

slate elk
#

{a2,b4,c6} a=2 b=6 c=12

potent nest
#

just use the stackoverflow code smh

pastel imp
agile galleon
#

Just saying, if you need fast data access don't use rest apis?

#

Imo the fastest json file served wouldn't be much faster using Rust than Scratch

pastel imp
#

kinda going to have to handle a lot of requests per second though

agile galleon
#

Why are websockets not an option

pastel imp
#

it's for a public project and to my knowledge websockets require extra setup and well, shouldn't be used for these things?

#

it's not for private use.

#
  • it requires for the user to open a port
#

so, yeah, unsure what other options I have

ornate nimbus
#

i asked her

half harness
#

even if it does take like >1ms, if it's a large library it probably has taken performance into account, so latency should be like 99% uncontrollable by the server software

#

I haven't made a rest api in java before 🥲 so I can't really say much

half harness
#

from the user perspective, the amount of setup should be the same, if not less for using a websocket

cinder flare
#

not if you're hosting the web server and the clients just have to send the data lol

#

keeping websocket sessions open is a pain, it's not really worth the overhead

half harness
#

oh

#

wait wdym?

cinder flare
#

just use any rest api framework, it basically doesn't matter, you'll be constrained by data storage no matter what

agile galleon
#

@pastel imp Tebex for example, which has pretty quick execution, just sends a GET requests every 10 seconds

cinder flare
#

good old polling

pastel imp
pastel imp
agile galleon
#

yes

#

the other way wouldnt really work

pastel imp
#

true lol

#

either way gonna have to handle like 100 requests per second minimum

half harness
#

only the server of the websocket needs the port open

pastel imp
#

don't they require some type of password/auth?

half harness
#

but password/auth is not required

#

afaik

pastel imp
#

I can still have some type of api key though right?

half harness
#

i think?

agile galleon
#

websockets are prone to just shitting themselves

distant sun
half harness
agile galleon
#

so having an instance just send a request every 10 seconds and split the requests onto multiple instances via a loadbalancer, you should be good to go

pastel imp
agile galleon
#

how about you first tell us for what exactly you need all those requests

pastel imp
agile galleon
#

for every message?

distant sun
#

sending a request for each message sounds like a bad idea?

half harness
pastel imp
#

it is a bad idea

agile galleon
#

yeah not exactly

half harness
#

why is it a bad idea?

agile galleon
#

why do you need a request for every message?

half harness
#

depending on the usecase

distant sun
#

metrics

pastel imp
#

actually no

agile galleon
#

no that would be too stupid

distant sun
#

just send the data every x seconds or when it reaches a certain threshold and that should be fine alex_cool

pastel imp
#

I said analyse as an example since they are similar in the way it works, but working on an AI Moderation system/assistance. For the assistance mode, this would be fine, to send in bulk every few seconds, but for real-time, each message would have to be checked asap and return a response to know if the message should be sent in chat or not. from what I have seen it would delay messages around 80-140ms which isn't that noticeable.

half harness
pastel imp
#

it's a tricky challange, since you have to find the middle ground for UX and at the same time not blow up my webserver lol

pastel imp
#

but it's not going to be solely minecraft focused.

cinder flare
#

it should just check messages async after they're sent and remove them if they're not allowed

agile galleon
#

yeah

cinder flare
#

if your service goes down for whatever reason, people just won't be able to send messages anymore

pastel imp
#

how do you want to remove a message in a minecraft chat?

#

💀

half harness
#

u can remove signed messages

cinder flare
#

send a lot of blank lines?

#

you can never really remove anything technically

distant sun
#

yeah well, you did not mention this part, you said "analyse" which simply accepts post requests with data smh

half harness
cinder flare
#

most servers don't do signed messages

half harness
#

true-

pastel imp
#

true

cinder flare
#

and even then, same thing as discord

#

the clients can just decide to not

half harness
#

also true

#

but i feel like less true

#

but true

pastel imp
#

either way, "real-time" mode would be impossible in that case

cinder flare
#

moral of the story, literally any good REST api framework will be able to handle thousands of requests a second easily with a fair bit of resources

#

Django, FastAPI, Laravel, Spring, ASP.NET, anything

agile galleon
#

i believe the bottleneck would become the moderation ai pepela

cinder flare
#

^

#

was just about to write that lol

pastel imp
#

that part is covered, working quite decently

distant sun
#

cool

cinder flare
distant sun
#

fast++

pastel imp
#

xD

cinder flare
#

here's a cute one I personally liked

pastel imp
#

hell that reminds me of that one time like 3-4 years ago where people were using skript as a backend 💀

agile galleon
pastel imp
agile galleon
#

random generator bruh?

distant sun
agile galleon
#

you have a dictionary and a brain that can do programmer things

pastel imp
distant sun
pastel imp
#

good point

pastel imp
#

true

#

I mean, it still sucks in a few things

#

fking mod

#

(auto mod didn't let me send the msg)

agile galleon
#

so lets see if it shits itself

pastel imp
#

like it doesn't really recognize "noob" or the 3 letters used to tell someone to yeah, RIP

#

but it does handle stuff like

#

"shit, you are right"

distant sun
#

doing pretty good, I see

agile galleon
#

ping me when you let it moderate a thousand messages a second pls

pastel imp
#

gotta make a system to make it more compact for that

agile galleon
#

what

pastel imp
#

right now it generates a json with some extra data

#

so it would be a nightmare to read

cinder flare
#

OLAP db time

cerulean ibex
cinder flare
pastel imp
cinder flare
#

idrc though, there's not a lot of speed difference in web frameworks like this

cinder flare
pastel imp
#

bruh

#

.-.

#

barry needs a mod ai

cinder flare
#

yeah look into clickhouse fr though, shit is so good at storing that kind of data

pastel imp
#

will give it a check, thanks

#

I am also doing tests to compare this with using something like fine tuning an openai model, turbo models are awesome and from the tests I did are decently better than my current one but it would be way more costly to do it.

agile galleon
#

how much are you planning to charge?

pastel imp
#

Right now, I am in a dilema on if I should do like Minevision and make it based on a discord bot + kofi for starters, then move to a website or if I should just go with a web app directly, which would require much more time, and knowledge since I have no experience with web apps lol but have a lot with discord bots.

#

So quite unsure on that side on how I should proceed. I am going to begin trials on 2 servers I work for whenever I have the web api set up.

agile galleon
#

A Discord bot works for Minevision because Discord is an easy way to exchange prompts and return images, like Midjourney did. If you want the whole thing to also work on Minecraft servers and on other platforms, you shouldn't use a Discord bot

#

You can still use KoFi, but I've had a few issues with it and it's not really built for that

#

You can easily achieve a monthly subscription with stripe or Gumroad for example

#

thats just my opinion though

#

having a discord bot as your interface will shoot you in the knee in the future

pastel imp
pastel imp
agile galleon
#

gonna. be. a. pain. in. the. butt.

pastel imp
#

gonna be a pain in the butt either way since I have near zero experience building web apps xd, so chances something goes wrong are very similar

agile galleon
#

an issue i had is kofi saying that the subscription expired while the customer only cancelled yesterday and the subscription should still be available until the end

agile galleon
#

also as I said, kofi isnt built for such a thing

pastel imp
#

I think at the end, I know that I should just do a web app, but my lack of experience scares me of fking up and the comfort I have with discord bots works as an escape for me

agile galleon
#

youll have to do it either way?

pastel imp
#

fighting a mind war lmao

agile galleon
#

honestly if you go with Laravel you will save much time

pastel imp
pastel imp
cinder flare
#

Laravel 😌

#

if you're not familiar with frontend shit, you can get pretty far with just Blade templates

agile galleon
#

yeah

cinder flare
#

especially for like, a basic config thing for the service

agile galleon
#

doesnt have to look pretty

cinder flare
#

javascript

#

React/Vue/Svelte

pastel imp
#

I am quite decently comfortable with html and css, javascript I suck lmao

pastel imp
cinder flare
#

you can use Laravel/Inertia with Svelte easily

pastel imp
#

although react ecosystem do be poggers

cinder flare
#

it's kind of annoying to get it SSR'd, but if you're just doing a basic config site it shouldn't be that bad

pastel imp
cinder flare
#

you can use Blade templates for the marketing part if you need

agile galleon
cinder flare
#

it is for marketing/public facing parts

#

unless you want to never get any SEO and not show up on google lol

agile galleon
#

the text is always static, isnt it?

cinder flare
#

huh?

agile galleon
#

wat

#

maybe im stupid

#

oh shit yeah

cinder flare
#

in a normal SPA, the html is empty, it just mounts a javascript script that makes all the content

#

that's why you SSR, so that the first initial page load has all the shit on it

agile galleon
#

i was stupid there for a sec

pastel imp
#

xD

#

Was thinking on using Laravel Spark if I went with Laravel but it sadly only supports Stripe...

pastel imp
#

Could Tebex be an option? Don't they have Tebex Checkout or whatever it's called?

cinder flare
#

Tebex is more for game servers

agile galleon
#

like stripe is the thing you'd use

cinder flare
#

use something like Shopify or Lemon Squeezy if you want broad support and an easy API

agile galleon
#

imho

cinder flare
#

in both of those, you could just make a checkout link, redirect the user to it, then receive a webhook when the payment goes through

cinder flare
pastel imp
agile galleon
#

ah crap minecraftttttt

pastel imp
cinder flare
#

idk but your fees are most likely going to be higher than just doing your own thing

#

especially if you don't plan on using their webstore

cerulean ibex
agile galleon
cinder flare
#

I guess they could use actix-http for 500,000 requests per second lol

agile galleon
#

or just a load balancer

cinder flare
#

i severely doubt the rest layer will be the bottleneck

pastel imp
cinder flare
agile galleon
#

i believe this is for somebody already familiar

cinder flare
#

Just follow the Laravel breeze tutorial

#

super easy stuff, it can scaffold a whole project with auth and everything with Svelte iirc

#

might just be React/Vue, but it's pretty easy to swap out

agile galleon
cerulean ibex
agile galleon
#

(only doing this because i dont pay for them)

cerulean ibex
#

Actix or axum are more lighting

cinder flare
#

yeah lol, kind of a weird ad

pastel imp
#

just reminding you, you are speaking with someone with 0 knowledge on these things, max I have done on the web is static websites, I am more of a frontend dev

agile galleon
#

yeah the one i sent above is straight for beginners

agile galleon
pastel imp
cerulean ibex
cinder flare
agile galleon
#

but yes it could be seen as an ad

#

i dont intend for it though

pastel imp
cinder flare
#

Just do Breeze & Blade

pastel imp
#

welp, will have to check this out tomorrow, gotta head to bed rn

#

thanks though for help in both things

prisma wave
wind patio
#

oh

#

I've setup paypal with laravel myself, was quite iffy but doable

cerulean ibex
#

haskell <<<

#

curry man <<<

ornate nimbus
#

D:

prisma wave
#

if necessary

slate elk
#

i will always have on my hand the existing possible drops

#

everytime an item will be token out i will re generate them back to list

#

instead i wont use double anymore for lower precentages its dumb

#

ill shuffle everytime and take [0] and ill just add the missing item using its ID

#

Actually no need shuffle

#

ill just make work in loops

#

when i add something to list it goes always to be last position right?

potent nest
#

Yes

#

But that’s not really random

#

But I still don’t know why you don’t just use the NavigableMap approach

slate elk
#

really random does no exist lets be honest

#

it will be random for users

#

because they wont know whats next ;p

#

and it will keep things in right balance

pastel imp
#

we ain't cloudflare

#

unless you have 100 lava lamps in your basement

potent nest
#

There are different RNG implementations that have different guarantees about their quality

wind patio
#

my team senior dev uses white theme intellij

#

should I hit him with 'white theme detected, opinion rejected'??

pastel imp
#

101%

final scroll
#

I have this code for storing a value in a MySQL database.

private static final String INSERTION_QUERY = "INSERT INTO FooBar(id, data) VALUES (?, ?) ON DUPLICATE KEY UPDATE data = VALUES(data)"

//...

String id = structure.getUUID().toString();
String serialized = new String(ByteSerializer.SERIALIZABLE.serialize(structure));

PreparedStatement pstmt = connection.prepareStatement(INSERTION_QUERY);
pstmt.setString(1, id);
pstmt.setString(2, serialized);

pstmt.execute();
pstmt.close();

I also have this code for getting the value in the database.

private static final String SELECTOR_QUERY = "SELECT data FROM FooBar WHERE id = ?";

//...

String id = uuid.toString();

PreparedStatement pstmt = connection.prepareStatement(SELECTOR_QUERY);
pstmt.setString(1, id);

ResultSet set = pstmt.executeQuery();
String value = !set.next() ? null : set.getString("data");

set.close();
pstmt.close();

But I get the following error when loading the data and I do not understand why java.sql.SQLException: Column 'data' not found.

agile galleon
final scroll
#

So yes, the table is there

potent nest
#

have you tried to use a debugger?

slate elk
#

Because random can hit twice same@number

#

Or never something

potent nest
#

also data is highlighted there, maybe it's a keyword in your sql dialect? If so, try putting it in ``

slate elk
#

That way I know once 100 generates there will be 1 lucky player 😉

final scroll
potent nest
final scroll
potent nest
#

no, in Java

final scroll
final scroll
#

Thank you :)

slate elk
#

How should I queue

#

The thing is there will be couple queues

#

For category and sub item

#

Now it will be appeared within 10 other items

#

It doesn’t really matter because users will do 600 of those every hour

potent nest
potent nest
# slate elk How should I queue

The same you do as with the list, but removing the first element from an ArrayList is far more expensive than removing it from an implementation that is meant to be used as queue

inner umbra
#

Set<Object> objects -> objects.get(Random.nextInt(objects.length-1))

slate elk
#

now u can multiplie those options by 100

#

which gives me 200,000

#

i think too big list lol

potent nest
#

yeah that might be fine then

#

but then you really shouldn't remove the first element from an ArrayList lmao

slate elk
#

i wont remove any element

#

i will just init the size

#

and then do if (size > pos){ +1 } else { 0 }...

potent nest
#

yeah that's fine then

slate elk
#

yeah the amount of things players can get is so huge actually

#

some items have different stats

#

its rng in rng in rng in rng lol

#

dunno how i will do wiki haha

slate elk
#

it works like shit from some reason

#

and doesnt feel like the 0.5% is 0.5%

inner umbra
#

I create a map of items with their chance... Run random and collect items above the number. Then I choose a random item from the collected.

potent nest
slate elk
#

at the moment i do simillar thing

#

i have sum of all options it doesnt go by 0-100

#

it goes by amount of options which is around couple of thousands

#

and i reterive the most close option

potent nest
#

if random isn't really random, what are you doing to make it actually random?

wind patio
#

in programming there's no actual 'random', just 'random'-enough or pseudo-random

crude cloud
#

there's the dn random algorithm

wind patio
#

dn?

pastel imp
#

jokes on you, did a coinflip once using the Random class, somehow a guy won it 16x in a row lmao

#

either he's a luckly mf or idk

#

that's like 0.001526% of happening

potent nest
#

I mean that's just how probability works

wind patio
#

true

crude cloud
#

yeah, 16 times in a row adding up to a whopping ~0.0015% for the entire sequence

tawny crest
#

"a better gaming chair"

slate elk
#

some random algorithm depends on system time , or other thing that updates consteantly

#

and then you get some sort of random

#

but in general random class is really bad i think

#

it doesnt work like random at all

#
int randomnum = (int)Math.floor(Math.random()*(max-min+1)+min);
#

i think Mah.random is better

#

then Random

potent nest
#

man you really have no clue what you're talking about

#

Math.random() uses a global instance of Random

wind patio
#

Lol

#

Blud be bluddin

wind patio
# slate elk i think Mah.random is better

Gonna repeat what SirYwell said, but yeah, you use the Random class when you, for ex. want each class instance to have a different seed for it, Math.random() just uses a static instance of Random class itself, and you're kinda limited to the one method Math class provides which returns double. If you use Random itself you can use next, nextInt, nextLong, nextBoolean, etc.

#

What

#

Shocker

#

Its like this is somewhat universal between coding languages

#

You'd be shocked that javascript also has Math.random

#

Guns are illegal in minecraft

#

Banned

#

Yea yeah I think its only for the servers

inner umbra
#

Mods, plugins etc... can't be removed by mojang cause it's not their code. But servers can be blacklisted that have these banned resources... you could just remove the ban code from the client though.

crude cloud
#

they can send you a takedown request if the plugin/mod does not align with their community guidelines

inner umbra
#

They have no legal standing to do so. As long as you aren't using their assests you're fine.

wintry plinth
prisma wave
#

Yeah lol they have every right to do something like that

flint crow
#

oops wrong channel

wind patio
#

epic fail

agile galleon
#

Yapper yapping again

crude cloud
#

they can definitely take that to court if you refuse and they wanted to

#

will that happen? unlikely, they'll probably take other cheaper actions, but they can

charred violet
#

How long does it take for my spigot account to be verified in average? I kinda need some support for the premium version of the guild plugin sad

tawny crest
#

I remember not having any problems with that lol

charred violet
#

Right ill try to be patient then lul

#

Eyy its done ! Lovely

tawny crest
#

yup

compact perchBOT
peak zealot
#

anyone able to help me with this im trying to use a left click requirement

#
      requirements:
        anything_here:
          type: has item
          material: QUARTZ
          amount: 50```
prisma wave
past eagle
inner umbra
#

Damn doing some micro optimization for my bitcoin mining software...
Just doing String blockheader = job.version + job.previous_hash + hexRoot + job.time + job.bits + nonce; drops the amount of calculations from 100+ mh/s to 13 mh/s
Also tested with StringBuilder and had the same performance issue.

Any ideas on how to optimize this? Literally just appending variables into a string.

#

Seems like collecting the values from the variables is what causes the strain on performance...
String blockheader = "Test1" + "Test2" + "Test3" + "Test4" + "Test5" + "Test6"; works fine.

potent nest
#

Well the latter will compile to a single string

#

But generally, string concatenation has a few problems: you need to allocate memory , you need to create a string from most non-string objects before, you need to convert numbers into a string representation…

#

But e.g. converting an integer to a hex string should be somewhat faster than decimal

inner umbra
#

Well... all of those variables are strings lol

potent nest
#

Then it’s most likely just memory overhead

prisma wave
#

as always, run a profiler before trying to make any assumptions about performance

inner umbra
#

I was adding in line by line to see where the most strain from the calculation comes from. So I narrowed it to that to start with.

#

That then hex then hash.

potent nest
#

Changing code is a bad idea when tracking down performance issues

#

Just use a profiler as bm said

inner umbra
#

Long.toHexString() also takes some time but not many better methods then that.

#

I can do both ways. It's only a few lines of code so there isn't a lot of code to profile lol

#

Also got and increase in calculation by not checking an atomicboolean and just doing while(true) {

potent nest
inner umbra
#

🤷 working out fine for me.

I'll probably pre concat the string when the job is found and add the nonce when needed.

inner umbra
#

Yeah having the variables appended when the job is found makes about a 10 mh/s difference.

#

String blockheader = preheader + nonce; is still taking a good 70+ mh/s off the total calculations it can do before hex/hash

#

string.concat(String) is faster then +
String blockheader = preheader.concat(nonce); jumped up to 43 mh/s

#

Getting an additional 2 mh/s as the result 😉

#

100+ kH/s on my raspberry pi

inner umbra
#

Well at the moment its varying in my favor lol

potent nest
#

Yes

drifting aspen
#

Just why would you write a CPU miner in Java?

snow oriole
#

can someone explain how gradient work ?

inner umbra
potent nest
ocean quartz
#

"because java slow" - them, probably

prisma wave
#

i meannnn

#

there are some cases when that statement is actually meaningful

drifting aspen
#

It's definitely slow for making a CPU Bitcoin miner

crude cloud
#

bro hasn't heard of hotspot

drifting aspen
#

:/

#

I have

inner umbra
#

Yeah Java isn't the fastest language for a bitcoin miner. But if you look for one there aren't many if any. And I like to make my own things and I know Java more then c so 🤷

blissful sluice
#

Could try something like rust, or i imagine go is even faster than java

inner umbra
#

They wouldn't be faster then c. At least in this case.
(That could or might have already changed though)

prisma wave
#

rust can outperform c under the right circumstances

blissful sluice
#

you said know you more Java than C, so I was trying to find a middle ground :p

#

i find rust so bulky sometimes

#

like, with the whole crates thing

inner umbra
#

Honestly I should learn c and stem to other languages from there. Been limiting myself to Java for years.

blissful sluice
#

Maybe try working down, rather than falling down

inner umbra
#

Nah. I go straight for my goals lol

blissful sluice
#

Going from not managing your memory at all to managing every spare bit sounds... painful

inner umbra
#

I usually try to keep in mind what I'm saving to memory anyways

prisma wave
blissful sluice
# prisma wave how so?

you need a use crates for basically everything meaningful, at least that's what it seems like

prisma wave
#

maybe

blissful sluice
#

async- need a crate
decent http stuff- need a crate
json stuff- need a crate

prisma wave
#

but it's not like theyre hard to use

#

java doesnt have json built in either

#

and it only recently got decent http

prisma wave
#

it's the "npm philosophy" i guess lol

blissful sluice
drifting aspen
#

Literally one command to install the relevant crate

#

Or tbh, the IDE might even install it for you

prisma wave
drifting aspen
blissful sluice
#

Idk I just don't like that the sdk doesn't come with some of these imo basic tools

prisma wave
#

mmm

prisma wave
blissful sluice
#

yeah but it's Java, nobody expects it to be good

#

:p

prisma wave
#

😭

blissful sluice
#

using json and building CLI applications in go is fucking amazeballs

drifting aspen
prisma wave
#

technically you need a package for json in go too

#

i am all for hating on rust but this doesnt seem like a great way to direct the hatred

prisma wave
#

import "encoding/json"

realistically how is this different to adding a single line to the cargo file?

blissful sluice
#

because it's internal, not external

prisma wave
#

if you cant tell the difference, does it matter?

blissful sluice
#

imo yes

#

not to mention, go's json support is just generally a whole level of its own

prisma wave
#

maybe you're right

#

but i think as long as the 3rd party libraries are equally high quality it doesnt matter too much

#

a lot of languages have small sdks

blissful sluice
#

and like, concurrency in rust... gotta use tokio, there's another 3rd party dependency

decent flags system for commands? pretty sure that's another crate

#

go, flag support is native
concurrency too, with their whole channels thing (at least that's what I understand that to be for)

prisma wave
#

you're correct

#

i suppose the justification would be that it's better to let the community decide what works best rather than mandating a single "perfect" way of doing things

#

after all, go is not without its flaws

blissful sluice
#

go's need to constantly define and check for errors is kinda annoying

#

a lot of the time half the code just ends up being

if err != nil {
  lot.Fatal(err)
}

or some variation of that, repeated every few lines

prisma wave
#

yup

#

go error handling is potentially the worst thing in all of programming in the 21st century

blissful sluice
potent nest
#

In most cases, it comes down to whether someone knows what they‘re doing, the language is rather a secondary factor

prisma wave
blissful sluice
prisma wave
#

and i still think that's better than the sdk designers trying to get it right first-time, failing, and then being stuck with legacy code in the sdk for years

prisma wave
#

you also need to return in most cases or you end up with further errors later on

#

at least 3 lines of code per failure case is unacceptable

#

even checked exceptions are better

drifting aspen
#

God I hate checked exceptions

blissful sluice
#

i'd rather just have default behaviour be some sort of log/stderr/panic thing, for those smaller applications where doing anything more than that isn't necessary

potent nest
#

Checked exceptions are an extremely powerful concept

prisma wave
#

oh yeah theyre overhated

potent nest
#

But their integration in the language could definitely be better

prisma wave
blissful sluice
#

eh ig

prisma wave
#

anyway conclusion is that monadic errors > everything

blissful sluice
#

I also hate Go's variable system sometimes, mostly as a result of this error checking system

cus you can end up with 2 different variable states which means you either have to do hacky shit to assign the variables

#

one feature of go that i recently discovered which actually seems pretty powerful is go's return system

if you name your return types with variables, you can assign to them and just return at the end, rather than return x, y

prisma wave
#

oh i dont like that at all

#

it stinks of the single return point antipattern

#

yes lets introduce more mutable variables all the time that will be great

blissful sluice
#

hmm ig

#

i imagine there's some places where that's useful tho

prisma wave
#

very few

#

its definitely not something that should be encouraged imo

blissful sluice
#

imma say something that seems really dumb:

I don't actually understand async stuff, especially as frequently used in MC

Like, you're almost always going to end up joining onto the main thread anyway, so what's the point?

prisma wave
#

you're almost always going to end up joining onto the main thread anyway
not if you're smart

blissful sluice
#

async DB queries especially

prisma wave
#

ok, perfect example

#

let's say a query takes 200ms, so 4 ticks

#

doing that on main thread and joining means the whole server spends 4 ticks waiting for the query and doing nothing else

#

doing it on another thread and using a callback (or similar mechanism) means the server can be doing other things while it's waiting

#

if you're joining regularly you're doing something wrong

blissful sluice
#

fair chance i'm doing something wrong, tbf

prisma wave
#

it certainly sounds like it

blissful sluice
#

but in my defence, i'm not the only one

prisma wave
#

far from it

#

the spigot community is notoriously incompetent

#

cuz everyone learned from shitty yt tutorials and never learned how to actually program

blissful sluice
#

raises hand in shame

prisma wave
#

not too late to fix it!

#

i was the same

#

kinda

blissful sluice
#

i'm trying to learn, but it's so hard trying to wrap my head around these things

I learn best by doing and by seeing how others do things, but because of the nature of my projects being very... particular, there's not a massive amount of good quality references

prisma wave
#

i dont think theres an objectively right answer to that question, it's quite subjective

#

personally i try to stick to POJOs for the data and then have repository types that handle the actual reading & writing

#

like Spring does

blissful sluice
#

Like i've been sitting here on and off for the past few months/year doing those JetBrains Academy lesson/tutorial/project things, and I get kinda bored pretty quickly cus most of the stuff I know, and the projects are simple enough that they aren't really helping me

#

that's not quite what I meant, i don't think

prisma wave
#

is it not?

#

could you give an example?

blissful sluice
#

I was more talking about relationships with other objects, like say for the sake of argument in a factions/towny type thing:

Should the Player/User/whatever object hold a reference to their Faction/Town or should there be some sort of map, or both?

prisma wave
#

i think it depends, really

#

i prefer to go for hard references but theyre not always achievable, often if you have bidirectional references then it can get messed up

#

and you get a toString that StackOverflows

#

but hard reference unless you need a map, seems like a good approach

blissful sluice
#

same question for the DB representation, though I think the answer for DBs is a bit simpler:

Even though it's one to many, should it be a reference table with a composite PK (e.g. faction_guid, player_guid)

or just a coloumn in the player table: faction_guid

#

for DB purposes I'm always inclined to go for the latter, but that type of thing tends to result in me having circular relations:

a player with a faction, and a faction with a player (e.g. faction_leader)

prisma wave
#

you dont need a reference table for one to many

#

only many to many

blissful sluice
#

that's what i assumed

#

I've thought about adding a CS degree onto my list of degrees in the hopes it'd maybe teach me even half this sorta shit, but from what I've seen/heard, CS degrees rarely teach actual programming

#

at least this sort of programming; most of it seems to be web dev or python or the like

steel heart
prisma wave
prisma wave
prisma wave
blissful sluice
prisma wave
#

oh yeah i wouldnt get a degree just to learn relational database design lol

blissful sluice
#

I mean it wouldn't just be that, just program design type shit in general too

prisma wave
#

yeah all of that can be self taught with enough time & effort though

blissful sluice
#

exactly why i haven't added that degree to my list- it's only my backup if both my other 2 fall through

wind patio
#

Whats the topic, I'm a programming genius and I'll answer your question

prisma wave
#

what is a monad?

wind patio
#

Idk

blissful sluice
#

i've heard of that word, that's about all i know

prisma wave
#

hehe

blissful sluice
prisma wave
#

2 degrees??

blissful sluice
#

that's just undergrad

#

if i have the means (financial, motivation, and academic capacity) to do so, i'll probably end up with another 2 postgrad at least (one in each field- international relations and law)

steel heart
prisma wave
#

even so, thats still an insane amount

#

plus an insane amount of debt to go in

blissful sluice
#

bit less, bit more, depending on the exact arrangements

steel heart
# prisma wave true

Sadly had to learn category theory since we use haskell for reasons unreasoned for

prisma wave
#

why do you need 2?

prisma wave
blissful sluice
#

interested in international relations and law

prisma wave
#

thats so unnecessary lol

steel heart
blissful sluice
prisma wave
#

couldnt be uk

#

even so, it's a hell of a lot of commitment

prisma wave
blissful sluice
#

i've got a hell of a lot of time

#

and nothing better to do with it

prisma wave
#

get a job?

blissful sluice
#

that's a funny idea

prisma wave
#

it is

blissful sluice
#

if things work out with the degrees i'll hopefully end up with a job at DFAT (Australia's State Department/Foreign Ministry) or the UN, or somewhere similar

#

or if i do really well in my degrees, maybe i stay in academia and continue on to masters etc

#

that's 3-8 years (depending on configuration) down the line, we'll see what happens then

blissful sluice
# prisma wave it is

anyway, do you have any open source projects that deal with databases properly i can take a peak at

crude cloud
#

@prisma wave

#

what is going on

prisma wave
#

?

prisma wave
#

the actual implementation is in the persistence package

blissful sluice
#

thanks, will take a peak

prisma wave
#

but its a bit of a mess

blissful sluice
#

That is uh, certainly one way of describing what I'm seeing :p

prisma wave
#

it's slightly overengineered bc i wanted json support too

blissful sluice
#

overengineered is one of my favourite states :p

prisma wave
#

real

blissful sluice
#

is it really engineered if it isn't overengineered

#

One thing I love about newer versions of Java, I can now write multiline SQL queries without it looking like a mess

#

hmm, i notice you don't have a dedicated thread pool for your async stuff

prisma wave
#

yeah i just use the forkjoinpool

#

frankly im not sure if it's a good idea or not to do that

blissful sluice
#

From what I saw in LuckPerms and in Aikar's IDB, they both created some form of thread pool

#

suggests maybe not the greatest idea to do that

#

However, here's my problem:

you can't easily use CompletableFutures in a TaskChain-like manner switching between sync and async unless you have the executors for both handy

prisma wave
#

thats not entirely true

#

but ive basically never had to do that

#

but just make the executors constants and ur balling

blissful sluice
#

can't easily do that, at least without static stuff- e.g. an instance method on ur JavaPlugin or using the JavaPlugin#getPlugin/getProvidingPlugin stuff to access main thread

crude cloud
#

this is when you throw in a DI framework and you make your own @ServerThread annotation you can have something like public MyCtor(@ServerThread Executor serverThreadExecutor) and configure your DI setup to bind the main thread executor to an Executor.class annotatedWith ServerThread

blissful sluice
#

but DI framework = more bloat 😦

crude cloud
#

shh no

#

more engineering

#

here, have some copium

blissful sluice
#

i'm the type of person that will try to break down a library and remove all the shit that i don't want/need

inner umbra
#

^^^ except I just code it from scratch lol

agile galleon
#

You're the yapper type ig

blissful sluice
#

it's one of the reasons I have such a hard time settling on a command framework too

agile galleon
#

LAMP ftw

blissful sluice
#

Tried LAMP, it couldn't do everything i needed it to do

#

or wanted it to do

agile galleon
#

What do you need more?

blissful sluice
#

it was something to do with permissions

agile galleon
#

Wat

#

You can always check permissions yourself

blissful sluice
#

it was a complicated permissions system on top of the base permissions system

#

like, think factions permissions type thing

prisma wave
#

can still do it yourself hehe

blissful sluice
#

i wanted to use their resolver system

#

wait no that wasn't the most important part

#

the most important part was the ability to optionally consume input as part of a resolver

agile galleon
#

Can you not?

blissful sluice
#

I don't think so at the time

agile galleon
#

What type of resolver?

blissful sluice
#

I wanted to have it so that if the user hadn't provided input, the parameter value would be provided

#

idk what the deal was, but it wouldn't work

agile galleon
#

I'm confused

blissful sluice
#

wasn't designed to allow it

agile galleon
#

Eh whwatever

blissful sluice
#

I was trying to do something equivalent to ACF's IssuerAwareContext

agile galleon
#

Never used acf, then use that

blissful sluice
#

You may also use registerIssuerAwareContext instead to tell ACF that this resolver is able to resolve without consuming input, by understanding the context of the issuer of the command (such as World, Location, Etc)

A non issuer aware resolver must consume input. Issuer Aware may optionally consume input if supplied, and fallback to context if not.

f you want an Issuer Only resolver, one that always resolves based on Issuer and never consumes input, you may use registerIssuerOnlyContext

#

that's the description for ACF's parameter resolution system

prisma wave
#

why not just use ACF?

blissful sluice
#

ACF was too complicated in some parts

agile galleon
#

That sounds like legalease lmao

blissful sluice
#

too bulky for what i wanted

agile galleon
#

So you want complicated features but not a framework that has that feature and is accordingly bulky

blissful sluice
#

nah ACF has a bunch of stuff on top of that xD

agile galleon
#

If you want a cf and you can't adjust to any other make it yourself

blissful sluice
#

ain't that big brained

#

the next on my list of frameworks to look at is Piston by the WorldEdit people

wind patio
#

how yall people have time for this shit

#

do yall not work fulltime or something

blissful sluice
prisma wave
#

?

#

private final UUID owner; primary key

#

private final UUID id; primary key

blissful sluice
#

yeah, but normally you'd use a long/int auto-increment

prisma wave
#

that doesnt make a huge difference though

blissful sluice
#

especially for relational tables that are all inter-mingling

#

doesn't it though?

If you've got a bunch of tables all using a uuid foreign key?

prisma wave
#

how is that different to a long foreign key

blissful sluice
#

i mean, size of data for one
and also everyone i read online keeps saying that UUIDs are bad cus of indexing and sorting issues or something

prisma wave
#

i mean, size of data for one
yes but how does that make a practical difference. my code still works, doesnt it? just replace UUID with long

blissful sluice
#

i meant in the database

prisma wave
#

yeah? same thing

blissful sluice
#

efficiency n stuff?

prisma wave
#

just int instead of varchar(36) or whatever

#

i really dont get what your point is

#

just change the type

#

suddenly your #1 problem is solved

blissful sluice
prisma wave
#

sure but i dont care lol

#

it's an unfinished plugin that never released

#

and using UUIDs is infinitely more convenient

blissful sluice
#

that was generic you, not you you

prisma wave
#

sure

#

but without being rude i really dont see why this is my problem lmao

#

you know a better approach, so use it

blissful sluice
#

i know the approach I should be using, but i have no idea how to implement it properly xD

prisma wave
#

?

#

literally