#help-development
1 messages · Page 1142 of 1
sign it
and still need thoughts before wasting time even if I did want to sign it KEK
md will come and visit you on his kangaroo
you can look at all of @river oracles prs
i'm not signing it
smh
i'm not selling out my firstborn to daddy md5
Meh
I signed it a while back and no one has come calling for my kidneys yet
No reason for me to do so
you can call hima nerd more
Not really that interesting
but inventory prs
Yea, not interesting in the slightest to me
This though, would clean up some NMS code & make a particle related method public
miles prs suck, says spigotmc staff (2024, colourised)
ignore the partially busted stuff
bad schematic saves
but it's starting to take shape
not using structures?
It's quite likely I'll just end up maintaining it without it being public in the slightest in the spigot API lmao @remote swallow
nah
building it for a plugin that was already using worledit so I already have a whole pipeline for secondary systems in it
ah
got a builder working on this right now hoping to have some relaly neat stuff by the end of the day
They love me 😎
smh
My first decree as spigotmc inventory shill is to use InventoryView!!!
The git tree is getting annoying right now
I hate having so many entries
welp time to add one more
Well, I'm not gonna waste time if I don't get any thoughts on it lmfao
I already have a spigot only impl so 🤷♀️
what we talking about here
make feature requests on jira and maybe coll y2k or the chocolate will pr them
yeah yeah what are we talking about PRing though
i just saw a rat in an underground shaft
damn cant believe miles is with you
We get it, you're lazy
BoundingBox#getCenter()
tiktok level attention span fr
like a raycast?
I don't really see too much utility in adding such an API, I coul dbe wrong but I'm not sure if it'd be accepted. One this could be easily replicated with just the API all the methods seem to really do is apply some particles around the entity and apply some basic math to it. You could maybe make an argument for exposing getRandom[X,Y,Z] to allow yourself to use the players random, but then again you could just instanciate random yourself
a rectangle with two corners
that's called a line run
whats the goal
are you asking to get the coordinates on the persons physical screen?
that wouldn't be possible
I've no cluew what he wants, an intersection of teh raycast I guess
I mean you could assume 1920x1080 but that's such a naive assumption
It could be easily replicated, but why replicate it when you can just expose a perfectly good method which does it and is re-created in multiple classes already. It's not like it's a single method, but it's literally just copy pasted code with like 3 things changed max like 10 times
why do you need those coordinates
that's just my opinion I mean feel free to sign the CLA and put the idea forward
to make screen system with cursor
I think it might be reasonable to ping choco and coll with the proposal
gonna ping choco cause he's a nerd KEK
what is a screen system
@worldly ingot @young knoll
THOUGHTS
you could use player head rotation I guess if I understand what you mean
I approve
Just imagine how a player walks, and there is a conditionally screen (that is, TextDisplay), a player cursor that acts like a projection of a vector onto this “screen”/fictitious rectangle
put an Interaction entity on any clickable areas
It's probably too general to be considered API. "addParticlesAroundSelf()" would vary in definition from entity to entity, and in some cases just fail silently. For some entities it might show love mode particles, and for some it might show taming particles, but how do you make that distinction from an Entity? So it's not great API.
interface Particlable

but then I won't have a cursor
or ParticleAroundSelfable
AbleToSpawnParticlesAroundSelfButEachEntityHasItsOwnDefinitionSoGoodLuckIdiot
Perhaps util then? for most it's just a form of
for (int i = 0; i < 7; ++i) {
double d0 = this.random.nextGaussian() * 0.02D;
double d1 = this.random.nextGaussian() * 0.02D;
double d2 = this.random.nextGaussian() * 0.02D;
this.level().addParticle(Particles.HEART, this.getRandomX(1.0D), this.getRandomY() + 0.5D, this.getRandomZ(1.0D), d0, d1, d2);
}
I can look to see what deviates from the above
To make a menu like that you force the player to spectate an entity and then place text displays in front of the player.
The player still sends movement packets when they move their camera which you can listen to to calculate where the cursor should move to
There are two ways to interact. a clickable entity when the player looks at it and clicks, or in a UI IF they click on a slot
boolean addParticlesAroundSelf()?
Hope you remember your trig because you will need it
The silent failing is less what I'm concerned about because whatever, more that you can't really determine what that method does
hasAddParticlesAroundSelf()? or is?
Don't need has
has, because it is not a getter
fyi
It just spawns particles lol
if you look at this example, then yes, but how to make it so that the player can walk freely, and anywhere I could make a screen.
is it is
like hologram
Randomly spawns particles within a specified distance around the entity
Ayo docs basically done
It'd be like Entity#dance() but only Villagers, Allays, and Wolfs could dance, and you're not really sure what dance move they'd do
if the screen is following the player how can they ever click on something
The cursor won't be very user friendly if the player can move freely at the same time?
and piglins, choco
Right, Pigstep, how could I forget
do we really care that mojang made a bad decision in their code 😭
smh
It's based off the entity bounding box, so it's for any entity unlike #dance
is it worth the extra maintaining?
Well I guess you could have a static screen in the world
Mojang didn't make any bad decisions. We'd be imposing bad decisions by introducing a common interface
Or would it be better to just have a javadoc?
what about parrots
Anyways it's the same math
they can dance too
why?
I DON'T CARE ABOUT THE DANCING 
why not
tsk
do you not want to dance choco
i can min or max smth like this
You use trig to calculate the where the cursor should be
know what your users care about
can we implement piglin dancing on players
From what I understand, Optic says entities have methods that spawn particles around them with no abstraction to it whatsoever. He's proposing adding an interface that those NMS entities can implement so they are commoned out, then adding a method to Bukkit's Entity class to call it
Which imo is not correct
doesnt make sense for most entities
Mojang's decision to not have that commoned out is correct
also what would it even do for villagers
Because it varies from entity to entity
well, what if you just made it it's own interface and don't add it on entity
villagers have like a billion types of particles
Not even just particle type, but particle data and velocity
so some entities implement ICanHabeParticles
The issue is that the NMS entities don't have a common interface for it
IParticleable
You'd have to add one
Err what I mean is the cursor has little point if the player can move freely. The player already has their crosshair
This would be passed via method params
I just don't feel confident that it would be good API. It's too loosely defined. I'm sure md would probably agree
You can try if you want though
Particle Type, Y offset, amount
double d0 = this.random.nextGaussian() * 0.02D;
double d1 = this.random.nextGaussian() * 0.02D;
double d2 = this.random.nextGaussian() * 0.02D;
what ever the fuck 0.02D represents here
I recently opted against adding Entity#setPhysics(false) because it too varies from entity to entity and is too loose
but is the particle thing only in nms then now?
0.02 is probably offset on the x/y/z axis
like is there no api whatsoever
between -0.02 and 0.02
or is there just no common api
There's no common API in NMS, there's no common API in Bukkit
There is... it's just not... done properly
There are methods to spawn particles around entities on a need-be basis defined locally
e.g. a dog would have its own method to spawn particles when tamed
Each of the classes I've listed do the exact same thing with slight deviations, which can be shoved into a common method with a few params
right
Yes but NMS doesn't have an interface for those methods, right?
It would be easier to interact with the buttons on the “screen” with the cursor; it would be possible to interact with the screen from afar, and it would also be easier to control where the player is looking, that is, for example, changing the size of a button according to the position of the cursor
sounds like the dev can make their own common api then
See the spigot only api I made to show just how common it is https://paste.md-5.net/oqucixineb.cpp.
Because it's half assed. Some entities don't implement a method, others do. They all do the same thing just slightly deviated
There are effects for probably most of those btw
Taming for instance has EntityEffect#WOLF_SMOKE and #WOLF_HEARTS
The names are a bit dated, but they apply to all tameable entities
They've got it setup to be a single method, but the nerds haven't done so
There are also villager entity effects
I think all of what you want to achieve is already done with entity effects
EntityAnimal. EntityDolphin, for example
Yes, those are entity effects lol
This can be abstracted to a generic method, which can be used for anything
Yes. They have been
Entity effects
You are looking at the entity effect packet implementations
Yes, for specific entities
Right. How would you be more specific about it?
You don't need to know the details of the particles. You can just dispatch the entity event (effect)
note genericization. allows devs to impl their own stuff
I just want you to be aware that what you sent are client-sided methods
They're never called on the server
The first screenshot is EntityEffect.LOVE_HEARTS and the second EntityEffect.DOLPHIN_FED
What you're looking for is Entity#playEffect(EntityEffect). So if you want to play the breeding particles around an entity, you would do entityBeingBread.playEffect(EntityEffect.LOVE_HEARTS);
Oh, not entityBeingBread
lol
🍞
I mean, it would be nice if Entity had a method to get its Entity-specific effect/particle
No one entity has one specific entity effect
As for something generic that's not related to entity effects I've made https://paste.md-5.net/agijikociq.cpp
villager happy
Villagers also have effects for when a raid is won, when in love, and when angry
Each spawn particles around the entity, and each have an EntityEffect constant for it :)
ig it would be a pain to maintain
doesn’t make much sense to tie effects to a given entity
I do wonder if we're up to date on those though. We tend to leave them out of date all the time
Nope, we're up to date. Nice
Would be nice to just have the method bumped down to Entity and made public in Bukkit since it's there already and means I'm not rewriting code, but it's not hard to maintain a rewrite of the same method that already exists
Like I said, they're client-sided methods, there is existing API for it, it's done via EntityEffects because that's what you're wanting to use
You don't have to reimplement the particles yourself
You just have to know which EntityEffect to send :p
Doesn't allow you to do stuff outside of EntityEffects though, which a generic method would let you do
Yeah but then you're defining API for things that don't exist in the vanilla server
I mean, that doesn't really matter, does it
Sure it does
there's plenty of API that doesn't exist in the vanilla server
I don't know of any
showEntity/hideEntity is entirely a Spigot concept
It just sends the add/remove packets
health scaling?
Health scaling exists in vanilla
health scaling does exist
events
Events are just hooks for plugins :p
You'd be able to do the same thing with mixins
yes, it makes use of vanilla features to implement a concept API, not quite an abstraction over existing features
Or editing server source directly
I just don't see why draw the line here to be honest, aside from maintainability
I mean regardless, we're not adding API for client-sided methods
I already did that once for creative categories and now we have dead API
were creative categories deprecated?
(they were server-sided at the time, but got moved to client-sided later :p different situation)
o
In Bukkit, yes
I mean, creative categories are one thing, but this kind of method wouldn't matter if it ever gets removed since it is just the concept of adding particles around an entity
then again, I don't see too many people requesting such a feature so it is eh
Yeah, and the reason those methods exist is because they're handling entity effects!

Most just re-create it, see the whole demo screen thing in a variety of plugins
coll prd that
there is a method to show demo screen tho
iirc
Yea, but not before I bugged people about it
it was previously done with NMS or protocollib
That's generally how things work
We need to be aware of something before we add API for it lol
a valid one would be NPCs or entity disguises in general
or the damned armor change event
NPCs, nobody's proposed it. I've consider proposing a player disguise API (still wanting to draft one), and the armour change event is stuckin PR purgatory atm lol
Author got busy
Hence the suggestion on this idea, since it's just particle spawning and unlikely to change lmao
I mean, it is a simple method so just maybe if you PR it, somebody will argue against Choco around the idea 
What I think you're failing to understand is that those particle methods exists in response to the entity effect/event methods. They could have just as easily implemented it in the handleEntityEvent() methods (like they did with the villager), but they moved it out into separate methods for some entities for the sake of readability.
Some entity effects are being handled but they don't show particles. They have sounds instead
But we shouldn't have methods that expose getSoundFromEffect()
Those too would be client-sided
I wonder what an API to expose that kind of stuff would look like
in a way that it doesn't matter if it doesn't exist anymore in the future
If anything just re-create the method in API w/o touching the NMS method directly
The API you're wanting to propose would, in effect, just be invoking the handle event methods but on the server
Which isn't correct
No? I think you're missing was the method would do lol
And no, we're not going to reimplement or copy/paste the client implementations of those methods because that's a maintenance burden lol
tbf, I kind of see the point here after looking at launchProjectile implementation
private void addParticlesAroundSelf(ParticleParam particleparam) {
for (int i = 0; i < 7; ++i) {
double d0 = this.random.nextGaussian() * 0.01D;
double d1 = this.random.nextGaussian() * 0.01D;
double d2 = this.random.nextGaussian() * 0.01D;
this.level().addParticle(particleparam, this.getRandomX(1.0D), this.getRandomY() + 0.2D, this.getRandomZ(1.0D), d0, d1, d2);
}
}
The method would basiclly just be this, but bukkit friendly and more configurable
it just turned into a monster with the time
But at that point plugins can just reimplement it. Having utility methods like that isn't Bukkit's responsibility
Which I yoinked from EntityDolphin btw, but every other damn instance just copy-pastes the method code and changes 2 things lmao
Point is to not do so, since it's a perfectly valid harmless method that already exists
eh, some things aren't worth abstracting out
Why reimplement when it's already a thing
Yes, if you take into account how it's being used and not what it does specifically, which is literally just spawn particles lmao
this.level().addParticle unless this happens to be client-side, which I wouldn't be surprised
but that's the same way Chorus fruit handles it
I mean, while I agree it wouldn't hurt to have the method, I also see the point of maintainability being a burden that just nobody wants to deal with
sure it looks simple now, but if it is added as a general method in Entity, then every single entity where their hitbox is something special would have to override it
Hilariously enough, chorus fruit is also in response to an effect
Only it's a world effect, not an entity effect lol
https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Effect.html#CHORUS_FLOWER_GROW and https://hub.spigotmc.org/javadocs/spigot/org/bukkit/Effect.html#CHORUS_FLOWER_DEATH
declaration: package: org.bukkit, enum: Effect
Oh wait, I was thinking of randomTeleport for that one lmao
Random teleportation would be server-sided, yes
PR KEK
I feel like there already is API for that? Maybe I'm wrong
No
but yeah it would be an API candidate because it's well-defined behaviour
teleport(Entity), teleport(Location), teleport(Entity, TeleportCause), teleport(Location, TeleportCause),
Well, I dunno, maybe. Because chorus fruit's teleportation behaviour is now a component lol
No randomTeleport or teleportRandom
Enderman also use the randomTeleport method as well
There would probably have to be a Player#consume(ItemStack) or something now
I mean, it wouldn't be a method on the World or whatever, it would be a method on the item
Nah
public static boolean randomTeleport(int retries, Player player, boolean showTeleportParticles) {
Random random = new Random();
World world = player.getLocation().getWorld();
CraftPlayer craftPlayer = (CraftPlayer) player;
for (int i = 0; i < retries; ++i) {
// TODO: Make this configurable. Need to figure out what the values are exactly
double x = player.getLocation().getX() + (random.nextDouble() - 0.5D) * 16.0D;
double y = Math.max(world.getMinHeight(), Math.min(player.getLocation().getY() + (random.nextInt(16) - 8), world.getMaxHeight() - 1));
double z = player.getLocation().getZ() + (random.nextDouble() - 0.5D) * 16.0D;
boolean succeeded = craftPlayer.getHandle().randomTeleport(x, y, z, showTeleportParticles);
if (succeeded) {
return true;
}
}
return false;
}
This is a spigot-ish impl of the same randomTeleport
Just yoink that choco lmao
Oh, yeah, if that randomTeleport() method is on Entity or something it can have API for it easy
idk where it's defined. Probably Entity or EntityLiving
I can look lmao
tbh I'm fine with it not being API lol, I've seen enough people causing lag-machine plugins with random tp
It's EntityLiving and we have a patch there already
You'd likely want the craftbukkit code to do something like this, to take into account retries & the particles which enderman & chorus fruit use
Retries are 100% needed, if you want a guaranteed teleport
That's why enderman & chorus fruit loop it, so there's a guaranteed teleport
You may/may not want the particles, so you add a toggle
does it fail if it is not a valid block or what
It can return false for a few reasons
well, that's the internal method so ¯_(ツ)_/¯
we'd be calling the internal method, just putting something bukkit friendly on top 😎
Yeah, that one at least has justification for API
LivingEntity#teleportRandomly() is probably fine, with some parameters in there
Slightly modifying this is good enough
Eh, not point in directly calling it as there's useful toggles like the particles and retry count
also EntityLiving#randomTeleport requires the particle flag, so get rekt @worldly ingot
takes an x, y, z, flag
randomTeleport - https://paste.md-5.net/doresosiwa.java
No actual randomization, curiously. It comes from things implementing it, hence the extra code in my own method
that's probably why yarn just calls it teleport
safeTeleport is probably a better name
the second double looks like a starting y position, the other two doubles look like a target x/z
So, randomTeleport(targetX, startingY, targetZ)
It will start searching at the given y value at the column at x/z, then go down until it finds a block
If that position is obstructed, it will teleport to self (so, do nothing)
Guess you could get two api methods out of it.
Just one called safeTeleport and then randomTeleport which implements the randomization which Chrous Fruit & Enderman use
safeTeleport(x,y,z,flag) randomTeleport(retries, flag)
Flag, again, being a boolean that decides if the particles you get when you use a chorus fruit or when an enderman show or not
Perhaps an arg to set the range it tries to teleport the player within as well. I assume that's part of the randomization given I more or less 1:1'd the method itself here
double x = player.getLocation().getX() + (random.nextDouble() - 0.5D) * 16.0D;
double y = Math.max(world.getMinHeight(), Math.min(player.getLocation().getY() + (random.nextInt(16) - 8), world.getMaxHeight() - 1));
double z = player.getLocation().getZ() + (random.nextDouble() - 0.5D) * 16.0D;
I assume this is a range (16x16) @worldly ingot but I'm not sure on what the 0.5D & (random.nextInt(16) - 8) are meant for though.
progress
I somehow messed up the rollback logic though, it really doesn't like rerolling floor level stuff somehow
kinda weird
Make it an enum for future proofing
Doesn't need to be
if (flag) {
world.broadcastEntityEvent(this, (byte) 46);
}
All the flag does is show particles via an entity event if true, otherwise it doesn't
FUTURE PROOFING
what exactly would be future proofed lmao
what if something else adds it's own random tp particles
As it stands, no point in trying to future proof when we don't even know what that case would look like
for now supporting what exists is good enough
x,y,z range and the particle flag
Returns a boolean, so one can always pass false & do their own particles. I believe Enderman uses the boolean value for their sounds
yea
boolean flag2 = this.randomTeleport(d0, d1, d2, true);
if (flag2) {
this.level().gameEvent((Holder) GameEvent.TELEPORT, vec3d, GameEvent.a.of((Entity) this));
if (!this.isSilent()) {
this.level().playSound((EntityHuman) null, this.xo, this.yo, this.zo, SoundEffects.ENDERMAN_TELEPORT, this.getSoundSource(), 1.0F, 1.0F);
this.playSound(SoundEffects.ENDERMAN_TELEPORT, 1.0F, 1.0F);
}
}
Then we add a method overload
but for now, devs can just rely on the boolean value
How do I make a person execute a proxy command
performCommand() will work just fine
Any ideas on this Choco?
Looks like it's just adding anywhere from -8 to 8
No clue why it's written that way, but it is
Ah, realistically I guess only the x,z range matters as a param since it's range
player.getLocation().getX() + ThreadLocalRandom.curent().nextInt(-8, 9) would be equivalent
Not too many params then
boolean safeTeleport(x, z, flag) & boolean randomTeleport(int retries, xRange, zRange, flag)
I guess?
The x/z aren't ranges, they're target x/z positions
The "randomness" of the teleporation isn't really random, which is weird lol
It's more like teleportHighest(x, z)
The randomness comes from the uses of randomTeleport, e.g. chorus fruit has
double d0 = entityliving.getX() + (entityliving.getRandom().nextDouble() - 0.5D) * 16.0D;
double d1 = MathHelper.clamp(entityliving.getY() + (double) (entityliving.getRandom().nextInt(16) - 8), (double) world.getMinBuildHeight(), (double) (world.getMinBuildHeight() + ((WorldServer) world).getLogicalHeight() - 1));
double d2 = entityliving.getZ() + (entityliving.getRandom().nextDouble() - 0.5D) * 16.0D;
if (entityliving.isPassenger()) {
entityliving.stopRiding();
}
Vec3D vec3d = entityliving.position();
if (entityliving.randomTeleport(d0, d1, d2, true)) {
See d0, d1, d2
Bukkit's randomTeleport just takes into account the actual randomness, safeTeleport just calls randomTeleport directly
EntityEnderman does something similar with its teleport and teleportTowards(Entity) methods, both of which calls teleport(double x, double y, double z), which in turn calls randomTeleport
So the bukkit api would have a correctly named safeTeleport(location, flag) and a proper randomTeleport method, which takes into account randomness like ItemChorusFruit & EntityEnderman
LivingEntity#randomTeleport is better named as safeTeleport, and thinking of it as such.
Where as ItemChorusFruit & EntityEnderman, again, actually implement proper randomness.
So we'd get a safeTeleport, due to this "randomTeleport" just making sure things are safe.
The randomTeleport comes in due to there actually being a use for random teleportation. See the many RTP plugins and commands, plus EntityEnderman & ItemChrousFruit
which would give us a total of
// Current
Entity#teleport(Entity)
Entity#teleport(Entity, PlayerTeleportEvent.TeleportCause)
Entity#teleport(Location)
Entity#teleport(Location, PlayerTeleportEvent.TeleportCause)
// New
Entity#safeTeleport(Location, flag) // Flag determines if teleport particles are used
Entity#randomTeleport(retries, xRange, yRange, flag) // Flag determines if teleport particles are used
plus extra methods for PlayerTeleportEvent.TeleportCause
looks like EntityCat also uses randomTeleport too in giveMorningGift, instead it has the flag set as false and calls it as so
RandomSource randomsource = this.cat.getRandom();
BlockPosition.MutableBlockPosition blockposition_mutableblockposition = new BlockPosition.MutableBlockPosition();
blockposition_mutableblockposition.set(this.cat.isLeashed() ? this.cat.getLeashHolder().blockPosition() : this.cat.blockPosition());
this.cat.randomTeleport((double) (blockposition_mutableblockposition.getX() + randomsource.nextInt(11) - 5), (double) (blockposition_mutableblockposition.getY() + randomsource.nextInt(5) - 2), (double) (blockposition_mutableblockposition.getZ() + randomsource.nextInt(11) - 5), false);
I believe we'd really only care about how EntityEnderman & ItemChorusFruit use it though
Also I looked at EntityEffect, it could be improved still
WOLF_SMOKE & CAT_TAME_FAIL are the same. Should just be TAME_FAIL
WOLF_HEARTS & CAT_TAME_SUCCESS are the same. Should just be TAME_SUCCESS
They both use Smoke & Heart
As does the Horse,
Yea, I know. Surprised who ever implemented it didn't do it in a more sane way
Could be to do with sounds though. Don't know if either play sounds
Nope. Taming is always Heart or Smoke
Or, actually, I'd bet you it's because at one point cats were ocelots, which weren't tameable entities
Don't see any sound calls
Then cats became their own tameable entities so it handled the event
Yea, instead ocelots have Heart & Smoke trusting effects lol
Note, that ocelots aren't supported in EntityEffects nor are horses kek
This is also why I did particles the way I did kek
No duplicates and it still gives the right values & stuff lmao
Seems like EntityEffect is missing the allay hearts as well
Current entity effects @worldly ingot
Snowball -> Snowball or a specified item stack byte: 3
Egg -> egg particle byte: 3
tipped arrow -> RGB'd effect byte: 0
Villager:
HEART byte: 12
ANGRY_VILLAGER byte: 13
HAPPY_VILLAGER byte: 14
SPLASH byte: 42
Witch:
WITCH byte: 15
EntityTameableAnimal:
HEART tame success byte: 7
SMOKE tame fail byte: 6
EntityLiving:
PORTAL byte: 46
Entity:
HONEY_SLIDE byte:53
EntityHorseAbstract
HEART tame success byte: 7
SMOKE tame fail byte: 6
Ocelot:
HEART trusting byte: 41
SMOKE not trusting byte: 40
Fox:
item particle byte: 45
Dolphin:
HAPPY_VILLAGER byte: 38
EntityAnimal:
HEART byte: 18
Allay:
HEART byte: 18
Some do play sounds, but I need to double check if they're client-sided or not
The sounds would be
but those all have constants in EntityEffect
You'd have to look at source to see which constants match up with which id
Yea, checking handleEntityEvent, which is how I got the above updated list
Right but I mean EntityEffect in Bukkit
It's just an enum, the effect ids are in the constructor
You'd have to track the time of the last attack each mob performed then compare that to whatever you want your cooldown to be, and cancel it if they try to attack while on cooldown
Or alternatively just set player no damage ticks if you only care about zombies attacking players
I'd guess that some are still missing, considering even EntityEffects is outdated by its standards lol
I think it's up to date
At least according to the protocol it is
The names are a bit dated though
Yea, exactly. The names are fucked
Oh wait you said decrease
Nothing for horses, allays, ocelots, etc
That's why I said this lol
So yeah this would work with multiple zombies if you wanted the player to take damage more frequently but you can't directly make a zombie attack faster
The EntityEffect system could probably be overhauled in general to have less duplicates, considering effects are reused outside of different bytes
Deprecate the aforementioned effects, replace with TAME_SUCCESS & TAME_FAILURE and you replace those too and cover EntityTameableAnimal and EntityHorseAbstract. If you make it just SUCCESS & FAILURE, then you cover Ocelot taming too
Wait, no. Different bytes for those. Impossible with the current system.
No idea why they're 40 & 41, instead of 6 & 7 like the other two
EntityEffect is dumb
why
what does EntityEffect abstract out anyway
like, are these constants backed by a registry or something?
Or is it just defined in the craftbukkit impl
They're just magic numbers. Not registry based
It's dumb because it duplicates things for no reason lmao
EntityEffect abstracts out https://wiki.vg/Protocol#Entity_Event and Effect abstracts out https://wiki.vg/Protocol#World_Event
WOLF_SMOKE
The smoke when taming an entity fails.
This is incorrectly named.
CAT_TAME_FAIL
Cat taming failed.
CAT_TAME_SUCCESS
Cat taming succeeded.
These are useless and very specific, where's HORSE_TAME_FAIL & HORSE_TAME_SUCCESS with this naming?
guys how can i parse all placeholders?
(i know PlaceholderAPI.setPlaceholders())
example:
%luckperms_prefix% output is %img_owner%
how can i parse?
They were accurate for the time, but those status definitions change all the time
Yes, and they need updated to match kek
It's just not really worth it most of the time
Unless it gets registry backed and needs to match a key
But right now it doesn't :p
It's an easy fix though?
Deprecate WOLF_SMOKE, CAT_TAME_FAIL, CAT_TAME_SUCCESS.
Add TAME_SUCCESS, TAME_FAIL. They all use 6 & 7
One of the places mojank still uses magic values
Not the first time something is deprecated within EntityEffect. See DEATH, and SHEEP_EAT for one's that got split and HURT for something that got replaced with a method
:(((
Could probably replace it with something better, but that requires maintaining lol
You'd still need magic numbers, but the rest would be registry based or whatever
it really needs to not be an enum cause enums suck
no u
magic values are not always terrible. Not like you can always escape them
why do enums suck? first time I'm hearing this
enums don't always suck, but the Bukkit API used them in SO many places they shouldn't have. You don't get generics, you can't have "custom" ones (see Biome), can't have server implementations so its harder to add API surrounding them
or rather, them being enums at the start is fine. Pretty sure even vanilla used enums way back then, but they should've done the ItemType/BlockType to Material a long time ago
Makes sense to have an enum for hands, for example.
Biomes would be better as a registry which allows custom biomes
Alas, I doubt custom biomes are happening anytime soon if ever
DayOfWeek is an enum
Ain't no way we're getting a Gregorian Calendar 2.0 update to add a new week day
wait then how does something like Terralith (datapack) have custom biome names
Lol
datapack, different than bukkit
datapacks are vanilla code, not bukkit
You can't do it in the api?
Nooooope
Datapacks having more ablities than the bukkit api is concerning
Fr how did this happen
Bukkit's old as hell
Sounds like we want a whole rewrite of bukkit
Well I guess one thing datapacks don't have is basic fucking math
ehh they do to some degree
datapacks, however, are newer so properly support stuff
rewrite in rust
Idk if I'd ever put enums in my front facing api even if minecraft defines them as an enum
Ok do sin and cos in a datapack
that's not basic math sir
and it should be possible in theory
we have enough people here that if md wanted to do a rewrite we could probably have one done in a few days
And the whole scoreboard system for storing shit sounds miserable
realistically 1.13 should have seen major rewrites, but weren't added due to backwards compatability
then call md, we need a new bukkit api
I would be in favor of a rewrite
Fuck backwards compat
rewrite in rust
no
e.g. items and how they're handled
sethbling
Handle my audio input in rust
he made a physic engine in datapacks
I wrote a 3D rigid body physics engine datapack for Minecraft 1.20, and I'm also releasing the CBScript compiler that I used to make it.
Datapack: https://sethbling.s3.us-west-2.amazonaws.com/Downloads/DataPacks/physics_sandbox.zip
CBScript Code: https://github.com/SethBling/cbscript
Mysticat's "Fake Mobile Game": https://www.youtube.com/watch?v...
Sethbling is not just "one guy" he is a god among men
real
Dudes brain just built different
We don't need a rewrite it's more of a needing to cut the fat. Stop dreaming about 1.8-1.21 support
he made his own datapack language
not sure what you are on about on that last bit?
That's what I'm saying
I hate old versions
but yes the spigot api/server needs a rewrite
The people still a decade in the past need 1.8 support for whatever reason
Quite literally a decade
Fuck them
They aren't relevant
I'm kinda just meaning the API would beable to actually make good changes if there was a sensible deprecation schedule
would have been a good time to rewrite a lot of things, really
we still have the Legacy material stuff e.g. LEGACY_REDSTONE_BLOCK etc
yeah, a lot of that stuff can be removed
Sounds ass
however, implementation needs some rewriting too though
What's the difference between a redstone block and a legacy one
fuck you
banned
😔
One is modern, one is 1.8
That can be done over time, again with a sensible deprecation schedule no rewrite is really needed as you could phase these changes in over time
But how are they even different
one sucks, one is spigot 😎
hell I'm working on a rewrite of the entire Bukkit#createInventory system right now
if you want to do it the hard way sure
but rewriting it would be far better
That requires md actually adding that lol
99% of the API is create & forget
I'm very much pro API supporting multi-version compatibility, but idk if I think it should extrapolate so far
I think its a good thing that could be taken to an extreme
still better than Windows
It should have dropped compat on 1.13, making 1.13 the earliest supported version
can't even name a fuckin file con
I agree
you can
Why would you name a file con
I mean we could still by dropping all the legacy material stuff etc make plugins figure it out themselves if they want it so bad
md won't lol
idk watch the Tom Scott video
I miss him :(
I have, I have watched quite a few videos about con
I see no reason to name your file con
meh idk about the defeatest attitude either I think its worth a conversation tbh.
an actual constructive one at that
Lmao
Fair. 1.13 would still have been the best cut off point.
Legacy (EOL except for security issues) < 1.13
Modern 1.13 >
tbh I think the best deprecation schedule is 3-5 major versions I feel like that's beyond fair.
true, I think if you really love cross-version compat as we all know plugin devs do, I think 5 version cut-off is super fair tho
I mean at 1.21 that puts us back to 1.17
ofc but 1.13 would have been the best compromise, drop everything legacy & don't remove anything after
yeah true if there were to be a compromise 1.13 would be it
1.8 is getting too old
plus their are already a ton of 1.8.8 forks too
I would
I wouldn't ever. Because its easier to mutate and change Interfaces
enums are much more rigid
Bukkit API should probably be close to 95% interfaces
and 0% of that should be enums just imho
yeah, same, but for some things it's nicer, i.e. plugin state can only be LOADED, ENABLED, DISABLED, UNLOADED
it can't be something else
that's not really representing a minecraft value though
that's a spigot value
Yeah, but that was my first example
what about directions
no minecraft value should be represented as an enum even if its an enum internally imho
Player equipment slots?
Exactly. Could have dropped a lot of the old API. Bad ItemStack impl, Bad Biome impl, Bad Material impl etc, etc
Replaced it with better & more modern code which made the best use out of 1.13 code
I think its very possible for their to be more equipment slots or for those to eventually go data driven
I'd say it could be a okay enum, but not perfect
Well fair enough
Is ItemStack really that bad
Yea, certain things aren't possible with how it's currently done
Doesn't paper have their own item stack impl or something
yes
no clue, IIRC lynx said they got rid of Bukkit's ItemStack, which is a good move, and something I eventually want to implement
like setting entities to a specific spawn egg, e.g. a villager with custom trades
it supports breaking changes without needing to do weird hacks :P
(i.e. the API can have huge breaking changes and old plugins will still work, because of how the API is managed)
You gotta use NBT & NMS directly for this KEK
ItemMeta could really use a rewrite, but that is a tall task
or you handle the relevant event, which is 🤢
Why handle it when you can just let vanilla do it for you lmao
in the world of plugins it really is something that should be avoided especially since plugins are built upon the idea of Mutli version compat
mods are better anyway
its the reason of having an API in the first place otherwise all you need is a thin NMS wrapper
I very much disagree, they may be more powerful but also its a ton more work
mods, but with plugin stability, would go so hard (not foreshadowing)
its the trade offs
Why? You shouldn't. You'll likely miss out on stuff vanilla Minecraft does with spawn eggs, unless you crawl through the NMS and 1:1 copy it lmao
Exactly my idea
Bukkit always holds my hand
I really don't like that
I don't want everyone to use it, I just want a good and reliable system for my projects, if others want to use it, be my guest
Excuse me the api can absolutely do this now
Smh
Yea, little reason to use it when forge & fabric are already huge lol
that's kinda the point...
yup
its supposed to be easy and user friendly
I might get beaten for saying this, but
I like forge
nah you're good
there are options out there for those who rather blow their foot off
And how so?
SpawnEggMeta's just an EntityType
EntityType != Entity
setSpawnedEntity
Yes, entity type
No
Building your own API is fun
?jd-s
how about you just manually track the entity and send the packets for it, huh? you priviledged kids
Oh, that's new
declaration: package: org.bukkit.inventory.meta, interface: SpawnEggMeta
yes very new
when tf did that get added?
praise be to coll
Some time 1.20 iirc
like 1.20 iirc
that is WILD
It’s usable with spawners too
thank you whoever added that
:3
plus
mixins
I had to do something like that arounddddd 6 months before 1.20 dropped, but thank you nonetheless
lmfao I complained about that repeatedly ages ago and completely forgot about it
Didn't realize something FINALLY got implemented KEK
Imagine: Mixins that can be uninjected if the mod unloads
Why are you unloading mods
I get left doing the thankless jobs 😭 I spend all this time working on and shilling the great Inventory PR and I get 0 love, Coll writes some useless entity thing and all of a sudden everyone loves him
Because I found a safe way to do so?
Is your PR added yet? No
still don't
Go back in your hole and finish it
like 2/5 of it
I gotta take baby steps cuz its so big
I allow you to, because it's safe, I don't allow you to because you should
5/5 is deprecating everything 😄 I genuinely can't wait
@young knoll Make entity snapshot serializable
How do I make fullbright for all players without night vision
override the packets for light levels
you don't
You do, rad
legit got a PR for doing that rn 🥲
you are just skill issued
shaders 🧌
Is there a straight forward way without packets
my lord and savior
idk if MD will ever accept that though
Nope! Have fun!
Sad
because I don't think he likes Bytes
true I forgor that was a thing
Yeah should probably make it SNBT serializable at some point
@rough drift give us back spout fr fr
you know what'd be cool... ByteSerializable
just sayin
Spout?
Both are good
What's that
Does anyone know how i fix this error: java.lang.NoSuchMethodError: 'net.minecraft.server.level.ServerPlayer org.bukkit.craftbukkit.v1_21_R1.entity.CraftPlayer.getHandle()'
you aren't remapping
remap your plugin
?nms
it is: <dependencies> <!--This adds the Spigot API artifact to the build --> <dependency> <groupId>org.spigotmc</groupId> <artifactId>spigot</artifactId> <version>1.21.1-R0.1-SNAPSHOT</version> <classifier>remapped-mojang</classifier> <scope>provided</scope> </dependency> </dependencies>
Server <-> Client modding.
basic ```It allows a complete join between the client and the server.
So that if someone makes a plugin and requires the client to have a certain mod, spout will automatically install the mod to the client. ```
$100 on you not using the maven plugin
uhm
Oh! Yeah that already works with mine
oops xD
kinda
wheres my 100
ike
pay up bucko
xD
It lets the server do things such as client side keybindings, client side rendering and better registry sync
it's neat-o
Spout does waaaay more than just those lol
10 years ago
Well, yes, but the client should run no untrusted code
nice website
Sounds like a skill issue in regards to security on your end
Yeah letting the server just send an entire mod to the client is big yikes
just get good
very 🧌
It makes more sense to have an existing client mod that enables the server to add custom functionality
Yep
Spout allowed for things like https://web.archive.org/web/20140630045851/http://spoutcraft.org/resources/morematerials.3/
note that it's a plugin
Basically how the bedrock client works
That is exactly how my thing works
I will open source it by the end of the year under two conditions:
- I either get meds
- or I manage to willpower through my head
Is it called CabernetMC
also had entire minigames https://web.archive.org/web/20140630174637/http://spoutcraft.org/resources/zarena.39/
Yeah, mine is more of a full overhaul of the Spigot API with the ability to do that asw
I fucking love it but it's not ready yet
It wouldn’t be that hard to implement a lot more customization into the client
Would be much nicer if you could do it directly though, saves a lot of mixin fuckery
there was a wip spout forge version actually
@microsoft I’ll buy minecraft off you for $7
iirc the repo correctly anyways
Yeah, it isn't actually
Does it support custom blocks yet
Not really? I am not working on that RN
I am working on other stuff before blocks/items/entities/etc
polymer for helix when
I'll probs add that sometime late October, at least items
interesting
there are a few parts
Items actually seem super easy
they are
What base data does an item even have that you’d have to sync
helix-experimental-api (main API for helix)
helix-experimental-loader (loads helix and plugins, doesn't load as plugin/mod)
helix-experimental-translator (server only using helix)
helix-experimental-connector (client <-> server both using helix)
then there's
helix-spigot-loader
helix-fabric-loader
helix-forge-loader
etc
also Ike I'm still interested to see how you're gonna make your rendering api because the way you want it is very likely not possible lmao
Yep dw I'll try to get it done quickly
because you'd have to have a set of predefined fonts / shaders for vertical offsets
I actually can’t think of any, it’s all controlled by item components now
if you're planning to do the whole thing with shaders you'd need a fuckton generated at server load
Kind of, when I was working at yora they'd made some fuckery to do dynamic positioning of stuff on the screen
which I'm very impressed by
If you have a custom client mod you don’t need any of that tho
You can just draw text wherever you want
The client mod is optional
I see
You can join a helix-powered server (Platform of choice + Helix) and it'll work for 99%
that 1% is keybinds and the likes
Brawls also just has a predefined set of vertical shifts, with steps of 0.5f. Now if you want to support custom fonts, you'd also have to do that for every single custom font which will get a lot quickly. Especially with bitmaps, you'll have fun
Yep, I'll see to implement it manually soon so I can show you how it works
Hey how can i change the skin for the player itself? for others the skin got changed
We pretty much just ```kt
val PINCH = registerChevyFont("pinch")
val PINCH_OFFSETS = OffsetFontProviderManager(PINCH, ::registerOffsetChevyFont, -35, 16)
val PINCH_OFFSET_NEGATIVE_88_5 = registerOffsetChevyFont(PINCH, -88.5f)
and then have that generate a fuckton of fonts. Previously it was in steps of 0.02f :concern:
We used to have ~250 fonts
of just offset variants
So yeah, either you have a 1mb shader or some shit or 1mb of font json files
there really isn't a good way to do this
We are currently at 137 font offsets. We have two fonts that we use...
Trust me for I shall cook
mhm
oh yea, how the fuck do I show the credits and/or loading screen(s)?
I know it's a Game Event event packet for credits w/
4 Win game 0: Just respawn player.
1: Roll the credits and respawn player.
Note that 1 is only sent by notchian server when player has not yet achieved advancement "The end?", else 0 is sent.
but iirc that didn't work, but I could have just fucked it up somehow
Send a packet to that player
Also with shaders you just eliminate cross version compatibility as a whole
would it work for cracked player too?
so yeah, they're fun
offline mode is not supported
Probably not question mark
who knows offlinemode ain't supported brother
Online mode? Offline mode? How about a Clothesline mode!
how about Coll pay me 1000 mode
It should just be this.player.connection.send(new PacketPlayOutGameStateChange(PacketPlayOutGameStateChange.WIN_GAME, 1));
I think? idfk
Minecraft
end screen
Duh
I never believed in the notion that defeating enderdragon is the end of the game psh
Unless the client just straight up rejects it unless something's set, which is a possibility
Used like this though. Like, it should work lmfao
if (!this.wonGame) {
this.wonGame = true;
this.connection.send(new PacketPlayOutGameStateChange(PacketPlayOutGameStateChange.WIN_GAME, this.seenCredits ? 0.0F : 1.0F));
this.seenCredits = true;
}
It should work is the story of my life
The end of the game is +- 30 million blocks
Unless it requires wonGame to be set, but I doubt that
Could just be behind a proxy
in which case bungee handles everything
I give it a 0% that that's the csae
Oh fair
there is a big difference between I'm using offline mode and I'm behind a proxy
those who actually use bungeecord will likely say I'm using bungeecord will it still work? Instead of I'm supporting cracked or I'm using offline mode
seems like it might just be getSeed or something
declaration: package: org.bukkit.generator, interface: WorldInfo
They're using NMS
and?
doesn't mean the api can't be used
not sure why people think they can only use one or the other and not both at the same time o.O
They specifically are using everything via NMS.
@rugged fern You want the WorldServer, you'd then use getSeed on that
WorldServer isnt existing in remapped
yea, you'll have to figure out the equivalent
1.21.1 has it as ServerLevel, for example
CraftPlayer craftPlayer = (CraftPlayer) player;
ServerPlayer nmsPlayer = craftPlayer.getHandle();
ServerGamePacketListenerImpl connection = nmsPlayer.connection;
ClientboundPlayerInfoRemovePacket removePacket = new ClientboundPlayerInfoRemovePacket(Collections.singletonList(nmsPlayer.getUUID()));
ClientboundPlayerInfoUpdatePacket addPacket = new ClientboundPlayerInfoUpdatePacket(ClientboundPlayerInfoUpdatePacket.Action.ADD_PLAYER, nmsPlayer);
for(Player online : Bukkit.getOnlinePlayers()) {
CraftPlayer onlineCraftPlayer = (CraftPlayer) online;
((CraftPlayer) online).getHandle().connection.send(removePacket);
((CraftPlayer) online).getHandle().connection.send(addPacket);
}
Holder<DimensionType> dimensionTypeHolder = nmsPlayer.level().dimensionTypeRegistration();
ResourceKey<Level> dimension = nmsPlayer.level().dimension();
long seed = player.getWorld().getSeed();
GameType gameMode = nmsPlayer.gameMode.getGameModeForPlayer();
GameType previousGameMode = nmsPlayer.gameMode.getPreviousGameModeForPlayer();
Optional<GlobalPos> spawnPos = Optional.empty();
int portalCooldown = 1;
// Create the CommonPlayerSpawnInfo object
CommonPlayerSpawnInfo spawnInfo = new CommonPlayerSpawnInfo(
dimensionTypeHolder, // DimensionType Holder
dimension, // Level ResourceKey
seed, // World Seed
gameMode, // Current GameMode
previousGameMode, // Previous GameMode (nullable)
false, // Is debug world
false, // Is flat world
spawnPos, // Optional GlobalPos for spawn location
portalCooldown // Portal cooldown
);
connection.send(new ClientboundRespawnPacket(spawnInfo, (byte) 1));
player.teleport(player.getLocation());
}``` im trying to do it like this but now there is a error? because the skin is black
Why are you "refreshing" the player
for letting myself see the skin too
but now its just black
for other it is the skin i chose
Are you just changing the player's skin
Because I'm like 99% sure there is a method for that in Spigot
to update the player?
Yes just changing the signature and texture of the skin
of the player* in order to change the skin
Give me a second, let me look for it
declaration: package: org.bukkit.profile, interface: PlayerProfile
i hide and show the player for all online players to update the skin for them and thats works fine but only for myself its the same skin as before or its turning black
setTextures to be exact
You can also use https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/OfflinePlayer.html#getPlayerProfile() to get the player's profile
declaration: package: org.bukkit, interface: OfflinePlayer
im confused haha
i actually have this for changing the skin: ``` public static void applySkin(Player player, String value, String signature) {
CraftPlayer craftPlayer = (CraftPlayer) player;
ServerPlayer nmsPlayer = craftPlayer.getHandle();
GameProfile profile = nmsPlayer.getGameProfile();
profile.getProperties().removeAll("textures");
profile.getProperties().put("textures", new Property("textures", value, signature));
for(Player online : Bukkit.getOnlinePlayers()) {
online.hidePlayer(Main.getInstance(), player);
online.showPlayer(Main.getInstance(), player);
}
refreshPlayer(player);
}```
You gotta do something similar to this
Player player = ...;
player.getPlayerProfile().setTextures(...);```
send a respawn packet to yourself to refresh your own skin
will it update automatically?
Idk, try
Yeah but this isnt working it just turning the skin black or to a random default skin
alr
Hey,
How can I get the world Item when a dispenser dispenses?
BlockDispenseEvent gives the ItemStack.
ItemSpawnEvent gives Item, but i dont know if it was a dispenser that made it? getThrower returns an entity UUID, not a block -- and there is no "SpawnReason" or similar it seems
declaration: package: org.bukkit.event.block, class: BlockDispenseEvent
oh you right
there isn't
unfortunately it doesn't work for player skins actually setting a player skin is way more involved
you have to send extra packets etc and iirc its very volatile and glitchy too, I can't see it really being great API
Perhaps I need to listen to EntitySpawnEvent and check its instanceof Item
hmm, EntitySpawnEvent seems similar to ItemSpawnEvent in that it doesnt have a method to get a spawn reason
Any MC java devs able to assist me real quick? Needing some help on figuring out how to impimplement liment something and my brain is fried after trying multiple things... Need to make it so a plugin can detect if a player is flying on an elytra and if they press space bar something happens... I just cannot detect the spacebar! I've tried protocollib, invisable entities, everything haha
well no you can't just detect them pressing the spacebar
that's not even possible, you can detect the actions that occur from pressing it e.g. gliding or jumping, but just pressing the spacebar isn't possible to detect
Yeah thought so, that's why I was trying a work around with invisible entities
Just wasn't sure if there was something I was missing or if someone knew a workaround type of thing
My logic was if while the player was gliding they would be controlling an invisible entity and the entity could detect a space bar or something
...can you even be gliding while controlling a horse or something?
with the recent 1.21 developments you might be able to listen directly to movement keys
WASD at least i've heard are possible
thats always been possible to some extent using velocity while riding an entity
Yeah I was hoping to just listen direct to the keys, but I couldn't get it working, the entity thing was a random thought but nothing was working
I was just hoping someone here just figure out a way to detect a space bar input while gliding
why specifically space bar?
Essentially I want to make it so if a player is gliding with an elytra, holding the space bar will increase their velocity
Space bar just makes most sense
I could do an item in the inventory but that's boring haha
you mean like a firework rocket? xD
Yes, however, without the firework being in someone's hand haha
Essentially my game glitched recently and my elytra just went upwards when holding space and it was fun, I was trying to recreate it haha
you should make a thing where you have an ability that does the riptide animation and while its doing that you reflect projectiles or some shit
make dogfighting
Still doesn't defeat the fact I need to somehow detect input
yeah but it'd be cool af
I legit spent 4 hours earlier trying every possible way haha
is it just a fun side project or does it have to be a plugin?
if you dont care about vanilla then try modding its pretty fun as well
Doesn't have to be a plugin, plugins are just something I know haha
Anyone have any thoughts on this? Im at a loss.
Seems like a bizarre thing to not have an event/method for retrieving the item
I think the thrower would be the dispenser blockentity
so you might be able to check it that way
but idk
blockentity?
well yeah
the dispenser itself
but
idk if you can even do something with that information
because thats still not the item
so there is probably no way
its probably called before the item gets created
the dispense event
I dont think Dispensers, or TileEntities for that matter have UUIDs I can compare against in the ItemSpawnEvent as far as im aware
you could try putting a flag in the ItemStacks PDC in the dispense event and check for that flag in the spawn event
Ah, thats a great idea, as i can get the ItemStack from the Item 👌
il give that a go, thank you, but id guess the caveat then would be; dispensed items would no longer stack with non-dispensed I assume
correct, but you can always remove the flag on spawn
good one
hmm annoyingly it seems the two events might happen in the same tick.
numbers being System.currentTimeMillis()
i guess not, with adding a delay before checking the PDC for the flag. which im now doing to be safe.
but im not finding my key on the itemstack it appears.
i must be adding it wrong
You shouldn’t need a delay
https://paste.md-5.net/olaginaqeb.java
Am I at least adding the flag to the PDC correctly?
No
You should be adding it with the ItemMeta instance you have
Since each call to getItemMeta returns a new copy
oh, of course. thats silly of me. 1 mo il retry
Hmm still not setting the PDC correctly it seems,
am I doing anything else wrong now?
https://paste.md-5.net/polenebibu.java
Ah I see
in teh dispense event just call setItem at the end
Yeah, sorry. tis late and my brain is running 5 seconds behind my eyes 😄
and yes no need for any delay, just remove the pdc entry in the spawn event
Sweet, all working.
id also forgotten to set the meta back after removing the pdc entry in itemspawnevent. sorted now 👌 and all working as needed.
thanks all for the suggestions and assistance ❤️
how do i get rid of the stupid server 3 second invincibility when the player respawns
I'm using eclipse and Maven, I wrote a pretty simple plugin last month
I made a small change to it but the build now isn't including the .yml file for some reason
how do I force maven to include the .yml when I compile the .jar?
As long as it's in the src/main/resources directory, it should go with the jar when you mvn clean package
I've added it to like every directory now, it still won't add it to the jar : /
is there like a command I need in the build config?
Or is there up-to-date documentation I can use to remake the project?
I gave up and just used winrar to add it manually
just going to make a note in my documentation to do that from now on
What does your pom look like?
Anyone give me deluxe hub plugin latest plz
progress
mods ban this guy
^
bro ain't deluxe hubs free wtf
https://www.spigotmc.org/resources/deluxehub-3-professional-hub-management.49425/
download it yourself
fr bruh what is this dude even asking for
I feel like its either a bot or someone who shouldn't be running a server
imo its both
🤔 smart enough to script bots but too stupid to download a free plugin
interesting proposal
I'm sure such inviduals unfortunately exist
@blazing ocean 5eid here!
He’s asking for the latest, because deluxehub doesn’t support 1.21, but they offer dev builds of it that do
ok
Guys, I have vault and luckperms installed, and when I do /lp user username info, it shows the prefix and the suffix, however, when I get them through my plugin it doesnt work for some reason. Anyone know why?
?nocode
It’s hard to answer a programming question without code
Oh no! You ran into a problem. But no worries, people are willing to help, but first they need to see your code. This is because otherwise, they would be providing help based on guesses instead of concrete knowledge. Whether it be a compile error, runtime error, or an unexpected output, I'm sure that if you were to provide code, you'd receive a quick solution.
Vault.getChat().getPlayerPrefix(player)
Fr
Do I need to get the prefix from getPermission
Bcuz vault has no chat setup
Without chat plugin
For some reason?
Valid
So luckperms doesnt serve as a chat plugin?
I've never used lp+vault
I know Vault detects a chat component when using GroupManager
it enables both permissions and chat
however there shoudl be no static getter for prefix
show actual code. Where did you get the ResourceProvider for chat?
Tbh its still doesnt work :/
On load
I can't help you anymore if you refuse to show ACTUAL code.
I dont have actual code rn
of course you do or you would not be having errors
Im on phone
Dont have code
don;t get ResourceProvider in onLoad only IN or after onEnable
THE IMPERIUM OF MANKIND
why so complicated
for not a source and then also a do not mirror or something
because if it was easy it'd be called your mom
If it were easy, I'd still be waiting for you to figure it out
good thing it was hard and I figured it out then
ah, so you do know how to handle hard things
man bring back imillusion at least when he makes fun of me it's not completely braindead
look okay this is like already over the top for me, I'm severely skill issued at insulting
or making fun of someone
actually no I can be pretty good at insulting someone, I am just very bad at then continuing it and replying
you're giving me brainrot just reading your replies so I'm just going to block you and try to get some braincells back
what 😭
you know I get that water's gotta come from somewhere, but it feels kinda odd seeing all these skyscrapers then just... wells
what did I do man
neat
everything is just placeholders, there's only one 4-way intersection module right now
I'm still just prototyping this to see what the full kit requirement will be
other than the wells being out of place it looks pretty cool
??
[ERROR] No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?
Does it mean exactly what and how do I fix this problem?
JRE = Java Runtime Environment. JDK = Java Development Kit
Guess which you need to do development work?
I have installed both
there is no 1.21
Then why is it in there?
It existed at one point
but it was superseded by 1.21.1
as there is no reason to use 1.21
Guys can you save a runnable into PDC 🤓
Wtf are you doing
Actually
I need a consumer
Fr
Right clickable items btw

