#help-archived
1 messages ยท Page 31 of 1
oh he left
yeah there is a spigot folder on my desktop
as long as you didnt get any errors
spigot folder got nothin
i can post the log in a second
i have the server on a computer that is not this one
i pasted it at the link
Save and re-send the link
Ctrl + S?
i did
its saying you used cmd.exe
no you shuold be fine
okay
when you right click you should see something like "open git bash here"
or open up git bash your self and navigate to your desktop
yeah
im going to run gitbash as admin for extra measure
then cd desktop
where the buildtools jar is
what is the command again to run the jar ?
java -jar BuildTools.jar --rev latest
only if it doesnt work
?paste
but before that it says build success
Oh you deleted it lol
i didnt

'twas the bot
BUILD SUCCESS doesnt mean success btw, lol
ok
youll know it works when u have three bits of text saying where the things are
at this point
i would delete everything
put buildtools in its own folder
(with nothing else)
and run it again
with git
okay so one caveat
is that I had a vanilla minecraft server running before
and im trying to convert
to spigot
should be fine
so should i delete the minecraft server stuff too? i already have a back up of the world
minecraft server was hosted on desktop aswell
i wouldnt know if it is legacy
legacy means before 1.13
then no
i say put buildtools in its own folder because its quite finicky
^ definitely this
one time it just stopped working in the directory i had it originally
i moved it somewhere else
perfect
Create a folder on your desktop (or wherever, really. A path without spaces preferably)
I keep mine on my desktop because I work with it frequently for PRs and whatnot, but it's fine in your documents if you don't want to see it
it has everything for my vanilla server there and i backed up my world data already
You'll use it often to build new versions / updates
just put buildtools in its own empty folder
Should have its own dedicated folder
nothing else
I literally have one called BuildTools lol
i have several lol
it also had a jar file from bukkit that i thought was the right one, renamed to spigot then i made a script to run it and it turned out to be the same server
cuz it just breaks sometimes lmao
just giving you the rundown
getMetaData returns a List, does that imply if i call setMetaData twice on the same key will it just add the second value to a list?
wow big man got a folder called Repositories
i would never consider kotlin ๐ฆ
scala*
okay so now
Oh that's even worse!
im going to go into a folder where my media is on the desktop
and create a folder called buildtools
then put the buildtools jar in there and run it with git
ya do it
u wont ๐ก
when i found out scala and kotlin were just bootleg java
i was instantly turned off
for(CustomEnchantment e: Main.customEnchantments) {
if(event.getBow().getEnchantments().containsKey(e)) {
event.getProjectile().setMetaData("myKey", new FixedMetadataValue(Main.getInstance(), e))
happier? lol
๐
im just trying to see if getMetadata will have a list of e or if each subsequent call will overwrite the previous call
hush now
i really just want to surprise my friends with a bloodmoon plugin they arent expecting
ignore the static abuse
@placid owl just as a fair warning any vanilla farms/mechanics might break in the process of upgrading.
break as in
they just wont work on spigot
not work
like redstone farms
i mean like iron farms etc
we want to build those
most are fine, but some use mechanics that arent in spigot
does that mean we cant on spigot ?
no
so not everything works on each type of non vanilla server
but yeah my question still stands:
for(CustomEnchantment e: Main.customEnchantments) {
if(event.getBow().getEnchantments().containsKey(e)) {
event.getProjectile().setMetaData("myKey", new FixedMetadataValue(Main.getInstance(), e))```
will getMetadata have a list of e or will each subsequent call overwrite the previous call?
correct
once again
most things will
but as you get more complicated
youll have to test before building them
understood
we are just amateur players who want to remain connected
we have one guy who aspires to build those redstone things but he is just the one guy
@jovial trout im jsut gonna tell u flat out that i wont be able to help you, i have no clue wahts goin on
i have 0 experience
somebody will
pogchamp
yep
just wanna make sure you dont think im ignoring
because i would help if i could :P
after it all finishes
i just have to drag and drop server properties
and world right
you just have to replace whatever minecraft jar you have
with spigot
well not even that
just put the spigot jar in the same folder as your current server jar
yeah
and run the spigot jar just like you would with minecraft
so if i use a start server notepad script
nothing needs to be replaced
i would change jar file name to the spigot one
correct
that is something i dont really have an answer to
hoping it will decrease cpu temps on my laptop and therefore prevent it from throttling my chip
is there a way to tell the script, similar to how we use the Xmx argument in it
is there a way to tell it to use video memory to render the server
there are other server jars you could use that promise optimizations that are (according to them) way better than spigot
but im not gonna say what those are
becuase this is spigot
i dont trust them
ive been around spigot for ages
and ive seen bukkit forums since i was a kid, using hamachi method before open to lan came about
server does not render anything
latest
the way servers handle entities and such is via packets
packets are pieces of info sent to the client
and the client interprets these packets
what we as plugin developers can do is send packets that have faulty information that trick the client into seeing things that really arent there server side
but add a really cool effect
e.i. i can send 1 client 2,000,000,000 particles that only affects that one client
but the server doenst process them or even know it exists
but i just crashed the client
@placid owl You remember the pre-spigot craftbukkit fork?
yeah i was around when there wasnt a fork
ah yes i remember
i was so confused when catching up on all this
CraftBukkit was its own thing
i forget what happened tbh all i remember is some dmca idk
got the success message
\o/
it's up there in my memories
along with grooveshark
and how you could use the cydia jailbreak exploit to offline music from grooveshark
then they got shut down :(
oh yep its still a thing
yeah i know
but it stagnated after iphone 5 or 6 so i stopped paying attention
but now there may be new capabilities making it worthwhile to get the latest iphone
i remember having iphone 3GS jailbroken, and seeing so many posts about how not to upgrade to latest iOS, and that you should use tinyumbrella to downgrade, and feeling so relieved after i realized i had the backup in tinyumbrella
then my friend showed me an HTC phone and it was gg, I hopped on a HTC One M8 and never looked back, now im rocking the Pixel 3XL but feeling left out of an ingroup as I am 23 and so much of my generations culture revolves around blue messages, facetiming and whatnot
yep i had original pixel, preordered it and everything
didnt last me more than 2 years
switched to iphone
so now I just move spigot 1.15.2 jar to my original vanilla server folder ?
yep
and change your start file to account for the different jar
do i delete the other server jar file
dont have to
or should i keep it for a rainy day
its a pretty big jar, and redownloading it can be a pain
yea
all right, booted the script up
wait that took way longer than before
average load time was 15 seconds on old script
it cuold be some first time conversions it has to do
since it was vanilla its gonna rearrange some things to match what spigot likes
in the plugins/ folder yes
nope
and do i git bash the plug in jar or just drop the jar in there
Is there a buycraft api to get how much a certain player has spent on your server?
just gotta put the jar in the plugins folder
simple as that :)
and then you have two options
restart server
or /reload command
(preferably the former)
@night solstice https://docs.tebex.io/plugin/endpoints/payments
sorry im spamming links
but those all give useful info
go for it
thanks!
then drop the plugin jar
Anybody wanna call and help a bit with a Hub?
I'm 60% done with it just need small help
and @night solstice youll notice when using player lookup, youll find there is a purchaseTotals list
im assuming you know how to request an HTTP response with a header
Yeah ive done it before with another api a while ago, ill have to refresh on that.
i find http requests to be one of the most satisfying things :P
wait should i start server though before installing plug in
after
/user/{user}");
HttpURLConnection con = (HttpURLConnection) url.openConnection();
con.setRequestMethod("GET");``` something like this? then i need a header for the secret key @wanton delta
so installed the plugin
and started the server
but the commands didnt work
so i restarted the server
and the script hasnt popped back up yet
do i just start the script myself ?
ya if the start script does not match the one in the spigot.yml the /restart command will not work and you will have to start it yourself
should i fix that or
if you want to be able to use the restart command, otherwise its not that important
gotcha
so the plugin commands dont work still
just says no console command yet stay tuned
how do i know if it is working if i cant show the amount of time before next bloodmoon ?
try the command in game
that message may just be telling you the command does not work in console
how do i make sure my players cant use that command
it depends on how the plugin is setup, you may need to assign a permission for users to use it or deny a permission to not be able to use it, it could also be ops only already, (i don't even know what plugin you are referring to)
do you have the * perm?
idk what that means
do you have a permissions plugin?
so all you have is spigot and bloodmoon?
then you are op
as op you could
i dont want to accidentally fly
ops can do anything
yeah i dont want to be able to fly
most anything anyway
unless you have a fly plugin you wont be able to fly unless you are in creative
wait this site says "bloodmoon.bloodmoon" allows usage of the bloodmoon command
wait i found the config file for the plug in
wow
without a permissions plugin those permissions are basically useless. they will apply however the plugin developer defined them, whether they are for ops or not. If you want more control you need a permissins plugin so you can add those permissions to the specific groups of players that you want to
im dumb
Does anyone know if it's possible to check if the vanilla datapack is enabled via a plugin?
@golden vault so if i install luckperms for example, i will be able to assign permissions for who is allowed to use the commands associated with my bloodmoon plugin and every plugin introduced going forward ?
yep
Can someone help me with setting up a local MySQL server
im really confused and i need it so i can actually work on my plugin
okay do i need to really worry about TPS? server console rarely reports that it is running ticks behind but should i get ahead of this and implement a plugin that doesnt track all entities to reduce TPS?
Yes
adding plugins will not really help your tps it just adds overhead
if you are already running behind your hardware is insufficient. however the message can be ignored if it is just during startup and doesn't continue and the tps drop is not noticeable
^ Also, make sure you've tweaked your settings in bukkit.yml, spigot.yml and server.properties. There are optimization guides on Spigot you can look up ๐ Do this before attempting to add any kind of 'Lag Reducer' because often times, they do quite the opposite of that.
^
@golden vault y got a minute?
๐
I was wondering how to make a void generated world
like without making a whole new, i have a huge HUB
instead of Copy/Paste can i maybe generate it as a VOID
can someone help me with essentials
no idea i have not messed with world generation
and any recommendations for hub except the Tab/Scoreboard/Server Compass,etc..?
@little crater Yeah i am using it
i don't know how to do it
when i try import it doesn't work
Follow the instructions. You have to set the generator in bukkit.yml (or if you use multiverse, it's configs)
i set the generator
p.getWorld().spawnParticle(Particle.FLAME, particleLocation, 3); is spawning a particle with a force that is shooting them away from my player. How do I spawn particles with no force?
thanks for all the help @golden vault @wanton delta !
np
@frigid ember iirc, set it to 0
That 3 is the count though?
has anyone ever seen this stacktrace before? I was adding stuff to a plugin from spigotmc which i decompiled and edited some of the inner workings
@little crater
20.04 20:12:25 [Server] INFO Caused by: java.lang.LinkageError: loader constraint violation: when resolving method "me.bournedev.commands.CmdHelpPage.<init>(Lorg/bukkit/command/CommandSender;Lme/bournedev/Core;[Ljava/lang/String;)V" the class loader (instance of org/bukkit/plugin/java/PluginClassLoader) of the current class, me/bournedev/commands/CmdRoot, and the class loader (instance of org/bukkit/plugin/java/PluginClassLoader) for the method's defining class, me/bournedev/commands/CmdHelpPage, have different Class objects for the type me/bournedev/Core used in the signature
Does dissallowing friendly fire allow arrows to go tbrow teammates?
fucking server owners man
That's exactly what causes issues lol
i've never used plugman in my life
Should never be used in production
use plugman reload pluginname
Bruh
no, either use the plugin's reload command or restart, especially if you are having problems
if the plugin does not have reload command then it was likely not designed to be reloaded
blaming my decompiling skills
Maybe add a built-in reload command if possible?
nah this was the first test
like he put the plugin into the plugins folder
and just turned it on usnig plugman
i spent like 5 days decompiling it
and he's like
iT DoeSnT wORk
5 days? ๐ค
this is why you ask for a latest.log
you read it
you see plugman
you tell them uninstall it right now
@keen moth it was an obfuscated plugin and i was adding a feature ๐
http://luigical.me/images/Screenshot_04_20_G1HCHmeNY8.png
anyone know why this happens? What could be a solution?
use BaseComponent::setColor instead of adding colors into the text itself manually
alright
Or use fromLegacyText. ๐ Read more about it all here: https://www.spigotmc.org/wiki/the-chat-component-api/#common-pitfalls
thanks
When i start another server on my Machine why dose my other server start lagging? My CPU usage isn't maxed out? https://i.gyazo.com/def831f802851be7e70fcc799c7d0e83.png
What kind of machine
@gritty mulch check memory usage and network usage as well.
i think it spikes, hecne the reason /tps doesnt pick it up
is there a way to add special characters to item lore, text components, etc?
Yeah
I want to retexture the null, eof, etc characters to add more symbols since they should never actually show up and be rendered anyway, right?
[00:47:21 WARN]: com.mysql.jdbc.PacketTooBigException: Packet for query is too large (5526600 > 1048576). You can change this value on the server by setting the max_allowed_packet' variable.
how do i fix this??...
Is there any faster way to generate a world with the worldborder plugin? It dose 100 chunks every 3-4 seconds and it takes forever.
Hi can someone help me I have a blast pickaxe plugin breaking blocks in a radious of 3x3 it is also breaking blocks outside bedrock is there any way to prevent this?!
Faster way to generate a world? Get a faster server?
Or just wait for it to finish on its own.
@buoyant path The PacketTooBigException tells you, or make your queries less intensive.
its just me connecting to the server lol
Why, when I run the command, is the enchanting inventory not opening?
public boolean onCommand(CommandSender sender, Command command, String s, String[] args) {
if (sender instanceof Player) {
Player p = (Player) sender;
p.openEnchanting(null, true);
return true;
}
sender.sendMessage("You must be a player to use this command!");
return true;
}
I can confirm my command is registered as it outputs the "You must be a player to use this command!" when trying to use the command from console
@frigid ember I would assign the result of p.openEnchanting(null, true); to a value and check what it returns. It could be returning null which means there's a problem elsewhere.
Also, the method returns an InventoryView which can be opened manually. You could try p.openInventory(p.openEnchanting(null, true)); Based one what the documentation says, you shouldn't have to do that but it doesn't hurt to try.
Alright I'll try
It isn't null.
When doing p.openInventory(p.openEnchanting(null, true));
Can you paste the full code again?
package io.github.aimorris.VirtualEnchant;
import org.bukkit.command.Command;
import org.bukkit.command.CommandExecutor;
import org.bukkit.command.CommandSender;
import org.bukkit.entity.Player;
public class CommandHandler implements CommandExecutor {
public boolean onCommand(CommandSender sender, Command command, String s, String[] args) {
if (sender instanceof Player) {
Player p = (Player) sender;
p.openEnchanting(null, true);
return true;
}
sender.sendMessage("You must be a player to use this command!");
return true;
}
}
Honestly I have no idea then. What you had originally, based on what the documentation says, should be working if it's not returning null.
Do you have any inventory listeners that could be cancelling it?
Nope
Literally only just started this plugin, this was my first command/listener/anything.
Check when illegalargumentexception is thrown in the java docs.
Iโm not at a computer but thatโs your first step
I'm at a computer now
openInventory apparently never throws an IllegalArgumentException
I found a nice way to serialize data to and from a file but I need to know if I am doing it the right way just because it works doesn't always mean its great
public class JsonStorage{
public static void write(File file, Object object) {
Gson gson = new GsonBuilder().setPrettyPrinting().create();
try (BufferedWriter bufferedWriter = new BufferedWriter(new FileWriter(file, false))) {
gson.toJson(object, bufferedWriter);
} catch (IOException e) {
e.printStackTrace();
}
}
public static <C> C read(File file, Class<C> clazz) {
C c = null;
Gson gson = new GsonBuilder().setPrettyPrinting().create();
try (BufferedReader bufferedReader = new BufferedReader(new FileReader(file))){
c = gson.fromJson(bufferedReader, clazz);
} catch (IOException e) {
e.printStackTrace();
}
return c;
}
}
Any suggestions on how to improve it?
I'm utterly confused with this enchanting thing...
Okay so you got the exception because you tried to open the Crafting 4x4 thing in ur inventory
??
btw, I just made some progress. If I change null to a location of an enchantment table, it works.
So you figured it out?
Well that's not how the method works
I haven't touched inventory objects much, but perhaps define a new enchantInventory objet
Alright
Maybe look for a method that returns an inventory object called getEnchantInventory or something
I think will be your best bet
Inventory inv = Bukkit.createInventory(p, InventoryType.ENCHANTING);
p.openInventory(inv);
opens an inventory, but doesn't let the player actually enchant their items (like javadocs said would happen). Is there a way to get this functioning like a normal enchanting table?
Sure, create a listener that does it
Well there is a enchant event or whatever it is called
player.openEnchanting(location, force);
You set the location to null
Null implies player location
I also tried p.getLocation()
hmm
Besides, I need to be able to set the enchanting table level anyway
This was my thought
make a listener that listens for when itemstacks are put into the slots
then when they are add functionality
This openEnchanting method seems to have a common bug since it has been introduced, it's messed up in every new update
If the method isn't working properly just use NMS it looked pretty easy to do in the forums and you just have to figure out what obfuscated methods to use and i imagine its just getters and setters
https://www.spigotmc.org/threads/open-virtual-enchantment-table.359548/
NMS answer right here
Might even be up to date if you want to be spoonfed
Mk what didnt work
well
EnchantmentContainer no longer exists, EntityPlayer no longer exists, PacketPlayOutOpenWindow no longer exists, CraftPlayer no longer exists, etc.
I'm assuming you have NMS as a depency in your build.gradle or however you are getting the package to your project
lmao
What do you use for project dependencies
Maven
Those classes arent available for use by default xD
dependencies {
compileOnly 'org.spigotmc:spigot-api:1.15.2-R0.1-SNAPSHOT'}
That would be regular spigot
api
Is that with gradle or something
hmm
I've got a hacky solution
Instead of bothering with nms
just create an enchant table at some location and then open it...
its 1:30 am so ima head to bed in a min
i think i'm gonna just do this stupid hacky solution lol
aight ima head out pce. You can always ask one of the pros for information about the spigot api as there is probably a clean way to do this assuming openEnchant method thingy actually works as it should and i bet you can just make a subclass of enchantable
build a level 30 enchanting rig down in the void, delete it on close.
The table has to be near the player xD
reallllyyy?
guys i have seen a plugin on bukkit, can i recode it adding some features? wont be posted. (using plugin source code)
reallllyyy?
@frigid ember no i don't think so
there is no check of the radious
- you're just opening an inventory
not a nearby inventory
@Spleed the method opens a nearby inventory if you're refering to openendchant whatever method
you know what i mean
night all
bye
for me its 10AM lol
yeah 10:30 for me
for me its 10:22AM
Also spleed if itโs open source you can pretty much do whatever you want assuming thereโs no license or anything
so for you now is 20/04?
so you are going into the 22
No Itโs morning lol
oh
Itโs 1:30 am the 21
keep on topic
With ?
Its 8:32pm 21st
well has the plugin a license
Is it really worth making a mini games server any more? I was thinking about making one but a will it really get players and B will it be able to pay for its self or even make profit? Tag me when replying to this thanks!
well has the plugin a license
@vale slate idk lol i just need it for me
I went over 200 blocks away from the enchanting table and it still worked
Ihusk what happens at noon? Maybe I can get some good stock prices buys xD
Is it really worth making a mini games server any more? I was thinking about making one but a will it really get players and B will it be able to pay for its self or even make profit? Tag me when replying to this thanks!
@frigid ember no
Why not
@vale slate idk lol i just need it for me
@pearl pawn If it has a license it could restrict the use of it
@pearl pawn But why
Spleed I mean youโre fine to do whatever with open source stuff usually but read the license if you wanna be safe itโll probably say you canโt make money off of it
Aim then you got your solution gz
@pearl pawn If it has a license it could restrict the use of it
@vale slate tought i could edit without any problem if that was for personal use
You can't legal if the license forbids that
Itโs not really a big deal if you are just taking it and doing personal stuff with it
Just donโt publish it
Assuming itโs open source
but, no plaintiff, no judge
Whoโs going to get you in trouble for playing around with an open source plugin? Lmao
They wouldnโt make it open source
If they didnโt want people downloading the source code
Even then you can just decompile
its just for me
I think the problem is not present if you don't republish it
License is likely just for making money
yeah so i am having some issues while starting it
https://hastebin.com/owemibozim.java this is the whole code
And if you would use it on a public server
Youโre fine lol
finally somebody removes this damn autocompletion
Uh context? Whatโs wrong w it?
I literally hate it
I assume you have protocollib
Whatโs the error?
java.lang.NullPointerException: null
at me.alexmc.AntiCommandTab.onEnable(AntiCommandTab.java:38) ~[?:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:263) ~[spigot.jar:git-Spigot-800b93f-8160e29]
at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:352) [spigot.jar:git-Spigot-800b93f-8160e29]
at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:417) [spigot.jar:git-Spigot-800b93f-8160e29]
at org.bukkit.craftbukkit.v1_15_R1.CraftServer.enablePlugin(CraftServer.java:462) [spigot.jar:git-Spigot-800b93f-8160e29]
at org.bukkit.craftbukkit.v1_15_R1.CraftServer.enablePlugins(CraftServer.java:376) [spigot.jar:git-Spigot-800b93f-8160e29]
at net.minecraft.server.v1_15_R1.MinecraftServer.a(MinecraftServer.java:457) [spigot.jar:git-Spigot-800b93f-8160e29]
at net.minecraft.server.v1_15_R1.DedicatedServer.init(DedicatedServer.java:267) [spigot.jar:git-Spigot-800b93f-8160e29]
at net.minecraft.server.v1_15_R1.MinecraftServer.run(MinecraftServer.java:784) [spigot.jar:git-Spigot-800b93f-8160e29]
at java.lang.Thread.run(Unknown Source) [?:1.8.0_241]```
good old NullPointer
Packetadaptor
a little more specific
xD
If youโre learning for the first time Iโd highly suggest avoiding protocol lib related stuff lol
Itโs rather advanced
Hi
yes it is
IMO a lot of NMS stuff is easier than it
public void onPacketReceiving(final PacketEvent event) {
Why is it final?
removed an explicit array
Can you post the entire method and put a comment where line 38 is though?
he/she already did that
Can somebody help me with my problem?
no
one at a time
Ok xD
ok mum
Did you put @Override above the onEnable method?
well, a Method head can't throw a exception
^
so how could i fix this issue?
Need to know what is throwing the NPE
@Override does nothing
it's a marker yes
i do not have @ovveride
You need it dont you?
it's bad coding practice to not use it, but it is removed at compile so
Its only for you to see at compile time hey does this method actually override somethign, but once compiled its useless
it is a relatively new thing in Java it was introduced in java 8
arent we up to java 13 :/
so guys how do i get who's throwing Null
yeah because LoNg TeRm SuPpOrT
so guys how do i get who's throwing Null
@pearl pawn debug, add print statements or sth
so guys how do i get who's throwing Null
@pearl pawn So lets learn how to read a stacktrace
@pearl pawn So lets learn how to read a stacktrace
@vale slate i know how to read the error
but i don't know how to fix the error
Well we can't help you without knowing what the line 38 is in your source
a Methodhead can't throw a exception
i told you lol i sent you the hastebin page with an # who says down here
Npe happens usually when you try using an object before it is instanciated
Rerun the code, might be that you changed it after you put it on your server
yes
Maybe it points to your old version of ur code
because the line you gave us is not able to throw any exception, as no action is made
this line cannot be the cause
Hold on
Is this your AntiCommandTab.java?
Always a possibility that the compiler reads that huge ugly block as one line
Because of how lovely protocollib is
Is this your
AntiCommandTab.java?
@frigid ember im just making a recode for me
adding like more configurable things
What class have you sent a screenshot of.
He meant is the class name AntiCommandTab lol
yes
well that could be luke
try to add Sysouts with numbers in them after every line in the nested method
an run it again
@Spleed do me a favor and throw a console println in between 38 and 39 and show me the stack trace
ok
Oh
this is easy now
Lmao
Lmaoooo
Whereโd the NPE go?
No field type
There is no field in that class you could reflect
protocollib is not even loading
i'm looking for an anticheat that doesn't just alert the staff but can also ban if passed enough checks. any ideas? i have a low budget
AAC does that
Army I like Spartan
doesn't AAC have alot of false flags?
Spartan omg
No field type in Map in EnemProtocol
Spartan and AAC are both really bad
@pure pasture any suggestions?
Code your own?
Spartan kinda doesnโt flag enough but at least you donโt have rubber banding like most anti cheats and itโs relatively cheap
No lol
@pure pasture sadly, i would if i knew enough. i only know simple java.
learning programming takes alot of time, and i don't really have alot of that.
ok than maybe an anti cheat is a bit too ambitious if your just starting out i see
nice now is 37 lol
i'm trying to learn simple plugins, but nothing large.
Coding a anticheat is one of the most complex and advanced things you could do
^^
^
if (player.isCheating) { ban(player) }
so there are no good alternatives?
there done
Nice
as it happens most anticheats have test servers so you could try them out on those
Spleed
Love this anticheat @lofty otter
Spleed
@thorny ledge what
Youโre getting NPE because protocollib isnโt even enabled lol
YEAH i told you
Did you try removing it?
but idk why is not working
It probably is not a compatible version xD
Show your plugin yml
its 1.15.2
Your code obviously wonโt work since it uses a plugin that isnโt initiated
lol
You forgot something
Quick question: Does anyone know what event is triggered when you exit riding an armor stand? EntityDismountEvent and VehicleExitEvent both don't fire
now?
Yeah it should
Alright thx
Using ProtocolLib
To use the library, first add ProtocolLib.jar to your Java build path. Then, add ProtocolLib as a dependency (or soft-dependency, if you can live without it) to your plugin.yml file: Code:
depend: [ProtocolLib]
From bukkit^
^
even tho IntelliJ suggest another way ( with the spigot addon on intellij )
Iโm sure both work
I always use the syntax from the wiki
i set it to Postworld?
it is included in depend by now
if you are making an anti-cheat that relies on checking packets, would highly recommend that it not be part of the server otherwise if you get enough players your anti-cheat will cause network slow downs
if you are making an anti-cheat that relies on checking packets, would highly recommend that it not be part of the server otherwise if you get enough players your anti-cheat will cause network slow downs
@keen compass its an AntiCommandTab
what
Forgot to disable a plugin im working on, that's growing glowstones at ground level, on my server before going to bed last night ๐ https://imgur.com/a/bEhgMkk
xD
Surprisingly, even PlayerToggleSneakEvent doesn't fire when exiting an armor stand. Is this a bug?
well, I created a new Entity and I forgot to destroy it after a drop so I got a fountain
Do you guys think itโs worth making a mini guide for NMS villager NBT tag manipulation?
meh I created a complete lib for this annoying stuff, but I think it would be helpful
I was thinking it could be helpful for people who are good enough at java but havenโt learned enough about the source code
It would be specific and short, but well explained
that would be a cool project
OMG that worked
how do you english people remember to type I instead of i
Glad to hear. And itโs autocorrect
now let's see if commands do work
@vale slate my biggest concern is poor code. Iโm in java courses right now so while Iโm pretty decent at some stuff thereโs another stuff I havenโt even learned yet. Iโm sure you could find Tons of things wrong with this class https://github.com/LukeEff/ImprovedVillagers/blob/master/src/main/java/io/github/lukeeff/version/v1_15/Handler_1_15_R1.java which is the NMS behind the packet manipulation
make โspecial priceโ string a constant
That Iโd likely use in it. I want to spread the best practices and conventions on to less experienced programmers
Is it not declared as a final object ?
You re-declare it each time the method is called.
Yea but thatโs not a constant lol
i mean a class level variable that persists through all instances of that class
Iโm not sure Iโm following you. A constant in java is generally defined as a final keyword
Enumerator?
Not necessarily. final means it canโt be re assigned.
It should be defined in the class and static.
final is a part of what a constant is
Iโm aware of that, and that it can be muted if it is possible
With your current code, it's not a constant because it only exists while in the scope of that method.
Ah, so the fact it doesnโt get instanciated is crucial and is only accessible within its respective scope
itโs instantiated once despite how many instances of that class are instantiated
You'll always have memory allocated for it rather than just allocating memory while in that method call, but if you have multiple instances of that class it'll save memory.
A constant in Java must be static final, so far the official documentation
whether itโs private or public is up to you. depends on the scope of accessibility you need
Let me phrase what I said, I meant it always exists (within the program) and therefore wasnโt instanciated if you will.
I really appreciate the feedback. I did not know this
It's not phrased correctly but yes
I assumed final was Javaโs constant
no there are differences
Even though itโs mutable
Final? If you do something like public final Object myObject = new Object(); then it will just reference that object and not any other one later on. But you can still change variables inside of it.
Which is why Iโm refraining to making a guide until I have a strong understanding of java
reeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee
Lol
@frigid ember Could you at least do getWorld() only once? :[
Whatโs the length of a crafting table?
at the VERY least
^
lol
ALSO WAIT A MINUTE
add() changes the current location.
thank you all guys โค๏ธ thanks for the help
So you keep changing the same location...
yes
So is that math correct?
thats what I wanted
This is what I would let fail so hard in a review
I don't feel like looking at the numbers, just wanted to make sure you knew.
wait
No problem @Spleed glad itโs working ๐
Lmaooo
Who here has experience with making maven dependencies with jitpack.io, i am coming across problems
now is when I cry.
putting them on jitpacks repo
yes java is pass by fuck you
@frigid ember loc.clone().add() instead.
Who here has experience with making maven dependencies with jitpack.io? i am coming across problems
help me
?ask
If you have a question, please just ask it. Don't look for staff or topic experts. Don't ask to ask or ask if people are awake or available. Just ask the question to the channel straight out, and wait patiently for a reply.
Clone is not cheap. Use getRelative or similar
Oh true.
Who here has experience with making maven dependencies with jitpack.io? i am coming across problems
@frigid ember no one?
?ask
If you have a question, please just ask it. Don't look for staff or topic experts. Don't ask to ask or ask if people are awake or available. Just ask the question to the channel straight out, and wait patiently for a reply.
Just ask your question
I'm guessing it's a no, I've never even heard of jitpack
I'm out if it comes to jitpack
descriptive
Then make them work
Wait how do I getRelative?
how?
@dusky herald ?
Maven just says it could not find the artifact
Then your artifact link is fucked up
https://jitpack.io/#purpdev/PacketEvents jetpack recognises it
Go look for the link on the jitpack page and make the artifact I'd correct?
just 1.0.0 and 1.0.1 work
And fix your pom.xml
If Maven says it cant find the artifact, then your artifact id you used is broke
I must say I'm very proud.
@frigid ember im making a plugin about enchanting in survival games, if you chose a specific kit and you use an item an full enchantment table will drop to you with particles as a falling sand and then place like a meteor
after 3 uses of enchant it will explode
so it cannot be resolved
I think you should ask on another forum
a forum for maven for example
I dont know
I mean, if I were you then I would retrace my steps
And figure out where you broke it
are you using intellij?
try File -> Invalidate Caches/Restart
So like
I'm just gonna leave my hardcoding in like that as a "maybe will change later"
because maths is too hard
invalidate?
invalidate and restart?
yea
ok
the button should say โInvalidate Caches/Restartโ
btw thanks for answering, im a big fan of u
ur a real g man
after clicking the button
it asks another menu
uhm, does anyone know why it's lagging swimming up in water?
i clicked invalidate and restart
may viaverisons have caused that?
1.13.2+
what happens after that
๐ฎ
send a ss if you can, iโm not on pc
jit pack issue
dms?
somebody, one at a time, what is the problem with that, I don't come to a service point in a store and crash a conversation
who knows how to enable auto import on the LATEST version of intellij
i cant seem to see the option anymore
yea
it shwos some small icon
and i must click it, so much diff from old intellij versions
the bulb?
i think so
i almost missed it the first time i updated
and was so confused
i want it automatically
but as you type, doesnt it underline it and say hey import this class?
Hello, I am trying to make custom trade villagers, which work fine for the most part except that a bug in Spigot seems to prevent the deals from happening when the villager is supposed to buy from the player a custom lore item (he can sell it with no issue though). The only way for the trade to work is to use a give command to get said custom lore item and trade it right away, without tempering with it (like restacking, ...) which makes it impossible to create a custom paper currency to use as rewards for dungeons. Does anyone know about a workaround or a plugin that would allow an alternative ?
who knows auto import setting in intellij for maven
in latest version
of intellij
I think they changed stuff
anyone?
I'm a oldschool eclipse user so no, sorry
ok
anybody help me find a good spigot /wild plugin for 1.15.2? all i need is command /wild ๐ฆ
mbe search for it xd
buddy.. you need to give up on 1.8 alrdy
less and less people bother rn to make compatibility for 1.8
think what happens with 1.16 release
even forge dropped 1.8 by now
Anyone would know something about my custom lore object, villager trading issue ?
Well on topic @rain cloud found this
but sadly he no longers offers support for it
How i can get offline player statistic ?
OfflinePlayer#getStatistic(...) //does not have
I need to transfer player statistics to the database once
it's no that easy
getStatistic(Statistic.Type)
If the player is offline?
It'll return null if the player isn't online
Well seems its dropped unlucky
You need to get the servers stats folder
there is a json file named by the uuid of every player that was online at some point
Well, then I can just see it in the world folder
yes
Guys im programming an own gamemode at the moment and I have a method that prevents players from pickung up certain items in their inventory.
It works but when I switch worlds it doesnt work anymore.
@blazing owl
new File(Bukkit.getWorld("Whatever name").getWorldFolder(), "stats");
should be the right folder
Trixone, could you format that, my eyes are bleeding
me when I steal code from 19 different sources and paste it together
me when I steal code from 19 different sources and paste it together
@arctic cloud Thanks great help xD
I never posted any code in Discord I dont really how it works xD
know how it works*
@EventHandler
public void onClick(InventoryClickEvent e) {
final Player p = (Player) e.getWhoClicked();
if (e.getClickedInventory() == null) {} else {
if (e.getCurrentItem() == null || e.getCurrentItem().getType() == Material.AIR) {
return;
} else {
if (e.getCurrentItem().getItemMeta().getDisplayName().equalsIgnoreCase("ยง6SkyWorld Menu")) {
e.setCancelled(true);
p.updateInventory();
}
}
}
}```
ohhh hnice
stonks