#help-development

1 messages · Page 1613 of 1

summer scroll
#

I decompiled it using jd-gui and the class and the method is exist.

indigo crypt
#

okay, now i am ask. How to unnamed entity before he die

chrome beacon
#

If not don't ask here

indigo crypt
indigo crypt
quaint mantle
quaint mantle
#

nvm it is

#

just very weird

#

can u just

@Eventhandler
public void onEntityDeath(EntityDeathEvent event) {
  event.getEntity.setCustomName("");
}
quaint mantle
halcyon topaz
#

out of curiosity, what does the # actually mean

#

and why do people use it instead of .

quaint mantle
#

its a replacement for .

halcyon topaz
#

o

#

im so silly lol

#

thank you

quaint mantle
#

also its used on the docs

torn shuttle
#

also often times people use it to indicate it's pseudocode and as such not every method may be named exactly the way it shows up

oblique pike
#

How do i properly get Particle from string?

quaint mantle
#

Particle.valueOf(string);

oblique pike
#

Spigot API particle names differs from minecraft ones

oblique pike
#

...yes

quaint mantle
#

But can i turn the volume down somehow?

#

ITS SO LOUUD

oblique pike
#

Minecraft - HAPPY_VILLAGER, Spigot - VILLAGER_HAPPY

oblique pike
quaint mantle
#

How?

quaint mantle
#

its on 1

#

the lowest

oblique pike
quaint mantle
oblique pike
quaint mantle
#

Particle.values()

#

OOPS

#

forgot to put F behind the number

oblique pike
#

the thing i wouldn't like to do as it is really weird

#

Thats why i've asked

torn shuttle
#

man I was feeling like I was tired of working

#

turns out, it's been 11 hours already

oblique pike
#

I still cannot understand whats the purpose of changing HAPPY_VILLAGER to VILLAGER_HAPPY

#

Sounds like trolling

torn shuttle
#

probably a historical reason

#

I know for a bunch of mismatched enums it's because mojang changed their own nomenclature as they went but spigot stayed backwards compatible

quaint mantle
#

How do redstone paritcles work

indigo crypt
quaint mantle
#

First of all dont call me bro, second why do u even wanna reset the name?

summer scroll
#

@stone sinew, sorry for tagging but update from the previous conversation. I try to send head rotation packet and get the yaw of the armor stand, it says the yaw is 0, so you're right it doesn't change. I'm using EntityArmorStand#getBukkitYaw

[16:06:35 INFO]: [-29.603943] - [0.0]
[16:06:35 INFO]: [-28.85382] - [0.0]
[16:06:35 INFO]: [-16.403442] - [0.0]
[16:06:36 INFO]: [-358.8537] - [0.0]
quaint mantle
#

third another fix:

@EventHandler
    public void onEntityTakeDamage(EntityDamageEvent e) {
        if(!e.getEntity().isDead()) {
            LivingEntity let = (LivingEntity) e.getEntity();
            if(let.getHealth() - e.getDamage() <= 0) {
                let.setCustomName("");
                let.setCustomNameVisible(false);
            }
        }
    }
hasty lynx
#

Ñ

chrome beacon
indigo crypt
quaint mantle
#

before u start coding maybe learn correct english? no offense @indigo crypt

indigo crypt
quaint mantle
#

nah just learn it yourself

#

its better

chrome beacon
quaint mantle
#

oh yea

indigo crypt
indigo crypt
quaint mantle
#

np!

plush crescent
#

Hi, I need help with a plugin.

Can Spigot spawn an alter ego of the player who executed the command?

chrome beacon
#

If that's the case, plugins like Citizens can

#

I'd recommend hooking in to that rather than reinventing it

plush crescent
#

I see....

#

Thank you!

grim ice
undone axleBOT
grim ice
opal juniper
#

Jail loc is null

reef wind
#

surprised how many people can’t read stacktraces

opal juniper
#

They were literally here for the same thing last night and I gave the same response

#

But no, they must ask again

reef wind
opal juniper
#

That’s right though?

#

It’s like “jails.arg[1].x”

#

What is args[1] @grim ice

grim ice
#

wait

grim ice
#

the jail name

opal juniper
#

Then why are you getting a player from it?

grim ice
#

what?

#

wtf did i write a player

opal juniper
#

Player target = Bukkit.getPlayer(args[1]);

#

And you are using it in the location

grim ice
#

oh wait]

#

bruhhh

#

args[0] is the player i gotta fix that

opal juniper
#

Myeah

quaint mantle
#

Can i get recipe from furnace in FurnaceSmelt/BurnEvent?

grim ice
#

u can get the item that is getting burnt

#

and u also can change the result iirc

quaint mantle
#

i need to get recipe

#

or this namespaced key

smoky oak
#

if someone has a permission like simple, is that part of a permission named simple.complex?

opal juniper
#

simple is the root perm

#

So like

#

you can grant simple.complex

#

Or simple.*

#

Which is all children nodes

smoky oak
#

but it does not contain it?

#

when its like that?

#

eh whatever im just going to put everyting in a separate perm

vivid zodiac
#

Hi, i'm blocked to make table initialisation, and i don't know why

public static playerball[] tabplayerball = new playerball[16];

public class playerball {
    public String playername;
    public int timerleft;
}

public static void Tabini()
{
    for(int i = 0; i <= tabplayerball.length; i++)
    {
        tabplayerball[i].playername = ""; 
        tabplayerball[i].timerleft = -1;
    }
}

with error

        at fr.kokokaz.plugintest.task.TimerBall.Tabini(TimerBall.java:44) ~[?:?]```
silver cove
#

please follow java naming conventions

#

my eyes are burning

#

and it's a great way to improve ur code aswell :)

#

also have u tried using a list?

#

u can't add new items into an array afaik

ivory sleet
vivid zodiac
#

when i try to create new object
like this tabplayerball[i] = new playerball();

#

i've again error

smoky oak
#

is it a null pointer exception?

vivid zodiac
#

No enclosing instance of type TimerBall is accessible. Must qualify the allocation with an enclosing instance of type TimerBall (e.g. x.new A() where x is an instance of TimerBall).

torn shuttle
#

if I spawn a livingentity using world#spawn() and that gets cancelled by something how can I detect it was cancelled without hooking to the spawn event?

#

because isValid also triggers if it's in an unloaded chunk

#

#isDead?

unreal quartz
#

maybe try getting the entity by uuid?

summer scroll
#

How can I check if a class implements Listener?

unreal quartz
#

instanxeof

#

ce

vivid zodiac
#
java.lang.NullPointerException: null
        at fr.kokokaz.plugintest.task.TimerBall.Tabini(TimerBall.java:44) ~[?:?]
        at fr.kokokaz.plugintest.MainPlugin.onEnable(MainPlugin.java:13) ~[?:?]
        at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:263) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:351) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:480) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugin(CraftServer.java:494) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugins(CraftServer.java:408) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.reload(CraftServer.java:881) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.Bukkit.reload(Bukkit.java:651) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.command.defaults.ReloadCommand.execute(ReloadCommand.java:27) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:149) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.dispatchCommand(CraftServer.java:763) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at org.bukkit.craftbukkit.v1_16_R3.CraftServer.dispatchServerCommand(CraftServer.java:748) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at net.minecraft.server.v1_16_R3.DedicatedServer.handleCommandQueue(DedicatedServer.java:387) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at net.minecraft.server.v1_16_R3.DedicatedServer.b(DedicatedServer.java:356) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at net.minecraft.server.v1_16_R3.MinecraftServer.a(MinecraftServer.java:1008) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:847) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$0(MinecraftServer.java:164) ~[spigot.jar:2991-Spigot-018b9a0-f3f3094]
        at java.lang.Thread.run(Unknown Source) [?:1.8.0_301]
Class TimerBall

public static playerball[] tabplayerball = new playerball[16];

public class playerball {
    public String playername;
    public int timerleft;
}

40- public static void Tabini()
41- {
42-    for(int i = 0; i < tabplayerball.length; i++)
43-    {
44-        tabplayerball[i].playername = ""; 
45-        tabplayerball[i].timerleft = -1;
46-    }
47- }
Class MainPlugin

11- @Override
12- public void onEnable() {
13-    TimerBall.Tabini();
14-    getCommand("pstart").setExecutor(new Commands());
15-    getCommand("pstop").setExecutor(new Commands());
16-    getServer().getPluginManager().registerEvents(new PluginListeners(), this);
17- }

Quelqu'un serait m'aider ? c:

queen niche
#

There is also something at your main.Java

#

Line 13

#

Do they have a connection?

vivid zodiac
#

wait i give u this

#

TimerBall.Tabini();

vivid zodiac
smoky oak
#

What's the fastest way to find and manipulate the first empty slot of an inventory

opal juniper
#

loop thru

#

find first empty slot

#

worst time complexity is O(n)

smoky oak
#

fair but i got a different issue now...

#

Is there a simpler way to check if there's a shulker box in an inventory than this

for(ItemStack itemStack : shulkIV){
  if(itemStack == null)
    continue;
  if(Tag.SHULKER_BOXES.isTagged(itemStack.getType())){
    return true;
  }
}```
#

im just gonna assume no

unreal quartz
#

inventory.contains

unreal quartz
smoky oak
#

at this point I'm just checking by checking if the return of addItem is empty

#

also issie with contains

#

cant check for the 17 materials that make up shulker boxes

summer scroll
#

Anyone knows how to teleport player while having a passenger? I've been trying to use client side entity, but it's still doesn't work, right now the issue is you can't teleport between worlds.

unreal quartz
#

i mean you can check with contains for all 17 materials but at that point you may as well just use your own loop since i imagine contains does the exact same thing you do

smoky oak
#

ok

unreal quartz
#

why not dismount the passenger first

#

teleport both and remount them

summer scroll
unreal quartz
#

why do you need the teleport event

summer scroll
#

To dismount the passenger?

#

The teleportation is not from my plugin.

unreal quartz
#

there is a different event for switching worlds

summer scroll
#

The player doesn't got teleported anywhere.

quaint mantle
#

Is there any way to make a custom item, that is a player head, and add metadata which gives me a custom head item with a custom texture?

summer scroll
quaint mantle
#

well not custom texture

#

skin textures yes

crude sleet
#

Is it possible to remove or deactivate the recipe book in an furnace inventory without removing the permission for it?

quaint mantle
#

if u want custom textures ull have to make a skin for it add it to yourself and use this: https://minecraft-heads.com/custom-heads/heads-generator to get the texture value @quaint mantle

quaint mantle
#

Can you elaborate on what you are trying to achieve?

#

My guess: u want custom items that are heads that have textures, lore, displaynames etc?

#

Yea

#

This is my code that I tried

    private static void createSuicideWand() {
        ItemStack skull = new ItemStack(Material.PLAYER_HEAD, 1); 
        SkullMeta skullMeta = (SkullMeta) skull.getItemMeta();
        skullMeta.setOwningPlayer(Bukkit.getOfflinePlayer());
        skull.setItemMeta(skullMeta);
        suicideWand = skull;
    }
#

nope not how it works

#

ull have to use a head value on minecraft-heads

#

u can find there

#

skullmeta part is right

#

but u gotta add this

#
GameProfile profile = new GameProfile(UUID.randomUUID(), null);

        profile.getProperties().put("textures", new Property("textures", "whatever the value is"));

        try {
            Field profileField = skullMeta.getClass().getDeclaredField("profile");
            profileField.setAccessible(true);
            profileField.set(skullMeta, profile);
        } catch (IllegalArgumentException | NoSuchFieldException | IllegalAccessException e) {
            e.printStackTrace();
        }
#

this is what i use

#

Oh ok

#

if u want textures from skins

#

you go to the site

#

uhm i am kind of new to java and plugins so not sure how i would apply it to the skull meta

#

enter the name

quaint mantle
#

just put the value in

#

and u have it

#

Oh wait i see it now

quaint mantle
#

replace sthe setOwningplayer line with everything i sent

#

oh ok

#

if u wanna get the value of ur own skin go to the site then the heads generator, enter ur name

#

copy the command into notepad or smthing

#

and ull see the Value:"hgsdhsghsugsgus something="

valid crag
#

@torn shuttle daily reminder that i'm disappointed

quaint mantle
#

and copy everything inbetween that

#

Uhm i am getting a few errors when i use your code

#

tell me

#

show me*

#

Ye import gameprofile first

#

Uhm it says that GameProfile cannot be resolved, what version did you code yours in? Mine is in 1.17

valid crag
#

gameprofile isn't included in the spigot api

quaint mantle
#

OH YEA

valid crag
#

i think paper api might have an api class for it

quaint mantle
#

oh ok

#

im using paper api looooooooool

valid crag
#

and also a method to set the profile directly

#

without reflection

quaint mantle
#

actually im using both spigot AND paper

#

ah ok

summer scroll
quaint mantle
#

idk

#

might work

#

actually no

#

ull need to having a paper server then :/

#

oh no i do have a paper server, my plugin is just only spigot

summer scroll
#

i'm gonna use libs for that

valid crag
#

depend on spigot rather than spigot-api

#

for nms classes and mojang authlib classes

#

you'll have to build spigot locally

summer scroll
#

simply just SkullUtils.applySkin(skullMeta, value)

#

no need to use paper api, and long ass code

quaint mantle
#

hmm lemme check

valid crag
#

you cannot teleport a player while having a passenger

#

the client doesn't like it

summer scroll
#

even tho the entity is client side?

valid crag
#

precisely because the client doesn't like it

#

it's not a server issue

summer scroll
#

alright

#

im confused how origin realms managed to do that

valid crag
#

you can't even dismount, teleport, and remount immediately

#

need to wait a few ticks in between or the client shits bricks

summer scroll
#

mhm, been having this issue for like 1 week

eternal oxide
#

batmans mask has slipped?

summer scroll
#

so like, there is no way to do that?

valid crag
#

there's not a way that isn't cancer or bulky that i know of

summer scroll
#

oh damn, my head hurts a lot

quaint mantle
quaint mantle
#

ok

summer scroll
quaint mantle
#

Ah ok

valid crag
#

there's also this nice skullcreator library

quaint mantle
#

Did i do it right? Sorry im a noob

    private static void createSuicideWand() {
        ItemStack skull = new ItemStack(Material.PLAYER_HEAD, 1); // Create a new ItemStack of the Player Head type.
        SkullMeta skullMeta = (SkullMeta) skull.getItemMeta(); // Get the created item's ItemMeta and cast it to SkullMeta so we can access the skull properties
        skull.setItemMeta(skullMeta); // Apply the modified meta to the initial created item
        SkullUtils.applySkin(skullMeta, "eyJ0ZXh0dXJlcyI6eyJTS0lOIjp7InVybCI6Imh0dHA6Ly90ZXh0dXJlcy5taW5lY3JhZnQubmV0L3RleHR1cmUvYjYyNjUxODc5ZDg3MDQ5OWRhNTBlMzQwMzY4MDBkZGZmZDUyZjNlNGUxOTkzYzVmYzBmYzgyNWQwMzQ0NmQ4YiJ9fX0==");
        suicideWand = skull;
    }
summer scroll
quaint mantle
#

ok

summer scroll
#

so i saw one server that can teleport entity with passenger, is it possible that they have modified custom server jar?

valid crag
#

it's not about the server

#

the client gets desynchronized and shit

#

maybe if you try to resynchronize the client somehow by throwing the right packets at it afterwards it can be achieved

#

are you sure they weren't just using entity destroy/create packets instead of actually teleporting it

summer scroll
#

im not really sure about that part

summer scroll
valid crag
#

i mean instead of teleporting it, destroying it and spawning it back in the new location

stone sinew
summer scroll
#

the teleportation is not come from my plugin

#

so i can't destroy the entity, teleport the player, and spawn the entity again

valid crag
#

you could maybe rig up a listener on the protocol layer that catches teleport packets for mounted entities and instead replaces the teleport packet with a pair of destroy/create packets

summer scroll
valid crag
#

something along those lines

#

I don't remember if the server properly supports it either, but I remember the bigger issue being on the client

quaint mantle
#

hmm still doesnt work, i just get a plain player head

valid crag
#

pretty sure you can teleport entities as long as a player isn't mounting them or they aren't mounted on the player

#

I don't remember the details, it was something player related

severe marsh
#

Can I change the way built-in commands (/gamemode, /kill etc.) work?

valid crag
#

no but you can override them with a new command of the same name

opal juniper
#

NNya back>?>>

valid crag
#

we'll see

severe marsh
#

How could I do it?

valid crag
#

you'd reimplement and override the gamemode command with your own and not send it

summer scroll
#

sounds like i need to use protocol lib

torn shuttle
valid crag
#

i am very disappointed in that despite doing java since 2016 or whatever you still haven't learned oop 101

#

it's a bit baffling, really

#

didn't think such a thing possible

torn shuttle
#

I'm glad that I could broaden your horizons

opal juniper
#

== "Im sorry im shit"

torn shuttle
#

I will strive to find new and interesting ways to make you see the world

valid crag
#

do you understand why your original question was dumb or should I broaden your anal prolapse with some 101

torn shuttle
#

the main issue really is that I assumed there was only one object for the getLocation method when I should've checked

valid crag
#

but see, this is where the OOP side of things comes into play

#

even if there were only one object, your question would still be dumb

#

let me see if I can dig up your original question

#

location = livingEntity.getLocation();
livingEntity.remove();

30 minutes later

location == null ?

torn shuttle
#

you can do a repeat of the earlier discussion but I understood it just fine

valid crag
#

do you? it really doesn't look like it

severe marsh
#

Ty

proud basin
#

hey skull head

torn shuttle
#

yeah I know you are basing this on very well established data with the fact you have implanted a mind reading chip in my brain and all but I guarantee you that I understand the difference between a field and an object

valid crag
#

then why did you ask that question

#

a blind man can see it with their forehead that location would never become null if they know the difference between an object and a field

torn shuttle
#

because sometimes you've been working on something without being able to test it for over 100h and you just want external validation that you are not going insane

valid crag
#

smells like an excuse

torn shuttle
#

if you didn't want a reason you shouldn't ask for one

valid crag
#

it was a rhetorical question

torn shuttle
#

smells like an excuse

valid crag
#

but at least we've got you to admit that it was dumb

#

admitting things is the first step towards improvement

#

next I expect you to improve

torn shuttle
#

yeah you got me to admit it was dumb even earlier today when I realized getLocation was getting generated every time

valid crag
#

getLocation being cloned each time is completely irrelevant to why your question was dumb

vivid temple
#

in an item pickup event, how do you check the amount of picked up items?

valid crag
#

get the itemstack from the item and get its amount

stone sinew
vivid temple
#

thanks

torn shuttle
#

I should just make a macro on my keyboard that automatically adds a debug line

valid crag
#

have you considered using the debugging feature that comes with IDEs

torn shuttle
#

yeah but I'm a masochist

#

also remote debugging is a pain to set up

valid crag
#

yeah you have to like open a port and change one or two settings in your ide

#

digging through megabytes of sysouts in some logfile is obviously easier

torn shuttle
#

I'm too lazy to locally replicate my remote setup you think I'm going to open ports?

#

what is this, 2008 magmaguy trying to host warcraft 3 games?

vivid temple
#

my IDE errors that this will always be false, why?

e.getItem().getType().equals(Material.RAW_GOLD)
valid crag
#

because getItem returns an entity

#

and entity::gettype returns an EntityType

summer scroll
#

yo nny, you know how to use protocol lib?

valid crag
#

and an EntityType will never be equal to a Material

summer scroll
#

this is so confusing

torn shuttle
#

not with that attitude

opal juniper
valid crag
#

my attitude is very anti equality

opal juniper
#

u just have to write directly

summer scroll
#

i dont even know where to start

torn shuttle
#

hold on let me go find two identically named enums

summer scroll
#

so i want to listen to a entity teleport packet, and i want to get the entity from that packet

opal juniper
valid crag
#

register a packet listener or whatever it's called and then override onPacketReceiving or Sending depending on what you're doing

#

and from there it's just like working with events

opal juniper
#

its a packet adapter

torn shuttle
#

how the hell is CHICKEN a material name

summer scroll
#

yeah thats what i do right now

valid crag
#

chicken meat

#

COOKED_CHICKEN is the cooked meat and CHICKEN is the raw one

#

ask mojang why they didn't call it RAW_CHICKEN or whatever

torn shuttle
#

EntityType.fromName(Material.CHICKEN) there

#

I brought a chicken back to life

#

or at least it will be once it spawns

valid crag
#

at least chicken is halal

vivid temple
#

how do i remove something from a players inventory?

chrome beacon
#

Inventory#removeItem

valid crag
#

you kindly ask them to drop the item

summer scroll
vivid temple
torn shuttle
#

damn nnya I didn't know you were physically unable to make people drop items

#

must suck

valid crag
#

who says I am

#

take note of the 'you'

torn shuttle
#

I did a really cool magic trick where I managed to make a living entity disappear

#

it's so magical even I am stumped as to how the trick is done

valid crag
#

was it the chicken

torn shuttle
#

we all know how the chicken disappearing act really works, deep down

valid crag
#

have you worked with mythicmobs

torn shuttle
#

that really depends on your definition of worked with

valid crag
#

do you know if the MythicMobSpawnEvent is fired only when the mob spawns for the first time, or if it's also fired when its spawned into the world as it loads with a chunk

torn shuttle
#

no clue

valid crag
#

great

torn shuttle
#

I know how my code does it

#

I just changed the logic for it lol

#

you'd hate it too

#

so you know it's quality

valid crag
#

i hate many things

torn shuttle
#

you'd find it in your heart to especially hate this one

valid crag
#

is it a minority

torn shuttle
#

you're really testing the mods today huh

#

do you already have the next account lined up?

valid crag
#

several

#

regardless, I haven't said anything wrong

#

any implications you may have derived from anything are purely results of your inner corruption

hybrid spoke
#

he's finally allowed to be back on here

valid crag
#

i guess I'll test it when I have the effort and plug in an entity add to world event if it doesn't cut it alone

dusk flicker
#

welcome back NNY mainish account

torn shuttle
#

he gets paid by the banned account

ivory sleet
#

That’s a new account or no?

dusk flicker
#

prob?

torn shuttle
#

no he just renamed

valid crag
#

this account was originally the batman one

dusk flicker
#

ah

torn shuttle
#

he's been on here for at least 3 days

#

actually probably more, I think I slept for 20h

#

time is relative

ivory sleet
#

Ah did imaginedev tell you?

valid crag
#

maybe? he did tell me something

ivory sleet
#

I presume it was about that then

torn shuttle
#

you making him a mod instead of handing out a ban?

valid crag
#

brilliant

dusk flicker
#

👏

torn shuttle
#

make him a mod and have him ban himself on loop

#

I'll be waiting for my nobel prize for good thinking

valid crag
#

i'd be too corrupt to ban anyone but 1.8 people

torn shuttle
#

I'd give it about .3 seconds before you go power crazy

valid crag
#

@ivory sleet is it about the gay shit

unreal quartz
#

eh i’d argue that’s a good thing

ivory sleet
#

Hmm maybe is it?

valid crag
#

i don't know

ivory sleet
#

Maybe I should ask him instead

valid crag
#

i'm told a lot of things all of the time

oblique pike
#

Is there any way to make arrows not slow down in water?

opal juniper
#

heyyyy nnya

#

so

ivory sleet
#

Got a point, well anyways it’s decided you’re allowed to be here legally if you don’t break any rules. And yes the admin is involved in this decision (;

opal juniper
#

you said that there was optimising to do?

torn shuttle
#

so that's going to last all of 3 more days

valid crag
#

makes me wonder why you're not unbanning my original account

ivory sleet
#

🥲

dusk flicker
#

lol

torn shuttle
#

I mean

valid crag
#

initially I assumed it was because nobody wanted to overturn the orange cube's ban

ivory sleet
#

Tbf I don’t remember the name nor I’d

torn shuttle
#

I look forward to seeing what it is that gets you banned this time

valid crag
#

@NNYaKNpGms0eUVpiSdHx#5618
599731521922007066

ivory sleet
#

we can ban trade I guess

valid crag
#

alright, you can take, uh, @past pawn

torn shuttle
#

you really should've pinged a staff member there nnya, your comedic timing is horrible

ivory sleet
#

I was thinking of yeeting the one you’re on now and pardoning your original one

valid crag
#

i don't really see the point but sure i guess

#

it'll blacklist this ip so I need to cycle out the vpn again though

#

so you should unban the original before banning this one

ivory sleet
#

Right

#

Actually idk if I can unban

#

?unban

undone axleBOT
#
CafeBabe Help Menu
Syntax: ?unban <user_id> [reason]
Unban a user from this server.

Requires specifying the target user's ID. To find this, you may either:

  1. Copy it from the mod log case (if one was created), or
  2. enable developer mode, go to Bans in this server's settings, right-
    click the user and select 'Copy ID'.
opal juniper
#

looks like u can

ivory sleet
#

?unban 599731521922007066

undone axleBOT
#

Unbanned that user from this server.

ivory sleet
#

?ban 871395117074907156

undone axleBOT
#

User with ID 871395117074907156 not found

opal juniper
#

NNya can u help wit the path finding pls. u said there was some shit to optimise

ivory sleet
#

?Ban 599731521922007066

#

?ban 599731521922007066

undone axleBOT
#

Done. That felt good.

ivory sleet
#

Ok

valid crag
#

conclure

dusk flicker
#

wasnt that the original?

valid crag
#

you banned the wrong one

opal juniper
#

bruh

dusk flicker
#

lmao

valid crag
torn shuttle
#

alright place your bets, how long before the next main account ban

ivory sleet
#

Man

#

Uh just let it be like this

queen niche
#

String temp = String.join(" ", args);

How do I make this string ignore the args[0]?

ivory sleet
#

🤨

quaint mantle
#

I`m using long defaultTime = System.currentTimeMillis() + 86400000L; to set one day cooling.

valid crag
#

i'll ask someone else to do it later i guess

ivory sleet
#

Sure

quaint mantle
#

but it returns 452198 hours

#

time in mysql

dusk flicker
#

looks like thats a time in ms

valid crag
#

consider using Instants or dates or whatever

dusk flicker
#

not duration

#

So it's showing an actual date I believe

valid crag
#

show me what you have @opal juniper

quaint mantle
opal juniper
#

ill do a paste of both classes

summer scroll
#

Is calling this method every 1 second for each player is a bad idea? I want to check if the player is near a portal, so i can remove the passenger. https://paste.md-5.net/huweducoyu.cs looking for alternatives that is faster of course

opal juniper
valid crag
#

right so

queen niche
#

String temp = String.join(" ", args);

How do I make this string ignore the args[0]?

opal juniper
#

args[1:] or something

#

i think

valid crag
#

the path can be made a bit more optimal if instead of backtracking through a chain of parents, you backtrack through the nodes nearest to the starting point

opal juniper
#

well

valid crag
#

for that to happen you need each node to actually cache their adjacent nodes

#

instead of constructing new ones each time

dense goblet
#

Also your time is so long as you add the current time since jan 1st 1970 to the duration

valid crag
#

you could maybe replace the Set<Node> with a Map<Node,Node>

opal juniper
#

right - so its like a trade off between memory and efficient path essentially?

opal juniper
valid crag
#

well, since Set is just a Map anyway, the difference in memory is negligible

#

and yeah, processed

dense goblet
#

@opal juniper which algorithm are you using for pathfinding

opal juniper
#

A* ish

valid crag
#

the actual cost is that it takes a bit more cpu time

#

since each backtracking step involves looking at all of the adjacent nodes and selecting the one nearest to the origin

#

rather than just grabbing the parent

dense goblet
#

Then A* should have built-in backtracing right

opal juniper
#

yeah if you do parent node

#

which is wat i am doing

dense goblet
#

Since it's pretty much Dijkstra

#

With a skew

valid crag
#

we're using a depth-first approach with heuristics so the parent chain isn't always optimal

dense goblet
#

Ah true

opal juniper
#

What do the key and value node represent? surely it should be a Node -> Multiple Nodes

valid crag
#

it still won't be optimal after this but it'll be a little bit better

opal juniper
#

as if it is pointing to all neighbours

valid crag
#

the processed set right now contains all of the nodes that we've processed

queen niche
valid crag
#

in a Map<Node, Object> map

#

Set::contains is just map.get() != null

#

and what we want to do here is ensure that no two Node's are created for the same location

#

or if they are created, they aren't retained

#

whenever we want at a certain location, we want the same Node instance to be returned

#

and since the equals method of Node is based on the location, a Map<Node, Node> will achieve just that

#

consider it a Map<Location, Node>

opal juniper
#

myeah that makes sense

valid crag
#

but since the Node is a sort of a Location, we substitute the Location with Node

#

a fancy term for this is a 'canonical instance' map

eternal oxide
#

Use Block rather than Location. Location is too precise

dense goblet
#

Apparently if your heuristic function doesn't over-estimate the remaining distance then A* should be guaranteed to backtrace optimally

valid crag
#

which is why we're using Node instead of Location or Block

#

because Node may not be defined in terms of either

#

but Node is always in terms of Node

maiden briar
#
bedLocation.getBlock().setType(type);
Bed bed1 = ((Bed) bedLocation.getBlock().getBlockData());
bed1.setPart(Bed.Part.FOOT);
bed1.setFacing(direction);

bedLocation2.getBlock().setType(type);
Bed bed2 = ((Bed) bedLocation2.getBlock().getBlockData());
bed2.setPart(Bed.Part.HEAD);
bed2.setFacing(direction);

Why?

valid crag
#

what we have right now is this

#

as you can see the path isn't optimal

opal juniper
#

yep. that path is not the optimal

valid crag
#

to alleviate the issue what we're going to do is kind of doing a second A* path search in the reverse direction

eternal oxide
#

yep, the one I did was a tree search, depth first. Then I prune for shortest path. The code I gave you was bugged

#

I gave fixed code to jeff

valid crag
#

but limit its node set only to the closed set of the original call

opal juniper
#

myeah i did try it elgarl but it didn't work in all instances

valid crag
#

so it's exponentially faster

dense goblet
#

Is your heuristic just the distance?

valid crag
#

pretty much yes

dense goblet
#

Then the path should be optimal no

eternal oxide
#

Yep, the issue with mine is speed, however it "shoudl" find its way around any obstacle, given enough time

dense goblet
#

Since it won't overestimate

#

Only underestimate

valid crag
#

not quite

eternal oxide
valid crag
#

instead of selecting the deepest or an arbitrary node from the open set, we always select the one closest to the target

#

which results in what the gif shows

#

when it hits a wall, it starts branching perpendicular to the direction to the target

eternal oxide
#

all you have to do is prune after with the one you showed me

valid crag
#

which results in a suboptimal path

eternal oxide
#

you would plot a line straight to the corner then

valid crag
#

because the shortest path would usually be diagonal

dense goblet
#

Is that more efficient than normal A*?

valid crag
#

rather than perpendicular

opal juniper
valid crag
#

well, normal A* with looks like this

#

it finds the optimal path but has to process exponentially more nodes than a search for a slightly suboptimal path

eternal oxide
dense goblet
#

Okay makes sense

valid crag
#

the current way it happens is 'fine' but can be made slightly better with just a slight increase in required cpu time

eternal oxide
#

Find the fastest route, then prune it for most direct

dense goblet
#

But mentally that doesn't seem like the A* we were taught...

#

When it hits the wall why would it go back to the beginning

opal juniper
#

oh elgarl the reason i didn't want to use the raytracing is cause i wanted to try and keep it more universal to older versions for once. i am working with godcipher on this and he is trying to keep it 1.8 safe

dense goblet
#

That's like normal DFS

valid crag
#

it goes back to the beginning because that's the only way to make the parent chain result in the optimal path

dense goblet
#

The closest available nodes are the ones near the wall

valid crag
#

the parent of any node must have a shorter distance to the origin than the node itself

#

if we branch perpendicularly like in the first gif, that is not the case

#

now granted the algorithm I wrote is far from the actual proper impl for what results in the first gif, but it's close enough most of the time

opal juniper
#

so the idea is to go this way?

#

cut across

valid crag
#

almost

#

we'd want to restrict the path to the processed set

#

which means we'd only pass through the colored circles

opal juniper
#

oke

valid crag
#

i'm not sure if we can go through the empty circles

#

but maybe with some tweaks

torn shuttle
#

run pathing on your pathing

valid crag
#

pretty much yes

opal juniper
#

did you want me to set all the "processed" to glass for a test?

#

to see what it contains

valid crag
#

sounds fine

dense goblet
#

When you hit the wall shouldn't normal A* just crawl along the wall, since those are the available nodes with the lowest weight? Then their parent nodes would be whatever cloud node is closest to them

opal juniper
dense goblet
#

Since that's what Dijkstra does right

#

And A* is just weighted Dijkstra

valid crag
#

where's the target and where's the obstacle

#

and don't put the target 500 blocks away

torn shuttle
#

don't run a* algorithms at 3 am gone sexual

maiden briar
#

Why is PlayerPickupItemEvent deprecated?

tame coral
eternal oxide
#

Javadoc tells you why

maiden briar
#

Ah EntityPickupItemEvent

opal juniper
#

src is the first yellow glass, target is the last yellow glass

valid crag
#

i can't see shit

opal juniper
#

no obstacle

#

lmao

valid crag
#

it runs off the screen

opal juniper
#

ok one sec

#

its a vid?

valid crag
#

oh it's a mp4

#

you know ripcord doesn't play video

opal juniper
#

LMAOOOOO

#

that explains shit last night

valid crag
#

yeah that path looks fine

opal juniper
#

ye

valid crag
#

try putting some large obstacles in between

opal juniper
#

okk

valid crag
#

put the target in a house with a door on the opposite side to the origin

torn shuttle
#

I've actually never tried to mess with the pathfinding, how are entities fed the next target location? sort of similar to raycasting to a specific point?

valid crag
#

i'm not sure how it works under the hood tbh

#

i'm pretty sure entities use like some sort of a precomputed navmesh pulled from like a heightmap or something

torn shuttle
#

I'd be surprised, since that would need to be updated on every block place

valid crag
#

myeah

#

but, so are the heightmaps

torn shuttle
#

and iirc navmeshes aren't the ligthest thing to compute

eternal oxide
#

for MC I'm fairly certain its just pick a target and head towards avoiding specific blocks

opal juniper
#

its another video

valid crag
#

yeah i'm not sure about the navmesh part

opal juniper
torn shuttle
#

would probably be easier to just feed it breadcrumbs based on a*

valid crag
#

the entire path is definitely computed on the spot

opal juniper
#

yeah

#

why?

valid crag
#

and iirc the pathfinding puts different weights on different blocks that mobs walk over

#

though that might be bedrock only

#

the pathfinding changed in like 1.8 or something, previously it was like what elgar said

#

just move in the direction of the target until you hit something

torn shuttle
#

something like that

valid crag
#

now the whole path is computed at once and zombies can run 300 block long paths inside mazes

torn shuttle
#

they have gotten smarter from previous versions that's for sure

#

they have ledge detection now

#

imagine that

valid crag
#

which is why mobs sometimes spin around stupidly on slabs or block corners and shit

opal juniper
#

tbh it dont look that bad at all

#

it looks pretty optimal

valid crag
#

something about velocity and collisions prevents them from reaching the next point in the path

#

and then they just spin around it

#

which has made the mobs' movement look pretty stupid and artificial in more recent versions

#

the old dumb ai was more organic imo

#

can you make the processed set glass clear

torn shuttle
#

you know I think you're wrong actually, I am pretty sure they spin because they're listening to you spin me right round

opal juniper
#

sure

#

what colour

valid crag
#

clear

#

colorless

opal juniper
#

ok

valid crag
#

it's kind of hard to tell yellow from green in this puke clusterfuck

opal juniper
#

lmao

torn shuttle
#

somehow the worst pathfinding in minecraft right now is for flying creatures

opal juniper
#

wait thats small

#

lemme send individuall

torn shuttle
#

now make code to generate a maze then have it compete against your maze solver

opal juniper
#

there are definitely a lot of the "processed" nodes

maiden briar
#

How can I run a task which will auto put all players on a list if they are afk?

valid crag
#

in the first screenshot

#

the stone wall

maiden briar
#

On PlayerMoveEvent I remove them from the list

valid crag
#

starting from the end of the stone wall that is closes to the camera

#

extend it to the left

#

to make an L shape

opal juniper
#

ok

#

lmao it went over it

#

lemme make it taller

torn shuttle
#

or put a big inwards ledge

opal juniper
#

it has done a stupid

#

source is on my right

valid crag
#

yeah that's a fucked parent chain right there

opal juniper
#

mhm

#

cause the target is to the right

#

it thinks it should go that way

valid crag
#

right

#

it first hits the wall

#

then hunts the target to the right

#

then hits the second wall

#

then crawls the first wall upwards until it's the closest it can get

#

and then starts spreading radially outwards

#

creating a circle

#

and all of this is captured in the parent chain

opal juniper
#

mhm

valid crag
#

you'll want to change the processed set to a node node map

opal juniper
#

so magic coding hitler

valid crag
#

and pass it to the node constructor

opal juniper
#

oh ok

valid crag
#

and in the getNeighbours method, check the map for an existing node at that location and if it exists, return it

opal juniper
#

wait so you want the map passed in the constructor? why?

valid crag
#

because the Node needs it to shit out the correct neighbors

#

you don't want two different nodes giving out two different node instances for the same location

opal juniper
#

but getNeighbours is a method in the pathfinder

#

so we could just make it a field no?

valid crag
#

probably?

opal juniper
#

just thought it would save passing it aroung thats all

valid crag
#

doesn't matter

#

on line 77 you'd check the map for an existing node at that location

#

Node existing = computed.get(neighbourNode);

torn shuttle
#

I've managed to create a situation where one entity has two spawn locations and I am too spent to fix it, it's high time I call it a day for today

valid crag
#

or more concisely, you'd replace line 78 to neighbours.add(computed.getOrDefault(node, node))

torn shuttle
#

going to need a second spawn field, very ugly

opal juniper
#

i forget which way the default is

valid crag
#

mmmm both should be neighbourNode

opal juniper
#

oh ok

valid crag
#

what it does is it looks in the map for a node that is equal to the created neighbourNode

#

if it exists, it returns the equal neighbourNode

#

the "canonical" node for that location

#

if it doesn't exist, it returns the newly created neighbour node

opal juniper
#

oh yeah i keep forgetting i did an override on equals

#

line 41

valid crag
#

containsKey

opal juniper
#

okee

valid crag
#

and drop the !

opal juniper
#

i will!

valid crag
#

then, in retracePath

#

instead of getting the parent

#

get all of the neighbors of the node

#

and pick the one that is closest to the origin

#

actually, that's probably not going to work

#

you'll need to pick it based on the shortest path distance, not just raw distance

#

which is a bit more difficult

opal juniper
#

myeah

valid crag
#

you could do a second iteration of a*, breadth first, on the computed set i guess

indigo crypt
#

hello all, how to call event in another class

opal juniper
#

call or listen

valid crag
#

by learning oop

indigo crypt
opal juniper
#

oh, you must register the class as an event listener

#

so it must implement Listener

#

and then just annotate the methods with @EventHandler

indigo crypt
opal juniper
#

code?

valid crag
#

error?

indigo crypt
#

wait

opal juniper
#

hmm this seems like it may be a fair bit more expensive to get a "better" route

valid crag
#

if you restrict the improvements to the processed set of the first iteration, it won't be very much more expensive

indigo crypt
#

idk why now i dont got an error. but event not work.
i am register it with
this.pm = this.getServer().getPluginManager();
pm.registerEvents(this, this);
pm.registerEvents(new Gui(this), this);

i have implement listener and annotate methods with EventHandler
and, if code on main class, all work correctly

valid crag
#

i have an idea

#

throw some randoms at the compareTo function

#

let's see what happens

#

it's probably going to give a really shit path but it'd look natural

opal juniper
#

ok...

#

should i undo all these changes

valid crag
#

return (int) Math.signum(this.target.distance(this.location) - this.target.distance(otherNode.getLocation()) + (ThreadLocalRandom.current().nextInt(6) - 3));

#

yeah

#

they won't fly

opal juniper
#

wtf

#

lmao

valid crag
#

try the one where it was being stupid before

opal juniper
#

better

valid crag
#

brilliant

opal juniper
#

but i feel like the "randomness" should be lowered a bit

valid crag
#

try playing with the numbers in the nextInt call

#

maybe change it to a nextDouble if you need more control

#

this is a really retarded way of 'fixing' the issue but you can always call it a feature

opal juniper
#

Fuck. Me.

valid crag
#

lmao

opal juniper
#

oh i remember when 1.8 servers used to start in like 2 seconds

valid crag
#

use plugman you plebian

opal juniper
#

i thought it was kinda shit

#

well

#

it was for one plugin i used

#

so i stopped

#

bit hard to see but here are a few example paths

valid crag
#

it's just the wind

quaint mantle
#

welcome back

opal juniper
#

ello imagine

valid crag
#

is it against the rules to be racist

quaint mantle
#

is that a surprise?

opal juniper
#

ok place your bets. how long do we reckon an 11k pathfind will be. eg how long will it take

valid crag
#

I'd expect it to be against the rules to act in a racist way or discriminate

quaint mantle
#

🧍🏿‍♂️

valid crag
#

but what about being racist

quaint mantle
#

why u racist

opal juniper
#

he is not white, he is simply tone1

valid crag
#

let me pose a hypothetical

#

did you know that i'm a farmer

opal juniper
quaint mantle
shadow gazelle
#

Very interesting conversation

valid crag
#

what if being a farmer was against the rules

#

me farming my crops has nothing to do with what I do here

quaint mantle
#

lmaoooo

valid crag
#

would you now, with the information that I am indeed a farmer, ban me

indigo crypt
opal juniper
#

yeah

quaint mantle
#

just dont be racist 😉

valid crag
#

simple for you to say

opal juniper
#

fuck my pc just bluescreened doing an 11k A*

quaint mantle
#

🧍🏿‍♂️

opal juniper
#

well it seems to work NNYa

#

thanks

#

apart from the whole bsod

quaint mantle
#

computers still bsod

indigo crypt
#

I repeat again, how to listen event on another class

opal juniper
#

it definitely was not a co-inky dink

#

Make a class

#

Make it Implement listener

valid crag
#

"in another class"

#

what is that supposed to mean

opal juniper
#

not main

worn tundra
#

lol

valid crag
#

the same way you'd do it in any other class?

indigo crypt
worn tundra
indigo crypt
valid crag
#

spigot is indeed the leading cause of mental damage in the bukkit ecosystem

quaint mantle
#

it takes a parameter type other than a world

#

Like?

#

check

#

it should say in problems

#

bottom of screen

#

Yes

quaint mantle
valid crag
#

learn2read

tardy delta
#

whats the difference between event.getInventory and event.getClickedInventory in the invclick event?

#

player inv?

valid crag
#

could be none, kind of like BlockPlaceEvent::getBlock and getBlockPlaced

tardy delta
#

found it

deep tiger
#

Hi ! Is there a way to unregister vanilla commands such as /gamemode ?

#

The command map contains only bukkit related commands...

valid crag
#

no

#

at least not easily

deep tiger
#

i take all solutions including nms 🙂

wary harness
#

need help with loading player balances from mysql
that need some time
problem is galistenere for example or some other plugins runs command to add/ remove tokens from player
that will make server throw error because getBalance method will return null because balance is not loaded yet in hashmap

valid crag
#

load the balances before the player has logged in

wary harness
#

can I make my add or remove method to wait until balance loading finishes

valid crag
#

the player isn't supposed to be let in until their data is loaded and proper

wary harness
#

well balance loading is delayed

#

for 1 sec

valid crag
#

make it not delayed

wary harness
#

must be

valid crag
#

must not be

wary harness
#

because on leave event

#

I save them

valid crag
#

so?

wary harness
#

so if player switches server

#

server A will not save in time and server B will load

#

old amount

#

big time problem

valid crag
#

have server B wait until server A is done saving

wary harness
#

how would I do that

valid crag
#

by facilitating communication between the two

wary harness
#

I have from that reason 1 sec delay

valid crag
#

via for example bungee's plugin messages

wary harness
#

problem again is other plugin will try to run command

#

to add tokens

valid crag
#

it won't, because the player isn't online yet

wary harness
#

and balance will not be loaded

valid crag
#

because the player won't be allowed to join before it is loaded

#

and it won't be allowed to be loaded before it is saved

wary harness
#

how would I load and block them to join

valid crag
#

wait in the player async prelogin event

#

you don't necessarily need cross server communication either, just a table on the sql database with a [player, server handling player's data] columns will do, but is less optimal

#

server B won't attempt to load any data or let the player in until the database reports that the player is not connected to any server

#

server A will mark the player as not connected to any server only once all data is saved

#

server B loads the player's data and marks the player as connected to server B

wary harness
valid crag
#

throwing arbitrary delays at things has never solved anything

wary harness
#

but there could make many problems think of server crashing and not saving player data

#

that player now is marked as not saved

#

they can't join any server anymore

#

big time problems

valid crag
#

you'd need timestamps or shit to get around that

#

that is why the actual cross server communication is better

wary harness
#

I think I will just make one more hashmap which will store amount

valid crag
#

sure, whatever

wary harness
#

which need to be added and when player loads then just add it

#

your idea will need a lot of rewriting

shadow gazelle
#

Copied the wrong line

#

there

valid crag
#

and not doing the rewriting and just jerryrigging shit together is just kicking the can down the road

#

you'll have to rewrite it eventually

#

because throwing delays at and storing everything in a dozen temporary hashmaps is not maintainable

outer crane
#

How should I handle errors (such as SQL Exceptions) in a custom vault economy?

#

because things such as accountExists exist which don't have a proper way to error out

lost matrix
tribal holly
#

Is there a way to manually update the light of a block ?

outer crane
#

thanks ^^

tribal holly
#

like block.updateLight() ?

shadow gazelle
#

?paste

undone axleBOT
quaint mantle
#

^

dry forum
#

how would you get the version from plugin.yml in a commandexecutor class

quaint mantle
quaint mantle
dry forum
#

yeah but you cant do that in a commandexecutorclass

quaint mantle
#

yeah you can

covert valve
#

any guide to use spigot mappings on gradle (nms 1.17)

dry forum
quaint mantle
dry forum
#

you cna only use it in a extends javaplugin class

covert valve
#

imaginedev don't bully me

quaint mantle
#

?learnjava

undone axleBOT
covert valve
#

i need help here

dry forum
#

i know how to use java...

covert valve
#

im trying special-gradle but it's not working for some reason

quaint mantle
dry forum
#

you didnt tell me before you told me Plugin#getDescription().getVersion()

quaint mantle
#

?dependencyinjection

#

?di

undone axleBOT
covert valve
#
plugins {
    id "xyz.jpenilla.special-gradle" version "1.0.0-SNAPSHOT"
}

group 'com.willfp'
version rootProject.version

dependencies {
    compileOnly 'org.spigotmc:spigot:1.17-R0.1-SNAPSHOT'
}

specialGradle {
    minecraftVersion.set("1.17")
    specialSourceVersion.set("1.10.0")
}

tasks {
    build.dependsOn productionMappedJar
}

here's my build.gradle for my 1.17 module

#

i'm not sure why it doesn't work

tardy delta
#

why doesnt it work to remove the bossbar? i vanished three times and i got three bars

chrome beacon
covert valve
#

correction: fixed by replacing version with 'org.spigotmc:spigot:1.17-R0.1-SNAPSHOT:remapped-mojang'

#

but i can't find playerInteractionManager anymore

chrome beacon
#

Where did you get that name?

covert valve
#

*playerInteractManager

chrome beacon
#

Spigot now uses Mojmaps so old Spigot mapping names won't work

covert valve
#

no but the class doesn't exist

#

decompiled server jar - it is there

chrome beacon
#

Invalidate cache and restart

#

See if that fixes it

covert valve
#

just did

#

it still doesn't exist

chrome beacon
#

Hm

covert valve
#

it's not like the fiedl or method don't exist

#

the class itself doesn't

chrome beacon
#

Yeah idk and I can't really check for another week

minor garnet
#

how works the minecraft projectile velocity ? with your losing velocity etc

quaint mantle
#

like real life

minor garnet
#

but and the projectile increase velocity ?

deep tiger
covert valve
#

not only does PlayerInteractManager not exist

#

but the packets don't either?

#

but i'm not missing all classes

#

most are there

#

it seems to just be the classes i care about

#

and MinecrafKey?

#

what the fuck

split panther
#

JavaFX running on Java 11 show this error on startup
Error: JavaFX runtime components are missing, and are required to run this application

javafx {
    version = "15.0.1"
    modules("javafx.base", "javafx.controls", "javafx.fxml");
}
    runtimeOnly("org.openjfx:javafx-base:$javafx.version:win");
    runtimeOnly("org.openjfx:javafx-controls:$javafx.version:win");
    runtimeOnly("org.openjfx:javafx-fxml:$javafx.version:win");
    runtimeOnly("org.openjfx:javafx-graphics:$javafx.version:win");

runtimeOnly are shaded in with shadow plugin
anyone know how can I fix that?

vivid temple
#

so i tried this, but it doesnt work, can someone help me?

Location location = e.getBlock().getLocation();
            location.getBlock().setType(Material.WHEAT_SEEDS);
tardy delta
#

inventories start with 0 right?

vivid temple
tardy delta
#

oh forgot it

#

would be strange but anyways

covert valve
#

alternative to codemc nms repo? the mapped mojang seems to be missing a bunch of classes

ivory sleet
#

Yarn

covert valve
#

i can't use buildtools for the jar because it needs to be built by jitpack

#

but the actual spigot jar is also missing the classes

#

what

ivory sleet
#

Lol

covert valve
#

it's also missing ServerPlayer

#

does serverplayer even exist? what the fuck is happening

outer crane
#

How do i deal with Vault on a UUID database? It works with player names instead of UUID's for some reason?

covert valve
#

PlayerInteractManager does exist on the spigot jar

#

but not on the mojang mapped jar

#

what the fuck?

vivid temple
#

didnt work

#

This errors with a null

@EventHandler
    public void onBlockBreak(BlockBreakEvent e){

        Player player = (Player) e.getPlayer();

        if (e.getBlock().getType().equals(Material.WHEAT)) {
            player.sendMessage(ChatColor.GRAY + "You broke wheat! - " + ChatColor.RED + "Admin Tools");
            Location location = e.getBlock().getLocation();
            location.getBlock().setType(Material.WHEAT_SEEDS);
        }
    }
hasty prawn
#

All classes still exist in the Mojang Mapped jar, they're just under different names

covert valve
#

ew

#

how do i use spigot mappings?

hasty prawn
#

Just depend on the normal Spigot jar

covert valve
#

but then it's obfuscated

hasty prawn
#

The one the server uses

covert valve
#

why isn't there just deobfuscated spigot mappings

#

because if i use mojang mappings my 1.17+ nms is different to my 1.16 nms

hasty prawn
#

Because that's Mojang's maps

#

Yep

vale breach
#

Hi guys,
does anyone of you have experience with Agents, in particular I mean injectable Agents to JVM. I am trying to unterstand it, but am having a hard time.

I am trying to inject some code into existing 1.17 NMS classes.

I figured it out with static Agents but am currently trying to figure it out with dynamic ones.

vivid temple
hasty prawn
#

The error is on breakBlock line 347

#

Well that's the method name

#

Class is PlayerInteractManager I think? Hard to read that on mobile lmao

tardy delta
#

java.lang.IllegalArgumentException: Cannot get data for not block WHEAT_SEEDS

hasty prawn
#

There you go, need to place Wheat not seeds

queen niche
#

For (int I = 1; i++; i<args.length) { string = string + " " + args[I] }
Does someone know whats wrong with this line? For method cannot be resolved

hasty prawn
#

For shouldn't be capitalized

tardy delta
#

:oof:

#

owh

queen niche
#

mobile shit

tardy delta
#

sad

vivid temple
#

didnt work either

covert valve
#

are there any mojang mapped 1.17 plugins that are open-source?

outer crane
#

How do i deal with Vault on a UUID database? It works with player names instead of UUID's for some reason?

hasty prawn
vivid temple
hasty prawn
tardy delta
#

wdym error

[19:05:05] [Server thread/INFO]: FourteenBrush issued server command: /debug spawnitems
[19:05:05] [Server thread/WARN]: java.lang.IllegalArgumentException: items.length must be < 1
[19:05:05] [Server thread/WARN]:        at com.google.common.base.Preconditions.checkArgument(Preconditions.java:168)
[19:05:05] [Server thread/WARN]:        at org.bukkit.craftbukkit.v1_16_R3.inventory.CraftInventoryPlayer.setSlots(CraftInventoryPlayer.java:217)
covert valve
#

anyone got the mojang -> spigot mappings txt file? i can't find it

smoky oak
#

can i spawn in a item with a count of -1? As in, create a 'infinite' block?

hardy swan
covert valve
#

and i need the server mappings which show a 'doesn't exist' thing