#help-archived
1 messages · Page 64 of 1
Time: 5/6/20 10:54 PM
Description: Exception in server tick loop
java.util.ConcurrentModificationException
at java.util.HashMap$HashIterator.nextNode(Unknown Source)
at java.util.HashMap$KeyIterator.next(Unknown Source)
at net.minecraft.entity.EntityTracker.func_72788_a(EntityTracker.java:290)
at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:779)
at net.minecraft.server.dedicated.DedicatedServer.func_71190_q(DedicatedServer.java:397)
at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:668)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:526)
at java.lang.Thread.run(Unknown Source)
Deleting entities in main tick
thats not a spigot log
do you know what the solution could be?
Minecraftserver? 🤔
Yeah, it keeps crashing due to that same error
Hello,
I am using ProtocolLib to grab the Vehicle Steer and Vehicle Move packets while riding a Ravager. My end goal is that the ravager's body rotate to match the rotation of the player during movement. I've got this working, but now the player rubber bands hardcore. I believe the issue extends from the fact that I am cancelling packets (line 108) and then sending new packets (110), but I don't know what else to do. If someone wouldn't mind skimming over my code to help me understand why this rubber banding occurs, I would appreciate it. Code:
https://sourceb.in/b33c82a06c
Please ping me if you have a suggested fix or any tips to optimize my code 🙂
you have a while loop that runs that code
your while loop must be continuously running
Any loop can go to infinite if not properly used
forgot to do i++
no one ever does i-- 😔
i just did i— in a discord bot
There just aren't as many cases
i'll get this error if I want to change the spawner with selfmade /spawner cmd: org.bukkit.craftbukkit.v1_8_R3.block.CraftBlockState cannot be cast to org.bukkit.block.CreatureSpawner
in console*
cast block to spawner iirc
then get spawner creature
i haven’t used a spawner in forever am probably wrong
CreatureSpawner spawner = (CreatureSpawner) targetblock.getState();
this is the code
and Block targetblock = p.getTargetBlock(new HashSet<Byte>(), 6);
and
Block targetblock = p.getTargetBlock(new HashSet<Byte>(), 6);
@ebon charm here the cast?
your error is in your spawner initialization
i could again be very wrong
and i’ll double check
but if you cast block to spawner
that should be acceptable
wait nvm
Block#getState()#getSpawnedType()
that’s should be cast-able
I have what I think to be a problem having to do with bungeecord.
I've been experiencing a problem ever since I attempted to use OnlyProxyJoin. I set it up on each server of my bungeecord network and tested it. It kicked any player who joined from any ip (even the proxy) despite attempts to prevent it from doing that. I uninstalled OnlyProxyJoin on all servers. Now, every time I try to join (even on the proxy), it gives me this message: "Kicked whilst connecting to hub: Please join directly on example.com \n This is the default message" and "Upstream has disconnected." in the proxy's console. I have been searching on the internet for fixes and I know it has something to do with bungeecord and firewalls, but each attempt I've made at fixing it has not worked. Has anyone on here had a similar problem and gotten a solution?
Whats a good skyblock plugin that you can create your own skyblock island for people to use
and vault
@frigid ember there are a ton of free/premium Skyblock plugins, I recommend you do your own research.
https://www.google.com/search?q=skyblock+plugin+spigot @frigid ember
there are a lot
I can't get Multiverse portals to work
Is it possible to make a map renderer only run once?
Whats a good way to stress test my server
spawn a bunch of mobs
On a technical standpoint is ChunkGenerator or BlockPopulator Faster? If i was making very detailed caves? I see alot of people use block populator for caves
That's most likely the job of a populator
chunk generator is faster
and like, caves are part of carving phase, if you look at vanilla
populators are decoration, that happens much later
Hey guys, how do I get the attacker in an EntityPlayer class?
@Override
public boolean damageEntity(DamageSource damagesource, float f) {
boolean damaged = super.damageEntity(damagesource, f);
if (damaged && velocityChanged) {
new BukkitRunnable() {
@Override
public void run() {
Knockback.applyKnockback(getBukkitEntity(), null, 0);
}
}.runTaskLater(Kingdoms.getPlugin(Kingdoms.class), 1L);
}
return damaged;
}
Oh nevermind, I think I found it ```java Entity entity = damagesource.getEntity();
wheres md5 @
I found him! 
Hey guys, how would I change the nametag with packets with protocollib per player?
protocolManager.addPacketListener(
new PacketAdapter(this, ListenerPriority.NORMAL, PacketType.Play.Server.PLAYER_INFO) {
@Override
public void onPacketSending(PacketEvent event) {
}
});
}
This is what I've got so far. Using gameprofiles or scoreboards isn't an option unfortunately
Could someone help me?
public static ItemStack createSkull(Inventory inv, int invSlot, String username, String displayName, String... loreString) {
ItemStack skull = new ItemStack(Material.SKULL_ITEM, 1, (short) 3);
SkullMeta skullmeta = (SkullMeta) skull.getItemMeta();
skullmeta.setOwner(username);
skullmeta.setDisplayName(displayName);
skull.setItemMeta(skullmeta);
inv.setItem(invSlot - 1, skull);
return skull;
}```
This doesn't set it to the player skull it sets to a steve head why does it do that
I use it like this Utils.createSkull(inv, 11, p.getName(), "&b&lPlay Time", "Lore");
@true anvil
ItemStack playerHead = new ItemStack(Material.PLAYER_HEAD, 1);
SkullMeta playerHeadMeta = (SkullMeta) playerHead.getItemMeta();
playerHeadMeta.setOwningPlayer(Bukkit.getOfflinePlayer(targetPlayer.getUniqueId()));
playerHeadMeta.setDisplayName(ChatColor.YELLOW+"Moderating: " + ChatColor.RESET + targetPlayer.getName());
playerHead.setItemMeta(playerHeadMeta);```
that's what I use to do it. works fine for me.
ok ill try that thanks
yep np 🙂
Im in 1.8
oh 😐
so would i change PLAYER_HEAD to SKULL_ITEM?
probably actually
ok ill try that
and now I'm not even sure that setOwningPlayer() will be there
iv been trying to find a fix for the past 2 days
yeah ill check
I cant get the uuid for a string smh
?
yea
UUID#fromString
UUID.fromString()
ok
ty
Yeah set owning player doesnt work
The method setOwningPlayer(OfflinePlayer) is undefined for the type SkullMeta
setOwner perhaps?
I'm looking for a plugin for setting up occasional broadcasts to display website/discord/dynmap links and general info
@true anvil oh, okay 😦
setOwner is what i have
ive tried autobroadcast but it's giving me trouble
wait a sec
hey what is a good scoreboard/tab list plugin
maybe try looking for an automatic command executor
@true anvil does it take a String username or Player?
then setup commands that /say
setOwner takes the Name of the player
@wanton delta not either or?
afaik its just the username of the player
1.8
ItemStack skull = new ItemStack(Material.SKULL_ITEM, 1, (short) 3);
SkullMeta skullmeta = (SkullMeta) skull.getItemMeta();
skullmeta.setOwner(username);
skullmeta.setDisplayName(displayName);
skull.setItemMeta(skullmeta);
inv.setItem(invSlot - 1, skull);
return skull;
}```
oh
thats what i had before
@patent monolith he's on 1.8
oof
username is a string
use 1.15 though, then install protocolsupport and oldcombatmechanics
does anyone know of a good broadcast plugin that supports adding click links?
Utils.createSkull(inv, 11, p.getName(), "&b&lPlay Time", "Lore");
oh
-_-
Bukkit.broadcast(username, "some.permission.here");
or, p.sendMessage(username + "'s skull obtained");
when i log user name to console it sends my ign
it does say the correct name?
i would assume profilestring is the json from that one mojang url i cant think of
that looks confusin
yeah i asked in another discord and noone could help and linked me here and said "Have fun"
lol
well in 1.15.2 it's easy
I suggest using 1.15, then install protocolsupport and oldcombatmechanics
but doesnt that mean i have to change all other plugins?
are the others not up to date?
probably, or at least update them
well if they have the newer version on spigot, go ahead and download them
@true anvil try it out on a test server first, and find if there are new plugins to replace your ones that require older version
ok i will thanks
yeah
Thats my best bet?
clone your current server
so you can go back if things go south
like copy the directory
you could also always just look at how another lpugin does it
for 1.8
and replicate it
nothing wrong with referencing code
(just dont steal it completely lol)
well afaik, isnt it possible to use vanilla commands to set skull owners?
OK, ill try that first then if it doesnt work ill try 1.15
yes perzan
@patent monolith not in 1.8 afaik
could i use something like skulldatabse to reference?
head database*
wait nvm thats $10
Maybe build 1.15 and look at the SkullMeta.java
ok
not super spigot related but I can't imagine asking this elsewhere
How can I make it so my server runs plugman unload <plugin>, copies the target artifact to the plugins diectory, the runs plugman load <plugin> on maven build or with another shortcut in intellij
Why not just live debug instead
or, in case of xy, is there another way of hotswapping on intellij?
So whenever you compile/save, it updates on the serve
^
server
yes
I think I tried live debugging but it froze up after 1 minute on an event or something like that
Wow im about to get an epic upgrade thanks sir
Guess it's time to move on from eclipse
it's always time to move on from eclipse
pats eclipse thank you 😢
I am a little attached to eclipse but there are times where we need to move on :,)
Im back bc im persistant 🙂 Soooo i found code that gives you your head (Literally what i had except without a few extra things...) And when you run the command it gives it to you so i was like yk what ill try that in my utils. So i do. And yk this is the code ``` public static ItemStack createSkull(Inventory inv, int invSlot, Player p, String displayName, String string) {
ItemStack playerskull = new ItemStack(Material.SKULL_ITEM,1, (short) SkullType.PLAYER.ordinal());
System.out.println(p);
SkullMeta meta = (SkullMeta) playerskull.getItemMeta();
meta.setOwner(p.getName());
meta.setDisplayName(ChatColor.DARK_PURPLE + "Player Info");
playerskull.setItemMeta(meta);
inv.setItem(invSlot - 1, playerskull);
return playerskull;
}``` but it still shows steve head... No notice i printed username and this is what it printed CraftPlayer{name=GenGummy} Is it supposed to print that? Im thinging my error is where im getting th player unless its supposed to say that
Stanley the steamshovel is about to get clapped by the newer shovels
@true anvil something like this should do the trick
ItemStack item = new ItemStack(Material.SKULL_ITEM, 1 , (short) 3);
SkullMeta meta = (SkullMeta) item.getItemMeta();
meta.setOwner("Demeng");
item.setItemMeta(meta);```
yes but the thing is im trying to set it for the user that opens the gui
ik
but i dont want it to be a specific head
i want it to be the player who opened the gui
meta.setOwner(player.getName()):
thats whats not working
ItemMeta#setOwner is depreceated 1.15
im in 1.8
oh lol
yeah
That worked for me back when I did something like this :thonk:
same
Try opening the GUI twice
Does it show Steve first time and then the actual head the second time
steve head both times
i let the gui sit open since i sent the message asking for help
i feel like its the way im gettig the player
private ItemStack getPlayerHead(String name, String player, String... lore) {
ItemStack head = new ItemStack(Material.SKULL_ITEM, 1, (short) 3);
SkullMeta headMeta = (SkullMeta) head.getItemMeta();
assert headMeta != null;
headMeta.setDisplayName(ChatColor.AQUA + name);
headMeta.setOwner(player);
head.setItemMeta(headMeta);
return head;
}```
my method
that I used
My project was from 2016 so no way I can find it lmfao
Didn’t know how to use git back then 😄
haha I wrote that literally 3 days ago
Hey guys, can someone join my test server I have to test nametags but I don't have another account usest.homehosted.pro:25566 (Version 1.8.8)
is that a joke?
Invalid IP lol
did you see it's 25566 not 25565?
lmao
rekt whoever I just joined and rekt nerd >:D
lol
I tried both
beaker it didnt work -_-
nothing is there now
1.8.8 👀
At least use via version :/
Nvm I got someone
I'm trying to make prefixes 32 characters in 1.8
hi
@frigid ember , my plan is to have a prefix of 16 characters, and then use the name and suffix for the rest
Do i need to export in different java when 1.8
No
was wondering if anyone knew how to make votingplugin give out keys as a reward?
And I have it with protocollib where it doesn't change the name in chat but the name above the head changes
so just use that plugin in 1.15?
@scenic tendon pretty sure you can just execute the commands for giving key on vote, no?
DOES ANYONE know how to make clickable messages?
@earnest grove message components
yes
but i want to do something like "do you accept [yes] [no]"
that tutorial doesnt explain how
literally just make a command for either yes or no
i can do this with that tutorial "[yes] [no]"
If you use a entity destroy packet does it stay as long as the player stays online?
I believe so iron man
So like, if i were to do an armorstand health bar, it would stay hidden as long as I destroy it when they log in?
yep
@stone rampart
TextComponent acceptComponent = new TextComponent("§a[ACCEPT]");
acceptComponent.setClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/duelaccept"));
TextComponent declineComponent = new TextComponent("§c[DECLINE]");
declineComponent.setClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/dueldecline"));
TextComponent interactiveComponent = new TextComponent();
interactiveComponent.addExtra(acceptComponent);
interactiveComponent.addExtra(declineComponent);
invitee.spigot().sendMessage(interactiveComponent);```
found some code I wrote a while ago
just do it like this
hmm
Hey guys, can someone join my server again? ip usest.homehosted.pro:25566 version 1.8.8. I'm testing nametags
how do i run a command when it detects a vote w/ votingplugin
How can I test if a player moved an item into a certain inv slot? InventoryDragEvent?
@stone rampart Thank you
&a for example would work right?
the method auto translates color codes?
Hey guys, I'm getting a null pointer exception, can this ever be null?
Scoreboard score = Bukkit.getScoreboardManager().getMainScoreboard();
if you are using #getMainScoreboard() it depends when you are initializing score. I looked it up quickly, and since that method uses the vanilla scoreboard manager, it means that it doesn't exist and will be initialized after the worlds are loaded
so yeah, basically it can be null, just depends on your code as a whole
(at which point you call it, it will exist but at a "specific time")
Quick and easy question
whats the best way to get someones x y and z
not trying to get it based off block preferably
Hey guys, how is PlayerInfoData#getPing() different from PlayerInfoData#getLatency()
How would I go about updating liquids after setting them in my custom chunk generator via setBlock()?
update pyshics ?
{"extra":[{"text":"Meow"}],"text":""}
Is there any way to parse this with Spigot's api?
ComponentSerializer
Thankz :3
so how would I update physics/lighting in my chunk generator?
do an if statement checking if that == null
yeah
oh wait
you want a boolean?
Sorry just confused with your question
if Teszt.use is a boolean you can do plugin.getConfig().getBoolean("Teszt.use")
or just barse it with
Boolean.parseBoolean(plugin.getConfig().getString("Teszt.use"))
getBoolean(path);
also reading from a config each time is not a good idea
you should make a class that stores the values
You're not really reading from a config (file) each time. It's cached in linked hash maps on first getConfig. With that said, if performance is what you're after, caching the exact value yourself does make sense.
what does it mean to "load" or "unload" a world?
@scenic osprey That means what it looks like.
Load meaning is load the world and chunks in the world to server.
server console[15:05:36] [Server thread/WARN]: Can't keep up! Is the server overloaded? Running 5012ms or 100 ticks behind
says this
occationally
i have 17 gb memory free
and it still says this
memory is not the issue usually when the server gets overloaded
when it is running behind, it means the cpu can't keep up with whatever is going on in the server
usually this is because you are running the server on subpar hardware, it is running in a VM with subpar cpu, or plugins and/or plugins and subpar hardware lol
Anyone got a clue why the armor stand isnt spawning with the attributes? (invisibility etc)
EntityArmorStand stand = new EntityArmorStand(EntityTypes.ARMOR_STAND, s);
stand.setLocation(loc.getX(), loc.getY(), loc.getZ(), 0, 0);
stand.setCustomName(new ChatMessage(ChatColor.translateAlternateColorCodes('&', display)));
stand.setCustomNameVisible(true);
stand.setArms(false);
stand.setInvisible(true);
stand.setNoGravity(true);
stand.setInvulnerable(true);
PacketPlayOutSpawnEntityLiving packet = new PacketPlayOutSpawnEntityLiving(stand);
((CraftPlayer)player).getHandle().playerConnection.sendPacket(packet);```
^Was working in 1.14
oh is that so. Hm how do is pawn an entity just for one player then?
Send a metadata packet after the spawn packet
yup
gotcha thanks
i have a problem with my server config its a bungee
server_connect_timeout: 5000
remote_ping_cache: -1
forge_support: false
player_limit: 100
permissions:
default:
- bungeecord.command.server
- bungeecord.command.list
admin: - bungeecord.command.alert
- bungeecord.command.end
- bungeecord.command.ip
- bungeecord.command.reload
timeout: 30000
log_commands: false
network_compression_threshold: 256
online_mode: false
disabled_commands: - disabledcommandhere
servers:
lobby:
motd: '&1Just another BungeeCord - Forced Host'
address: 26.6.247.121:25566
restricted: false
hungergames:
motd: '&1Just another BungeeCord - Forced Host'
address: 26.6.247.121:25567
restricted: false
skyblock:
motd: '&1Just another BungeeCord - Forced Host'
address: 26.6.247.121:25568
restricted: false
prisons:
motd: '&1Just another BungeeCord - Forced Host'
address: 26.6.247.121:25569
restricted: false - query_port: 25565
motd: '&1Another Bungee server'
tab_list: GLOBAL_PING
query_enabled: false
proxy_protocol: false
forced_hosts:
pvp.md-5.net: pvp
ping_passthrough: false
priorities:- lobby
bind_local_address: true
host: 26.6.247.121:25565
max_players: 99
tab_size: 60
force_default_server: true
ip_forward: true
remote_ping_timeout: 5000
prevent_proxy_connections: false
groups:
md_5: - admin
connection_throttle: 4000
stats: 3d6f1906-b3b4-4e46-a3c2-8962cba42958
connection_throttle_limit: 3
log_pings: true
- lobby
thats the config
can u create a config for me in that stae
IT GIVES AERROR
idk
how
@ripe spear You should be more descriptively whenever explaining your problem.
i mean i cant start my bungee server
And try to use hastebin/pastebin which are fore text codes if your text is large
pastebin isnot working for me
@chrome edge can you teleport to unloaded worlds?
it worked until today
ok i try
i cant add new server
localhost
ok do u mean in cha
now i wait 25 hours and still haven't got my plugin
@atomic rapids @zenith palm
I bought a plugin and haven't got it yet
ask the dev @frigid ember
on spigot
if 24 hrs has passed then there is a problem on spigot side
it happened to me too
i had to add him manually
i wait more than 25 hours
You loop through each string from the configsection "Teszt" and send a message for each rather than repeating yourself
Also plugin.getConfig().getDouble(path) returns the number to set healt
Double because there are 0.5 in half a heart
I think I've already told you this, but you should not read directly from the config each time
But tell me how do u add servers to bungee without the a problem u
Luke normallt
Normally
?
Just put the server info in the lines
Right
I am on mobile buy earlier i showed u
There thats the one i send
Yea its happens in any part
But thats the defailt
Thats the latest bungeecord
Next i have is papers waterfall or travertine
They suck
For me
Cant u dm me
Pls
I am on mobile
Ok ill copy it somewhere
Hey, so I'm having a bit of an issue with bungeecord. This is a super specific situation but i havent found many resources and I have been at this for nearly 6 hours now. Everything worked perfectly fine for the longest time but suddenly today, my server could not handle more thatn 20 people moving around. Bungeecord just uses insane amounts of cpu and everyones ping goes up. Then, the bungeecord server crashes. I'm on an I9-9900k dedicated server and there would be no reason for this cpu usage. So i'm not sure what to do. Any help would be muchhhh apreaciated. Thanks
So like clear everything out and then only drop the jar in and restart the server?
hello
Sure
if(forward > 0){ //Vooruit
EulerAngle angle = mc.getHeadPose();
dir = new Vector(Math.toDegrees(angle.getX()), Math.toDegrees(angle.getY()), Math.toDegrees(angle.getZ()));
dir.multiply(0.35);
dir = dir.setY(player.getVehicle().getVelocity().getY());
armorstand doesnt move
mc = armorstand
okay
some expreienced coders?
Alright, I'll give that a shot! thanksss
Not yet, still trying to load the new jar up
Yes I know. I saved the stuff like you said
So then I deleted everything
Now I'm putting the Jar back in and i'm going to restart.
the server
Like so it generates the files
uhh
im winging it
What third world english means reinstall is also stop the server...
Hi guys, I've been looking for a Wanted plugin for a while to put a player every x time and that he kills him gives him a reward. I have seen similar but they are outdated can you help me one for 1.15.2
Skript?
I stopped the server, deleted everything, put the jar and configs back in, and I started the server.
After doing that, the cpu still rises to like 40% when just one player joins
Gry it worked thanks
@frigid ember
Thanks
For u code
It worked
No the bungee cord config u fixed
p.sendMessage(plugin.getConfig().getDouble("Teszt.Message"));
plugin.getConfig().getDouble("Teszt.Message") == double
p.sendMessage(String)
:-)
so do p.sendMessage(String.valueOf(plugin.getConfig().getDouble("Teszt.Message")));
then your double is 0
check your config at Teszt.Message :P
just do a bit of linear algebra 👌
Hello ! I have a problem with this code : p.closeInventory(); p.sendMessage(Main.logo + " §aVotre home a bien été défini sous le nom de §e" + creationHome.get(p) + "§a." creationHome.remove(p); p.getInventory().remove(new ItemStack(Material.IRON_BLOCK, 5)); p.getInventory().remove(new ItemStack(Material.GOLD_BLOCK, 1)); p.updateInventory(); All is working great except for the items. They are not removed and I don't understand why
do they have a metadata?
nop
Try .removeItem() ?
yeah .remove() only works if the ItemStack in the inv is exactly the same
so the player should have exactly 5 iron_blocks
Oh okay, I see. Thank you !
I should have read the doc with more attention
my bad
probabily removeIfExact would've been more descriptive
Hey guys I need help from you.Basically I am making OpPrison server and I will add fortune on pickaxes.I want fortune to be able to get more blocks if you mine stone,cobblestone
Every block that is in mine
Any good plugin for it?
1.8 version
???
plssssssssss
i will pay whoever helps me 😄
cuz i dont have time
and coding is not good for me
i get idea and pay the coders
to make something
then i sell their work
So everyone knows how hypixel skyblock has collection thingies, is there any plugin doing this for 1.15.2 or if not how tf can I make that
So everyone knows how hypixel skyblock has collection thingies, is there any plugin doing this for 1.15.2 or if not how tf can I make that
@blissful verge "Collection thingies" ???
'everyone knows'... Not everyone does
I mean which record like iron mined etc.
Yeah to be honest I've never played on Hypixel once
lol
Same
BlockBreakEvent ?
But it basically records like iron ore broken and then if you break enough you unlock a recipe
So like how can I make it so when you break enough of block x you get a permission lets say iron.recipe.1
Anyone know much about NMS im trying to do entityplayer.spawnin it works, but the player has to relog
in the W key packet i want to move the armorstand in the direction of the headpose
EulerAngle angle = mc.getHeadPose();
dir = new Vector(Math.toDegrees(angle.getX()), Math.toDegrees(angle.getY()), Math.toDegrees(angle.getZ()));
this doenst work
?
@blissful verge statistics?
I guess
@wanton delta Atleast this one isn't for 1.15.2 https://www.spigotmc.org/resources/stats.3638/
When I use the restart script I get another CMD window stating " '.' is not recognized as an internal or external command,
operable program or batch file."
c:\users\username\Desktop\Mincraft Server>
Any Idea how to fix?
mines a .bat
mine is*
it still restarts, it just opens up another cmd window
also getting that. How do I stop programs from using that port?
you have another server running on your same port
you obviously can't run two servers on port 25565 or whatever
you'd need to close the other before
I don't have another server running though
egyt check your task manager close all jar
anyone know how to link an mc account to an account on a forum (not xenforo/mybb etc)
I did that
?
I had closed all jar before, but it still says it's being used.
I even did a command in cmd to tell me what ports are being used
@arctic stone i thought you meant you did the account link before lmao
No thosemethods sont work
Yhea
you have something running on that port if it can't start...
Did u port foward
I port forwarded
At least try to
It worked yesterday
Did u change somethig as of yetrday
but today my internet just stopped working
and I had to restart router
maybe that is why
lol
May be it will help
And remove the portfoward
The port doesant mattet
The ip
Is the thing
So the local host is used with that ip
Or you portfoward ip
Chances are if you've restarted your router and it's now not working, you're on a dynamic IP
Check your external IP, see if it's changed
For me i just changed the ip of my server in rhe server prooerties fille
And didnt portfoward
I use radmin vpn
Its secure more
Than portfoward
I can join using thar ip now but not with localhost
I wouldn't say it's more secure
No
if anything, you're just adding more potential for exploitation lmao
But its morr
Nit actualy a vpn its network
U need to join the networj
To join the ip
Do I just use IP chicken to check external IP
U can easily use it without portfoward
Just type wahts my ip in a browser
Or some other way
Ip chiken ?
I'm setting a static IP using portforward software
What did u use to set tge portfoward
Check your machines IP, check your external IP and make sure neither has changed
Until we know that information is correct, we won't get anywhere
I set my pc's IP to a different one. Gonna change the config file of server to match new IP
I changed my external IP
Any can help me for make a plugin?
gonna change the server one now
Any can help me for make a plugin? if you can dm me
And yeah, it had changed
Hey i dont know very much about coding
due to it being dynamic
Thought so
Might be the case
Not the place to ask, go to the forums
ok
YESSS!!! It worked 🙂
Nice one
What
yaw and pitch
Nope
?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.
Using worldedit?
using bukkit
You'll need worldedit
but i can fill an area in vannila with /fill
can someone recommend me an anti-vpn api?
Don't know anyone that's ever used vanilla /fill lmao
i was just wondering if there was an easier way to do it in a plugin since i dont want to make 81 variables for a small cube
9 i mean 9
how do i store multiple block types
Hello
@hollow thorn I think NMS does that anyway
So I mean I don't think it would be a big deal to make those references
@arctic stone
Atleast for me the server breaks if I use restart. Try stopping and starting server again always when you want to "restart".
Lol, I fixed it. But thank you!
How do you make a custom currency as a Vault Economy?
Okay
Hello!
Does anyone knows the best way to iterate the whole world already generated chunks?
Maybe reading region files directly? It'd be really nice if an API already exists for that task
Thanks
yep exact, I have to iterate all chunks generated in a world to get every location of every block of a particular type set as search argument
this task will be executed only one time and doens't matter how much time it'd take
well then parse the region files for their x, z then load the chunk and do things to them
so i parse the region file, check which chunks it contains, load the chunk using spigot api and iterate its blocks?
yeah
okay seems legit if there's no other solution, an API would be cool but i cannot find anything online (i want to avoid reinventing the wheel)
i doubt there would be a better way
parse their name split dot get 1 and 2
then parse them to int
x and z
Hello, when I do a restart using my start.bat file, another window opens. Here is a screenshot of it.
The server restarts but that pops up.
run file name maybe instead?
the bat filename
yeah, I run the file name.
ohh, you mean run.bat
I use a plugin to do an autorestart. I'll send a screenshot of my .bat file
anyone know how to link an mc account to an account on a forum (not xenforo/mybb etc)
just to a website in general
I still get that popup
do you use a plugin to do an autorestart?
no
or timer?
i just /stop
ok
how do i know if someone jumping
did they add PlayerJumpEvent?
Ok.
last time I search for it there wasn't
it isnt.
only paper has playerjumpevent
you'll need to make your own playerjumpevent if you want to be compatible with spigot
does entity-activation-range override the entity's pathfinder range?
so there is no way i can use playermove event to know if a player is jumpin?
you definetly can but it won't be only for jumping
thats probably fine.
for a bungee PluginMessageEvent sent from a connected server to the bungeecord server, how can I get the player that the message was sent through?
it's not in the event?
Connection sender, Connection receiver, String tag, byte[] data
i imagine one of them is the spigot server and the other is the proxy server
it might be sender
since the plugin message never gets sent to the player
/**
* Creator of the action.
*/
private final Connection sender;
but if it's being sent to a player....
it's send or received?
sent from spigot to bungee
it should be sender imo
so what would receiver be
was a getPlayer too much to ask for 😭
more details in the java docs would've been more useful
Any of you heard of Apex minecraft hosting? Cause I need some help...
I found so strange thing... If you put custom head on gui in thread and if there's another custom head in same slot, it would be very slow. Does anybody know that issue?
why 1.8.8
why not 1.8.9?
why not 1.4
ah yes.
@quasi rapids they use multicraft as their panel so go ahead?
1.8.9 had no server release
Hey guys, when I try adding a player to a scoreboard team no one sees the prefix or suffix
String prefix = "[32Longcharacterprefix] ";
PlayerConnection connection = ((CraftPlayer) p).getHandle().playerConnection;
PlayerInfoData pid = event.getPacket().getPlayerInfoDataLists().read(0).get(0);
ScoreboardTeam team = new ScoreboardTeam(
((CraftScoreboard) Bukkit.getScoreboardManager().getMainScoreboard()).getHandle(),
p.getName());
team.setPrefix(prefixScoreboard.toString());
team.setSuffix(suffixScoreboard.toString());
ArrayList<String> playerToAdd = new ArrayList<>();
playerToAdd.add(pid.getProfile().getName());
connection.sendPacket(new PacketPlayOutScoreboardTeam(team, 1));
connection.sendPacket(new PacketPlayOutScoreboardTeam(team, 0));
connection.sendPacket(new PacketPlayOutScoreboardTeam(team, playerToAdd, 3));
PlayerInfoData newPid = new PlayerInfoData(pid.getProfile().withName(nameScoreboard.toString()),
pid.getPing(), pid.getGameMode(), WrappedChatComponent.fromText(name));
event.getPacket().getPlayerInfoDataLists().write(0, Collections.singletonList(newPid));
if you do it this way only the player p will receive the packet and so only him will see the change
The player I want to have the prefix is the player with the name pid.getProfile().getName()
you have to get the connection of him not the connection of p
But then how would p be able to see the prefix?
The player I want to have the prefix is the player with the name pid.getProfile().getName()
@frigid ember
i dont get it who of the 2 players need to see the prefix
p has to see the prefix of the player with the name pid.getProfile().getName()
you can't change chat messages with packets because the server handles the chat and the prefixes
if you want p to get the prefix of pid you should use the packet for sending a chat message to p
Just quickly how would I make an explosion?
I just need to make a quick plugin for myself and want arrows to explode, here's what I have so far:
for(Entity entity: SpanishCore.get().getServer().getWorld("world").getEntities()) {
if(entity instanceof Arrow) {
if(entity.getVelocity().equals(new Vector(0, 0, 0))) {
//Explode
}
}
}
Small spanish project ^
Nevermind got it
Or if there is some event to make it look a bit nicer?
World#createExplosion iirc
Ok thanks, is there some event to check if the arrow lands or only by a task like above?
my plugin RandomPackage loads in but none of the commands work, when I click the java file it says invalid or corrupt files and idk how to fix it can anybody help?
Can someone help me on my server again? usest.homehosted.pro:25566 1.8.8
@wheat summit ProjectileHitEvent is called when the projectile hits an object
Ah ok thanks a lot!
I have a problem with some code but it'd be quite a long message to send here so I created a thread on the forums. If anyone can give it a look and help me that'd be great. Thanks! 😁
https://www.spigotmc.org/threads/exceptionininitializererror-npe.436999/
you should post the code for EnvoyManager
i'll make an edit
also, not related to the issue, if possible dont call everything a Manager
sometimes manager doesnt really explain what the class does
yeah true
i'll make sure to stop doing that
what code do you want from the EnvoyManager?
bc i dont think any of the methods from it are causing the errors
Does anyone know where the server .jar is? for some reason I can't find it...
Download for it
you have to run buildtools @wheat summit
Ok thanks
@inland depot I think the problem is you're not doing singletons properly
you're trying to create an instance of the class outside of the constructor
@subtle blade do vanilla items have an ItemMeta?
if possible you shouldnt even be using singletons
i dont think its possible
and instead use dependency injection
don't use singletons
i have multiple classes that need info from the EnvoyManager class
ah thank you, as i thought
If you're fetching it from a vanilla source, it most likely will not have meta
you can pass the instance around
(unless it obviously does have some sort of meta - name or whatever)
I'm trying to make one instance and use it for multiple classes
xUltraGaming
EnvoyManager in your main plugin class
how would you recommend initializing the envoymanager in the onenable
EnvoyManager should have a constructor that you pass your plugin instance to
also, dependency injection is more testable/reusable,
explicit cohesion and defined ordering of how classes are used
Scoreboard score = Bukkit.getScoreboardManager().getMainScoreboard();
if (score == null) {
p.sendMessage("null score");
return;
}
Team team = score.getTeam(newPid.getProfile().getName());
if (team == null) {
p.sendMessage("creating new team");
team = score.registerNewTeam(newPid.getProfile().getName());
}
team.addEntry(newPid.getProfile().getName());
Hey guys, why are team prefixes and suffixes not showing up
@boreal tiger I removed all of the getInstance() methods and references and added a constructor the EnvoyManager
Gonna test it now
I fixed the error, now I need to see if the instance worked
how do I fix jar file is corrupt or invalid
can I do that with a server hosting company?
ite
fun, the original error is back
Can someone join my server or download the jar and test it, I don't have 2 accounts usest.homehosted.pro:25566
1.8
@frigid ember That's vanilla 1.8 behaviour. Name tags are limited to 16 characters afaik
@marsh nova I'm making it so that 16 character prefix for the prefix + 16 for the name, and then the players real name goes in the suffix, so instead of dividing it up into 16 / 16/ 16 I'm doing 32/16
Like I said, the complete name tag can't be longer than 16 characters
16 for the prefix, 16 for the name, and 16 for the suffix
@marsh nova are you able to come on though? usest.homehosted.pro:25566
what would that do?
I have it so that if you have 32 characters in the config as a prefix, it sets the team prefix to the first 16 characters, and then your name gets sent to the other 16, and then your real name gets put in the suffix
@frigid ember have you tried retrying
I see
Are you able to come on?
First one to come on gets $0.10
OK FINE
I MADE A FAKE PLAYER
Gg
+1
+2
How does tab reborn do it? https://www.spigotmc.org/resources/tab-1-5-x-1-15-x-free-version.57806/
When in doubt, look at source
Yeah, I'm having trouble finding where they do it
Hey guys, do you know how to fix player skins being set to alex when I do this
PlayerInfoData newPid = new PlayerInfoData(pid.getProfile().withName(nameScoreboard.toString()),
pid.getPing(), pid.getGameMode(), WrappedChatComponent.fromText(name));
event.getPacket().getPlayerInfoDataLists().write(0, Collections.singletonList(newPid));
i'm using this for skins:
gameProfile.getProperties().put("textures", new Property("textures", npcdata.texture_value, npcdata.texture_signature));
What is event for right clicking armor in hand? BlockPlaceEvent and/or PlayerInteractEvent doesn't work (allows me to still to equip it)
what is the velocity of an entity when it is standing still? its not 0 apparently...
or velocity.length
are you checking if entity is standing still or something different?
add threshold. velocity.length < 0.1 or something
I'd suggest you use Velocity#lengthSquared instead to avoid the costly square root
thanks for the tip
and yea i should probably debug what the minimum is
thanks for that suggestino
I Have an problem, How can i convert an String to Double without it to look like this: 1.23456789E8
i tried:
public static double getMoneyFormat(double balance) {
String pattern = "";
if (MF == 1)
pattern = "#0";
if (MF == 2)
pattern = "#0.0";
if (MF == 3)
pattern = "#0.00";
if (MF != 3 || MF != 2 || MF != 1)
pattern = "#0";
DecimalFormat formatter = new DecimalFormat(pattern);
Double balance2 = balance;
String formatted = formatter.format(balance);
if (formatted.endsWith("."))
formatted = formatted.substring(0, formatted.length() - 1);
return Double.valueOf(formatted).longValue();
}
if so, divide Y by 0.98, and then add 0.08
nah i jsut realized the velocity only matters when the player is airborne
is there a Spigot 1.7.10 download anywhere? and if so, is there a way to run Forge Mods on it? and Spigot can run Bukkit Plugins right?
buildtools doesnt have 1.7
- yes
oh?
well
anyways
you're looking for sponge i believe
this isnt the discord for that
Okay, so then, is there a way to get Spigot for 1.7.10?
not really
well, no official way
you can download it off some sites, but im afraid if i post it here I'll get harassed by the people here
or you can go to ipvp's github repository, clone it, and compile it
it's a paperspigot fork, though
What's PaperSpigot?
a fork of spigot
a fork is basically a mod, or extension
pretty much spigot, but with some slight changes to the code
why the hell are you using 1.7.10
So... whats the Differences between Paper Spigot and Spigot?
Trying to set up a modded server for a friend
slight changes in the code. paperspigot claims to run faster than spigot
Hey when I want to start my server I get this problem :
[21:57:48] [Server thread/INFO]: Starting minecraft server version 1.15
[21:57:48] [Server thread/INFO]: Loading properties
[21:57:49] [Server thread/INFO]: This server is running CraftBukkit version git-Spigot-f39a89e-4633e6c (MC: 1.15) (Implementing API version 1.15-R0.1-SNAPSHOT)
[21:57:49] [Server thread/INFO]: Debug logging is disabled
[21:57:49] [Server thread/INFO]: Server Ping Player Sample Count: 12
[21:57:49] [Server thread/INFO]: Using 4 threads for Netty based IO
[21:57:49] [Server thread/INFO]: Default game type: SURVIVAL
[21:57:49] [Server thread/INFO]: Generating keypair
[21:57:49] [Server thread/INFO]: Starting Minecraft server on *:25565
[21:57:49] [Server thread/INFO]: Using default channel type
[21:57:51] [Server thread/WARN]: **** FAILED TO BIND TO PORT!
[21:57:51] [Server thread/WARN]: The exception was: java.net.BindException: Address already in use: bind
[21:57:51] [Server thread/WARN]: Perhaps a server is already running on that port?
[21:57:51] [Server thread/INFO]: Stopping server
[21:57:51] [Server thread/INFO]: Saving players
[21:57:51] [Server thread/INFO]: Saving worlds
could anyone help me please?
I was gonna try to use Cauldron
@frigid ember some other application is already running on port 25565
close your other services on port 25565
how do I stop that ?
you can do it from htop
?
or a task manager
Yeah but I don't know what are the services that run on my port
well in that case you can go into your server.properties file and change the port to something else
what I want or ?
okay
for example, if you changed your port to 32523, your address would look like this 123.456.789.012:32523
you're welcome
Does anyone know why this isn't working?
File userdata = new File(Bukkit.getServer().getPluginManager().getPlugin("DonationClaim").getDataFolder(), File.separator + "userdata");
File playerFile = new File(userdata, File.separator + uuid + ".yml");
wut why are you getting your own plugin like that
also have a read on this
https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/io/File.html
@odd rover use DI or MainClassName.getPlugin(MainClassName.class) as an instance of main. You also don’t need to create a File instance for a directory. Make something like this.
File user = new File(MainClass.getDataFolder() + File.seperator + “userdata”, uuid + “.yml”);
if (!user.exists()) user.createNewFile();```
(It’s recommended to use DI of main for managing userdata plainfiles)
thank you conclure :) using parts of your example, I was able to fix it :]
😉
this is argent which one of these https://cdn.discordapp.com/attachments/695335638794240030/708064756337999943/wswsw.PNG
makes hopper minecarts disappear with clearlagg
i'm at the end of my rope guys. i can't figure out how to create a hyperlink in chat that works unless it's a /tellraw, which i cant get to work on broadcasts
im sure there is a plugin out there which will let you do that
i'm using chatmanager for broadcasts
Hey, any help for massive lag on a small server ?
i've looded ceasely for a plugin that would do that for me too
looked*
Here is some stats : https://timings.spigotmc.org/?url=ihekococeg
@glacial drum Check out NameTagEdit GitHub would be my advice, they use teams to set playernames but dont intervene with scoreboards
o/ hello.
Just looking at Bukkit Bungee Messaging Channel.
Is there any way I can get the server a player is on?
I've seen it a million times before where people have / commands or broadcasts containing hyperlinks. I just can't figure it out xD please help!
@glacial drum You could see how to put players on multiple teams from it possibly
@frigid ember look at base component
is that a plugin?
finding something about bungee and it
no luck still
does anyone know how to upload a paper.jar into the multicraft panel?
(not using a hosting company, just regular multicraft)
Having a issue, I am trying to convert the block placed into water level 7. But it simply evaporated despite my attempt to turn off blockphysics.
Here's the code:
``
public class OnBlockPlaceListener implements Listener {
@EventHandler
public void onPlayerBlockPlace(BlockPlaceEvent event) {
NameOfPlugin mainclass = JavaPlugin.getPlugin(NameOfPlugin.class);
Player p = event.getPlayer();
if (event.getBlock().getType().equals(Material.LAPIS_BLOCK)) {
if (p.isOp() && mainclass.MakeWaterLeveled7 == true) {
event.getBlock().setType(Material.WATER);
p.sendMessage("Yo we heard you wanted special water.");
Levelled waterlevel = (Levelled) event.getBlock().getBlockData();
waterlevel.setLevel(7);
event.getBlock().setBlockData(waterlevel, false);
}
}
}
}
``
Basically, I want ultra thin water. When I test it out I do indeed see the lapis block turning into water level 7. But then it almost immediatly dissapears, almost as if it's evaporating. I don't want that.
why do you get plugin instance like this?
Hey guys.
Do you know where I can get help with massive lag on a small server 🙂 ?
use /timings
Got that : https://timings.spigotmc.org/?url=ikevebuqay most time spent on entity, can't really figure out why
Only 6 player active, server is quite powerful, tps is between 10 and 17
i see world save spike
i see a whole lot of numbers 😳
too many entities maybe?
what cpu is the server on.
There's not THAT much. Fews cows, I've reduced activation to "12" for animals.
and rest of it's specs
8 core intel 2.4ghz
ssd or hdd
what plugins are you running?
WorldBorder, that's all
Hey.. Hello
quick question... how to show all map, which command i use as OP? Ty in advance
Im getting a Could not pass event EntityDeathEvent error when using EntityLiving#damage any way around that?
you're trying to damage an entity when they die? lol
It's only on the killing strike, the mob is still alive when called
you're trying to damage an entity when they die? lol
Extra death
lol
It's only on the killing strike, the mob is still alive when called
okay, so i guess the error is just #damage is broken
🤦
@frigid ember Show config
@lusty vortex
auto-removal: minecart: true
Change to minecart: false
thx man
@lusty vortex by
- this_world <-This world will be ignored during removal!
oh wait
i cant find that
the auto removal
AH
thx
Hey guys, do you know how to fix this https://www.spigotmc.org/threads/player-skins-not-working.437041/
Hello I can't connect to my localhost's server
[01:54:11] [Server thread/INFO]: /127.0.0.1:50663 lost connection: Internal Exception: io.netty.handler.codec.DecoderException: java.lang.NullPointerException
That's the problem
@frigid ember what ip are you entering on minecraft?
localhost:25566
25566?
I changed the port cause 25565 are in use
Do you have another server running as well?
What service?
Restart the machine
What does it say when you try to use 25565?
It stops the server
Wait i'll give you the log
[21:57:48] [Server thread/INFO]: Starting minecraft server version 1.15 [21:57:48] [Server thread/INFO]: Loading properties [21:57:49] [Server thread/INFO]: This server is running CraftBukkit version git-Spigot-f39a89e-4633e6c (MC: 1.15) (Implementing API version 1.15-R0.1-SNAPSHOT) [21:57:49] [Server thread/INFO]: Debug logging is disabled [21:57:49] [Server thread/INFO]: Server Ping Player Sample Count: 12 [21:57:49] [Server thread/INFO]: Using 4 threads for Netty based IO [21:57:49] [Server thread/INFO]: Default game type: SURVIVAL [21:57:49] [Server thread/INFO]: Generating keypair [21:57:49] [Server thread/INFO]: Starting Minecraft server on *:25565 [21:57:49] [Server thread/INFO]: Using default channel type [21:57:51] [Server thread/WARN]: **** FAILED TO BIND TO PORT! [21:57:51] [Server thread/WARN]: The exception was: java.net.BindException: Address already in use: bind [21:57:51] [Server thread/WARN]: Perhaps a server is already running on that port? [21:57:51] [Server thread/INFO]: Stopping server [21:57:51] [Server thread/INFO]: Saving players [21:57:51] [Server thread/INFO]: Saving worlds
@patent monolith
Hello I can't connect to my localhost's server
[01:54:11] [Server thread/INFO]: /127.0.0.1:50663 lost connection: Internal Exception: io.netty.handler.codec.DecoderException: java.lang.NullPointerException
Nvm it was ProtocolLib who do that error
@frigid ember what does your server's startup batch file look like? What's in it?
Need help finding a plugin that allows users to get efficiency 6 power 6 sharp 6 etc on an enchantment table at low chances, and allows players to add mending books, etc to kits that have efficiency 6 on items (essentials unsafe enchantments)
Any help would be appreciated
Guys I keep getting this error
java.lang.NullPointerException
at me.phaze.tab.Tab.changeSkin(Tab.java:206) ~[?:?]
at me.phaze.tab.Tab$1$1.run(Tab.java:137) ~[?:?]
at org.bukkit.craftbukkit.v1_8_R3.scheduler.CraftTask.run(CraftTask.java:71) ~[spigot-1.8.8.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.craftbukkit.v1_8_R3.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:350) [spigot-1.8.8.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.MinecraftServer.B(MinecraftServer.java:723) [spigot-1.8.8.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.DedicatedServer.B(DedicatedServer.java:374) [spigot-1.8.8.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.MinecraftServer.A(MinecraftServer.java:654) [spigot-1.8.8.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:557) [spigot-1.8.8.jar:git-Spigot-db6de12-18fbb24]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
((CraftPlayer) pl).getHandle().playerConnection.sendPacket(
new PacketPlayOutPlayerInfo(EnumPlayerInfoAction.REMOVE_PLAYER, ((CraftPlayer) p).getHandle()));
#general for more code
Player target = Bukkit.getPlayer(pid.getProfile().getName());
Bukkit.getConsoleSender().sendMessage("----" + pid.getProfile().getName());