#help-development
1 messages · Page 1687 of 1
what
it tells you everything
use the docs to look at methods for the config
?jd
FileConfiguration
do someone know a free maven provider like jitpack?
why not use jitpack?
i fucked it
Jitpack
Oh
its not giving me any options to get fileconfiguration or anything
it tells you how though
You cant compile with nms on your classpath
ik
ive checked it... unless im blind, i didnt see it
config = YamlConfiguration.loadConfiguration(file);
InputStream configStream = plugin.getResource(fileName);
if (configStream == null) {
return;
}
config.setDefaults(YamlConfiguration.loadConfiguration(new InputStreamReader(configStream, Charsets.UTF_8)));
}
configStream.close();
Hey all,
Anyone know why when I run:
INSERT INTO `premiumpunishments`.`players`(`uuid`,`username`,`banned`,`banexpirydate`,`muted`,`muteexpirydate`,`warns`,`kicks`)VALUES(uuid='511eef29-4923-4497-bbad-4172dd22a16e',username='Exortions',banned='false',banexpirydate='2021-09-10 17:12:00.016',muted='false',muteexpirydate='2021-09-10 17:12:00.016',warns='0',kicks='0');
it inserts all zeroes into SQL?
Raw Java code:
String sql = "INSERT INTO" +
" `" + PremiumPunishments.getPlugin().getDatabase().getDatabase() + "`.`players`(" +
"`uuid`," +
"`username`," +
"`banned`," +
"`banexpirydate`," +
"`muted`," +
"`muteexpirydate`," +
"`warns`," +
"`kicks`" +
")" +
"VALUES(" +
"uuid='" + player.getUniqueId() + "'," +
"username='" + player.getName() + "'," +
"banned='false'," +
"banexpirydate='" + new Timestamp(System.currentTimeMillis()) + "'," +
"muted='false'," +
"muteexpirydate='" + new Timestamp(System.currentTimeMillis()) + "'," +
"warns='0'," +
"kicks='0'" +
");";
here's a screenshot: I honestly have no clue why this is happening, no results on Google
wait lemme send Imgur
Whats the problem here? Error occurred while enabling plugin v1.0 (Is it up to date?) java.lang.NullPointerException: Cannot invoke "org.bukkit.command.PluginCommand.setExecutor(org.bukkit.command.CommandExecutor)" because the return value of "com.CJendantix.plugin.Plugin.getCommand(String)" is null at com.CJendantix.plugin.Plugin.onEnable(Plugin.java:17) ~[?:?] at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:264) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:342) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:480) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at org.bukkit.craftbukkit.v1_17_R1.CraftServer.enablePlugin(CraftServer.java:511) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at org.bukkit.craftbukkit.v1_17_R1.CraftServer.enablePlugins(CraftServer.java:425) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at net.minecraft.server.MinecraftServer.loadWorld(MinecraftServer.java:619) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at net.minecraft.server.dedicated.DedicatedServer.init(DedicatedServer.java:266) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at net.minecraft.server.MinecraftServer.x(MinecraftServer.java:1010) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at net.minecraft.server.MinecraftServer.lambda$0(MinecraftServer.java:305) ~[spigot.jar:3231-Spigot-3c1fc60-e167f28] at java.lang.Thread.run(Thread.java:831) [?:?]
command is not in plugin.yml because the return value of "com.CJendantix.plugin.Plugin.getCommand(String)" is null
IK
I don't understand that, here is my main file ```package com.CJendantix.plugin;
import org.bukkit.plugin.java.JavaPlugin;
import com.CJendantix.plugin.commands.PluginCommands;
import com.CJendantix.plugin.events.TutorialEvents;
import com.CJendantix.plugin.items.ItemManager;
public class Plugin extends JavaPlugin {
@Override
public void onEnable() {
PluginCommands commands = new PluginCommands();
getCommand("heal").setExecutor(commands);
getCommand("givewand").setExecutor(commands);
getCommand("givefirewand").setExecutor(commands);
getCommand("giveadminwand").setExecutor(commands);
getServer().getPluginManager().registerEvents(new TutorialEvents(), this);
getServer().getConsoleSender().sendMessage("Plugin Enabled");
ItemManager.init();
}
@Override
public void onDisable() {
getServer().getConsoleSender().sendMessage("Plugin Disabled");
}
}
why are you setting all commands to teh same executor?
anyway, as I said one of your commands is not in your plugin.yml
it wasn't tabbed correctly givefirewand: description: Gives the TNT on a stick. usage: /<command> permission: default:op permission-message: You do not have permission to use this command! giveadminwand: description: Gives the OP Admin Weapon. usage: /<command> permission: default:op permission-message: You do not have permission to use this command!is now givefirewand: description: Gives the TNT on a stick. usage: /<command> permission: default:op permission-message: You do not have permission to use this command! giveadminwand: description: Gives the OP Admin Weapon. usage: /<command> permission: default:op permission-message: You do not have permission to use this command!
THAT IS ONLY PART OF MY PLUGIN.YML
its still not tabbed correctly
anyone?
use a stringbuilder
you're creating a new instance of StringBuilder everytime you use '+'
and when I print it to the console I get INSERT INTO premiumpunishments.players(uuid,username,banned,banexpirydate,muted,muteexpirydate,warns,kicks)VALUES(uuid='511eef29-4923-4497-bbad-4172dd22a16e',username='Exortions',banned='false',banexpirydate='2021-09-10 17:12:00.016',muted='false',muteexpirydate='2021-09-10 17:12:00.016',warns='0',kicks='0');
therefore it works
Just SQL doesn't handle it correctly?
ik
String sql = new StringBuilder()
.append("INSERT INTO")
.append("`uuid`," // etc.
why would that do anything
you're creating a new instance of StringBuilder everytime you use '+'
make it faster
okay but that wasn't really relevant
Jesus
Why doesn’t the compiler optimize that
it might, idk
can you just listen lmao
the string once built is INSERT INTO premiumpunishments.players(uuid,username,banned,banexpirydate,muted,muteexpirydate,warns,kicks)VALUES(uuid='511eef29-4923-4497-bbad-4172dd22a16e',username='Exortions',banned='false',banexpirydate='2021-09-10 17:12:00.016',muted='false',muteexpirydate='2021-09-10 17:12:00.016',warns='0',kicks='0');
The SQL is correct
Which is why I asked the question- SQL is being weird and I don't know why.
Afaik "a"+"b"+"c" compiles to new StringBuilder().append("a").append("b").append("c").toString()
JDK 9+ someone said
im using JDK 8
Well Java 8 is old af anyways
Java 5
um, the values should not have the names, they should just be values
print the actual query
lemme show u
String sql = "INSERT INTO" +
" `" + PremiumPunishments.getPlugin().getDatabase().getDatabase() + "`.`players`(" +
"`uuid`," +
"`username`," +
"`banned`," +
"`banexpirydate`," +
"`muted`," +
"`muteexpirydate`," +
"`warns`," +
"`kicks`" +
")" +
"VALUES(" +
"uuid='" + player.getUniqueId() + "'," +
"username='" + player.getName() + "'," +
"banned='false'," +
"banexpirydate='" + new Timestamp(System.currentTimeMillis()) + "'," +
"muted='false'," +
"muteexpirydate='" + new Timestamp(System.currentTimeMillis()) + "'," +
"warns='0'," +
"kicks='0'" +
");";
"VALUES(" + "uuid='" +
🤓
you are including the value names in values
No you not
Hello, sorry but my Maths are really bad
do you know how can I get the distance between a player and the current worldborder?
the worldborder is the vanilla one, a square
I found this:
But is giving bad values when player is near to the border, negative values
Abs the players X and Z, then use the larger one to check the distance to the border
what do you mean with using the larger one?
I abs the border size too?
if you summon for example, an arrow. Is it possible to change the amount of damage it deals?
?
fck i cant send screenshot
I’ve not tried it but it should work
double result;
Location playerLocationABS = player.getLocation();
playerLocationABS.setX(Math.abs(player.getLocation().getX()));
playerLocationABS.setZ(Math.abs(player.getLocation().getZ()));
double borderSize = Bukkit.getWorld("world").getWorldBorder().getSize()/2;
if (playerLocationABS.getX() > playerLocationABS.getY()) {
result = playerLocationABS.getX() - borderSize;
} else {
result = playerLocationABS.getZ() - borderSize;
}
player.sendMessage(
"You are "+
result +
" Blocks away from the border!");
}```
EntityDamageByEntityEvent
k
well is just for testing if works
i try
Lol it works perfect!!!
so in this event, how would I actually change the damage it deals
Add a pdc tag to the arrow
setDamage
And then use event.setDamage
@young knoll Thanks you very much with the distance problem. I should have attended more in math classes hehehe
Oh but I see that is only working well in one side of the square
how do I make it only by an arrow, and what should I use to make it only an arrow summoned by my "Admin Wand"
?pdc
would this make uuid never be null?
this.uuid = uuid == null ? null : "";
If you really want a not null uuid
for other stuff
UUID.randomUUID iirc
Anyways Id use Objects::requireNonNullElseGet rather than the ternary
alright
Lmao
Yeah me too
ok but how would I apply this PersistentDataContainer to only arrows shot by my "Admin Wand"
Or the one without Get at the end of the object isn’t a heavy one
Get the PDC instance from the arrow you spawn?
Is the wand an item you right click
Or a bow
this one
Then you are manually spawning an arrow
yes
Arrow a = player.launchProjectile(blahblah)
requireNonNullOrElseGetObjectWhichIsNonNullOtherwiseApplicationBreaks
???
uuid = Objects.requireNonNullElse(uuid, ""); this one is actually easier @ivory sleet
public class MyCustomArrow {
private final NamespacedKey pdcKey;
public MyCustomArrow(Plugin plugin) {
this.pdcKey = new NamespacedKey(plugin, "my.custom.arrow");
}
public boolean isArrow(Projectile p) {
PersistentDataContainer pdc = p.getPersistentDataContainer();
return pdc.has(pdcKey, PersistentDataType.BYTE);
}
}
I have no Idea what that means
should I create a new class for my arrow*
i'd do it
Yes but it depends, you see there you have to pass an object of corresponding type, with the get one you can pass a factory reducing redundant object creation
also read up on that thread to understand this, and implement a way to set the custom arrow to an itemstack
With that being said interned strings are probably fine since they’re value based
Whaaaaa
just read the thread
I copy and pasted this ^ (I'm sorry) Where is the data actually stored here
in the entity container
here? "my.custom.arrow"
thats the key
ok I'll change that
@shadow tide You should probably brush up on your Spigot/Java skills a bit
I know
its like a map on a thing
I just want to store something like an NBT value (I was an expert in minecraft commands once) or a tag so I can identify the entity so I can change how much damage it does, not something super complicated like this don't you dare hit me with the its suuuper simple you just need to know more java hahahaha
🥲
I'm looking at you
It is literally easy nbts
just read the thread
?pdc
I DID
then you should understand how to use it
I DON'T UNDERSTAND
I dont know
i cant really help you
if you got a question ask it, but that thread covers it all
just go with it
when your comfort zone is making calculators in python thats when you start feeling like me
ok, in the thread he stores this PersistentDataType.DOUBLE, Math.PI right?
yeah
what is he actually storing, and what is the use of what he did store
he stored the PI value
so when I store I should do PersistentDataType.DOUBLE, Math.aidhludhg
you would store
PersistentDataType.BYTE, (byte) 1
because in this case, the byte exists
so you can check if it exists when you're checking for admin arrow
so should I replace 1 with something?
lets say I'm using multiple PersistantDataTypes (this is just an example) would I replace the 1 with something?
what do you want it to be
idk
the byte represents a boolean, or just a placeholder since you're only using #has
people keep using #s, what does that mean
A a = new A();
a.something();
// a#something
B.something();
// B.something
= instance representation
yes
k
ok so when I summon the arrow Player player = event.getPlayer(); Entity entity = player.getWorld().spawnEntity(player.getLocation(), EntityType.ARROW); Vector velocity = player.getEyeLocation().getDirection(); velocity.multiply(2); entity.setVelocity(velocity);
how do I add a PersistantDataType to it
entity.getPersistentDataContainer()
this is so much simpler than I thought, but I'm not done yet
How can i change the damage of a weapon in 1.8.8 ?
I used attributes, then again I'm creating a plugin for 1.17.1
hmm k ty
@quaint mantle kinda like how I checked to see if the player is holding my item if (event.getItem().getItemMeta().equals(ItemManager.wand.getItemMeta())) how would I check for the entity with my pdc and if it exists do something to it
whats not good
that if statement
if (event.getItem().getPersistentDataContainer().has(wandKey, PersistentDataType.BYTE)) {
//
}
I wouldn't care if someone used a goto as long as it works
whats getItem() supposed to be
@quaint mantle
@quaint mantle
so ItemManager.adminWand
i guess
nope
i mean you're checking the item here
public class FireballDamageFix implements Listener {
final FileConfiguration file = Main.getPlugins().getConfig();
@EventHandler
public void fireballDamageFix(EntityDamageByBlockEvent e) {
if (e.getEntity() instanceof org.bukkit.entity.Player &&
e.getCause() == EntityDamageEvent.DamageCause.BLOCK_EXPLOSION) {
double realdamage = e.getDamage();
e.setDamage(realdamage / this.file.getDouble("fireball-damage"));
}
}
}
i wanna make for weapon damage in the same way but i cant find the event D:
EntityDamageByEntityEvent
public class IronSwordDamageFix implements Listener {
final FileConfiguration file = Main.getPlugins().getConfig();
@EventHandler
public void IronSwordDamageFix(EntityDamageByEntityEvent e) {
if (e.getEntity() instanceof org.bukkit.entity.Player &&
e.getCause() == EntityDamageEvent.DamageCause.IRON_SWORD) {
double realdamage = e.getDamage();
e.setDamage(realdamage / this.file.getDouble("ironsword-damage"));
}
}
}
Something like this right?
ye
whats the default damage of iron sword? in 1.8.8?
k ty
I'm still trying to use event.setDamage in EntityDamageByEntityEvent the whole reason this started was because I needed to check if it was an arrow from my "Admin Wand" so I could then change the damage value
Didn't we say to just add a PDC tag
I am
I'm trying to figure out how to check for it
I need some sort of if statement
yeah, ik
but imaginedev gave me this one ```if (event.getItem().getPersistentDataContainer().has("pdcKey", PersistentDataType.BYTE)) {
}```
but the tag is on an entity that the item is creating if (event.getAction() == Action.RIGHT_CLICK_BLOCK) { if (event.getItem() != null) { if (event.getItem().getItemMeta().equals(ItemManager.wand.getItemMeta())) { Player player = event.getPlayer(); Entity entity = player.getWorld().spawnEntity(player.getLocation(),EntityType.ARROW); Vector velocity = player.getEyeLocation().getDirection(); velocity.multiply(2); NamespacedKey key = new NamespacedKey(plugin, "pdcKey"); entity.getPersistentDataContainer().set(key, PersistentDataType.BYTE, (byte) 1); entity.setVelocity(velocity); not an item
So use the entity instead
how
?jd
getDamager
stop it
?.jd
the javadocs are wayyyyyyy out of my comfort zone when it comes to documentation, its a small change but maybe a prettier design and some more examples would help
Go tell java that
Am I being stupid or is it broken lol, this is what the System.out returns "true" | false
what
it has the quotes around it
@quaint mantle what do I put in event.getItem()
I'm using an entity
I want to check an entity
Entity entity = player.getWorld().spawnEntity(player.getLocation(), EntityType.ARROW);
Vector velocity = player.getEyeLocation().getDirection();
velocity.multiply(2);
NamespacedKey key = new NamespacedKey(plugin, "pdcKey");
entity.getPersistentDataContainer().set(key, PersistentDataType.BYTE, (byte) 1);
entity.setVelocity(velocity);```
.
???
just tell me exactly what to put there I got to got very soon idc if I don't learn anything
like what.getDamager
@young knoll
pleeeeeaaaaassssseeeee
my entity is in the same class but not in the same event so how do I link to a specific event in here public static void onRightClick(PlayerInteractEvent event, Plugin plugin) {
@young knoll
HELLO??????
I'm tired, stressed out and having a panic attack
@young knoll
@young knoll
You can put the event wherever you want
You don't need a link to the entity you spawn
lmao
how does one go about registering every command automatically
instead of this.getCommand()
bro calm tf down LMAOO
how to fix org.bukkit cannot be resolved?
What does the cache method look like
Its all in one Async task, it can't run first unless you have some scheduling in the other method calls
I have not an ounce of an idea what I'm doing. I've got 2 servers trying to send a message from my lobby server to my manhunt server.
PluginMessageSender.jar(Lobby Server) : https://paste.md-5.net/yugubehuwe.java
PluginMessageReceiver.jar (Manhunt server) : https://paste.md-5.net/obuwuqojoq.java
Im gonna open a thread for this.
Sorry I can;t view pastebin links. uBlock blocks them
where else can i paste them for you to see?
?paste
What version
having an issue where an inventory a player is looking at isnt refreshing fast enough
does player.updateInventory() also affect invs theyre looking at
or is there another way to update what theyre looking at
Wym by update?
```language
code
```
is there a event that executes when the night skips because players sleep?
if (sender.hasPermission("kit.use"))
@quaint mantle ask in one channel and ask only in the proper channel, in this case #help-server
oh they meant like how to set LuckPerms permissions?
or PermissionsEx?
Idk
Also use #help-server
conc, can you help me with stuff after helping this human?
first will try fixing myself, if no success, will ask
who da hell deleted my message :(
how can i get the breaker of the block
Idk what the breaker is
how can i get who broke the block
ah so
Like what event are you using?
i am using BlockBreakEvent to spawn a specific custom entity, and whenever the boss spawns, i set the player's vector to something, but the vector applies to everyone online
but i want to vector just the player who broke the block
foreach not applicable to type 'org.bukkit.entity.Player'
Wat
oh wait
Of course you cannot write Player.foreach() or whatever u tried to do
I just deleted Bukkit.getOnlinePlayers or whatever, and still doesnt work
by invoking the send title method on the player who broke the block
when the player gets a advancement, how do i get the item on the advancement?
here for example is a map
i want to make a professional minecraft server
can anyone help me?
How to get tab complete by command string?
@EventHandler
public void onPlayerAdvancementDone(PlayerAdvancementDoneEvent event) {
Player player = (Player) event.getPlayer();
Server server = (Server) this.plugin.getServer();
player.sendMessage("Ваш режим игры сейчас будет изменён!");
Bukkit.getServer().getScheduler().scheduleSyncDelayedTask((Plugin) this, () -> {
player.setGameMode(GameMode.CREATIVE);
Bukkit.getServer().getScheduler().scheduleSyncDelayedTask((Plugin) this, () -> {
player.setGameMode(GameMode.SURVIVAL);
}, 3*20L);
}, 5*20L);
}
whats wrong?
already found it, so you dont have to help
any way i can make a custom entity immune to arrows?
looks like incorrect imports
I alr fixed
whoops, i forgot to put it in braces, ig every entity will now drop 4 diamond blocks
the data can be nullable depending on the type
Example: VILLAGER_HAPPY can be tossed without data
But REDSTONE requires it
Example
world.spawnParticle(Particle.REDSTONE, location, 1, 0, 0, 0, new Particle.DustOptions(Color.PURPLE, 1));
you can toss any RGB color in the DustOptions constructor
so color is editable ? nice
For some particles, yes
so im currently trying to change the sounds of players when they get hurt using ProtocolLib, firstly from what i can tell i cant actually cancel the sound of the client getting hit themself but other players can have it changed, Is this just a hard limit or is there a way around this, secondly is there a way of getting the entity/player that a sound has come from since i need to access of which player was hurt for the correct sound to play
How can I make player chat but without sending the message?
Like I want to make player type /hello but not send it
Afaik you can only do that when they click a chat component
Throw a bubble?
you mean a bottle of enchanting?
yes
cancel the playerInteractEvent if the thrown thing is what youre talking about
You can't throw bubbles in minecraft
read what I wrote. thats all you need to do
^^^
is it possible to scale a entity in size with nms inside a custom entity class?
why can't I throw an exp bottle?
i know i can save a hashset into a file but how do i deserialize it?
You said bubble not bottle. Read @crimson terrace 's msgs above.
"google translate is as good as a real translator"
:bruh:
meanwhile, me, an actual professional translator
yeah checks out
I am very good but how do I fix things guys
It’s hit box yes, not it’s client / model scale iirc that’s client sided 100%
Unless it’s something like slime but ye
Well, it's size is set in the entity types. constructur, in the server code, so is there some way to modify that, or update the access modifier inside the entity class.
maybe use reflection or something to set the value to a custom value??
Does someone knows a good idea that would allow to develop and build plugins from mobile? I'm a dev but i can't use my pc all the time, i still want to develop plugins.
Nop
Leave your PC on and use a remote viewer
how can I change the armor of a player with protocolLib? I could only figure how to change the tool
ProtocolManager pm = plugin.getProtocolManager();
PacketContainer packet = pm.createPacket(PacketType.Play.Server.ENTITY_EQUIPMENT);
packet.getIntegers()
.write(0, p.getEntityId());
packet.getItemModifier()
.write(0, new ItemStack(Material.WOOD_SWORD));
Bukkit.getOnlinePlayers().forEach(player -> {
if(player == p) return;
try {
pm.sendServerPacket(player, packet);
} catch (InvocationTargetException e) {
e.printStackTrace();
}
});
}``` this is my code
No i read it as player == null for some reason xD My bad.
np :p
Not sure honestly try debug?
this code works, i'm tryna add armor too
using getItemModifier#write() with higher indexes gives me an error in the console
Maybe read into this? https://gist.github.com/aadnk/4109103
found that too but it's outdated
[15:35:21 ERROR]: Error occurred while enabling ULT-RedPvP v4.0 (Is it up to date?)
java.lang.NullPointerException
at net.aboudey.ultimis.redpvp.sql.MySQL.createTable(MySQL.java:49) ~[?:?]
at net.aboudey.ultimis.redpvp.Main.onEnable(Main.java:196) ~[?:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:321) ~[patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:332) [patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:407) [patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.craftbukkit.v1_8_R3.CraftServer.loadPlugin(CraftServer.java:359) [patched.jar:git-PaperSpigot-"4c7641d"]
at org.bukkit.craftbukkit.v1_8_R3.CraftServer.enablePlugins(CraftServer.java:318) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.s(MinecraftServer.java:408) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.k(MinecraftServer.java:372) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.a(MinecraftServer.java:327) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.DedicatedServer.init(DedicatedServer.java:267) [patched.jar:git-PaperSpigot-"4c7641d"]
at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:563) [patched.jar:git-PaperSpigot-"4c7641d"]
at java.base/java.lang.Thread.run(Thread.java:834) [?:?]
[15:35:21 INFO]: [ULT-RedPvP] Disabling ULT-RedPvP v4.0```
Hello, i have this error for my plugin
line MySQL:49 = PreparedStatement st = getCurrentConnection().prepareStatement( "CREATE TABLE IF NOT EXISTS redpvp_data (Name VARCHAR(100), UUID VARCHAR(100), Kills INT(100), Deaths INT(100), Coin INT(100), ArrowTrail INT(100), Perks INT(100), TrailsMove INT(100), Messages INT(100), KillStreaks INT(100), KillStreaksTop INT(100))");
connextion null
// Create session
LocalSession editSession = FaweAPI.wrapPlayer(sender).getSession();
CuboidRegionSelector cuboidRegionSelector = new CuboidRegionSelector(editSession.getSelectionWorld(), vector.add(-radius, -vector.getY(), -radius), vector.add(radius, 255, radius));
EditSession affected = FaweAPI.wrapPlayer(sender).getNewEditSession();
// Mask
Mask mask = affected.getMask();
Mask2D mask2d = (mask != null) ? mask.toMask2D() : null;
// Replace biome
BiomeReplace biomeReplace = new BiomeReplace(affected, e);
FlatRegionVisitor visitor = new FlatRegionVisitor(Regions.asFlatRegion(cuboidRegionSelector.getRegion()), new FlatRegionMaskingFilter(mask2d, biomeReplace));
Operations.completeLegacy(visitor);
Hello i need help. I want change biome in region. I craete cuboid custom region and go to take mask, but mask has been null. And this code goto to exception after this code:
new FlatRegionMaskingFilter(mask2d, biomeReplace);
Is Fr33styler in this discord? From his BedWars plugin
Are you talking to me?
Yes, if you are the owner of the bedwars (clashwars) plugin
My friend wants generator speed customizable, and I don't think I have permission to change the code?
The spigot page links a support discord have you tried that one
Ok I will try
Hey guys, do you have to use NMS to spawn and later remove particles or is there an other way arround?
you can use spawnParticcle
declaration: package: org.bukkit.entity, interface: Player
and how can I remove them? Do I replace them with some kind of invisible particle or is there a method for that as well?
particles despawn after a very short amount of time
just let them die
ah okay. Can u specify the duration / what is the duration? :D
i dont think so, but you can make a loop and spawn them again
yea that's true, alright thank you guys :)
whats the best way of saving a hashmap to a yaml file?
make a screenshot of each value and save it in the yml, then you use python and image recognittion to build it back once you start the server
yw
:/
jk
you can just save the hashmap in the yml
it makes like a structure of data
i dont wheres the problem here
a bruh i meant hashset
ah no idea
maybe like this
.set("vanished_players", new ArrayList<>(vanishedPlayers));
and then load it with .getStringList().blablabla
is there some way to give a lambda as parameter that returns an array of strings? (String...)
funny
Fireball fireball = (Fireball) player.getWorld().spawnEntity(player.getLocation(), EntityType.FIREBALL);
this is firing a small fireball
wdym small
so
theres the blaze fireball size, normal fireball size, then ghast fireball size
SMALL_FIREBALL("small_fireball", SmallFireball.class, 13),```
theres these two, but the one i want is the rly big ones that ghasts shoot
Hi, I'm currently working on a plugin that makes a bow shoots ghast fireball instead of arrows, what I did was:
0. Catch the onArrowFired event
1....
what about this
This java examples will help you to understand the usage of org.bukkit.entity.Fireball. These source code samples are taken from different open source projects
cheers
building pyramids tututu
use variables for the unique id and chunk 🥲
i only use the chunk two times 🙂
usually the rule is if you use it more than once store it for readability 🙂
🥺
fuck the rules!
Explanatory variables 😌
You can simplify that a lot
if (uses.getOrDefault(p.getUniqueId(), 5) < 4)
Can also do a lot of early return
Also the perfect 'location.getChunk().isLoaded()' trap
😳
Idk
Technically you can hold onto a chunk instance
And let the backing NMS chunk unload
theres some stuff under it but thats just teleportation shit
It uses weak ref to the NMS chunk
int cx = loc.getBlockX() >> 4;
int cz = loc.getBlockZ() >> 4;
if (loc.getWorld().isChunkLoaded(cx, cz)) {```
@tardy delta getChunk loads the chunk 
You gotta use isChunkLoaded(int, int)
owh
CommandMagmabuildnetwork 🤢
or just isChunkLoaded(loc.getChunk()) ?
^
I said it here
ah so just that
I gave you the code to check if a chunk is loaded
Hello, does anyone know a method that can get the number of players on a network?
so I have an events manager and I need to link a variable from one event to another, is this possible?
Need help on how to update a spigot plugin, Thanks!
hey does anyone know i can intercept a packet, getting the name of the entity and changing it using protocollib? any good documentation on protocollib or some tutorials maybe?
does this looks good?
private List<Home> getHomes(UUID uuid) {
final ConfigurationSection s = homesFile.getConfigurationSection("homes." + uuid);
if (s.getKeys(false).size() > 0) {
List<Home> homes = new ArrayList<>();
s.getKeys(false).forEach(home -> homes.add(new Home(
homesFile.getString("homes." + home + ".name"),
(UUID) homesFile.get("homes." + home + ".uuid"),
(Location) homesFile.get("homes." + home + ".location"))));
return homes;
}
return null;
}
please
its a yes or no question
k
why do people even copy the imports :/
idk
https://paste.md-5.net/zokosepilo.cs this is my event manager
in this ```java
if (entity.getDamager().getPersistentDataContainer().has("pdcKey", PersistentDataType.BYTE)) {
}``` I need the entity part to be a variable from ```java
if (event.getAction() == Action.RIGHT_CLICK_BLOCK) {
if (event.getItem() != null) {
if (event.getItem().getItemMeta().equals(ItemManager.wand.getItemMeta())) {
Player player = event.getPlayer();
Entity entity = player.getWorld().spawnEntity(player.getLocation(), EntityType.ARROW);
Vector velocity = player.getEyeLocation().getDirection();
velocity.multiply(2);
NamespacedKey key = new NamespacedKey(plugin, "pdcKey");
entity.getPersistentDataContainer().set(key, PersistentDataType.BYTE, (byte) 1);
entity.setVelocity(velocity);
}
}
}```
is there something to say about this code?
https://paste.md-5.net/usunivuhak.java
so how do I do that (if possible)
also, how do I highlight my code?
```java
blabla
```
k
I swear there is no-one online to help rn
Avoid returning null, just return an empty list if they have no homes
world generation
What are you asking?
never mind
for once I stopped being stupid
and did something on my own
I don't need that question answered because that would be a VERY stupid way to do it
🤔
what happened and how do I fix it [12:37:56] [Server thread/INFO]: [plugin] Enabling plugin v1.0 [12:37:56] [Server thread/ERROR]: [plugin] plugin v1.0 attempted to register an invalid EventHandler method signature "public static void com.CJendantix.plugin.events.TutorialEvents.onRightClick(org.bukkit.event.player.PlayerInteractEvent,com.CJendantix.plugin.Plugin)" in class com.CJendantix.plugin.events.TutorialEvents
you made a static eventhandler?
this is my new events class https://paste.md-5.net/govomokibi.cs
k thanks
I did, but whats wrong with having it static?
it requires objects
(I don't really know what static does)
almost never use static
(and when I should use it)
Don't use static unless we tell you to 😉
makes something belong to a class
k

Are you one of those that claims static abuse at any sight of static
utils classes...
Utils and constants
yes , especially if you are dealing with multiple threads like in plugins dev
plugin instances 😬 😬
Then you're wrong.
Static is there for a reason.
It has its uses lmao
if you are running a normal shitty program on java you can use static all you want , i'm just saying on multiple threads you really need to be careful using static
so what would you use static for, give me an example
private static Main instance
smh my normal shitty program may be shitty but thats not for u to say!!!
There can be pitfalls, but you can't just say it's static abuse if you see it at all
so the main class should always be static?
did i say that? jeez just stfu
the instance...
😳
Yeah, you did 
idk
a class cannot be static :kekw:
I asked if you claim static abuse at any sight of static and you literally said yes.
public void inventoryClickEvent(InventoryClickEvent event) {
Player player = (Player) event.getWhoClicked();
if ()
}```
I want that no one can click a item in player inventory. How?
oh fail
stop, ik
event.setCancelled(true)
Uhm...
lol a friend of mine said it wont work with setCnacelled
why wouldnt it
idk
I removed static and I'm still getting this [12:43:13] [Server thread/INFO]: [plugin] Enabling plugin v1.0 [12:43:13] [Server thread/ERROR]: [plugin] plugin v1.0 attempted to register an invalid EventHandler method signature "public void com.CJendantix.plugin.events.TutorialEvents.onRightClick(org.bukkit.event.player.PlayerInteractEvent,com.CJendantix.plugin.Plugin)" in class com.CJendantix.plugin.events.TutorialEvents
did you repackage?
wdtm
wait
its literally saying the error
your method cannot have the signature (Event e , plugin p)
its an @EventHandler
you cannot have onRightClick(PlayerInteractEvent e ,CJendantix.plugin.Plugin p)
i cant be more straightforward than this...
why not
Your event handler method is only allowed to have one single argument which has to be of type Event
finna make a ?hardest command that just says my catchphrase,
The hardest part about using spigot is knowing java.
yes
k
Does this also work?:
if (player.isOp()) {
event.setCancelled(false);
else if (!player.isOp()) {
event.setCnacelled(true);
Do it
uhh just ```java
if (!player.isOp()) event.setCancelled(true);
kk, ty
never saw anyone using ..calcelled(false)
lol im using it xd
it's how you write cancelled in scottish
I would advise against this unless you want to overwrite previous cancellations.
Talking about event.setCancelled(false);
how do i make a custom world generator, and would i be able to make that world generator make multiple worlds i can teleport between?
alright my "Admin Wand" is now shooting arrows but java ((EntityDamageByEntityEvent) entity).setDamage(999999); this isn't doing anything
no I'm not
would java Entity damager = ((EntityDamageByEntityEvent) entity).getDamager(); ((EntityDamageByEntityEvent) damager).setDamage(999999); this work
And spit at u with that wrror
U get the damaged entity
Use that to get the damager
No casting some shit that won't ever work
how
public void inject(Player player) {
CraftPlayer craftPlayer = (CraftPlayer) player;
channel = craftPlayer.getHandle().playerConnection.networkManager.channel;
channels.put(player.getUniqueId(), channel);
if (channel.pipeline().get("PacketInjector") != null) return;
channel.pipeline().addAfter("decoder", "PacketInjector", new MessageToMessageDecoder<PacketPlayInUseEntity>() {
@Override
protected void decode(ChannelHandlerContext channelHandlerContext, PacketPlayInUseEntity packet, List<Object> arg) {
arg.add(packet);
readPacket(player, packet);
}
});
}
error: Caused by: java.util.NoSuchElementException: decoder
how
Gimme a minute
For god's sake
Hello guys, it's flash110 (again) and I have another question for the bukkit community!
I have been working on a cool death plugin that includes...
how do i get the servers tps?
dont you think i tried that already?
There's a few events I saw for the inventory, but what's the event to use for when getting an anvils output item
also everything that comes up is deprecated
Well there has to be a reason for it
Look for it
I has found this
"Try casting your event to an EntityDamageByEntityEvent
Like so
EntityDamageByEntityEvent entityEvent = (EntityDamageByEntityEvent) e;
Then use entityEvent.getDamager();"
Well not that hard to find is it?
?
what?
Wrong oing
lol
but u were saying casting wouldn't work
U casted an event to an player u donut
uhh, no
I was making an entity
then casting an event to that entity
so I could use .getDamager()
There's Ur probablem
Casting event to entity
Wtf
?learnjava
Here are some links to get you started on learning Java:
- https://www.codecademy.com/learn/learn-java
- https://www.sololearn.com/learning/1068
- https://www.learnjavaonline.org/
- https://programmingbydoing.com/
- https://docs.oracle.com/javase/tutorial/java/index.html
The last one is the only official one, however some of those concepts assume that you already know a bit about programming.
here u go
ok
LearnJava pleas
I was making a entity in an event
lmao
chill, just take some time to learn before you try and make plugins. I'm not here to make fun you but please take our advice
trust me it will make it easier for everyone
yes. this ⬆️
the thing is I do know a little java and C# just, like, I just learned how to cast
if you want help with something specific or you want links to videos or tutorials let me know
that's not how casting works so clearly you don't
please just listen and learn
ok, so I copied this from https://bukkit.org/threads/get-damager-from-damage-event.420509/ EntityDamageByEntityEvent entityEvent = (EntityDamageByEntityEvent) e; what variable is e supposed to be
Not copy core
?
Understand it
I know this is gonna be really stupid of me to ask, but i completely forget on how you get a username in a gui.
I tried Player p = Bukkit.getPlayer(getName()); that didn't seam to wanna work and all it did was return a null error and disable the plugin.
code
events are methods that are called by the server when something happens. The EntityDamageByEntityEvent is just a class for the event and has nothing to do with the Entity class, thefore you cannot cast them to eachother because it would not work and be pointless
So kinda wanting to just know ig how do i get the player name through a gui?
I do understand it, it is making a variable for a cast in an event
brb
username in gui?
@shadow tide watch these videos
https://www.youtube.com/watch?v=a9X0EeXtomY&list=PL65-DKRLvp3Yn7iglPfxKoc7bl0N80XgG&index=5
https://www.youtube.com/watch?v=vSPgTv6mKQM&list=PL65-DKRLvp3Yn7iglPfxKoc7bl0N80XgG&index=6
Make Minecraft listen to you with Listeners! Learn how to make some flying boots here :^)
---------- Links ----------
Spigot Player Events: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/player/package-summary.html
Spigot Entity Events: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/entity/package-summary.html
Download ...
Ever wanted to make cool new weapons and items in Minecraft? Check out this video!
---------- Links ----------
Spigot Player Events: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/player/package-summary.html
Spigot Entity Events: https://hub.spigotmc.org/javadocs/spigot/org/bukkit/event/entity/package-summary.html
Download Eclips...
so kinda got me thinking that idrk what to do.
not gonna happen
maybe later
u will never learn than. :(
?eventapi
i assume thats the player who executed the command?
You can learn without bad youtube videos
like (Player) sender
well, if u wanna put it that way ig,
but i have a cmd that opens the gui, and a completely seperate method aside from the command.
I won't spoonfeed you but i will give you resources to learn yourself. If you don't want to do that then leave this server because you will not get help like this. Nobody is going to take you serously if you won't learn stuff on your own. We aren't go to give you the code because then everytime you want to do something you will ask for us to spoonfeed instead of you actually learning
alright thx u
i dont get it
i'm sorry I just don't have time to watch 2 30-40 min videos
alright i'm not saying watch this right now but you need to find time to learn if you are going to take coding seriously
then atleast read some of the docs
anyone else still need help?
@EventHandler
public void onJoin(PlayerJoinEvent event) {
if (somethingHappened) {
// do something
}
}
basics
uhh
wait
lol
nvm take another event
@lost matrix Your Chunk pregenerator, it doesnt seem to support datapack chunk generators... is there a way to support them
It just lets spigot generate the chunk as if a player would load it...
hmmm, it just leads to stuff like this
yeah, the chunks inside the generator are not the datapack ones
and the farther ones are the datapack generated ones
there must be something specific to when the player loads them then which is different in the api implementation
in a EntityDamageByEntityEvent event, how would I check if the entity was damaged by a custom entity (arrow)
?pdc
forgot how pdcs work
stupid question, when ur adding a pdc to an entity, do you need a key?
Yes?
stupid question
Cannot invoke "org.bukkit.entity.Player.getUniqueId()" because "p" is null
Bruh......
kek
Tell what you want
Player p = Bukkit.getPlayer(getName()); is that even right for getting the users name? or am i just terrible at remembering on how to get the users name through Bukkit. and whatever...
someone said in an event function (I think thats what its called, if not correct me. this thing public void onEntityDamaged(EntityDamageByEntityEvent event)) you can't have more than one variable EntityDamageByEntityEvent event if this is true for the pdc the plugin instance as a variable?
Sorry for the noob question, my google fu is failing me.. How would you go about listening to an event after it has been fully processed. I Want to have certain blocks react to water flowing (Currently trying to use the BlockFromToEvent event)
Hashmap cointaing players' uuids as a key and value new object class in which you have every boolean with specific tasks "items"
You can have the JavaPlugin variable as a field in your listener class or create a static getter for it.
whats a static getter?
You could create method in class that is checking if all booleans are true
That doesn't work as its still before the event is actually finished, I Need the flow event to successfully complete first
static getSomething()
just check when they pickup an item or close an inventory
aka singleton @shadow tide
You can set boolean if you acquire item
k, I don't want to push you so how do you have the JavaPlugin variable as a field in my listener class
?
You can have e.g
private static Economy economy;
public static Economy getEconomy() {
return economy;
}
in which Economy is main class
extending JavaPlugin
Like this for example:
private final Map<UUID, Collection<Material>> playerMaterials = new HashMap<>();
public boolean containsAll(final Inventory inventory, final Collection<Material> items) {
// Check if the inv has at least one of each
}
@EventHandler
public void onPickup(final EntityPickupItemEvent event) {
if (event.getEntity() instanceof Player player) {
final Inventory inventory = player.getInventory();
final UUID playerID = player.getUniqueId();
final Collection<Material> materials = this.playerMaterials.getOrDefault(playerID, Collections.emptyList());
// PS: This might have to run one tick later
if (containsAll(inventory, materials)) {
// Do some stuff
}
}
}
But you should def put the map in its own class and maybe even wrap the Collection<Material> in a new class.
so now economy would be the equivilent of Plugin plugin?
Yeah
cool
wait would I use Economy.getEconomy()?
Yes!
cool!
how to make a org.bukkit.entity.Entity get fire effect ? (make it burn)
setFireTicks / setVisualFire?
should i set them both ?
and what value should i put it setFireTicks
the fire tick is
setFireTicks sets the ticks before the entity stops being on fire
oh
its the ticks before the fire burns out
ok, I'm sorry but can someone explain to me what this means? The method set(NamespacedKey, PersistentDataType<T,Z>, Z) in the type PersistentDataContainer is not applicable for the arguments (NamespacedKey, PersistentDataType<Byte,Byte>, int) I will try my best to learn these errors I promise.
np
show your code
Anyone know how the Particle.SPELL_WITCH is called in a texture pack?
PersistentDataType.INTEGER
Yeah it looks like the wrong data type but can you please show your code and what your trying to store?
@shadow tide
Or cast the int to a byte
Java 16
pls help
Each player has a fixed collection. The collection should be created and then not modified anymore.
you can if you know the right guy
you can if you just kick the player joining
"Just cancel the player controlling the Account trying to join"
I was referring to murder, but thats fine too
😵💫
Im on tumblr too much
Do I have to update an entitys PersistentDataContainer when I set something?
or is that just blocks
after I do this, is there still any way the entity will despawn or be removed?
it is a LivingEntity (Im on 1.17, maybe thats it?)
sorry, forgot to mention.
this is the only thing Im finding
cast it to the real entity i guess
that Method straightup doesnt exist (at least in the 1.17 one)
https://hub.spigotmc.org/javadocs/spigot/org/bukkit/entity/Entity.html#setPersistent(boolean) is the only method in Spigot
what does it mean when an entity is persistent? does it just not get removed by any means unless killed? or is there something else to pay attention to?
doesnt entity has a getPersistentDataContainer() method or something?
it does
🥴
Yeah I'm pretty sure it means it won't despawn
Much like a named entity won't
How are you sending it
Well there's your problem
You're doing string +
That implicitly calls toString on it
Which doesn't do what you want
Depending on what version you're on, you either need to call player.spigot().sendMessage(tmsg)
Or player.sendMessage(tmsg)
You can't send chat components to console because console can't click or hover over text like a player can
Better you don't do that because if someone want to use plugin with jdk 8 or others this will be give you error
Or you just use the latest version and then everyone is on 1.16 anyways
Servers like 1.8 or others,they aren't support jdk 16
If you make it for your self and you know that you will use jdk 16 its not problem but for public its better to don't do this
Sorry for grammar 😁
I think it would be pretty based if everyone stopped supporting spigot 1.8
So that people would be forced to move the fuck on
1.8 is the greatest
Servers like bedwars , auth servers and others better to build in this version
We don't have best , 1.8,1.12,and latest stable version are using on different servers for different works
I never said it was the best
I said it was the greatest
Those have different definition
idk ask the person who invented the word
english be like
dont u know? literally 1984
No
does anyone know how to ban a player?
Given this List of Materials: [STONE, IRON_INGOT, COBBLESTONE]
And this Inventory: [OAK_PLANKS, COBBLESTONE]
What would be the outcome of your containsAll method?
Try to go through the code step by step
with code?
Yes it would be true. Even tho the player does in fact not have all those items in its inventory.
but what is the source aka the last argument for the method? It says I need a source
You dont need a done list
You just need one list that never changes.
Ah i see. So even when the player throws the item away?
Bukkit.getBanList(BanList.Type.NAME).addBan()
I found this
what do I put for the last argument where it says source
you mean this?
Im getting this error when starting my plugin. Its supposed to wait 5 seconds after onEnable() and then spawn a skeleton with special PersistentDataContainer contents... I get the skeleton from another method which returns it.
Then:
public boolean removeAndCheck(final Inventory inventory, final Collection<Material> items) {
items.removeIf(material -> {
if (inventory.contains(material)) {
// Material is removed from collection
return true;
}
// Nothing happens
return false;
});
return items.isEmpty();
}
Or with an old school iterator
public boolean removeAndCheck(final Inventory inventory, final Collection<Material> items) {
final Iterator<Material> materialIterator = items.iterator();
while (materialIterator.hasNext()) {
final Material next = materialIterator.next();
if (inventory.contains(next)) {
materialIterator.remove();
}
}
return items.isEmpty();
}
Go through the Collection of Materials that still need to be done.
If the Collection is empty afterwards then the player is done.
You can react on each item that gets removed.
?paste
Your "other method" returns null
it shouldnt. https://paste.md-5.net/muzuhabenu.cs
oh wait
I may have found it
oh yeah I did initialize it with null which I didnt see. just automatically did the initialize when it told me to
wooooo its working... lmao
im not sure what you mean by source
I have a quite weired issue..
I try to speed up the arrow of bows, i added a eventlistener for the EntityShootBowEvent and changed the velocity of the arrow
arrow.setVelocity(arrow.getVelocity().multiply(10));
If i have the bow in the main hand it works fine, but if i have have the bow in the offhand the bow loses his velocity instantly after i shot.
That makes no sense for me at all.
Any ideas ?
Is 10x the default velocity even a valid length for the server?
Anyways. Try delaying the velocity change by one tick.
I just multiply the velocity by 10, which works fine for the main hand.
I also tried to delay it by 2 ticks, but then the arrow will loses the velocity instantly after the 2 ticks in the air.
try setting the multiplier to less
Why ? It works for the main hand, so that makes no sense or ?
I dont think anything is supposed to go 10x the speed of an arrow
maybe its that
I try it but i don't think that is the solution, because it works fine in the main hand 😄
send the code?
Its above
have you considered gravity?
a arrow will spawn kinda.. angled down not completly straight,multiplying that value would mean an arrow might even do a full 360 towards the player or towards the ground(who knos)
however it is indeed strange
that one works
Maybe i found the issue, have to test a few more things.
I found the cause, but i don't understand it o.O
If i hardcode the 10 like the example above it works fine for both hands.
If i get the 10 from the config and use the variable it don't work for the offhand o.O
i beleive there may be some issues if your setting a default?
try to debug the config value before using it
its java, you dont have to understand it
?
Show your code pls
This works for me no matter what hand i use:
@EventHandler
public void onShoot(final EntityShootBowEvent event) {
if (event.getEntity() instanceof Player) {
final Projectile projectile = (Projectile) event.getProjectile();
projectile.setVelocity(projectile.getVelocity().clone().multiply(5));
}
}
Give me a second, maybe i found something
Hmm.. i don't know..
But i found a way how it works...
arrow.setVelocity(
arrow.getVelocity()
.setX(arrow.getVelocity().getX() * multiplier)
.setY(arrow.getVelocity().getY() * multiplier)
.setZ(arrow.getVelocity().getZ() * multiplier)
);
.multiply should do that internal, but i don't know 😄
arrow.setVelocity(arrow.getVelocity().multiply(multiplier));
🤔
Is there a quick way to get the string produced by sending a BaseComponent array?
It's not just a string
i don't care about events
i just want the raw text with color formats
i'll take a look rq
nada, just .appendLegacy() on componentbuilder
java 8 to the rescue
public String getDescription(CharacterBase characterBase) {
BaseComponent[] desc = new ComponentBuilder("egg")
.create();
String[] descStringArray = new String[desc.length];
Arrays.stream(desc).map(BaseComponent::toLegacyText).collect(Collectors.toList()).toArray(descStringArray);
return String.join("", descStringArray);
}```
ended up just doing this
¯_(ツ)_/¯
it's gross, but so be it
how do i make a command block activate to the person who used it
is it possible to make a falling block never fall?
setAi(false)
so...
Quick question, if you cancel() a runnable task, that executes the rest of the code in the run() method anyway, right?
Yes
you cant hault a method
But you can return;