#help-development
1 messages ยท Page 2283 of 1
you can make inventory UI's
or if you're really cracked at plugin dev do smth fancy with fake armorstands and packets to have a 3d menu
but if you want a menu like minecraft's escape menu you'll have to use mods
It depends entirely on what you mean by "button"
On the server side you're restricted to vanilla inventories and listening for click events. So in that sense, yes, you can create a button and you can texture it with a resource pack. You can also make use of negative font widths and inventory titles to render a custom background texture in an inventory, but you're still limited to static textures and a fixed inventory size. If you want custom inventory rendering for a custom button with highlighting, yes, you will need a client-sided mod
If you just want a simple button in an inventory, you can use items
negative font width?
pretty fancy way to make a background, wasn't even aware that this was a thing
is this comming from spigot
Is there any settings to allow more packets to be sent
I just want to put the number of items to buy ๐
just change the amount of the itemstack
๐ซ๐ท par exemple si tu veut faire un shop ou tu vends 5 de fer, fait en sorte que l'itemstack du lingot de fer dans ton menu soit de 5 @ornate patio
@vivid cave I filled out the rest of that packet java ClientboundRespawnPacket respawn = new ClientboundRespawnPacket( nmsLevel.dimensionTypeId(), // dimensionType nmsLevel.dimension(), // dimension nmsLevel.getSeed(), // Seed serverPlayer.gameMode.getGameModeForPlayer(), // playerGameType null, // previousPlayerGameType nmsLevel.isDebug(), // isDebug nmsLevel.isFlat(), // isFlat true, // keepAllPlayerData serverPlayer.getLastDeathLocation() // lastDeathLocation );
Did you find it in BT?
Yep you were correct it was the old name
Yeah I'd figured that was the case. I hope all mappings are dropped in favour of Mojang mappings in the future
Right now it's a mangling of both lol
Sup, I have a plugin which depends on a non-plugin library (I put the library in plugins/lib)
I added -cp C:\path\to\server\plugins\lib\* to the start command batch file, but it still throws classNotFoundError
Windows search couldn't find the sky for looking.
the problem is for a server with friends and it should be possible to choose the number of items
Same, I like Mojang mappings
the dependency is set to compile
it fails because it cannot find a class in the library
it should be loaded to the classPath right? it is the right directory it's in.
Hello, how do you make a player invisible without removing any of their armor, weapon, and offhand
but like isn't there a way to say "you're controlling that new player now"
Not that I can see
Whats the diff between AsyncPlayerChatEvent and PlayerChatEvent? One is run on the server thread or sum like that?
PlayerChatEvent on the server thread, AsyncPlayerChatEvent on a separate thread
You should use the async one over the main thread one pretty much every single time
To fight chat reports is there a one which is better?
What chat reports?
And we're also not going to encourage you to do it here either when it does come available ;p
You're on your own if you want to disable a player safety feature
I'd happily help when the time comes but why bother worrying about something that hasn't been included yet
So im completely on my own for now?
Yes
It's not out yet so there's nothing to even do
Resources that fight it will get removed?
Nah likely not
Seriously don't even think about removing it unless you wanna dig through pre release 4s nms and figure it out yourseld
Then you can't even deploy those changes since the updates not even out on spigot or minecraft
We won't remove them from the platform because that's not really our responsibility. If you want to disable that feature and harm your users, you're welcome to do that. We have other potentially EULA-violating plugins as well. Though we're not going to encourage you to publish it because we're not going to actively go against Mojang here
thank you!! but i guess i'm quitting this respawn packet cuz i can't spam it to the user
But you're really fighting a non battle
I just like to get everythign right ๐
Idk had idea of disablin via chat event -> cancel message -> broadcast it instead
Will try that when spigot 19.1 is out
if I have a location like this (0, 0, 0) any way to make it so that I can subtract a block
like the way the player is looking
if that makes any sense at all
I can't wait till 1.19.1 releases and all the devs come here to beg to tell how to disable it.
My users are my irl friends so i really aint harming them
how is the player chat reports player safety
JAVA DOESN'T HAVE A FILTER
Well, it does, but it's controlled by the server owner
It's had a configurable filter for like 3 major versions now
You never know when there is heated moment with ur homie and you get reported
bro
i know but with the path microsoft is taking it may have one, its also nice to have more control over the chat system
YOU NEVER FUCKING KNOW
Some packets that deal with containers use the "State ID" field. Can someone pls explain what that field is supposed to do? Because I don't get it.
Don't play with fire if you don't want to get burned. It's really not that hard
well why not disable it
I am teleporting a sheep on top of a players head. When the player looks up the sheep is blocking the view. How can I like make it go a little backwards once you look up?
iirc it's the id of the last container opened but I would have to double check that
The last recieved State ID from either a Set Container Slot or a Set Container Content packet
It's really just an arbitrary number
I found this. https://bukkit.fandom.com/wiki/Using_External_Libraries_with_Plugins
I don't want to shade the library because I want to use it in multiple plugins.
I tried adding the classPath argument in the batch file: -cp "C:\path\to\server\lib\*" (Where the jar of the library is in the /lib folder). This did not work (ClassDefNotFoundError for a class in the library used) (I tried many variations of -cp path none worked)
I saw some stuff with "instructing the classloader to load the class" but that seemed too much for such a simple task.
It's to make sure changes to an inventory are linear
Anyways. Take this, choco, to calm the fuck down
So its useless?
I mean you can ignore it
how to use for discord bot?
They're inbound packets that use it
Ye, but what does the client do with that information?
Not sure what the client does with it
You could probably send 0 for the state id. Again, I'd imagine it's an ordering thing
ok lol, well thanks for the info
What version are you using? If 1.17+, there's a libraries entry in the plugin.yml where you can declare Maven Central dependencies to be downloaded at runtime
Otherwise if you're using a custom library that you wrote, yeah, you'll have to shade and relocate it
Or, alternatively, make that library a plugin and have your dependents depend on it
How do I hide an entity for certain players
declaration: package: org.bukkit.entity, interface: Player
thanks
A PlayerInteractEvent is called for players, and EntityInteractEvent for things like arrows or snowballs. EntityChangeBlockEvent is also called in more generic situations
I found hideEntity, but its deprecated
any other options?
Draft API
whats that supposed to mean?
That it is new and not thoroughly tested and also could change syntax
but personally, it seems likely to stay
so it means it can be ok to use afterall?
its deprecated so that you can see it in the IDE - just so that you know there are caveats with using it
depends when it was introduced
it has been there for a little while but not that far back
how far back we talking?
Why is it always always equal to 0 when i divide it?
I'm so stupid
I mean you create a new list for every player and then just put the player in it.
This means the list is always of size 1 at max.
yeah I saw it now mb
any way to see on the docs when a method was introduced?
Nope. You should strive to support the latest versions only, if possible.
Backwards compatability should be a "nice to have"
Almost nobody plays this version anymore...
75% are on 1.17 and above. Even 1.12 has a bigger playerbase than 1.8
And writing plugins for 1.8 is an absolute nightmare. You can throw practically half of your code in the trash.
where do this statistic come from?
bstats
what is bstats?
if I understand correctly this is a plugin?
Nope. Its a statistics tracking library. People usually shade it into their plugin to track usage.
oh
but
wat about the major pvp servers
It isnt guaranteed that those use bstats?
No, it's just highly likely they use a free plugin that contains bstats within it.
No its not guaranteed but very likely. Also people that want to play on big pvp servers will hop onto the handful of established 1.8 pvp servers that are still up.
1.8 is a bubble where everyone thinks that the whole world is playing 1.8 while in reality they are a minority.
It's also tech debt that keeps these servers on those versions. If most were to make a new server today it would undoubtedly be on a much newer version.
ok so I should go for the new version playerbase?
Thats up to you but i personally wont ever support older versions. Keep in mind that you also wont get any support here for issues you might run into.
1.8 is very frowned upon in the dev community.
Depends how good you make your server
ok let me rephrase
as esay
easy
oh nvm
I did say that
ok
but how far back should I support
again, depends on how much you want to struggle. Newer teh API, the better it is
back to 1.16.5 covers about 90% of the player base?
cool
Myes, but rarely is that new API of use
Iโm utilizing Multiverse to have multiple worlds, but upon teleporting the player via player.teleport() and then setting their gamemode to spectator via player.setGamemode(), the player ends up in survival mode since Multiverse sets the playerโs gamemode automatically. However, I donโt want to switch the gamemode for the world to spectator since I end up teleporting other players to the world and want their gamemode to be survival. Is it possible to force a playerโs gamemode and override it over Multiverse? Hope that makes senseโฆ
manage-gamemodes in Multiverse config I believe
Doesnt break spigot rules?
๐ค
Because the rules said that the plugins should work without ethernet connection
๐
Hello! I wanted to know if i typed unicode correctly
{"providers":
[
{"type":"bitmap","file":"custom/admin.png", "ascent":7,"height":7,"chars":["๊"]}
{"type":"bitmap","file":"custom/VIP.png", "ascent":7,"height":7,"chars":["๊"]}
]
}
Yes. They always talk about the fight club for example.
They are so fkcing amazing
Becaue spigot break his own rules
Because spigot must use internet to work
๐คก
Bstats doesn't make you require an internet connection lmfao.
How upload the data so?
thru the air?
If it can't it doesn't. Simple
๐ฌ
You mean "๊"? This is a valid unicode char. Not sure if the minecraft default font supports it.
Use your brain. If there's no internet it doesn't do anything
Therefore it doesn't require internet
No. I spelled it incorrectly when i do this alone {"type":"bitmap","file":"custom/admin.png", "ascent":7,"height":7,"chars":["๊"]} i works, but when i do both of them it doesn't. And yeah i want to know if i done that incorrectly. And how to fix it
They are so funny lmao
This is no place to do stupid jokes
You are missing a comma
Sure, the website requires internet connection - but this is about plugins
bstats breaks no rules. it fully works without the internet. Its your fault you can't see the website ๐
Oh this is not general right?
Yes
My bad
Can you help me witht that? Cuz i am really raw on that
Im really dumb
I have no idea how it works in general
This is how a json array looks like:
[ {}, {}, {}, {} ]
7smile each {} is an object right?
[
{},
{},
{}
]
yes
Oh ok
Its more or less similar to yaml
In yaml they are called ConfigSection in json they are just object
yaml is a superset of json
Oh i figure yeah because they are the same
But json uses more characters for saving data
@lost matrix
{"providers":
[
{"type":"bitmap","file":"custom/VIP.png", "ascent":7,"height":7,"chars":["๊"]},
{"type":"bitmap","file":"custom/VIP.png", "ascent":7,"height":7,"chars":["๊"]},
{"type":"bitmap","file":"custom/VIP.png", "ascent":7,"height":7,"chars":["๊"]}
]
}
And i think that json is fasther than yaml when came in terms of data savomg
Is hat right format?
yes
Ok i'am really thankfoul
So you ill have an array "providers" and them 3 objects
No problem if need something else just ask it here
Have a good day
Oh lmao im starting to hate paginated/paged menus
how would I go about letting an arrow pass through an entity
This is very tricky because the movement is also computed and extrapolated on the client. So it will look buggy.
First step: Cancelling the ProjectileHitEvent and see where that leads you.
would it be possible to see if an entity was hit by an arrow
and shoot it out with the same velocity?
What you can do us listen to the event, cancel it and teleport the arrow forward at the end of the BoundingBox.
Requires some math.
Using the angle and BoundingBox dimensions.
I don't see that in the config sadly. I'll do some research rq tho
anybody know a good lib for spawning shapes/effects with particles?
objection, heresay
Yet not a discord helper

its greenscreen
We do have โcandidatesโ although there was a while since last time we discussed newcomers to the team ๐
You make it sound so professional
Do I?
Yes
Hmm
i guess we are a "Team" but i wouldnt like put that on my resume
Lol
"Discord Mod" always comes good. Doesnt have any neckbeardy vibes at all.
Imajin pretending the other helpers don't exist
Hehe
which also does not put my above everybody
Proceeds to be supercilious/s
Back to your question: I personally dont use/know any libs of that kind. I mainly throw random math at Locations and then eyeball the outcome.
Time to create a lib/s
hey guys, I get this error when I try to run the command /play 1
the error: https://prnt.sc/dI063YO1vKvB
the code:
public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
if(sender instanceof Player){
Player p = (Player) sender;
hub = p.getLocation();
if(args[0] == "1"){
p1 = p;
p1Lives = 3;
plugin.addPlayer(p1);
plugin.updateScoreboard();
}else if(args[1] == "2"){
p2 = p;
p2Lives =3;
plugin.addPlayer(p1);
plugin.updateScoreboard();
}else{
if(p1 != null && p2 != null){
p1.setBedSpawnLocation(SetLocationCommand.getFirstLocation());
p2.setBedSpawnLocation(SetLocationCommand.getSecondLocation());
p1.teleport(SetLocationCommand.getFirstLocation());
p2.teleport(SetLocationCommand.getSecondLocation());
p1.addPotionEffect(SLOWNESS);
p2.addPotionEffect(SLOWNESS);
TitleApi.sendTitle(p1, ChatColor.GREEN + "" + ChatColor.BOLD + "3", "", 0, 20, 0);
TitleApi.sendTitle(p2, ChatColor.GREEN + "" + ChatColor.BOLD + "3", "", 0, 20, 0);
Bukkit.getScheduler().runTaskLater(plugin, () -> {
TitleApi.sendTitle(p1, ChatColor.YELLOW + "" + ChatColor.BOLD + "2", "", 0, 20, 0);
TitleApi.sendTitle(p2, ChatColor.YELLOW + "" + ChatColor.BOLD + "2", "", 0, 20, 0);
}, 20);
Bukkit.getScheduler().runTaskLater(plugin, () -> {
TitleApi.sendTitle(p1, ChatColor.RED + "" + ChatColor.BOLD + "1", "", 0, 20, 0);
TitleApi.sendTitle(p2, ChatColor.RED + "" + ChatColor.BOLD + "1", "", 0, 20, 0);
}, 40);
Bukkit.getScheduler().runTaskLater(plugin, () -> {
TitleApi.sendTitle(p1, ChatColor.DARK_AQUA + "" + ChatColor.BOLD + "Brawl!", "", 0, 10, 0);
TitleApi.sendTitle(p2, ChatColor.DARK_AQUA + "" + ChatColor.BOLD + "Brawl!", "", 0, 10, 0);
}, 60);
}
}
}
return true;
}```
main class: ```java
public final class MCBrawl extends JavaPlugin {
private JGlobalScoreboard scoreboard;
@Override
public void onEnable() {
System.out.println("MCBrawl loaded successfully!");
getServer().getPluginManager().registerEvents(new Knockback(this), this);
getServer().getPluginManager().registerEvents(new DoubleJump(this), this);
getServer().getPluginManager().registerEvents(new Misc(this), this);
getCommand("play").setExecutor(new PlayCommand(this));
getCommand("SetLocation").setExecutor(new SetLocationCommand());
scoreboard = new JGlobalScoreboard(
() -> {
return "&e&lMCBRAWL";
},
() -> {
return Arrays.asList(
"",
"&6" + PlayCommand.returnFirstPlayer().getDisplayName() + " : "
+ "&r&a" + PlayCommand.returnFirstPlayerLives(),
"",
"&6" + PlayCommand.returnSecondPlayer().getDisplayName() + " : "
+ "&r&a" + PlayCommand.returnSecondPlayerLives(),
"",
"By IR3DX",
"@R3D#0404"
);
}
);
}
@Override
public void onDisable() {
System.out.println("MCBrawl disabled successfully!");
}
public void addPlayer(Player p){
scoreboard.addPlayer(p);
}
public void updateScoreboard(){
scoreboard.updateScoreboard();
}
}```
What does this mean?
First of all
args[0] == "1"
Dont compare objects with ==. This will pretty much always be false.
Use .equals() instead
edited that
What the heck is com.tuinity:tuinity?
Tuinity server jar
paper fork
Oh ok
Thnks
Amazing repo i find
Instead of using build tools for spigot jars
I can use that
Not illegal at all
still not working after I edited it
Pls paste the full exception as text somewhere. The screenshot is hard to read and it looks like its incomplete
Just distribute mojang code 
I will use it for coding plugins faster, so i skeep the proccess of building every spigot locally and then install it to local repo, etc
how do I copy from the console?
linu or window?
If you are on linux you can copy everything like marking the text and pressing right click
unless you have it paasword locked that doesn't change it xD
what pass?
Its public
I mean i can use every artifact from the repo
So you are publicly distributing code you don't own nor have a licence for ?
windows
the repo is not mine
ah
yeah vague area
what means redistrubite mojang code
Well, you can just download the server from there
sharing mojang code
Because the spigot itself redistrube mojang code
this is the entire console https://paste.md-5.net/ecopazewow.md
should
and why you are building the server on your local system
he prolly didnt
spigot uses mojang server internally to work
OH LOL
it does not have a cancel method
buildtools downloads mojang code on your pc
using something != distributing something
and modifies it
Okay because i have a community with friends and we want to have a private repo with the spigots artifacts all together
ok
So then we dont depend from 3rd party repos
And also for uploading our custom libs
That my final point
should not be an issue to have a private repository. Tho also like, just use paperweight userdev ๐
That the repo i find
Can u take a look
Also here is redistributing mojang code ๐ค
light mode burns your eyes
Yea I know that repo
yesi cannot change it
It not mine repo
Its also a nexus repo
Well, don't use it /shrug
Light mode gives you wings
what lynx?
Well use a proper setup for nms
and you can fly to heaven because ur dead yes
More or less i would need a private repo for setting up all our artifacts and spigot, spigot-api, nms etc
i was more thinking the redbul commercials but that too
I dont think that mojang would do something
They are just for the money
They might not, but respecting their licence is just like
decent behaviour
I know happen the same with eula bruh
Most minecraft servers breaks eula rules
And mojang doesnt care that why
We also dont give access to that private repo they only will be used by our custom plugins
And thanks lynx you always answering i really appreciate that
๐
Yea if it is a private one you should be fine ๐
Its private but what if we sell a custom src which uses the repo?
I never thought about that
I mean, as long as the source does not contain the server jar xD
Oh ok
coding against it is not the same as distributing it
help would be greatly appreciated. Console: https://paste.md-5.net/ecopazewow.md
Sorry for ignorance but the only way for working with nms is minecraft-server artifact and the spigot?
First fix this exception:
java.lang.NullPointerException: Cannot invoke "org.bukkit.entity.Player.getDisplayName()" because the return value of "me.r3dx.mcbrawl.commands.PlayCommand.returnFirstPlayer()" is null
Doesnt get more descriptive than that.
Because i know that spigot is the "core", which uses spigot-api, minecraft-server
I mean, paper has a more elegant solution. For spigot yea
why is it returning null tho? shouldn't it return p1 which we set after doing /play 1 ?
paperweight-userdev?
So lyn if do public the repo and only upload the spigot and spigot-api artifacts i wouldnt break rules?
Hmn yeah that why
When the server starts then nobody called this command before. So what do you expect to be in the variable then?
?bootstrap
Bootstrap Jar
The main spigot-1.18.jar is now a bootstrap jar which contains all libraries. You cannot directly depend on this jar. You should depend on Spigot/Spigot-API/target/spigot-api-1.18-R0.1-SNAPSHOT-shaded.jar, or the entire contents of the bundler directory from your server, or use a dependency manager such as Maven or Gradle to handle this automatically.
Please read the release notes for further information: https://www.spigotmc.org/threads/9-years-of-spigotmc-spigot-bungeecord-1-18-1-18-1-release.534760/#post-4305163
the spigot minecraft mapped jar still contains the entire server
in 1.18
no ?
isn't that how spigot does NMS
Yes
yea
So does the unmapped one
but yea, spigot just shits them back together
so people don't have to define mojang libs manually
Col have you read all what we talking ? hehehe
I think its a interestic topic
Maybe i open a thread
If you want to use nms with spigot now then you should just use the special sources plugin + the setup presented to you in the forum post.
Does it apply with any spigot?
No. 1.17+
how do I fix that tho? before any player executes the command, the scoreoard is not supposed to have any player name
Oh that why heheh
Allright thanks to all lynx, smile and coll
Are you asking me how to fix a simple null pointer exception?
just a simple if null then return "" ?
I will talk to my friends and try to find a solution for this. Because we must need a private repo for hosting all the spigot artifacts because it a mess if not
A null check could help.
also why now yaml warns about nulleale
Its a mess using that spigots
I couldnt find a way to not care them without adding an annot
Is there a way to get the number of enchants on an item in a persons hand?
Get the itemstack from his hand
is entity.spigot().setCollidesWithEntities(false); still a thing?
hat version?
Also have you checked if exists in the jd-.s from your version
1.16-1.19
U will have to check manually on each versions
I cant find it in 1.19
How would I get the amount of enchants on that item with an integer?
does it mean its gone?
Because maybe exists on 1,19 but not on 1.16
ItemStack enchantments isnt a collection?
You get the map that contains the enchantments and simply call .size() on it
kk, ty
Its a method from Player.Spigot
declaration: package: org.bukkit.entity, interface: Player, class: Spigot
crunch from @waxen plinth
so I wrote that java if(PlayCommand.returnFirstPlayer().equals(null)){ player1Name = ""; }else{ player1Name = PlayCommand.returnFirstPlayer().getDisplayName(); } if(PlayCommand.returnFirstPlayer().equals(null)){ player2Name = ""; }else{ player2Name = PlayCommand.returnSecondPlayer().getDisplayName(); } but I'm not sure where it should be properly placed
just in my onEnable method?
where can I download spigot 1.19 api
Null checks always with ==
didn't you tell me to use .equals earlier?
All of your variables and methods are at random weird locations already anyways. Just throw it somewhere like the rest.
like what? I thought I properly placed all of them
where do I get the api dependencies?
Of which api?
spigot
What do you mean by "get"?
You should let maven handle pulling transitive dependencies
I am using intellij ideas build artifact thingy
where I downloaded the 1.8 api jar file
for spigot
๐
so where can I get the 1.19 one
please use maven or gradle
You should really use maven instead. The minecraft dev plugin for intellij generates a clean maven spigot project for you.
Otherwise: Run BuildTools and get the uber jar
doesn't IntelliJ idea use maven when building artifacts?
Just use maven or gradle ๐
how do I get started with maven?
.
you can get plugins for intellij?!
๐
how
Nah its just a multibillion dollar company that cant develop plugin support for its most popular IDE
can I just copy in my old project without changing the structure afterwards?
Sure
how do I build with the new plugin?
just the run button
No lol you run mvn package
The run button works
since when is a folder called a package?
since forever in java
Forever
and other langs
anyway to set it up so that the generated file goes in another "package"?
By doing artifact set and refactoring i think
You mean for example your project having mongo-driver inside your plugin?
can someone please help me with the error I'm getting when I execute my /play 1 command?
Error: https://paste.md-5.net/uduzasanil.cs
Code: https://paste.md-5.net/utepahuzar.java
no
I mean
You can do:
int input = Integer.parse(args[0]);
if (!input) {
sender.sendMessage(args[0] + " is not an number");
return true;
}
// more code
return fale;
setting the target folder to another folder
Oh uingmaven?
ye
so is the error because I'm using 1 and 2?
Let me find it
I haven seen your code
Wait please
I help one and then the other
take your time
@cunning canopy add this:
<build>
<plugins>
<plugin>
your plugin setting here
<configuration>
<outputFile>path/to/folder</outputFile>
</configuration>
</plugin>
</plugins>
</build>
add this where?
send me your pom please
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>Mgames</groupId>
<artifactId>mgames</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>jar</packaging>
<name>Mgames</name>
<properties>
<java.version>1.8</java.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.1</version>
<configuration>
<source>${java.version}</source>
<target>${java.version}</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.2.4</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<createDependencyReducedPom>false</createDependencyReducedPom>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
</resource>
</resources>
</build>
<repositories>
<repository>
<id>spigotmc-repo</id>
<url>https://hub.spigotmc.org/nexus/content/repositories/snapshots/</url>
</repository>
<repository>
<id>sonatype</id>
<url>https://oss.sonatype.org/content/groups/public/</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>org.spigotmc</groupId>
<artifactId>spigot-api</artifactId>
<version>1.19-R0.1-SNAPSHOT</version>
<scope>provided</scope>
</dependency>
</dependencies>
</project>
try {
while(Bukkit.getScheduler().isQueued(task.getTaskId()) || Bukkit.getScheduler().isCurrentlyRunning(task.getTaskId())){
Thread.sleep(500);
}
Thread.sleep(500);
} catch (InterruptedException e) {
Breadwars.logger.log(Level.SEVERE, e.toString());
return;
}```
is this ok for checking whether my task is done? could there be an issue with a reused task id?
cant you just call a function when the task exits?
Inside <configuration> tag add this: <outputFile>path/to/folder</outputFile>
wdym
why on this planet are you using thread sleep
to put the thread to sleep
You shouldnt do that
absolutely not
You can block the main thread
it's not on the main thread
thanks
use the scheduler
that sounds like alot of effort
If you are using the maven-shade-plugin it will generate many jars so you can add path/file-name.jar to only move the output for a specific jar
well if you're not open to trying, good luck!
I just scheduel things then wait
GOOD LUCK
If you dont listen is all what we can tel lyou
We are explaning how to do it...
@cunning canopy coould you understand? Sorry for pinging
arl but good idea to just call a function when task exit
ye
yup
I am new to maven
and have no Idea how pom.xml works
but I think it works
apparently maven is denied access to the folder
any clues?
did you run it as root earlier?
im on windows...
Okay i used to have that issue
But some days before started to work
I just ended up that maven was crazy
and the solution is?
I dont really know
I just leave that shit alone and some days after started to work
Maybe ask here because lot of people here uses maven, then can help you
Sorry matter
@sterile token did you take a look at my code?
I will do it now bro
But be patient
Im a bit bussy
Sfran what are trying to do ?
I dont understand
If you dont want to create with colores remove the .color()
and that all
what the fuck is that code
Same question man
The only way I could see this would be some sort of recursive function that scheduled a copy of itself again a few ticks later
Safran if you want the colored thing just do sout of ItemStack#getDisplayname()
ChatColor#translateAlternativeColors('&', "colored string") ill apply the color
Why do you want the color? are you comparing the string or something?
and you want it to have teh same colour as the item
do you know if the colour code is the first character in the name?
Sfran
The method name could be wrtten wrong
i just writed by hand on discord
That method i told u
Is usally used to convert the colored text that use this "&4Red text" into the spigot color
try ChatColor.getByChar(Char)
pass in teh first char of the string
name.charAt(0)
this will only work IF the Name has the color code as its first Char. If there is other formatting like bold, it may not be a color char
what is the exact text in the string?
the custom name you are trying to fetch the color from
Yeah he doesnt explain really well
Or atleast we dont understand what he wants
Either that nor he is trolling us
๐
I understand what he wants but yeah, lackign
if the first Char is not a color code I'm going to guess he's using RGB colors
Are you using ur server om ur pc or?
no
pulling an rgb is more code than I have time to explain here right now. Too busy
cause then he can just copy the name to clipboard with the hex values or what ever
Yeah rgb are not simply
with the ยง symbol
actually its rgb so shoudl be 7 characters?
I finx that tuto
yes but there is a control code
so 7 or 8, I forget
lets say 7
so Chatcolor.of(first 7 characters from name)
public static String translate(String message) {
if (FlameChat.getServerVersion() >= 16) {
Pattern pattern = Pattern.compile("#[a-fA-F0-9]{6}");
Matcher matcher = pattern.matcher(message);
while (matcher.find()) {
String color = message.substring(matcher.start(), matcher.end());
message = message.replace(color, ChatColor.of(color) + "");
matcher = pattern.matcher(message);
}
}
return ChatColor.translateAlternateColorCodes('&', message);
}```
I find that also
yep 7 chars
Hi :D I have a world creator plugin but i wanna make permissions. That means if e.g. player creates a new world, then the player who createt the world will be given the permission world.owner and he can delete it and so on. But how do i do that. I have to use for() or smth like that and save every players permissions IN EVERY WORLD in the config. I know im overcomplicating this(i hope i do so xd) so do you guys have any suggestions? Thanks :P
that shoudl give him enough to work from
it uses regex, all he needs is to get the first match
Hmn i dont still what he wants....
๐
I dont know if want to translate the hex into ChatColors
Or what the heck
he's trying to pull an RGB code from the custom name of an Item
he wants the md5 ChatColor.of(7 char rgb color pulled from Item Name)
Hi D I have a world creator plugin but i
yes
you need the first 7 chars of your String
ChatColor.of(name.subString(0,6)) I forget how to use substring without looking it up
Yes, your color is an RGB
?
it takes up 7 Characters in teh name
You only see a color once displayed
but its 7 characters long defining it
any one know?
or help
pls
You're welcome
kinda busy... bitch

I am getting this super weird error when opening a gui, I am using a wrapper btw (RedLib)
Am i correct in understanding that 1.8.8 used gson 2.3.1?
Read thsi and see if you understand it. I'm busy with my wife at mo so can;t help further. https://www.spigotmc.org/threads/detect-hex-colors-and-apply-them.448771/
It appears you're calling a method with itself or something that's creating infinite recursion
here is the code if you wanna take a look, I didnt find anything on my own
I know where the issue is coming from
The error in there mentions get first available plot or something
yeah
Check for recursion because obviously it's calling itself somewhere
yeah, the first available plot method ran a System.out.println for debugging which is where the error ended
Well what's choose plot line 97?
menu.open(player);
ok so
I figured out
where everything goes wrong
so
when the player clicks on a item in the inv, it closes the inv, then loads their plot. When they close the inventory, the plugin checks to see if they have a plot loaded, if not reopen the menu
Mike do u have experience with paginated menus
Im really exaust lmao
I cannot even see paginated/paged menus
Because they are really to deal with them or atleast for me
Yes, there are libs if it's too difficult for you.
Guava has some great methods for splitting arrays into pages and then you just need to add the indexing system if you want to do it yourself
I think i dont understand how they works
hi guys, whenever I try to build my project it tells me that one of the packages I imported (JAR) does not exist even though I imported it to my project
how can I fix that?
All you do is define a number of items per page (N) and then go through your content.
So from 0 -> N then N + 1 -> 2N then 2N + 1 -> 3N and so on...
What ide and which build system?
how can i make it so that e.g. when i make a command and execute it, and then like a message comes up with "Do you realla wanna do this [Y/N]" and then you can type in chat y or n and if you dont type that in like 10 secs the process is beeing cancelled
Intellji, just a jar file

I used minecraft dev plugin in IntelliJ to setup my plugin project. Is there any way to change the path that the jar file will be put in?
Spigot has a conversation api for this. You could also do something with the AsyncPlayerChatEvent, a map/set and a runnable that removes the entry.
Well. Make sure your dependencies are correct then. Not much we can help with.
dude, I'm not using maven
literally just a jar file that I specified the path to
As you clearly stated
Then make sure you "literally" specified the appropriate dependencies.
Can you simplify that xd Im learning java at the moment and dont quite understand what you mean
I did
no errors until I hit run
I just dont know how to implement it to actual menu api that why. So that the way how i create normal menus. Now im over and over thinking how do to the paginated way
Then build your artifact. If your IDE has no problems with your imports then everything should be fine.
If you're not using someone's library you really want to write a utility class for it.
This is not a trivial task. Do you know what a HashMap is?
Do some research and come back when you know at least
- what an instance is
- what a Set (specifically HashSet) is
- what a Map (specifically HashMap) is
- How to pass parameter through a constructor
Then i can explain in more detail on how to do it
Yeah
Motly
I used minecraft dev plugin in IntelliJ to setup my plugin project. Is there any way to change the path that the jar file will be put in?
I already told you
it did not work
Using maven you can set the output file route
Is there some kind of list with all items?
You have an enum called Material which contains all items
With maven? I would configure the maven shade plugin.
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<version>3.something</version>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<finalName>${project.artifactId}-${project.version}-something</finalName>
<outputDirectory>../guide</outputDirectory> <- Here
</configuration>
</execution>
</executions>
</plugin>
Then i know it already but ok
I sent the same code
But it said that he doesnt have permissions
It used to happen to me but i leave the error alone and days after test it again. And it was fixxed
๐
can the output dir be outside of the project folder?
Yes
Not the best idea to do it that way but it can be done.
hat about for putting it on a local server? ๐ค
๐ฌ
The InventoryCloseEvent also gets triggered when a player dies, is there a way to tell if that was the reason for closing the inventory?
You can always move it.
So why you said its not okay doing that....
Also mike its really painful deadling with paged menus i didnt thought it was so painfull
The close event is fired before the death event (iirc). So the only way i can think of is checking if the players health is 0
kk, thx
Use a library then.
You wanna me get more illnesses
The library feels me really ugly
Write your own library
What im doing hahaha
Maven is not meant for continuous integration. The clean way would be to use jenkins or a script.
Okay
If the server gets moved or deleted it'd be a pain to get it back, not to mention building a release
I dont know i just use the outputfile to not to chnage the intellij screen open the server and doing that ass-ole things
Honestly I'd just use Gradle and setup tasks to automatically run it on a server for me.
Gradle != Maven ==><==
Gradle > maven
I dont think
In terms of compilations i dont agree
It take more time for doing simple compiling phases
In theory you can also use the surefire plugin and write java code that gets executed
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.22.2</version>
<configuration>
<includes>
<include>SomeCustomTask.java</include>
</includes>
</configuration>
</plugin>
Yeah when caching. But the first build can take ages.
For smaller projects yes.
I'm just saying that if you want to do crazy stuff like copying hoo-ha's around the best method would be using Gradle. Performance isn't as important to me atm.
We should all just use ant
Maven is fine.
Never met someone that actually still uses ant
"back in my day we built the jars by hand"
It was default for intellij build package thing
who know how to do like this
a command that take from you economy from (essentiels plugin) and give you claim from GriefPrevention plugin
Hook into vault to remove currency and hook into GriefPrevention api to grant a claim...
explain more
You have been E X P L A I N E D
@lost matrix can i do it at same CMD
Yup
As in when it shows up on message? That's a client thing isn't it?
Quick question. So I was looking at the spigot wiki(I'm working on learning to make as well as making plugins) and I was looking at the code on the GUI page(https://www.spigotmc.org/wiki/creating-a-gui-inventory/) and I noticed that in the section of code that is the call to open the GUI he uses ent
ent.openInventory(inv);
}``` I was wondering what the ent means?
its the name of the variable that gets passed to this method. Could as well be catWithAHat43
ah ok
๐
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.
Sorry if this is a weird question but I've just been trying to find a friend who's decent at coding who is available to call sometimes and help me code some simple stuff. I'm making a server that is really important for a certain community because something really dumb happened on the server the community was using and now it's unusable. The server is so important that I decided to learn coding and create a replica of the specific function the server has that I was using. It's going well but there's like one or two parts I need help with but I can't really use a tutorial and I also would like to understand coding more by calling with 1 on 1 help so I can improve the server more. I know no one knows me but if anyone wants to help out some random dude I would really appreciate it
What is the "community"?
Hypixel parkour speedrunning
version?
I'm coding using 1.8.8 since I use 1.8.9 to do parkour
I want the server to be for all versions
You are going to be very out of luck
Preferrably
General questions and help we can give, but nothing 1.8 specific as our answers are almost guaranteed to require a more modern API.
Well I just want a friend
is possible to convert that into a lambda exprension
that is a lambda expression
lambda isnt the one that uses for example Player::getName ?
no lambda is ->
I mean thats method reference lambda
Oh ok
lambda expressions uses the "->" okay
I thought that lamda was when you use that what i sent on top
My mistake i get mixed
Oh i love that page man
it is most often used in lambdas
Its pretty amazing for reading about ava things
Oh lmao im messed with paged menus
I still cannot do atleast 1 simply but functional code
how can i kick a player after is totem was used?
@EventHandler
public static void EntityResurrectEvent(EntityDeathEvent event) throws InterruptedException {
if (event.getEntityType().equals(EntityType.PLAYER)) {
if (!event.isCancelled()) {
if (AfkCMD.isAfk.contains(event.getEntity().getUniqueId())) {
Player player = (Player) event.getEntity();
TextComponent tc = Config.tc;
tc = tc.append(Component.text("AFK-Schutz wurde aktiviert!", NamedTextColor.RED));
}
}
}
}
this is my code rn, but it just kicks the player before the totem gets activated
I would map the player uuid and them a boolean
but that doesn't change anything does it?, i mean my code kicks the player i want it to kick but like too early
Is there a way to get which enchantment is shown in the enchantment table preview or to get the enchantments that were added as a bonus after enchanting?
You can do what i told so when he use the token add to map with boolean true, and then on respawn check if contains the uuid and kick it
๐ค
put a delay before you kick
A Map<T, Boolean> is in almost all cases useless. Use a Set<T> instead
Why a type generic?
does a totem trigger the respawn event?
Bruh
Map<UUID, Boolean> its even more simply
https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/entity/EntityResurrectEvent.html take a look at this
declaration: package: org.bukkit.event.entity, class: EntityResurrectEvent
@zinc sedge, if its kicking your player too early then delay the task :thinksmart:
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/event/enchantment/PrepareItemEnchantEvent.html
https://hub.spigotmc.org/javadocs/bukkit/org/bukkit/event/enchantment/EnchantItemEvent.html
declaration: package: org.bukkit.event.enchantment, class: PrepareItemEnchantEvent
declaration: package: org.bukkit.event.enchantment, class: EnchantItemEvent
I looked at those, but couldn't really find anything. The getEnchantmentBonus method returns an int, not the actual enchants added ontop of the original enchant. And I cant find anything that can get me the original enchant (see picture) https://prnt.sc/kTSlBrJUboB0
declaration: package: org.bukkit.event.enchantment, class: PrepareItemEnchantEvent
You would just have to store the list of enchantments before and after enchanting - (removing) the expected enchantment from the list
The method does not exist in 1.8.8. If I were to make the plugin in a more recent version, would it still work on 1.8 spigot servers?
Thankfully not
1.8 is ancient. Support was dropped years ago and the player base is vanishingly small. Nobody should write plugins for that version anymore.
in a lifesteal plugin i payed for there is a bug where when you relog to the server it resets your health to full and im wondering if anyone could help me fix it, i think its 1 of 3 codes
@EventHandler
public void onRespawn(PlayerRespawnEvent e) {
setPlayerHealth(e.getPlayer(), getPlayerHealth(e.getPlayer()));
if (getPlayerHealth(e.getPlayer()) == 0)
setPlayerHealth(e.getPlayer(), 20);
or
public void setPlayerHealth(Player p, int h) {
p.getPersistentDataContainer().set(this.Life, PersistentDataType.INTEGER, Integer.valueOf(h));
p.getAttribute(Attribute.GENERIC_MAX_HEALTH).setBaseValue(h);
p.setHealth(h);
or
public void setPlayerHealthNoUpdate(Player p, int h) {
p.getPersistentDataContainer().set(this.Life, PersistentDataType.INTEGER, Integer.valueOf(h));
p.getAttribute(Attribute.GENERIC_MAX_HEALTH).setBaseValue(h);
}
Do you have a listener for the PlayerJoinEvent?
if im going to be honest, i dont know how to code plugins all i did is download eclipse and im looking through to see if i could fine it, i have the source code but have no clue how to check sorry lol
then not entirely sure why you come here asking for help
if instead you actually want someone to do it for you then here is this
?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/
ah ok ty
sorry for wasting time
wait sorry again but would this be the listener?
@EventHandler
public void PlayerJoin(PlayerJoinEvent e) {
if (e.getPlayer().getPersistentDataContainer().has(this.Life, PersistentDataType.INTEGER)) {
if (getPlayerHealth(e.getPlayer()) <= 0) {
setPlayerHealthNoUpdate(e.getPlayer(), 8);
return;
}
setPlayerHealth(e.getPlayer(), getPlayerHealth(e.getPlayer()));
} else {
setPlayerHealthNoUpdate(e.getPlayer(), (int)e.getPlayer().getAttribute(Attribute.GENERIC_MAX_HEALTH).getValue());
look in your plugin's main class
all thats in the main class is the recipes and items
The main class is irrelevant. All you need is right there in the join event
} else {
setPlayerHealthNoUpdate(e.getPlayer(), (int)e.getPlayer().getAttribute(Attribute.GENERIC_MAX_HEALTH).getValue());
is it this?
if i remove that?
it looks like its overriding the getplayerhealth
I've been peeking around at enchantments and stumbled upon this
anyone has any idea what they mean by "start at"?
IIRC it's always 1
anyone here have any idea why the worldedit API wouldn't be giving me the correct blockdata when retrieving a block from a loaded clipboard (that was loaded from a schematic)?
on 1.19, using world edit beta 7.2.11-beta-01 on the server and API version 7.3.0
if I paste the schematic in game things like chests have the correct items, but getting the BlockState using the API doesn't have the same outcome
weird, but you're probably better off asking on their discord. IIRC they have a discord
I wonder if maybe the block entity is counted as an entity
alright yeah I'll head over there, thanks
I am getting these weird errors. I believe it is because of recursion. I just cant seem to find where the incursion is happening. Here is the code: https://paste.helpch.at/junoyirure.coffeescript (no clue why it is coffeescript) and here is the error: https://paste.helpch.at/emiyizeveb.cs
I am using a wrapper for GUIS btw (RedLib)
Yes as I said before the issue is right here.
You map the line -> code and figure out what line is giving the error.
I bet if you add some simple logging this issue will be over very fast.
My goodness that's a lot to be doing in a constructor
Indeed
lol
Seems like a misuse of a constructor tbqh. That could definitely be a static utility method at least
Also when pasting code please include everything (Ctrl+a) so we can match errors to lines 

I think it is worded wrong because really what it means is the minimum level. However, depending on settings or what gets modified, the minimum level can be different then 1. For the most part however, you are correct
hmm maybe I misunderstood it lol
I always thought it returns the value that's the "min level" for this enchantment
and IIRC there's none that doesn't start at 1
but no idea lol
assuming defaults
however, if something changes the starting level of an echanment, then it wouldn't necessarily be 1 anymore
true
I just wonder who'd say "the minimum level for my custom enchantment is 2", that doesnt really make sense
that is what I meant, is that it should be named as minimumLevel, and not starting level lol
yeah that would make more sense
Since there is a method for maxLevel, but no EndLevel ๐
well RAM isn't persistent unlike
HDD or SSD
correct
RAM = Random Access Memory. Can't be random if it never changes ๐
PR time ๐
Adds "Spigot Developer" to github bio after getting pr accepted
I already had a pr accepted ๐
I got a question about guis, is there a way to customize the way guis appear?
What would be a good & simple way to authenticate communication between 2 servers?
I have a proxy server with a few other servers that hooked into it via websocket connection
Rn i just have UUID as the server ID and then a passphrase (encrypted ofc) on both ends as well as IP verification (IE if the connecting IP mismatches a configs IP for that server it disallows the connection), i assume this would likely be good enough? Or is there some standard way this is done
explain
Theres afew things that come to mind when you say that
Like you can create a gui such as the inventory of a player, a chest, a beacon, etc
Is it possible to create a totally new GUI that Minecraft does not have
Not without forge no
like edit the buttons and appearance
You are stuck to the InventoryType enum types
How?
There is a way to make images appear in a GUI
IDK the way to do it, im sure google knows though
but ive seem some pretty crazy stuff with it
this might be very prone to dos attacks, but you could use symmetric encryption keys
Ah okay thanks
What would be prone to dos, what i have rn or symmetric encryption
I do have rate limiting both in code and through cloudfare
ip verification is unreliable
Indeed it is, but still is nice to have even though i know it can be faked somehow
Its just what i came up with rn
I was thinking maybe some ssh key type thing but im not sure how tf thats done
So i was thinking just a static encrypted keyphrase would be fine enough maybe
if there is no ip ban after a attacker sends a faulty packet the server may waste alot of power decrypting junk
i dont decyt no need to
decrypt*
I cache the encrypted passphrase for the server rn on startup
wdym
sec lemme explain
On start
-
run through config.json on proxy (Contains server UUID, allowed IP, and raw string passphrase)
-
Encrypt pasphrase with a public encryption key shared between both servers (The sending server will encrypt the password for the proxy)
From there server 1 connects to proxy, and then the proxy checks the config.json encrypted passphrase against the provided one
well the server1 would need to know the public key ahead of time
or you would need to use a certificate
Yes they both know the encryption key
its not even rly needed i just didnt wanna send the passphrase in raw text
The only thing server1 doesnt know is the password
which the proxy knows
Never used them before, i assume its similar to a JWT Token in a sense? Or a lets encrypt ssl cert?
yeah
what they use for https
but if you can just upload a public key it's alot less hassle
if server1 was an attacker they wouldn't know?
but if they are legit they will know?
Well i already am gonna be using ssl for my websockets
Rn theyre just running in ws (http) instead of wss but once i setup with SSL, i guess i could borrow the priv key from ssl and use that?
Yes only way to bypass my current system is to endlessly crack the password
I know pterodactyl just uses a token system to link between daemon and theyre containers, thats why i setup what i have rn
The servers are only ever going to be hosted by me
I think they use the token to make a symetric key
i just wanted to prevent someone from reverse engineering my proxy and gaining access to the game servers, as the CLI will be used to manage certain aspects of it
Not sure, idk how theyre code works past 0.7 since they switched theyre code up to Go
use certs
you can issue certs to each of the servers that connect to the proxy
if the server doesn't present a valid cert, then its not one of your servers
By chance is there any lib or native way in java to handle those certs?
i see
CertificateFactory
and
X509Certificate
for passwords i kinda just create and set them in config files on both servers
so like each user can have their own cert, all derived from the key on the proxy ๐
i assume i would do the same with cert? just manually give them to the servers i need?
Actually i can setup a linking system where i use a cli to create a server, and on first connection it send the cert that way
i think that may be a lot nicer
Well wouldn't want to do that, otherwise anyone who connects gets a cert ๐
lol
well it woul be a setup command in cli
and it only allows new connections for linking within a few seconds
and it will send a UUID and ask for linking confirmation
if uuid doesnt match the servers uuid dont issue cert
if you trust all servers completely symetric is still fastest
I still wouldn't issue certs like that. That is similar to how WPS works and the reason it is flawed
So just manually assign them then after creation?
how many nodes are you handling?
Depends
it will be 1-3 at the start
can be 50-100 in a few years time
They handle individualized game servers, the proxy allows safe communication between 2 game servers (If i manually connected them without the proxy, the networking would become a giagantic web and hard to manage, then proxy handes requests like server1 sends message to server2, and the two are never connected to each other) as well as easy admin interaction
im gonna look into creating certs in java rn
pretty much the best way to do it
this guarantees that the server you setup, is the one that you want authorized. While although the odds of someone trying to infiltrate your network setup, never hurts to be secure anyways ๐
Yeah i doubt anyone will ever even find this IP to this server but i just wanted to be safe
cause if proxy gets accessed all servers are at risk
well someone will find it, all ip addresses are public
Yeah but chances of them knowing what its for are slim
its just a matter of who manages to scan it first. But I was saying more or less someone trying to actually spoof being an mc server on your network lmao
ohhh
unless this is some other kind of setup
what I said would still be true in a way, and they would have basically have to wait at the right time where you were setting a server up to attempt such things with what you were wanting to do
and they would have to know the UUID
becuas eonce it connects there would be a message
"Server with <uuid> is attempting to link, accept linking and send cert (Y/N)"
so theyde have to know the new servers UUID (Which is normally created seconds before sending linking requests)
but imm just do manual
just use host key fingerprint
someone could do a mitm attack unless the connection does like a tls/ssl hanshake during setup
yeah its a handshake
It connects and directly sends the request when the socket opens, in facts its actually the opening connection message
Basically the flow would be:
On proxy (Server ID is the user friendly string of the server, basically just its name)
server create -serverid 5 -passphrase/cert cert -server_ip 192.168.0.1
And from there it will allow new connections and send
Now accepting new connections for 15 seconds, please start the game server you are wanting to link
On game server -> java -jar server.jar -> Auto connects to proxy on startup and sends its uuid (Will use HKF like frost said i like that idea better)
After the game server connects, on proxy:
Received a connection from 192.168.0.1 and it is identifying itself as <fingerprint/uuid>. Should this link be accepted, and a new cert signed for this machine?
When the game server restarts its connection it will then send the cert it was issues as authentication
I honestly dont think anyone would be able to MIT this as it would happen in mere seconds, someone would need to know the game servers hkf/uuid, as well as the game servers IP addres and be able to fool a manual review of the link
unless im dumb and dont know how web security works
(Might be the case ^)
when a connection leaves the local network you should assume it has been attacked with a mitm attack
I downloaded a source code of a plugin and loaded it on intelliJ idea and built it with gradle config but I cant find the build for some reason!
Connection wont ever leave until receiving server received its cert
Well
9:12:37 AM: Executing 'build'...
Task :clean
Task :compileJava
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Task :processResources
Task :classes
Task :jar
Task :assemble
Task :compileTestJava NO-SOURCE
Task :processTestResources NO-SOURCE
Task :testClasses UP-TO-DATE
Task :test NO-SOURCE
Task :check UP-TO-DATE
Task :shadowJar
Task :build
BUILD SUCCESSFUL in 24s
5 actionable tasks: 5 executed
9:13:02 AM: Execution finished 'build'.
Its in build/libs
o thank you!
sorry for that first passive-aggressive message i misread your msg lol
so the connection is within the lan?
RN Actually yes but in the future, i may need to run more game servers on another vps
My current configuration uses 2 IPs IP1 is used for my auth and proxy ip 2 is for game servers (They run on port increments of +1)
client server starts ssl/tls connection with server (the servers certificate is known to the client ahead of time)
client requests a certificate (it gives a random uuid to the server )
request is displayed on the server with the uuid
request is accepted
certificate is sent to the client
yep except for UUID ill use host keys
that was the single most anal discord server I have ever joined
thanks
lmfao
papercord is great
no, enginehub
epic world gen discord??
they made worledit and shit
ohhh them
they were helpful with me when i had issues with world edit api so theyre +1 with me
I actually just got an any% ban (or maybe kick)
I asked a question slightly wrong and instead of trying to figure out my question they basically just bitched about it
I asked like two questions and every one of them was responded with very passive aggressively
this shit is why people don't make github issues these days
I dont make github issues bc theyre so slow
enginehub?
world edit




