#help-development

1 messages · Page 1490 of 1

quiet ice
#

But I do not think that Choco also takes care of updating

digital plinth
#

why is there so many ppl in the vc

#

WHAT?

hybrid spoke
#

i think because they are new

onyx fjord
#

no im the only spigot dev

#

Choco can only PR

digital plinth
hybrid spoke
#

the voices or arent they?

quiet ice
#

no they are not

hybrid spoke
#

rip

quiet ice
#

they have been there for ever

digital plinth
#

they don't have any role :/

onyx fjord
#

its my alt account

quiet ice
#

blue = lead dev

digital plinth
#

mods kick LazWasHere

#

okay would you mind me uploading this non sense to youtube?

quiet ice
#

nah, he is our favourite person on here

digital plinth
#

= Lax

quiet ice
#

this is a recording, isn't it?

#

okay, perhaps not, still very strange

digital plinth
#

i don't think so

digital plinth
#

lol

somber hull
#
if (event.isRightClick()) {
    plugin.getConfig().set("command." + i, null);
    plugin.saveConfig();
    plugin.reloadGuis();
        plugin.blocksGui.show(event.getWhoClicked());
}
#

FOr some reason

#

this isnt saving

#

reloadGuis just refreshes the open gui

#

so i have an open gui that relies on whatever is in that "command" key
and the item disapears, meaning its doing something
but when i reopen it again it doesnt work

#

oh
im dumb
nvm

#

I have a list of items in a config

command:
- kick %player% Having Illegal Items

How do i remove a specific one?

#

If i dont know the order

deft geode
#

Why is this the wrong data for this particle? Trying to do the explosion particles

playerSender.getWorld().playEffect(playerSender.getLocation(), Effect.SMOKE, 0.1, 2);
somber hull
#

whats the double for?

deft geode
somber hull
#

try making it an int noit a double

#

so 1 not 0.1

wraith rapids
#

what's the exact exception

wraith rapids
#

List::remove

somber hull
#

yea but i dont know the position

wraith rapids
#

List::remove

deft geode
wraith rapids
#
    /**
     * Removes a single instance of the specified element from this
     * collection, if it is present (optional operation).  More formally,
     * removes an element {@code e} such that
     * {@code Objects.equals(o, e)}, if
     * this collection contains one or more such elements.  Returns
     * {@code true} if this collection contained the specified element (or
     * equivalently, if this collection changed as a result of the call).
     *
     * @param o element to be removed from this collection, if present
     * @return {@code true} if an element was removed as a result of this call
     * @throws ClassCastException if the type of the specified element
     *         is incompatible with this collection
     *         (<a href="{@docRoot}/java.base/java/util/Collection.html#optional-restrictions">optional</a>)
     * @throws NullPointerException if the specified element is null and this
     *         collection does not permit null elements
     *         (<a href="{@docRoot}/java.base/java/util/Collection.html#optional-restrictions">optional</a>)
     * @throws UnsupportedOperationException if the {@code remove} operation
     *         is not supported by this collection
     */
    boolean remove(Object o);
deft geode
wraith rapids
#

wouldn't that be a particle

bleak reef
#

Alright, so im having a bit of an issue; Essentially

return Material.valueOf("SUNFLOWER");```
Throws the error:
> `java.lang.IllegalArgumentException: No enum constant org.bukkit.Material.LEGACY_SUNFLOWER`


However when I try things such as
```java
return Material.valueOf("DIAMOND");```
It works perfectly fine, would anyone perhaps know a reason as to why this is happening?
wraith rapids
#

set your api-version to 1.13+

#

if it's set to 1.12 or is unset, the server rewrites the bytecode of your plugin to facilitate some bastardized sort of backwards compat

deft geode
wraith rapids
#

which means your valueOf("SUNFLOWER") actually looks for "LEGACY_SUNFLOWER"

#

because it's a 'legacy plugin'

bleak reef
#

Ah alright, thank you for the help

sharp bough
#

in SpawnParticleOnPlayer, line 78

#

and list on line 75 is empty

#

not null, empty

#

{}

wraith rapids
#

why are you calling a map a list

#

get returns null when there is no value associated with the given key

#

if the map is empty, every get operation returns null

sharp bough
sharp bough
#

when i run the command it adds the player uuid as key and args0 as value

wraith rapids
#

i have no fucking clue what I am reading

sharp bough
#

so theres always a value for the key

wraith rapids
#

what are you even trying to do

#

why do you have a class named createhashmap

sharp bough
#

spawn a particle under the player constantly

#

so like you run command /particles FLAME

#

and it will spawn a flame under you

#

until you disable it

wraith rapids
#

getHash returns a new, empty hash map each time

#

new CreateHashMap().put(player.getUniqueId(), particle);

#

you are creating a new CreateHashMap

#

which creates a new HashMap

#

you then add uuid, particle to it

#

and then you discard the entire created hash map

#

and forget about it, forever

#

new creates a new object

#

if you create a new object, you obviously don't have any changes made to it

#

if you create a new hashmap, the hashmap will be empty

#
    public HashMap<UUID,Particle> getHash(){
        return new CreateHashMap().getHashMap();
    }

this returns a new, different, empty hashmap each and every time you call it

#

because it creates a new, different, empty CreateHashMap

#

HashMap<UUID, Particle> playerParticle = new HashMap<>();
which then creates a new, different, empty hashmap

lapis imp
#

what is this channel for?

wraith rapids
#

read the channel description

ebon abyss
#

too difficult

sharp bough
#

so i have to check if its not created create it

lapis imp
#

i've read it but there are multiple ways to interpret it

sharp bough
#

otherwise just add the elemnt

lapis imp
#

like help with coding your spigot etc plugins or helping the creation of new spigot versions?

wraith rapids
#

former

sharp bough
lapis imp
#

well maybe they had some kind of channel to post issues they stumbled upon for other excluded devs to help out with? i dunno, maybe that could have been a thing?

sharp bough
#

"This is a java question. Override does what it says, it overrides the method from the extended class, and you don't create a new one, it doesn't actually matter in terms of runtime."

wraith rapids
#

no. absolutely not

sharp bough
#

so it runs just the method

#

instead of the class?

wraith rapids
#

no

#

you are so clueless and wrong that it's not possible for me to put it into words

ebon abyss
#

why do you have a million classes to begin with

sharp bough
#

then how do you create a gobal variable without creating a new class?

wraith rapids
#

you don't want a global variable

ebon abyss
#

why are you trying to make global variables

sharp bough
#

cuz its a hashmap

ivory sleet
#

?

sharp bough
#

that i need to share arround

#

so like i can save it load it edit it

wraith rapids
#

then share it

ebon abyss
#

that doesn't imply a global variable

wraith rapids
#

don't make it global; share it

sharp bough
#

but i dont want to put everything in a single class

ebon abyss
#

why

wraith rapids
#

share it; give it to the other objects that depend on it

ebon abyss
#

all of these classes are needlessly useless on their own

#

classes should accomplish a specific task

#

having one class call three other classes to do it's one simple job is very unorganized

sharp bough
wraith rapids
#

they don't

sharp bough
wraith rapids
#

i don't have the effort to handhold you on a "how to design a project" right now

#

maybe tomorrow

sharp bough
#

let me find an example

ebon abyss
#

you're literally having more lines of code doing it your way than just putting all relevant code in the same class

ivory sleet
#

It's most likely that they're inexperienced then

sharp bough
ebon abyss
#

that's evident

wraith rapids
#

you're either misunderstanding what people have made, or the people you're looking at are just as clueless as you are

sharp bough
#

i look at choco's code

ivory sleet
#

send it

sharp bough
#

wait let me find an example

wraith rapids
#

you should consider learning from it and understanding it rather than just looking at it

sharp bough
ivory sleet
#

But even so Choco isn't a java enterpriser so his code isn't the best goto

sharp bough
#

that kind of stuff

#

he adds like private static final maps

#

and details on top

sharp bough
#

haha

wraith rapids
#

i would argue that the whole thing being static is poor design

ebon abyss
#

the only reason code like this is "okay" is because this class is never instantiated

#

this reeks of static abuse

sharp bough
#

wait fr?

ivory sleet
#

I mean that code could work fine non statically

wraith rapids
#

@worldly ingot justify yourself

sharp bough
#

i have been looking at his code for week s

#

lmao

#

so 1 big class is better than small classes?

#

like 1 big class doing 1 thing

ivory sleet
#

Altho I guess looking at his code might be more pleasing than other developers who over engineer everything they touch.

wraith rapids
#

it isn't a matter of size

ebon abyss
#

there is no one "size" a class should be

#

classes should have a specific purpose

sharp bough
#

but ig thats wrong?

wraith rapids
#

assigning a value to a variable is also a purpose

#

but you won't create a new class for every = operator in your code

sharp bough
#

yea ig

ebon abyss
#

psh speak for yourself :^)

sharp bough
#

psh?

ebon abyss
#

Onomatopoeia (also onomatopeia in American English), is the process of creating a word that phonetically imitates, resembles, or suggests the sound that it describes. Such a word itself is also called an onomatopoeia. Common onomatopoeias include animal noises such as oink, meow (or miaow), roar and chirp. Onomatopoeia can differ between languag...

worldly ingot
wraith rapids
#

private static final Map
this looks like state though

worldly ingot
#

The stated data is handled by Metrics, but all instances of Metrics are going to want to send the same stats that the plugin is collecting

wraith rapids
#

wouldn't a singleton serve the purpose better

worldly ingot
#

It was a singleton at one point, actually

wraith rapids
#

and then you made it static

worldly ingot
#

Look at the most recent commit in that file lol

wraith rapids
#

Make everything static
haram

wraith rapids
#

i suppose it makes practically zero difference either way but I'd probably hold a canonical instance of the class in my main class instance

#

instead of a singleton or an entirely static class

ebon abyss
#

honestly for such a simple task I don't blame choco for having that be static

#

might not be the best way to do it but convenient ¯_(ツ)_/¯

worldly ingot
#

It felt impractical having it be a singleton because I'd just call StatHandler.get().myMethod() every time I wanted to do something and they were always single-method calls

#

I never held a temporary instance of StatHandler in a local var

#

The get() was superfluous

#

That being said, my code shouldn't ever be considered the arbiter of good code design lol. I think my design choices are mostly well justified, this case included, but I'm most definitely subject to mistakes and poor design

wraith rapids
#

this is vaguely acceptable

worldly ingot
#

If I had kept local reference to the StatHandler, I'd have kept it as a singleton

sharp bough
#

bro i dont understand 70% of what their saying lmao

worldly ingot
#

Though I didn't ;p

wraith rapids
#

regrettably though paradis is getting some bad impressions from misunderstanding it

#

i don't know what part of this inspired him to make a dedicated class for a new HashMap operation

worldly ingot
#

I missed earlier conversation so I'm OOTL

sharp bough
#

idk im just trying to clean mym code

wraith rapids
#

basically

#

he made this

#

he's basically writing single-method subclasses instead of methods

ebon abyss
#

but hey

#

at least he's documenting it

sharp bough
#

ahhahahahahaahaa

#

btw


    /**
     * a scheduler to spawn particles on location of each player, using the hashmap<UUID, String> where string is the
     * particle
     */```
should be 
```public class StartSchedule {

    /**
     * a scheduler to spawn particles on location of each player, using the hashmap<UUID, Particle> 
     */```
#

i forgot to change it

rotund pond
#

?paste

undone axleBOT
torn shuttle
#

ironically I do have a glorified startschedule class but it's quite big and specific

sharp bough
#

yea apparently long classes are not bad, they just have to be clean

torn shuttle
#

my longest class is 1432 lines long

#

I'm pretty sure at least 1000 lines are dedicated just to the word banks I use for procedural item generation though, so that's sort of cheating

wraith rapids
#

consider reading them from a resource

torn shuttle
#

eh I could do that but really I just don't have much of an incentive to touch it

#

plenty of other priorities I should be getting to regardless

wraith rapids
#

like shortening your class names

torn shuttle
#

actually can you help me brainstorm, I have a class that has a name too short

#

BinderOfWorldsPHase1EndermiteReinforcementConfig

#

I feel like that's not specific enough

wraith rapids
#

consider including the full package and your plugin name in it

torn shuttle
#

oh that's brilliant

#

I'll also add time stamps of the last time it was edited

wraith rapids
#

yes, after all, how else would you find things that were modified at a specific time

torn shuttle
#

there is literally no other way

#

EliteMobsSrcMainJavaComMagmaGuyEliteMobsConfigCustomBossesPremadeBinderOfWolrdsPhase1EndermiteReinforcementConfigExtendingCustomBossConfigFieldsTime11_11PMOnTheEighthOfJulyOfTheYearOfOurLordTwoThousandTwentyOne

#

perfection

wraith rapids
#

if i'm repeatedly iterating over and modifying a list of values, is it faster to
a) pop out of one binary heap and push to a second binary heap, then swap
b) iterate a sorted list in order, then add the elements to an unsorted list, then sort the list and swap
c) iterate a sorted list in order, then add the elements to a sorted list, sorting them on insert, and swap

torn shuttle
#

pretty sure that depends on the size of the list

wraith rapids
#

i'm not sure

#

what algorithm does the standard java collections sort use again

ebon abyss
#

bogosort

torn shuttle
#

I've had to do some research in the past to optimize the trackers and came to realize that the reality of sorting under 100 elements and sorting 10,000+ elements is quite different, things that may make sense for a shitload of elements may not really be worth implementing when you're dealing with, say, 10 elements per tick

#

though imo the best sorting is no sorting at all, so just try to not have to do it in the first place would be my advice

wraith rapids
#

thing is I have to iterate over things from highest to lowest

#

and then modify the values, and then iterate over them again

torn shuttle
#

can't you modify as you go?

#

or are the mods based on the restructuring?

wraith rapids
#

i need to make sure that I modify each element exactly once per scan

torn shuttle
#

is there really no way to just do one scan in the first place?

wraith rapids
#

reordering as I go might end up with the same element being iterated over twice in succession

torn shuttle
#

hm not if you're reordering them into a different list

wraith rapids
#

myeah

#

that's why each of the options I listed involves writing to a second heap/list and then swapping at the end

torn shuttle
#

well what scale of operations are we talking about here and how frequent is this going to be running, are you reorganizing a data lake every ms or are you keeping scores for 5 players once a month

wraith rapids
#

mm, sorting a list in place is usually O(n log n) i think, which is apparently the same as inserting n elements into a heap

#

i would throw a vague guess of abount 20-200 elements being juggled around every second or so

torn shuttle
#

you're fine then

wraith rapids
#

it's not really something that needs minmaxing especially as it's done asynchronously

#

but I still want to use the more efficient implementation

#

building a heap in place is significantly faster than sorting a list

#

but that comes at the cost of each retrieval being done in logarithmic rather than constant time

torn shuttle
#

yeah it has its cost, that's why I mentioned scale

#

I mean if you really want to know do quick sort on one do your heap on the other and time them

wraith rapids
#

i suppose that is a way of going about it

torn shuttle
#

it doesn't take a whole lot of time to test them anyhow

wraith rapids
#

around 20 minutes probably

torn shuttle
#

but you get something far more important than money from it

#

you get KNAWLEDGE

#

out here in the hollywood hills, driving my laborghini

wraith rapids
#

i'm going to use an online java compiler because compiling a test in the current project would take eons and switching projects on this machine takes ages

torn shuttle
wraith rapids
#

i guess i could use fucking notepad and javac but i'd rather not

torn shuttle
#

how scuffed is your setup man

wraith rapids
#

600mhz processor running windows

paper viper
#

dafaq

torn shuttle
#

I am pretty sure you are in that hell dimension from doom just based on your UI

sharp bough
wraith rapids
#

the ui is just personal preference

#

hmm

torn shuttle
#

yeah and I am pretty sure you are red colorblind

#

possibly from all the blood on your screen

wraith rapids
#

i will write the code in my ide for autocompletions and shit

terse latch
#

when is spigot 1.17 releasing? sorry if this was answered earlier

wraith rapids
#

and then cuntpaste it into the online compiler

undone axleBOT
#

There is no ETA for 1.17. Having an ETA leads to unrealistic deadlines, false hope, and a bad product. It will be ready when it's ready.

torn shuttle
wraith rapids
#

everything is better with more profanity

torn shuttle
#

would changing to the latest rpi be an upgrade for your setup

wraith rapids
#

probably

#

this is a shit tier laptop, the processor does actually go up to like 3ghz

torn shuttle
#

actually we live in a world where upgrading to the hardware contained in a macbook charger might be an upgrade

wraith rapids
#

the issue is the cooling

#

the processor is permanently throttled down to 600mhz due to overheating

#

passive cooling, glued together plastic case without any air holes in it

torn shuttle
#

I would tell you to fix it but if you're stuck with that pc I have to imagine you don't have access to a drill and a fan

wraith rapids
#

i have access to many things

torn shuttle
#

just not a good pc

#

or a good ui

wraith rapids
#

I just don't want to buy a new computer because that would involve effort

#

and I don't have any

torn shuttle
#

or a good naming sense for classes

wraith rapids
#

I want a better pc but I also don't want to get ripped off by some salesman for my ignorance

#

and I don't have the effort to do anything about my ignorance

torn shuttle
#

smh

wraith rapids
#

not that the money is an issue

#

nor getting a substandard pc for the money involved

torn shuttle
#

hell these days it doesn't even take more than 15 min to go from nothing to full build with stuff like r/buildapc

wraith rapids
#

i just don't want to make scams successful

torn shuttle
#

I am pretty sure you are successfully scamming yourself out of living a decent life

wraith rapids
#

maybe, but at least it doesn't involve filling some scammer's pockets

torn shuttle
#

all this waste fills the chaos gods' pockets

wraith rapids
#

i am my own god

#

let me introduce you to my religion

torn shuttle
#

how's that going for you

wraith rapids
#

i call it maninism

torn shuttle
#

that's not even yours

wraith rapids
#

it is because I made it

#

someone just made something with the same name

torn shuttle
#

then pick a different name because it already exists

wraith rapids
#

no

#

my maninism is the true maninism because I am the center of the universe

torn shuttle
#

stop trying to scam people with your scuffed religion which isn't even yours

#

this is like trying to sell someone a bridge except it's selling the concept of a religion which doesn't even belong to you

wraith rapids
#

everything belongs to me

#

by virtue of me perceiving it

torn shuttle
#

except for a good pc, that is

wraith rapids
#

they too belong to me

#

I just don't use them

torn shuttle
#

hey take a look at my student debt real quick

#

thanks

#

you're it

wraith rapids
#

money is pointless

torn shuttle
#

sure, give yours to me

wraith rapids
#

you're just a victim of capitalistic propaganda

torn shuttle
#

yeah I need aid relief funds

ebon abyss
#

how do you do fellow spigot developers

torn shuttle
#

get out scarsz can't you see I'm debating the money off of nny

unreal quartz
#

i have no idea what i just read but i like it

wraith rapids
#

i heard that 1.17 sucks and doesn't have any of the promised features

#

is this true

paper viper
#

uh no

#

maybe except terrain gen,, but its moved to 1.18

wraith rapids
#

what about the world size

#

is it still 0 to 256 then

ivory sleet
#

-256 to 256 or no?

paper viper
#

well, the new one is -64 to 320

#

which is weird

#

idk if it got changed yet

wraith rapids
#

so uh

ivory sleet
#

oh nvm

wraith rapids
#

is there a buildable void below bedrock now

#

since the generator didn't get changed

paper viper
#

let me generate a world

granite stirrup
opal juniper
#

Out of interest

wraith rapids
#

lenovo something i think

opal juniper
#

Ohhhh I get ya

wraith rapids
#

i'm not sure, I'm not seeing any labels or names anywhere

opal juniper
#

Fair - I have built my own over the last maybe 2 years (as in slowly upgraded)

#

I managed to get an Rtx 3060ti at msrp

#

Which was very nice

#

But yeah - pcs are kinda expensive atm

granite stirrup
#

lol

runic abyss
#

Looking for help with a USA map server development, reward will be permanent administrative rights on the server. Need help specifically with setting up plugins and protecting land. Server will be some from of factions or land sale system, the economy will be based off where you are on the map, with some resources being abundant places and non existent other places.
Map is 80,000 blocks coast to coast

ivory sleet
#

This is not the channel

stone light
#

I don't know where else to ask this but pretty much I have a project that I compiled in java7 before I realised that I had done it by mistake but I changed the project version but I'm still getting errors does anyone know how I can change the class version?

runic abyss
#

Witch channel?

ivory sleet
#

?services

undone axleBOT
runic abyss
#

ok thank you

ivory sleet
#

cheers

unreal quartz
torn shuttle
#

man I have to review one of my core config systems and I am not looking forward to it

#

the systems have become too large for the originally really simple format

#

can't have 40 arguments when I use maybe 10 on avg...

ivory sleet
#

40 arg constructor? 😬

torn shuttle
#

yeah

#

it used to be about 3

#

but then I kept adding features throughout the years

ivory sleet
eternal oxide
#

You may as well write the whole plugin on one line at that point.

torn shuttle
#

this is also the system that reads and writes to and from config using defaults so I need to make sure I set it up in a way that is easy to play wwith

torn shuttle
ivory sleet
#

Magma, have you ever tried Guice or a DI framework?

eternal oxide
#

I can;t even imagine 40 args in a constructor

torn shuttle
#

well it's the constructor for making custom bosses, so every feature you can customize about default bosses is in here, which was fine when it was like name and damage and such but now there's stuff that is very niche and only 1 of them actually uses

eternal oxide
#

then make it a Builder

#

with defaults set you only need change specifics

ivory sleet
#

I believe native minecraft code had extremely long constructors and yes they resolved it with builders

torn shuttle
#

I might, I have to look around for good solutions because this both sets defaults but also respects custom values and such

#

just want to make sure I get good, scalable solution which is not a pain in the ass to play with

wraith rapids
#

reward will be permanent administrative rights on the server
that's not a reward

#

and should not be given out as a reward

torn shuttle
#

also I don't want to write 40-60 builders multiple times just because I fucked up and there was a better solution lol

eternal oxide
#

I'd have to see code to comment

torn shuttle
#

I dread to see how long this will get

#

uh

#

6% comment lines

#

on avg

#

total of 2711 comment lines

#

36924 source code lines, rest is blank

#

it's decently chunky

#

it's a good thing that I can't count total lines ever committed easily or I might just lose all hope

#

I suspect it's well over 500k

shut field
#

how do you slow down a sound

#

maybe about half the speed?

eternal oxide
#

pretty sure you can only control pitch

shut field
#

called DiamondFire, pretty sure they use spigot and they can slow it down

eternal oxide
#

playSound only has pitch and volume. Volume only affects how far it can be heard

shut field
#

I don't understand how that server does it then but all right

eternal oxide
#

does it use a resource pack?

shut field
wraith rapids
#

resource packs can include custom sounds afaik

#

without replacing existing assets

shut field
#

rlly?

#

I thought they had to overwrite sounds and item textures and stuff

wraith rapids
#

that's only the case for block and entity textures by this point i think

#

items and other resources can be added arbitrarily

shut field
#

then I guess they have custom speeds from 1-100% for every sound in the entire game unless it is possible in spigot ¯_(ツ)_/¯

wraith rapids
#

also pitch controls the speed

#

well, it controls both the pitch and the speed

shut field
wraith rapids
#

though i'm pretty sure the minimum pitch is 0.5 or something

granite stirrup
#

Why is the steam fee so high why can't it be like u need a Dev account to publish games and to get it u have to pay like $5 like Google has this and they don't get spammed by bots??

wraith rapids
#

because otherwise I would have to look at your crappy game on steam

granite stirrup
#

I wouldn't publish a game on Steam LMao

#

But I just wish it's more affordable

shut field
#

for playsound is volume 1-100 and same for pitch?

wraith rapids
#

see the docs

shut field
#

is this not the docs?

granite stirrup
#

Playsound in-game it's 1-10 for volume 0-2 for pitch I think

wraith rapids
#

pretty sure somewhere in there it lists the valid ranges

#

if we go by the vanilla ranges, 0.5 to 2.0 for pitch

granite stirrup
#

Oh though it was 0-2

torn shuttle
shut field
#

gotcha, thanks for the assistance

torn shuttle
#

top notch, bet there wasn't a better way either

#

cowards will argue you can group the cases together, I will remind them how impossible that makes it to compose a song sequentially lol

#

also I'll give an internet cookie for the first person to recognize the song

wraith rapids
#

wouldn't a list be less cancerous

torn shuttle
#

honestly the real cancer was trying to get the notes right when your background in music was failing to play the recorder nearly 20 years prior

wraith rapids
#

i'd probably us private final fields rather than methods and a float array rather than a string of cases

#

then get arr[counter++]

torn shuttle
#

iirc I ended using methods because I then wanted to use the same notes for some other minor stuff in some other class, can't really remember what that was about now

wraith rapids
#

make a note enum duke

torn shuttle
#

also while not impossible I would have to fill the list with pauses which uh

#

the real question is why the api doesn't have a note enum

tribal narwhal
#

Spigots going to be Java 16 for mc 1.17 right?

ivory sleet
#

yup

torn shuttle
#

Da

tribal narwhal
#

fun. I Haven't really had to change java versions much but its pretty much cross compatible right?

#

Like my java 8 plugins should work on 16?

vivid lion
#

Nani da FAQ java 16 dope

torn shuttle
#

what's that, NPE actually says what's null?

#

how far tech has come huh

ivory sleet
#

yeah crazy stuff innit

torn shuttle
#

wild

#

what's next, getting rid of CME erros before we colonize mars?

#

there's literally tens of possibilities out there

ivory sleet
#

get rid of Throwable poggies

torn shuttle
#

I'm going to say something out of this world

#

no longer needing getters and setters

#

sorry for the faint of heart in the audience that just passed away from a heart attack, my thoughts and prayers are with their families

dense goblet
#

yo this is a maths thing but does anyone here know the value of:
a^1 + a^2 + a^3 + ... + a^n

#

or what the name of this series is

ivory sleet
#

n*a^n ?

torn shuttle
#

nice meme

ivory sleet
#

oh lol didnt see it

dense goblet
#

n*a^n = a^n + a^n + ... + a^n

ivory sleet
#

oh yeah right

unreal quartz
#

a geometric series?

dense goblet
#

ahh thats the one

#

only difference is I need to start from a^1

#

so it would be (geometric series) - a^0 = (geometric series) - 1

torn shuttle
#

I mean seems rather trivial with a for loop no

#

unless you're looking for a purely mathematical solution

dense goblet
#

yeah but a for loop is slower than the direct solution

torn shuttle
#

uh

#

I don't know how long your series is planning to be but computers are quite fast at this sort of operation

dense goblet
#

it feels good to go from 0.01ms to 0.0001ms

ivory sleet
#

n
Σ a^i
i = 1

this right?

torn shuttle
#

I somehow doubt it would take 0.01ms for a computer to do that

#

unless you're going real big

dense goblet
dense goblet
torn shuttle
#

I think your uni has been watching too many cyberpunk movies

#

if that's the future they're preparing you for

dense goblet
#

they're preparing me for a future where I can skip exactly h toll gates in a row, no more and no less, after which I must not skip any of the next c tollgates

torn shuttle
#

hey you studied math, how many tollgates could you afford with how much you paid for tuition

dense goblet
#

let me check

wraith rapids
#

i often wish i had studied math more in depth

torn shuttle
#

I was thinking much of the same and am currently reading a book to learn it

wraith rapids
#

turns out shit that seems entirely useless is kind of useful for all sorts of shit

torn shuttle
#

see the difference between nny and I is that I have the energy to follow through

wraith rapids
#

i have more pressing matters to attend to

dense goblet
#

all roads are free in my country except for 2 tunnels, one costs 5 euro and the other 2 euro for a passenger car

#

with my first year of tuition I could pass the 5 euro tunnel about 208 times

torn shuttle
#

ok so you're telling me you could've spent a year travelling around the country around 200 times but instead spent that time calculating 10^8 tollgates when there's only 2 of those

wraith rapids
#

gasoline costs money

torn shuttle
#

I hate to say it but I think you got scammed

unreal quartz
torn shuttle
#

yall's a bunch of suckers

dense goblet
wraith rapids
#

on foot

dense goblet
#

no in a small passenger vehicle

wraith rapids
#

that has additional costs

torn shuttle
#

it must be a lit tunnel for it to be the only one you pay for

dense goblet
#

which consumes no fuel

#

yea gotta visit it some time

torn shuttle
#

well you can't

wraith rapids
#

fuel is actually quite a small part of the upkeep cost of a vehicle

torn shuttle
#

you spent all of your budget calculating what would happen if there were 10^8 tolls

wraith rapids
#

maintenance and registrations and taxes and all that shit cost quite a bit as well

torn shuttle
#

that's not really true nnya, unless your car is a shitcan you are probably spending thousands of dollars in fuel for hundreds in maintenance

wraith rapids
#

it is

torn shuttle
#

well

#

you know what I am going to say about that

wraith rapids
#

fuel is inexpensive

torn shuttle
wraith rapids
#

thorough maintenance is not

torn shuttle
#

do you live in saudi arabia or something

#

maybe the US

wraith rapids
#

maintenance just seems like a small cost set because it's so infrequent

torn shuttle
#

I've had a car for 6 years, gas is by far the loss leader

wraith rapids
#

6 years is nothing

torn shuttle
#

like, not even close

#

in some cities you can't have cars that are older than 6 years old my dude

wraith rapids
#

most passenger cars don't have major maintenance needs in the first 10 years

#

yeah and that's because it's often cheaper to buy a new one than to maintain and repair the old one

torn shuttle
#

the car itself is starting to push 20

#

no, it's due to newer cars on average being more fuel efficient

wraith rapids
#

especially with more modern production lines with worse spare part availability

torn shuttle
#

the cities that do it in europe cite air pollution as the reason

#

mind you I think gas in europe is about 2x more expensive than in the US

wraith rapids
#

nowdays production lines and spare parts are deprecated in just a few years except for the very popular models

#

around 4 to 8 times depending on the region

torn shuttle
#

yeah and I'm in one of the most expensive ones

wraith rapids
#

so am i

torn shuttle
#

then stop ramming your car into walls

#

my car is 20 and I don't spend that much on maintenance

wraith rapids
#

for example, many logistics companies are installing turbine clutches on their trucks

torn shuttle
#

or close enough to 20 anyhow

dense goblet
#

gasoline price is about €1.78/L and one litre of gasoline will allow me to drive about 17km in a VW golf so with my 1st year tuition I could drive 9,932km

wraith rapids
#

even though it increases fuel cost by around 20%

eternal oxide
#

Cars deteriorate at different speeds based upon use and area.

wraith rapids
#

it nets significant savings from longer lifespan and reduced maintenance

eternal oxide
#

Here in the UK its so wet and humid + salt on the roads in winter they fall apart

unkempt peak
#

Why are we talking about cars lol

wraith rapids
#

yeah, salting roads in the winter is a killer

torn shuttle
#

yeah that sucks

#

ain't no cold weather here, you can keep your car for as long as the parts hold in semi ideal conditions

wraith rapids
#

most vehicles are manufactured in warmer climates without salt so there is next to no protection to speak of

eternal oxide
#

My car is about to hit 20 and I had to do the first bit of welding on it this year.

torn shuttle
#

just emigrate

#

who wants cold weather anyhow

wraith rapids
#

most of my cars are 20-40 years

torn shuttle
#

I look forward to global warming, summer year round let's go boys

eternal oxide
#

I'd love a 40+ year old. No road tax or MOT needed on them

torn shuttle
#

it's beach weather 'eeryday

wraith rapids
#

got a 60 year old truck as well although it isn't licensed

torn shuttle
#

the plot thickens

#

nnya lives in a junkyard in hell

wraith rapids
#

i have many things

dense goblet
#

honestly plausible

torn shuttle
#

and somehow none of them are good

#

how many skeletons are there in your closet

wraith rapids
#

many of them are very good

#

i would never trade my old model toyota hiace for a new van

#

new cars suck

torn shuttle
#

at this point I would pay $5 to see nnya take a camera and catalog all of their stuff with creepy music in the background

eternal oxide
#

Toyota Hiace are excellent. unkillable

torn shuttle
#

I have a toyota rav4

wraith rapids
#

i get several emails and mails from all sorts of places of people wanting to buy my hiace

torn shuttle
#

I hope to never stop having that

wraith rapids
#

they want to ship it to africa

#

several dozens a year*

quaint mantle
torn shuttle
#

you know, having rented cars in africa I can't say that that speaks to the quality or reliability of the car as much as the price

wraith rapids
#

the cars that people use in those countries have to be built to last and to be maintainable

torn shuttle
#

every single time people go on convoys about 50% of the cars break down at some point and at least 20% get replaced

#

every - single - time

#

it's sort of wild really

#

they're certainly maintainable, I've seen people fix their cars with bananas

#

so gj on that

#

just a shame it lasts for another 50 miles and then dies lol

wraith rapids
#

if you fix it with a banana, it sure will

eternal oxide
#

Same reason Russian tanks beat German tanks in the 2nd world war. German tanks were precision engineered and broke down often and could not be repaired in the field. Russian tanks were built in tractor factories.

torn shuttle
#

yeah well the whole continent is bananas

wraith rapids
#

if you actually do it properly, it'll go for half a lifetime before the next major repair around the same area

torn shuttle
#

yeah my opinion of the repair shops I've seen there isn't exactly very high

#

then again I too would be at a loss if I have to resort to using bananas to fix car parts

wraith rapids
#

the people there have a different mindset

#

it's quite remarkable what they are able and willing to do

torn shuttle
#

yeah that mindset got us stranded in the middle of a safari about 8 times the year I went there

eternal oxide
#

But if need be, they can build a welder out of an old battery and a stripped down microwave.

wraith rapids
#

they maintain out of date and heavyweight technologies with poor tools and just ingenuity and experience

torn shuttle
#

tbf it was quite remarkable to have to pull a car out of reptile infested waters

#

I still remember that

wraith rapids
#

and they often can make a better job of it than high end repair shops in the western world

torn shuttle
#

I wasn't on the canoe that ran into the hippos though, there I might've lost my shit for real

wraith rapids
#

pussy

eternal oxide
#

Car in the river = fishing for dinner

torn shuttle
#

you go to africa and you get surrounded by the most dangerous animal there and tell me how you feel

eternal oxide
#

My wife?

torn shuttle
#

especially when there is quite literally nothing between you and them

wraith rapids
#

why would i go to africa

#

africa is a third world shithole

torn shuttle
#

pussy

wraith rapids
#

all of it should be fucking nuked

#

there is nothing of interest or worth looking at or knowing there

torn shuttle
#

I can see this comes from experience

wraith rapids
#

yes

#

i am very racist

torn shuttle
#

well yeah that I could've guessed

#

I'm honestly surprised some mod hasn't caught on to the hitler with a santa hat yet but it's not my problem

wraith rapids
#

being racist isn't a crime

torn shuttle
#

you don't have to be a criminal to get banned from discord

wraith rapids
#

you do have to break the rules, though

#

which i have not

#

exept when i've felt like it

eternal oxide
#

today 🙂

wraith rapids
#

there are zero mods and all of them are perma dead anyway so whatever

torn shuttle
#

I mean any mod could argue your profile pic breaks rule 2

eternal oxide
#

There are rules?

wraith rapids
#

the more likely reason for me to get banned is because I keep shitting on bukkit and spigot in particular and md5 gets his panties in a twist because of it

eternal oxide
#

oh yeah, I remmeber

torn shuttle
#

shocking, I know

#

I would be thunderstruck if md5 is the one who bans you

wraith rapids
#

at present it seems like the most likely outcome

eternal oxide
#

He kicks him frequently

torn shuttle
#

that's an award you can print

#

I still have you beat though

#

md5 banned not me but my username for a couple of years

#

and forced me to use a username I picked specifically to be "different"

#

unfortunately he won't let me have it back on discord, I loved that username

#

\^-^

#

pretty sure that hit all the irc characters they had forgotten or didn't really want to ban for usernames

amber aspen
#

Can someone please help me

eternal oxide
#

No idea

amber aspen
#

I’m trying to create a meme plug-in we’re three birch logs in a row makes a netherite block. Eclipse says the code is all good but when I put it in to the server it says Custom recipe can’t be enable crafting rows need to be 1,2 or 3 characters long does anyone know how to fix this

eternal oxide
#

?paste show your code

undone axleBOT
amber aspen
#

Ok gimme a sex

#

Sec

#

Omg

dusk flicker
#

haha they said sex 🍆

amber aspen
#

there i pasted it can u see

eternal oxide
#

You need to show us the link

amber aspen
#

oh

#

wait wrong one

eternal oxide
#

too many in teh middle one

amber aspen
#

thats the actual one

#

im confused on whats wrong with it

eternal oxide
#

getRecipe needs to return the recipe

#

you return null

amber aspen
#

so how do i write that

deep plank
#

i see 3 things wrong at first glance. 1, you have a capital letter in the key. 2, your getRecipe() is returning null. 3, your middle row is 5 chars not 3 (" TET ")

eternal oxide
#

return recipe;

amber aspen
#

ok

#

where is the capital key

dusk flicker
#

your namespaced key

#

cant have caps

amber aspen
#

k

#

sorry i just started coding i dont really know that

eternal oxide
#

line 26

#

all lowercase in the string

amber aspen
#

which named space key both of em ?

#

it says change to NamedSpaceKey with kap K and then Org.Bukkit

deep plank
#

Netherite_block is wrong. needs to be netherite_block

amber aspen
#

the one in named space keuy

#

key

#

is this correct

deep plank
#

try it and see 😉

amber aspen
#

ok

#

im prayin

#

fuck

#

damm

#

it didint work

deep plank
#

did you get a new error?

eternal oxide
#

theres nothing wrong with that code

dusk flicker
#

Send the stacktrace in a paste please

amber aspen
#

wjat is that

#

sorry

dusk flicker
#

the error in your console

amber aspen
#

it works now i just made the Key capital

dusk flicker
#

oh

#

I realized what you did

#

We meant the string, not the object.

amber aspen
#

Oh

#

Well it works so thanks

somber hull
#

?paste

undone axleBOT
dusk flicker
#

I don't care enough to read all of that lmao

#

any problems with it or do you just need to try it

torn shuttle
#

alright

#

800 lines of getters and setters later, I'm done

#

god help me

ivory sleet
#

Lombok kappa

torn shuttle
#

lick my lombocks conclure

dusk flicker
#

lmao

#

lombok is nice

ivory sleet
#

🥴

dusk flicker
#

if my object class didnt use lombok itd be atleast 1500 lines

vale cradle
somber hull
torn shuttle
vale cradle
#

I don't like lombok at all, I guess cuz I'd rather kotlin to java

ivory sleet
#

Also records Rack

dusk flicker
#

what

vale cradle
dusk flicker
#

Im confused

torn shuttle
vale cradle
ivory sleet
eternal oxide
#

Hi confused

torn shuttle
#

not with what I was working with

vale cradle
#

Depends of how your methods are named I mean

#

I'm pretty sure it did it to me in some ocasions

torn shuttle
#

more complicated than that, not worth getting into

dusk flicker
#

I got all that shit Conclure just done through lombok

#

😙

ivory sleet
#

😔

vale cradle
#

It needs Java 14 tho

ivory sleet
#

Yeah, basically java stealing Kotlin features

#

Like the sealed thingy

vale cradle
#

Some hosts don't provide any Java further than 11

vale cradle
#

How? 😳

ivory sleet
vale cradle
#

o

#

that's new

#

And stills in preview

torn shuttle
vale cradle
#

Java is advancing more this couple years than it did 8y ago

torn shuttle
#

bye bye

    public BinderOfWorldsPhase1EndermiteReinforcementConfig() {
        super("binder_of_worlds_phase_1_endermite_reinforcement",
                EntityType.ENDERMITE.toString(),
                true,
                "$reinforcementLevel &5Reality Corruptor",
                "250",
                2,
                false,
                0.1,
                0.5,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                false,
                false,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null,
                null);
    }

lol

#

wee

compact haven
#

that is way too many fucking constructor arguments

ivory sleet
torn shuttle
#

so this is going to be my life until

#

idk 8 am probably

vale cradle
ivory sleet
#

Hmm I can probably make you understand it with 1 line:
List<int>

vale cradle
#

Ok you got me

torn shuttle
#

rate my weight loss journey

public BinderOfWorldsPhase1EndermiteReinforcementConfig() {
        super("binder_of_worlds_phase_1_endermite_reinforcement",
                EntityType.ENDERMITE.toString(),
                true,
                "$reinforcementLevel &5Reality Corruptor",
                "250");
        setTimeout(2);
        setHealthMultiplier(0.1);
        setDamageMultiplier(0.5);
    }
ivory sleet
#

Phenomenal

compact haven
#

well its certainly better

torn shuttle
#

thanks bae

vale cradle
#

Undeniable better

compact haven
#

Is there a reason you turn ENDERMITE enum to a string?

#

like is it a display argument

torn shuttle
#

yeah it's writing it as a default into a config file

compact haven
#

ah

torn shuttle
#

this generates a config file

#

in short

#

this has big pimple popping energy

#

hm this is probably going to end with a net loss in line count

#

ah yeah important documentation

digital plinth
#

can I type into the console if I don't launch the spigot server using a bat file?

young knoll
#

The most efficient way would probably be with the MapChunk packet

#

But that has a weird format

crisp citrus
#

how do i add comments to my config.yml file?

sharp bough
#

1 second

torn shuttle
#

code rot circa 2021, colorized

young knoll
#

If you write comments in the files within your jar and then copy them with saveResource or saveDefaultConfig they should stay

#

But if you ever save the file from the code they will be lost

sharp bough
#

nono there was this api

#

spiderYML?

#

snake

#

it was a thing

#

i cant remember what thing

#

i saw it like 5 hours ago

#

snakeyaml java spigot

#

yess

#

i found it

young knoll
#

Spigot uses snakeYML

crisp citrus
#

yay thz

young knoll
#

But it’s an outdated version sadly

sharp bough
#

wait fr?

#

i didnt try it

young knoll
#

Mhm

sharp bough
#

idk

young knoll
#

Hopefully MD will update it one day

sharp bough
#

@crisp citrus 1 you cant add comments using the vanilla way like saveConfig etc

torn shuttle
#

I feel like refactoring this code should entitle me to getting an emotional support dog

sharp bough
#

2 you are gonna have to use an API

#

like snake

#

but updated

young knoll
#

You can add them fine with the default code

#

saveDefaultConfig and saveResource should preserve them

sharp bough
#

idk i never really made any comments in my yml files

#

its on my todo list

#

this might help

#

but im not sure

crisp citrus
#

thanks

young knoll
#

As long as you don’t modify the files via code you don’t need anything fancy

#

If you do, there are probably a bunch of apis on the forums

crisp citrus
#

so basically ```java
FileOutputStream writer = new FileOutputStream(new File(getDataFolder() + File.seperator + "config.yml"));
InputStream out = <yourMainClass>.class.getResourceAsStream("path_to_your/file");
byte[] linebuffer = new byte[4096];
int lineLength = 0;
while((lineLength = out.read(linbuffer)) > 0)
{
writer.write(line buffer, 0, lineLength);
}
fw.close();

sharp bough
#

no fucking idea

#

lol

young knoll
#

Like I said, you shouldn’t need that to just copy a file from within the jar

worldly ingot
#

Yeah, that's what saveResource() is for

young knoll
#

I didn’t know that at first and made a method to handle it

#

Need to remember to remove that

random ledge
#

Is there a way to check if a player is standing still?

torn shuttle
#

why have you not saved my heart choco

#

tfw you forget entire complex features your plugin has

young knoll
#

Just

#

Comment them out

torn shuttle
#

I'm using it

random ledge
#

thanks for the answer But the speed while a player walks/runs is the same as that of a stationary player is (0.0,-0.07,0.0), but if the player runs and jumps the value will be different.

torn shuttle
#

I just also forgot it existed

#

good lord I think I'm done with the rewrite for now

young knoll
#

You’re never done

#

Rewrites are eternal

torn shuttle
#

hence the "for now"

young knoll
#

I’ve rewritten custom enchantments way too many times

torn shuttle
#

?paste

undone axleBOT
torn shuttle
#

because I'm using a builder pattern to create config files

random ledge
#

Player velocity has not changed. it is equal when the player standing still or when walking,running without jumping

torn shuttle
#

god this truly is the accounting of programming

#

and hey I was pretty close with my time estimate I think

#

actually nah I finished 2 hours early, probably still have 1h of debugging to do to make sure stuff is working

#

it's just a refactor, I'm not too worried

#

actually spotted a few undetected bugs while working on this which was depressing

#

just keeps reminding me of why I absolutely despise having to type a string twice regardless of context

#

it's really easy to get it one character off and the entire thing can break in non-obvious ways

random ledge
#

i displayed only p.getVelocity().getX() p.getVelocity().getZ()

young knoll
#

You may also want to try the length of their movement vector

torn shuttle
#

BonkEvent

#

looks like it yeah

glossy venture
#

cuz it doesnt have comments yet

#

i will probably have to choose like a license though

nocturne quest
#

I've an issue with something about library shading
[07:20:39 WARN]: [SayanChat] Loaded class me.Mohamad82.RUoM.StringUtils from DuelOrganizer v0.9.1 which is not a depend, softdepend or loadbefore of this plugin.
This SayanChat and DuelOrganizer both have a library named RUoM and it's shaded in their jar file, But it's like SayanChat is trying to get classes of the library from DuelOrganizer, SayanChat has it's own me.Mohamad82.RUoM.StringUtils but it's using from DuelOrganizer
What should I do to prevent this?

elfin creek
#
            System.out.println("1");
            if(player.getInventory().getItemInHand().equals(Material.COMPASS)){
                System.out.println("2");
                openGui(event.getPlayer());
            }
        }```
even tho i have a compass in hand it console logs 1 only
vivid lion
#

bruh

#

.getItemInHand()

#

returns ItemStack

#

not a Material

elfin creek
#

ok

#

got it

vivid lion
#

refer

elfin creek
#

thanx :)

vivid lion
#

to spigot API

drowsy helm
vivid lion
#

spigot Jd i mean

elfin creek
vivid lion
#

javadocs

elfin creek
#

ohh ok

vivid lion
#

this is an example

#

of a JD

vivid lion
nocturne quest
drowsy helm
#

hold up ill get an example

nocturne quest
#

Really appreciate

silk mirage
#

um

#

Is there any wiki/tutorials on how to create a dummy player?

#

I want to run a command as player so i'll have to create dummy player

#

any idea on how would i do that?

vivid lion
#

nms

#

from what i remember

silk mirage
#

even i do know that

#

but i need to know how would i make it

drowsy helm
#
<plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-shade-plugin</artifactId>
                <version>3.2.1</version>
                <executions>
                    <execution>
                        <id>shade</id>
                        <phase>package</phase>
                        <goals>
                            <goal>shade</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
               <relocations>
                  <relocation>
                     <pattern>the.apis.initial.package</pattern>
                     <shadedPattern>the.apis.relocated.location</shadedPattern>
                  </relocation>
               </relocations>
            </configuration>
            </plugin>```
@nocturne quest
vivid lion
#

well youll need to understand the connections

#

between spigot player interface

drowsy helm
#

juist that extra bit in config will do it

vivid lion
#

and craftplayer

#

and EntityPlayer

silk mirage
#

Craft player just implements the player

vivid lion
#

yep

#

and the craftplayer is what holds

#

to

#

nmsPlayer

#

when you .getHandle()

#

so for e.g.

silk mirage
nocturne quest
drowsy helm
#

yep precisely

#

well not path in maven

nocturne quest
#

That's great, Thanks!

drowsy helm
#

but package name

nocturne quest
#

I got it.

vivid lion
silk mirage
#

i cant just do new CraftPlayer() Ig

vivid lion
#

ik

#

im opening up my decomp to check the constructors

#

i can use

silk mirage
#

alright, please find a solution

#

would make my day

vivid lion
#

so this is what i saw from the decomp

#
public CraftPlayer(CraftServer server, EntityPlayer entity)
#

this is a constructor to the CraftPlayer that you can use

#

EntityPlayer is a nmsEntity

#

so let me find that constructor for you too

#
public EntityPlayer(MinecraftServer minecraftserver, WorldServer worldserver, GameProfile gameprofile, PlayerInteractManager playerinteractmanager)
silk mirage
#

so whats PlayerInteractManager

quaint mantle
#

What’s the problem here?

silk mirage
#

that can execute command as player

#

but is actually not a player

quaint mantle
#

As an npc?

silk mirage
#

NPC is not an player

quaint mantle
#

Yes it is it’s a fake player

silk mirage
#

can it run commands as player?

quaint mantle
#

But I’m just using that as a word, no? Not unless you make it

glossy venture
quaint mantle
#

How do you plan to execute commands

glossy venture
#

it can be a craftplayer

silk mirage
glossy venture
#

which can execute command

silk mirage
#

i want to execute it through plugin

#

by creating a dummy player

vivid lion
#

looking for where playerinteractmanager is atm but if i cant find this is its constructor

#
public PlayerInteractManager(World world)
#

that is nmsWorld

silk mirage
#

nmsWorld

vivid lion
#

WorldServer worldserver

silk mirage
#

alright

vivid lion
#

you can use worldserver

#

because worldserver

#

extends nmsWorld

silk mirage
#

is it just named nmsWorld?

vivid lion
#

no

#

i called it that

#

so that you would understand

quaint mantle
#

Dude what

#

You want a command

#

That creates a fake player?

vivid lion
#

no

#

he wants a command

#

ran by a fake player

#

i think

silk mirage
quaint mantle
#

When they do what

silk mirage
#

i want a fake player that executes a command

#

as an instance of player

quaint mantle
#

When do you execute the command

vivid lion
#

@silk mirage do you also want other players

silk mirage
#

smh so listen,

if player do /migrateme

it'll trigger plugin commannd, plugin will dispatch a command as the fake player and do the other jon

vivid lion
#

to see this player

#

fake player

silk mirage
#

it'll dispatch comamnd from another plugin

#

i don't care

#

i just want a CommandExecutor

#

as an instance of player

vivid lion
#

ah gotcha

glossy venture
#
new CraftPlayer((CraftServer)Bukkit.getServer(), new EntityPlayer(((CraftServer)Bukkit.getServer()).getHandle(), ((CraftWorld)world).getHandle(), gameprofile, new PlayerInteractManager(world)));
``` will this work?
quaint mantle
#

What’s the problem dude, just make a block of code

#

Run on your fake entityplayer

#

I don’t understand what’s so hard about that?

#

When that specific case happens

silk mirage
#

i tried by implementing Player and CommandExecutor

#

that didn't work so i was here

silk mirage
#

whats value for "gameprofile"

quaint mantle
#

You don’t call a new craft player

#

I believe

glossy venture
#

you need to create GameProfile gameprofile and World world variables

silk mirage
vivid lion
#
public GameProfile(UUID paramUUID, String paramString)
vivid lion
#

constructor at gameprofile

silk mirage
#

k, i can do UUID.random for UUID

vivid lion
#

UUID.randomUUID()

silk mirage
#

what about paramString

vivid lion
#

yep

#

thats the name

silk mirage
#

alright

#

hope it works

vivid lion
#

ye 🤞

quaint mantle
#

airbubble event changed plz

glossy venture
quaint mantle
#

similar to this

#

but i want it for airbubble

#

lolol

glossy venture
#

oooh

#

like the oxygen bar

quaint mantle
#

I believe you need to edit entity meta data?

#

aw so no event?

glossy venture
#

idk

quaint mantle
#

I doubt it

glossy venture
#

look at the spigot javadocs

quaint mantle
#

unpog