#help-development
1 messages · Page 34 of 1
If you're unsure how to navigate javadocs, feel free to ask
But they're really handy and can often answer a lot of your questions without needing to ask a person
Using old libs means using no longer maintained libs most of the time
Not sure if it's a good idea (mainly for security)
It really depends
Sometimes the code solves a problem that never really changes
So it doesn't matter how old it is
I see
Unfortunately most problems aren't like that
They change over time in one way or another
Cause most of what a programmer does isn't in a vacuum, it's most often handling the interaction between two or more discrete systems
Alright 😂
Which are often their own projects that evolve and grow and change over time and whose tools will need maintenance
can someone come dm
Is there any doc about which mc version fits best with which java version? I can set sourceCompatibility
targetCompatibility from build.gradle.kts and IDK what should I set them to. Going to publish multiple jars for mc version 1.8-1.18
how do i use Plugin#saveDefaultConfig()
How can I avoid dropping specific items when a player dies?
Can I use an NMS ItemStack in a BukkitObjectOutputStream#writeObject?
what is the problem with that
thx it worked
do a clean setup and run it again
you mean maven clean or what
Hm? Just throw the lates BuildTools in an empty folder and run it.
ok
still the same
What does mvn -version show?
The command mvn is not found
Are you a dev?
yes but I dont work with maven since I only stuck to 1.8 so I added the jar manully but now I want to go to newer version where you need to run buildtools
Then properly install maven first
how do I block a pufferfish's idle animation?
did it still not working
bump
can't really figure out how to use the packet play out classes because mojang mapped doesn't deobfuscate those
Without renaming the player?
sorry but what do you mean renaming the player
Yes it does
I want to change the text above a player's head entirely
Chat, Tablist etc. Change the actual name of the player.
Then you need to hide it (with teams) and work with invisible named entities
is that the only way?
I heard its possible with packets
The packets will rename the player completely
7smile7 what do now?
oh
so do you reckon i teleport invisible armor stands wherever the player goes or something
try again
mount them
An entity can have multiple passengers on a single slot. (Unless you are using an old version)
do you mean as in
still the same error
having entities stacked on top of each other?
or you can literally have two entities on top of a player
No. In the same slot.
how would you do that?
also the Marker entity is a thing too, can I assign a custom name to that and mount it on a player or no?
This path looks scuffed C:\Users\Philipp\.m2/bin/mvn.cmd
some solutions online also say to rapidly teleport the armor stand to the player
is that a good idea
why, you were already given a decent solution
we gave you a solution
and you're actively seeking a different one
either you're in denial, or blind
I have an object that has a long "id" value in it. What's the best way of sorting the objects from least to greatest based on the "id" value if I don't necessarily know what the ids are.
Hm ok, I'll look into a comparator. Thank you very much 🙂
just asking for an opinion on the other
but also
how lmao
any mob can have infinite passengers then?
but would the name be positioned correctly?
i fixed all of that but now IntellJ cant find extends JavaPlugin
I found an image of someone using this approach online
and the text is too low
I mean
that looks like a baby armorstand
a taller one would be better
only problem I see with this approach is messing up your hitbox
same
it might also block arrows
https://hastebin.de/jomocifife.java
Would something like this work? InteliiJ recommends List#sort() instead of Collections#sort() What's the difference?
also i kinda want the name to be hidden to the player
Whats the approach if i wish to create something like this (example below) in my config.yml?
- Test:
- Test: 'test'``` ?
invisible to the player it's mounted on, but visible to everyone else
ConfigurationSections
Thanks
List#sort has a more consistent impl
on openjdk-18 they both do the same
Ah alright, thanks 🙂
I mean sure yours would work but I'm not sure how efficient it is for a linkedlist to sort, comparing to an arraylist for example
You'd need to change nodes a bunch
I'm not really making this for efficiency, it's only going to be run at most once an hour lol
Obviously doesn't hurt to make everything as efficient as possible but it seems like extra work that wouldn't make a huge difference
Bukkit.getPlayer() only returns a player if they're online, correct?
ye
How can I avoid dropping specific items when a player dies?
PlayerDeathEvent
get inventory contents and remove that item
event.getDrops().removeIf
Thanks to all
?paste
Okay so this is all my classes, just testing out
https://paste.md-5.net/ifiyodolon.java
Why is it that whenever i write "testing" in chat, nothing happens in my customConfig.yml
And also when creating the ConfigurationSection, does it always do String: {} ?
No error or anything in chat, not when the chatEvent is executed or when loading the plugin
that is a horrible approach at configging
And what would the better approach be ? :)
I'll look into that, but first, why does nothing happen with the customConfig.yml when i type "testing" ? Is it something with the code, and if yes, what ?
I mean you're creating an empty section
just tried it myself
It because I wanna set it up so it looks something like this
set("test.test.test", "test")
no need to create sections
How can I send a sound to all players online?
Bukkit#getOnlinePlayers#forEach
use a lambda expression
?paste
https://paste.md-5.net/ayunihajov.coffeescript I'm trying to cancel teammates from hitting eachother however for somereason this code only stops players from punching and shooting eachother as soon as they have an item in their hand they can deal damage to their teammates again
?
?learnjava
Here are some links to get you started on learning Java:
- https://www.codecademy.com/learn/learn-java
- https://www.sololearn.com/learning/1068
- https://www.learnjavaonline.org/
- https://programmingbydoing.com/
- https://docs.oracle.com/javase/tutorial/java/index.html
The last one is the only official one, however some of those concepts assume that you already know a bit about programming.
learn how to loop before coding spigot plugins
Ok thx
also I'd like to add I added debug statements and even if you hit the other player with a sword it reaches the debug
but then it allows the attack
hmm interesting Idea could this have to do with another event clashing?
what event are you using
it ended up being another event from another plugin clashing
I fixed hte issue by elevating event priority during that stage of the game
though in the future I need to work out a proper event staging. Which I'll end up discussing with another dev tommorow
How can I make String.join(" ", args) get all args except the first one?
Arrays.copyOfRange
args[1..] 😄 🦀
Can I get how many blocks are within a boundingbox
Yes. Clip the edges and then x * y * z.
If you want to filter blocks by type then you can do something like this
public static void forEachBlock(final BoundingBox box, final World world, final Consumer<Block> blockConsumer) {
for (int x = (int) box.getMinX(); x <= (int) box.getMaxX() - 1; x++) {
for (int y = (int) box.getMinY(); y <= (int) box.getMaxY() - 1; y++) {
for (int z = (int) box.getMinZ(); z <= (int) box.getMaxZ() - 1; z++) {
blockConsumer.accept(world.getBlockAt(x, y, z));
}
}
}
}
Thank you, this helps
so I'm trying to build modified spigot 1.10.2 but I'm getting errors such as ```
TimedRegisteredListener.java:[35] System cannot be resolved
Is this because I'm using the wrong java version? My java home is java 17
XD why would you ever want to play on 1.10?
And why do you need to build against 1.10 then?
to find out where the bug is
I have no idea why it happens so I'm trying to find why it occurs
the bug is tnt being knockback happening through walls and ignoring distance between entities
Anyways your bug comes from java not being properly enabled for your project.
Set a java version for your project.
how do I do that?
What ide are you using?
File -> Project Structure -> Project
Then select SDK
I need to download an even older version I guess
And make sure maven also has the same jdk version
What? No. How do you compile?
mvn clean install
<maven.compiler.source>1.6</maven.compiler.source>
<maven.compiler.target>1.6</maven.compiler.target>```
in the pom.xml
your project version is 1.8 versus the maven compiler source of 1.6
you could also try to compile against 1.8 instead of 1.6
how might I disable the version check for bungeecord server switching?
change the compiler source and target
(I have viaversion installed but Bungeecord will only accept native version)
wait I'm curious to know if you need the 1.8/1,6 jdk's to compile to it
properly install the plugin and make sure its enabled. Look at their plugin page.
I'm not sure how that works exactly
ok I'm convinced it somehow still isn't using java 1.6
oh come on
now I can't change my default java version back
Can you get a chat color from rgb?
Color.fromRGB(0xFFFFFF);
Does Color (Color object, not ChatColor object) work in chat messages?
hi, how can i create a license system?
You don't
You can make it difficult to remove but in doing so you'll spend more time on the license system then actually working on the code
It’s still trivial to remove
It’s Java
ok
Basically, you host the code on another platform and during runtime you download and generate all the classes required.
And the files thus exist on the local machine and can be dumped
Java is still Java
No, they don't, only in memory

So it's a lot more work
The memory is totally accessible and can be dumped to a file
oh
This
Yeah, but that's a lot more work then having a jar
ChatColor rgbFromAwt = ChatColor.of(new Color(0xFFFFFF));
BaseComponent[] coloredText = new ComponentBuilder().append("Some Text").color(rgbFromAwt).create();
Also
I'm not saying it's a great solution, just that's what professional licensed projects do
That isn’t gonna work nicely for spigot lol
Not much. There are already programs for this
Professionally licensed software is usually written in a language that’s more difficult to modify
And it still gets cracked regularly
True, but with a java lib I tried to use they pulled the API-for-files nonsense
It makes it a lot harder to modify
if i work a lot of time on the license system i add a lot of difficult to break it
right?
No. More work != more security
Not really lol
Then, due to an oversight, it's cracked in 10m.
As much time as you spend on it, someone will crack it in an afternoon
You don't want to spend 100 hours to make something that takes 1h to bypass
Also, if you’re planning on releasing this on spigot, you’re not allowed to include a licensing system anyway
So no point
You can use one of the obfuscators that break decompilers. I wouldnt go beyond that.
ok
pretty sure that’s not allowed by spigot either
I don’t have the of() function.
What version are you on?
1.17.1.
😘
Do you even have something that is worth cracking?
I would just only give support for customers.
ok, ty for help me
Anyways?
🤷 I just have the latest version on hand
1.17 doesn't have ChatColor.Of()?
Did you use the right ChatColor import
Use the md5 bungee one not the bukkit import
Resolved.
stares at my premium plugin that has been sitting for 4 months with 0 purchases
If I have a domain that basically redirects to another domain, can I get the domain that is actually inputted when logging into the server, and not the domain that is being redirected to?
if its a redirect, no
for what usecase anyway?
It has 1!
How to fix?
[07:36:53 ERROR]: Error occurred while enabling NetFFA v1.0-SNAPSHOT (Is it up to date?)
java.lang.NullPointerException: Cannot invoke "org.bukkit.command.PluginCommand.setExecutor(org.bukkit.command.CommandExecutor)" because the return value of "netffa.netffa.NetFFA.getCommand(String)" is null
at netffa.netffa.NetFFA.onEnable(NetFFA.java:28) ~[NetFFA-1.0-SNAPSHOT.jar:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:264) ~[paper-api-1.19.1-R0.1-SNAPSHOT.jar:?]
at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:370) ~[paper-api-1.19.1-R0.1-SNAPSHOT.jar:?]
at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:542) ~[paper-api-1.19.1-R0.1-SNAPSHOT.jar:?]
at org.bukkit.craftbukkit.v1_19_R1.CraftServer.enablePlugin(CraftServer.java:563) ~[paper-1.19.1.jar:git-Paper-94]
at org.bukkit.craftbukkit.v1_19_R1.CraftServer.enablePlugins(CraftServer.java:477) ~[paper-1.19.1.jar:git-Paper-94]
at net.minecraft.server.MinecraftServer.loadWorld0(MinecraftServer.java:636) ~[paper-1.19.1.jar:git-Paper-94]
at net.minecraft.server.MinecraftServer.loadLevel(MinecraftServer.java:422) ~[paper-1.19.1.jar:git-Paper-94]
at net.minecraft.server.dedicated.DedicatedServer.initServer(DedicatedServer.java:306) ~[paper-1.19.1.jar:git-Paper-94]
at net.minecraft.server.MinecraftServer.runServer(MinecraftServer.java:1124) ~[paper-1.19.1.jar:git-Paper-94]
at net.minecraft.server.MinecraftServer.lambda$spin$0(MinecraftServer.java:305) ~[paper-1.19.1.jar:git-Paper-94]
at java.lang.Thread.run(Thread.java:833) ~[?:?]
[07:36:53 INFO]: [NetFFA] Disabling NetFFA v1.0-SNAPSHOT```
Add the command to your plugin.yml
that was the spigot review team
Welp I'm stupid as shit
decided "hey look it's 6:40am imma go hit the gym early"
so I went to fill up my water bottle
family's all asleep
I dropped the half full bottle into the sink
hyy can anyone suggest me some claim plugins? (i used gp and towny)
woke up the entire family
Well played
pls...
Learn java and write one yourself 😄
Go there and ask
If you're here asking for server help
Or go to #help-server
you have a bigger chance at learning how to code the plugin you're looking for
than actually finding the plugin you're looking for
i will but idh 2-3 weeks in writing it 😦
you can code one in about 3 hours
Claim plugin in 3 hours???
if you abuse worldguard's api
I'm writing pets plugin in 6 months now
Yeah with the basics. Seems about right.
And i don't see the end
Its all a matter of features.
Or you're rewriting spigot itself type thing
I've only had one project that I "spent" 6 months on
and it was a client-side tutorial system
6 months for a single plugin. Ive done whole server setups with thousands of lines of code in that time.
but I also had little packet and nms experience
And we ended up having npc animations
Before this project i also didn't know that much about them
But thanks to it I learned thousands new things
So I'm taking my time more on learning
all are saying go to #help-server but no one replying there 😢
Than writing
Well that's because the people who can help you aren't available at the moment
You don't go to the fruit section of a supermarket to ask about laundry detergent type thing
They do
I mean you technically can but the employees will treat you as special
😅
Sorry to cut in but how do I create a config file?
I tried to find some docs but its no help
I have a nice keyboard with very short travel
ah
Google on new tab
I couldn't even read what he said and you already...

I can do about 130wpm comfortably on this keyboard
We need a bot where we can reply to someone with ?google and it'll auto create a search lol
Google your question before asking it:
https://www.google.com/
Yeah, but like it autofills the Search query with their exact question
Google your question before asking it:
https://www.google.com/
Would be cool
Maybe a command to recommend a common research pattern
I'm tired of seeing people ask the most repeated questions all the time
"help how do I make plugin"
Still waiting for ?npe
What's npe
I need one for when people wrap things with Objects.requiresNonNull
And complain it throws a NPE
oh god that's cringe
Ohh null pointer exception
Like intellisense is not intelligence
we should make a tutorial for like
something so ironic
just to see if people even have a train of thought
like a tutorial for async garbage collection
where's just a while(true) System.gc() on a new thread
Just to see if someone's capping
Wait you can do that
ClearLagg be like
I didn't realize you could call the GC
!!Logic.UNTRUE
And whenever some ignorant mf goes like "help how do I make tps go up" you just reply with that
"Just call the gc each tick"
Oh man I had an issue in my mod where the TPS was going sub zero with our tiles. That was cause we'd check the recipe every tick. 20k recipes checks a second per tile. 
or just send some code that goes like
new Thread(() -> {
while(true) {
Field tps = MinecraftServer.class.getDeclaredField("tps");
tps.setAccessible(true);
tps.set(Bukkit.getServer(), 144); // set tps to 144 (to match with 144hz screen, we dont want to waste performance)
System.gc(); // gc to clear ram
}
}).run();
lol
If you think about it. The TPS will drop but as long as it's above 20 you're good
last question: do anyone of you have a claim plugin which i can get?
Gotta make it or find it on the forums
Use someone's sketchy 5 year old 1.8.8 disaster that uses individual text files for claims
I need help lmao; for some reason my maven dependencies are not taking effect in my kotlin source code
the dependencies are there, and also shown in the sidebar, but no invalidation of cache or anything is fixing it
in source it's like they dont exist in path
maven + kotlin
Interesting choice
hol'up
yeah I should really change this to gradle shouldnt I
you wot m8
god fucking damnit
I'd go to the gym but I'm getting an ab workout right here
Try invalidating caches and restart first.
does anyone know how to migrate a maven project to gradle without the IDE causing any problems
nah it's not that, I've tried that several times
You can switch it pretty easily in intellij
How?
this should work right? String cmd = "kill %player%" cmd = cmd.replace("%player%", player.getName()); Bukkit.dispatchCommand(Bukkit.getServer().getConsoleSender(), cmd);
however I am not getting any output
Why would you want to do that? Just kill the player...
it was an example, not actually what I am doing..
didn't want to post a wall of text tbh
But yes this should work
Bukkit.dispatchCommand(Bukkit.getConsoleSender(), "command");
lol, so gradle has taken the liberty to turn main and test into submodules of the module, and not designate the kotlin folder as a source root
Don't execute commands for other plugins
just use their APIs
Official LiteBans API repo, wiki and issue tracker. https://ruany.gitlab.io/LiteBansAPI/
Lmao wtf
they have an API, but not a complete one xd
then they further go on to say execute database queries to get ban information
like what the fuck
How to spawn a respawn anchor block, light it up with glowstone, and make it explode as if interacted with, without any player touching it
Check its blockdata
im going to throw a tantrum
why is this not working
I have the implementations in my build script
and yet no dependencies are being recognized in my kotlin file
So i coded an item command plugin but it got some problems
Clients got some auto recipe fill thing where you for example click on beacon and it puts the recipes in the crafting
How to cancel that what event gets called
why do people even use litebans lol
can someone exaclty explain how to configure the config file
That is like asking
How to write a plugin
u know a config.yml file in the folders that creates when u start the plugin
?configs
See this wiki page on how to use custom configuration files: https://www.spigotmc.org/wiki/config-files/
java.lang.NullPointerException: Cannot invoke "org.bukkit.command.PluginCommand.setExecutor(org.bukkit.command.CommandExecutor)" because the return value of "com.darkerdata.wildtp.WildTp.getCommand(String)" is null
I'm guessing that this is from the command not giving a response?
You forgot to define the command in the plugin.yml
Yo lil question, is ping a really accurate way to determine how good the connection is to the server?
Wouldn't there be a more accurate way like "calculating the amount of keep alive packets they received in the last second" or sth?
Keep alive is deffinetly not more accurate
I'm doing animation, so heavily spamming client with packets, I'm working a way to make sure that these animation won't make them crash though, what do you advise me to use?
Obviously if they're struggling keeping up i will send them less or even no more packets at all until they are good again
So you think I should use ping?
I think you should add a setting for the users to decide
And try to lower the amount of packets as much as possible
well its not really what i aim to do, i prefer the optic of sending them as much packets as possible as long as they are not lagging
E.g if many stuff are animating at the same time, in the ideal situation they'd be able to see everything
I'm implementing priority list based on angle of view & distance
could do so but most players won't even understand the settings and what they do, some people don't even care reading you know
so preferably i do it for them
technically they are not responsible for the animation so I can't blame them that they didn't read as technically it's not really vanilla
Ping isn't a great way to messure how much the client can handle
Users will need manual control
so there ain't anything more accurate?
besides user control
I have a question
How can I attempt changing a npcs model to mob or player
For older versions
While newer versions shows a custom model
I wanta try doing this with packets and citizens api
Not really
alr, thanks!
Custom models do not work on older versions older then 1.13
I’m using model engine to display an npc
My editor theme on IntelliJ resets everytime I restart the IDE, anyone know why?
no but tbh
intelllij default theme
is best
👎
I've used the same theme for nearly 2 years
fuck
I much prefer it
thats bad
@grim ice ur bad
how is that bad 🤔
how do u not get bored from t
look how nice this is 😫
exactly
lol
give me ur theme!
tho ill have to get a theme in notepad too
since that's where i code the most nowadays
💀
Honestly for having tried both Intellij and VSCode, even in java i personally prefer VSCode... It has as much tools for java but is way more versatile for other languges AND more customizable, themes plugins etc
im serious lol
w h y
you don't write code in paint? cringe
teleport-Delay: 180
#This is the teleport delay in minutes
teleport-range-max: 5000
#This is the max teleport range in blocks
teleport-range-min: 4000
#This is the min teleport range in blocks
This is my config.yml /\
int maxRange = config.getInt("teleport-range-max")
For some reason it always returns 0 all though I followed the docs?
(Also sorry for cutting in)
does intellij still have that "bug" where it removes the background when you restart it?
Use vscode
but i havent updated intellij in like 2 years lol
i remember i had that bug like few months ago
even tho i was even on the latest 2022 beta when it was out
lemme try it out
im using 2021.2
you got some random image i can use? i dont have any on my pc lol
'
2022.1.3 in my case
okay that looks fine thx
itsl ike first result when u search background or smth on google
Why not intelliJ
yeah
OMG
intellij is specialized
ITS ACTUALLY FIXED
Atleast intelliJ is a dedicated IDE for java
this actually looks poggers
it had that bug where after restarting intellij, it reset the background for the "empty frame" part
which was fricking annoying
empty frame?
when you have nothing opened
this
All of the time I've been using default intelliJ theme, time to change it
bruuuuh why does publishing take so long
while this is the normal frame
though it is uploading the shaded jar too
which i dont want
because its like 20 mb
without the empty frame, it does this weird shit
oh thanks windows
for breaking my screenshots everytime when using 3 monitors
Sorry to cut in
oh yeah
did you (re)load the config
Show code
I mean more lines
getInt cant return null so an undefined value is 0
Yes
I did?
Oh ok
well is that the full yml?
Yes
show more java code
is that your plugin config?
or a custom config
in a different file
would be helpful to see what config refers to
a custom config, or the "vanilla" one
I'm having a stroke
the one bukkit gives you
The same one I sent?
so what is the config object? i suppose just Plugin#getConfig?
the one you get with JavaPlugin#getConfig()
package com.darkerdata.wildtp.commands;
import org.bukkit.Bukkit;
import org.bukkit.Location;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
import org.bukkit.configuration.file.FileConfiguration;
import org.bukkit.entity.Player;
import java.util.Random;
import java.util.logging.Level;
public class WildTpCommands implements CommandExecutor {
Random random = new Random();
@Override
public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
FileConfiguration config = Bukkit.spigot().getConfig();
if (!(sender instanceof Player)) {
return true;
}
int tpDelay = config.getInt("teleport-Delay");
int maxRange = config.getInt("teleport-range-max") + 1;
int minRange = config.getInt("teleport-range-min") + 1;
Player player = (Player) sender;
if (command.getName().equalsIgnoreCase("rtp")) {
Bukkit.getServer().getLogger().log(Level.FINER, "rtp activated by " + ((Player) sender).getDisplayName());
Bukkit.getLogger().log(Level.SEVERE, "max-range is " + maxRange);
int blockX = random.nextInt(maxRange);
int blockZ = random.nextInt(maxRange);
if (random.nextInt(2) == 1) {
blockX = blockX * -2;
}
if (random.nextInt(2) == 1) {
blockZ = blockZ * -2;
}
Location finalLocation = new Location(((Player) sender).getWorld(), blockX, 300, blockZ);
((Player) sender).teleport(finalLocation);
//TODO TP THE PERSON YOU SHOVEL
}
return true;
}
}
Here
If it helps
youre getting the spigot config
not your plugin
thats the spigot.yml i suppose
Use DI so you don't have to make instances 
They do a private static instance then set it in onEnable. That's making an instance.
Just pass the thing around in onEnable. 
no, they're just setting the variable to the already made instance
That's just semantics. Point being. Using DI > static instance
api 'net.orbyfied.j8:j8s-command:0.1.1:dev'
api 'net.orbyfied.j8:j8s-util:0.1.0:dev'
api 'net.orbyfied.j8:j8-registry:0.1.0'
api 'net.orbyfied.j8:j8-util:0.1.0'
im including these modules in a core module, which is a standalone plugin, but other modules (also standalone plugins) need to include the core module, which is done like this
// for example, misc
compileOnlyApi project(":core")
but now i cant access anything from j8s-command in misc, although its declared as api, to add to the weirdness, i can use stuff from for example j8-util in misc
not necessarily
do i need to invalidate caches
in this case
theyre the same
but a static instance is easier to use
and less spammy
But it's not good practice
for what reason?
your class is already a singleton
you're just completing the singleton pattern
Because people should be using DI a vast majority of the time. Practice makes perfect
whole paper server
why should they be doing that?
that's a very bad point
there are cases where a singleton pattern is better
especially when your class is already a singleton
you're just completing it, literally
and a static instance is less spammy than di
with a manager pattern yeah, but if your class is already a singleton and isnt supposed to be protected from outside modules you can just use the singleton pattern
what the fuck
why does it still not work
Meh. Still don't like it.
yeah
clear caches! the ultimate solution to all problems
i invalidated them
The last time someone had an issue like this they hadn't installed the modules to their .m2
Or was it the core. I don't remember
i have them uploaded to sonatype oss
and the other modules are working
and i can download the jar from oss
with the correct content
Wack
do you mean in the user dir?
Depends, what purpose are they for?
yeah
oh aight
communication
If it's client-> server it's bad for example. Especially in forge
Forge provides a messaging system within itself already
I use this for my mods https://docs.minecraftforge.net/en/latest/networking/simpleimpl/
i know that fabric's api has a class for sending "packets" with data, i suppose its similar in forge
It's great because it allows you to easily serialize and read data
@vocal cloud

theyre not sending to a forge server
aight ive deleted .gradle/caches and ive invalidated cahces in intellij
should work now
they're sending to an actual backend
right
bascially you want to send an empty message to a server?
ClientPlayNetworking.send(new Identifier("mod_id", "packet_channel_id"), PacketByteBufs.empty());```
so fricking fancy
it doesnt have a forge server
imagine using forge
Wait so it's a forge mod -> vanilla server
Ah
Well, if you want to hook into that you'd probably need to add that functionality to their code
no
their code is legit
what i said
they have their backend
and they send and get info from it
Can you access said backend?
I mean you sent the code it seemed open source
yeah
but i dont actually have access to the backend
ah i love it when i see that
only the code
reminds me of me using my lib in my local maven repo
When they receive whatever just broadcast it via a channel
always throwing that bs
yeah i can def clone the repo
and add that functionality
lmao
but like thats effort
💀
oooooh
it didnt have anything downloaded yet
i had to reimport gradle proj
pls work
morgen, morgen, nur nicht heute, sagen alle, faule Leute.
pls
what does that mean
fuck its gonna have to do userdev shit again
Tomorrow tomorrow not today says all the lazy people. In other words, just do it 
It sounds better in German
inb4 1 still doesn't work
prob gonna take like a year
YEEEEEEEEEEs
everything is still broken but thats because i renamed like every method ever
get refactored
what fixed it
because i had a gradle issue like this for around a week!
and then fixed
I'm lazy. I'd just release a new version and that would fix it 
that sucks
until i just started deleting random shit
and i discovered deleting caches worked
man
i need topics to elarn
learn
fuck shit i forgot to implement shit
and the test string completion is still in
the release
looooooooooooool
its not borken
but its like in a test stage
and i just released it lol
guess ill implement the feature in my user project
I just wanted to replace custom model for older versions with a mob like it lol
Yes
you would have to get the entity id of each armour stand then send a remove packet to the player
then send a spawn packet for whatever mob you want
idk if model engine api can get the entity ids tho
So i coded an item command plugin but it got some problems
Clients got some auto recipe fill thing where you for example click on beacon and it puts the recipes in the crafting
How to cancel that what event gets called
We talking hacked clients?
Sounds like JEI
I don’t think that’s an event you can cancel. It’s just JEI internally looks up the recipe, checks your inventory and moves the items
It’s like doing it with your mouse except very fast
You can check how fast they do it but that's about it
You could rate limit it but that'd probably create frustrating moments for fast players
no you can click your hotbar button so an item from hotbar comes
i can't find anyway to cancel it
?jd-s
hey i need a dev to add a placeholder compatible with PlaceholderAPI into a plugin
thanks i will read the whole thing
i can try for listening for
Is this on a server of our own, or is it somewhere on the IDE?
inventoryclickevent on workbench if the click type is number key
but
how can i get the number
hey i need a dev to add a placeholder compatible with PlaceholderAPI into a plugin, payment via paypal @ me if interested!
If you wish to request or offer development/art/building/administration services, please do so at https://www.spigotmc.org/forums/services-recruitment-v2.54/
hey i need a dev to add a placeholder compatible with PlaceholderAPI into a plugin, payment via paypal @ me if interested!
...
ask here
this isn't the place
hey i need a dev to add a placeholder compatible with PlaceholderAPI into a plugin, payment via paypal @ me if interested!
asking to get muted or banned
dude literally get a life
this is not the place to ask
blocked 2 too
can we ban this guy
keep blocking and eventually all the good devs will be gone
pls stahp axing
Hash man to the rescue
i hate you
why you code c style in java with a bunch of not needed spaces
check the bungeecord source guys its a nightmare
so anyone got any idea
about how to cancel this crafting thing
Like I said, log all events and you'll find it
Add some "XYZ event fired"
Then go from there
I have done the first method on here, however, my plugin doesn't seem to be getting registered.
https://www.spigotmc.org/wiki/intellij-debug-your-plugin/
The home of Spigot a high performance, no lag customized CraftBukkit Minecraft server API, and BungeeCord, the cloud server proxy.
Have I missed something?
I don't need to build the plugin and put it on plugins right?
Then log more
Well there's got to be something lol
getHotbarButton found it
ask ur question
how to add placeholders?
look up placeholderAPI github
Hello, does anyone here know how to properly use Dagger 2? (ik I should ask directly, but there is not a single straightforward question)
it has an explanation there
nah
k
dont have paypal
goofy ahh
?services
If you wish to request or offer development/art/building/administration services, please do so at https://www.spigotmc.org/forums/services-recruitment-v2.54/
Lmfao we tried that. Even md_5 showed up
this services isnt working
i need 20 posts
should i go spam somewhere to post there?
ooh
i dont have to post
@rapid condor are you a bot ?
Can I use an NMS ItemStack in a BukkitObjectOutputStream#writeObject?
The bukkit instance doesn't save all of the nbt.
Its designed to be used with Objects which implement ConfigurationsSerializable
I see, thank you.
can you cast a Slime back to an Entity?
yes
But why would you?
making a function
that takes in entities
and rotates them
then T extends Entity, or ?
@small current Using DI here is absolutely useless because physically can only be 1 instance of the plugin
no need to cast
void matchPlayerRotation(Entity entity, Player player) {
entity.setRotation(player.getLocation().getYaw(), 0);
}
feel free to improve
Thanks for bringing up an old message. To me DI is something that is always good to practice. static always make me sad anyways
void matchPlayerRotation(T extends Entity, Player player) {
T.setRotation(player.getLocation().getYaw(), 0);
}```
not at ide so syntax is not correct
does it have to be called T?
what am i seeing 👀
Fix it, not in IDE here
The time of the message doesn't contradict what people can learn from it. Generally DI should always be done, this is just an exceptional case
the whole ide goes red lol
My point is, you're not adding anything to the conversation before
why you tagged me
You added nothing new
then why don't you fucking understand the word "don't ask here"
Whatever
I am here to add my own perspective regardless of whether you like it or not.
just take an entity as parameter lol
yeah, I'm not awake
What I was meaning was generics so his ide would not complain about passing a non cast entity
ie java <T extends Entity> void matchPlayerRotation(T entity, Player player) { entity.setRotation(player.getLocation().getYaw(), 0); }
no ide warnings then
I may be wrong but I think teh ide would complain passing a Player into a method which takes a LivingEntity
I can;t remember
LivingEntity extends Entity so should theoritically be okay?
shh hes not fully awake
brain cells firing
Yep you are correct. I was lost in a haze of generics for some reason.
life
does any of you use github actions for automated releases?
Hey !
I created a textComponent long time ago that normally run a command when it is clicked but since the 1.19.1, it doesn't work anymore:
TextComponent finish = new TextComponent(StringConverter.coloredString("&4&l[FINISH]"));
finish.setClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "exit"));```
Nothing is sent, and I don't find information related to a modification of that. Someone know how can I fix my problem ?
https://github.com/softprops/action-gh-release is pretty good
after 20 minutes i found the sound i was looking for lmao
hi i can get this to work pls help pl.sendTitle(ChatColor.RED + e.getPlayer().getName(), ChatColor.RED+ "tagget deg!", 20, 40, 20); i code 1.19
lets start using gson smh
I've got a question about NMS:
If we have complex tags, such as this (see picture) in an ItemStack, when we call .c() will it return the tag data in a HashMap, bound to the key name, which is in this case, LOTRPouchData?
What's the name of the sound played whenever you make a map?
ui.cartography_table.take_result?
THANK YOU!
probably not in that workbench thing yiu mean
i was looking all over the item section
empty map, map, filled map
but yes that's it x)
literallty had the sound list open
i would've never looked in UI tbh
anyways time to break my whole plugin
Are the armour slots counted as inventory slots?
i didnt read, what are you working on?
In a PlayerInventory
can anyone help me compiling this plugin idk how to compile it if anyone can help... https://github.com/WiIIiam278/HuskTowns
well i think you can read :)
getStorageContents gets only items inside of the common places u store shit like in chests but ignores offhand and armor slots iirc
Well sure, but that is exactly my question. Often people separate the two. If I could understand it clearly and hadn't already read it and not understood it, I wouldn't have asked...
Why doesn't the mob spawner block exist? I'm using Spigot 1.8.8
my explanation is better
It could be under another name
pig spawner maybe
I see, then getContents includes armour, and getStorageContents doesn't for the most part.
Thank you.
yes
smh kinda weird to implement a storage design for using database and non databases
In 1.8.8 I saw that it is Material.mob_spawner, but in mine it doesn't exist, in my "Material." there are only 20 blocks
1.8
?1.8
Too old! (Click the link to get the exact time)
Show me what you mean
^
I want get mobspawner block in 1.8
ElgarL, back alive? 😂
just about
theres a method to set the type
oh
so WorldType.FLAT or smth and then set the preset to null?
dunno what the preset is but ig that it is FLAT ye
Avast gross imo avast is just a virus like most other av
ik
all I have is Defender and common sense
I used to like the Enterprise version of Norton
until they made it almost impossible to remove
is it considered bad practice to do Class self = this?
no point
what if there was
inside a bukkit runnable
instead
of doing
Class.this
multiple times?
can we get any context lol
Sounds like you are using Class wrong
I have a lot of player data in my main class
that I need to access inside the gameloop (BukkitRunnable)
then pass an instance of your datasource
make a proper gameloop class i'd say instead of using a runnable where you put all the stuff in
