#help-development
1 messages · Page 1532 of 1
your code
but the yml looks okay tho
name: CreeperSpawn
version: 1.0
author: Jack
main: me.Jack.CreeperSpawn.Main
description: Spawns 10 creepers on player
commands:
creepspawn:
aliases: [cs]
description: /cs spawns 10 creepers on player```
(for readability)
maybe change yaml description: /cs spawns 10 creepers on player
to
description: '/cs spawns 10 creepers on player'```
codeblock test
i have intellij 2020
thats not a codeblock at all
cool
BIG BRAIN
its the best version
codeblocks are done like this:
your code
```
your code
oh i see
im reporting you for using betterdiscord
jk
@sullen domejava
class class {}
the java has to be on line 2
i am gonna try the plugin now
i'm dumb. it has to be like in this
System.out.println("hello world");```
exactly
ill report back in a bit
ive tried it, and it still doesn't work
is the error from the latest.log actually the error you sent in here? or did you get it from the console
@sullen domewhat do you mean?
you showed us the error
you copied that from your console, or from the log-file directly
I copied it from the log file directly
hmmm
i'd have to see at which line the error is.. so we need to see another class... do you have any other classes that could cause this?
search in your code for smt like (Map) <something>
should i check Main.java, or should i check CreeperCommand.java?
(im using eclipse IDE)
how do i undo these commits, i wanna be even with Iridium-Development:master
?paste
no idea of git
git reset --hard?
just resets recent changes
Believe you can revert it
git reset --soft HEAD~1
well is there a way to become even with the main repo
API missed YamlConfiguration.getMap()
pr
@sullen domewhere should i copy these classes from?
i dont want to pr
i just want to reset my fork to be even with the main repo
git reset --soft HEAD~1
then click on save, and send the url in here
doesnt do anything
@sullen domei pasted the code into your pastebin
i found those in a google search
wait a sec, ill show you
¯_(ツ)_/¯
@sullen domedid you find anything yet?
do it like this
small tutorial for my boy lol
and paste both of your classes's code into it
ur leaking mcp reborn code
i did worse stuff tho
that indentation
:/
it is
since ur where in mcp reborn
but not the class i had opened
oh
wtf is that code windward
the indentation is all wrong
its really shitty
XD
https://paste.md-5.net/unubuledey.java
check out if you want to. maybe ill leak a few Class names, but lets be honest. who gives a shit
@granite stirrupthank you
xd
can you paste your command class as well?
thats probably where the error comes from
^
private static void createGiantSpawnEgg() {
ItemStack item = new ItemStack(Material.ZOMBIE_SPAWN_EGG);
SpawnEggMeta spawneggmeta = (SpawnEggMeta) item.getItemMeta();
ItemMeta meta = item.getItemMeta();
spawneggmeta.setSpawnedType(EntityType.GIANT);
meta.setDisplayName(ChatColor.GREEN + "Giant Zombie");
meta.addEnchant(Enchantment.LUCK, 1, false);
meta.addItemFlags(ItemFlag.HIDE_ENCHANTS);
ArrayList<String> lore = new ArrayList<>();
lore.add(ChatColor.WHITE + "Spawns Giant Zombie!");
lore.add("");
//lore.add(TIER2);
lore.add(UNFINISHED);
meta.setLore(lore);
item.setItemMeta(meta);
item.setItemMeta(spawneggmeta);
giantSpawnEgg = item;
}```
i wish it did put it into a paste XD
made it quicker for you
that is my command class
is that not how u do the eggmeta?
oh wait that was your code? my bad
its bad, but it'll do
it isn't the way? i'd thought you have to cast it like you'd cast DyeableArmor and stuff
@sullen domewhat do you mean?
i meant to chewie
oh sry
like wdym
i don't really like answering to messages, because i hate to ping people
oh idc i have sound off
i mean... don't you just cast it at all?
looks right to me
i'm actually confused rn... no idea why you get that error, ngl
you talking to me?
ill try something different then get back
ill go ask the same question on help-server, thanks anyways!
well, it's a development-related question. they'll lead you in here
do you think anyone there could help me tho?
i need help with coming up with a plugin idea...
idk if they could... but they probably won't ouside of here... because people are dicks :/
but well to be fair, it's a dedicated channel for dev
@granite stirrupmake something that screams at you every time you craft something wring
he gets an error. and i got no clue whats the cause for it
nah
ill do it
i dare you
^
imagine has dev in his name.. so he obviously has knowledge
he probably can help
xd
@quaint mantledo you think that you could help me with this?
show code
Hello, How would I move forward where they are looking?
uhh
that doesnt mean he has knowledge
o pog
i know 10*10 = 100 :o
that didnt even ping me
thats all i know tho
I know pi = 3.1415926535897932384
62643383279502884197169
3.141592653589793238 thats all i can remember
pi is the cercumfrance / radius of a circle
I like pie
apparently you only need like 20 digits of pi or something to figure out how to make a rocket
i KnOw Pi
uhh wait sorry could someone answer the question above? I've been trying to do it for like 3 days now
Stop
π
No I can’t process
@dapper steppe version?
1.15.2
TELL ME
true
cake is squishy while pie is rock hard
lol
isin't pie just dum cake
any startup errors
HOLLY
is this how u do it?
in the log files?
i'd like if the bot would auto-ban people when they do such stuff multiple times
after getting warned
console
not to my knowledge
https://paste.md-5.net/uzowuroqon.java is this how u create a giant in a egg
idk if there's the possibility to change the plugin.yml while runtime tho
dont think so at all
@quaint mantle is the only way to make a command while the server is running is using the commandmap?
what if your making something like skript
thats not really changing lol
where u can register commands
it uses commandmap
@quaint mantleare there any other causes to why this would happen?
no
why?
@quaint mantleso you cant help me?
nope
they said it will make things harder for you
k thanks
then how would you add commands?
i think its cuz i was using it just to add commands when the plugin starts lol
if they're predefined, then why?
i actually made a Mod-Rendering-System for my Client. maybe create some system for anything spigot-related
that already is in 20k plugins out there
make it send a packet for keys :) only when in focused
i mean.. when creating a mod, i just use this:
pretty cool
FPS: 999
are you faking the fps
one sec
you see the difference?
the dummy is the one that is rendered in the screen where you move the mods
oh i couldnt see it
in here
are you making a hacked client
not really xd
yeah
so its just a shittier version?
^
and i can make my own cosmetics lol
and mods
and stuff
and i'm not willing to badlion, viewing my system-files
lol
so i can only win
why dont u make it update with the actual fps?
and it's actually quite much fun, because there's no api or smt.
so imo i learn more java lol
wdym
i actually cannot distribute the client at all
so i don't need to make EVERYTHING configurable
i thought u can just not open source it?
i don't know exactly. but i heard you are not allowed to distribute modified minecraft-code
i mean, i am allowed if i would create an installer and stuff, but lmao cmon
no it says on the thing ⚠️ WARNING ⚠️: You CANNOT publish any code generated by this tool.
it doesnt say you cant publish the client jar
yea
the client jar contains the unobfuscated code
it doesn't obfuscate when building
one sec, i show you a comparison
you cannot publish a modified client binary
left one is original, right one my client
why not?
mojang doesnt even force the eula that much
oh you bet they do when they find out about modified binaries
but what if you dont use the mojang mapped version of mcp reborn?
well they probably won't if i didnt earn anything. officially, even all those mc-servers selling ranks are agains the eula
do they do anything against it?
they mostly dont even give a fuck when you have one of the biggest servers
this is literally the one single reason why every modding platform builds patches on of the legit binary instead of just distributing it
does forge do that?
yes
you don't download the client, you download a little something that modifies the client
but then why doesnt it take years like buildtools?
it's like buildtools
because
it uses a different decompiler idk
for example servers who have ranks, with which you can join full servers > agains eula
ranks who gives you the ability to get more rare items than others who don't have the rank > against eula
;-;
uh nothing really to do with gradle
you mean doesnt
actually i think the eula says you cant sell items for money thats vanilla not custom things
crate keys only
ranks is custom
i'm sure it defines general advantages over other players
not really
@sullen dome how did you do ur client thingy? did you like, decompile the client src and modify that or what?
i mean, if you have a rank, you can join full servers. if you join, someone without premium rank gets kicked for this player. do you really think this is eula-conform?
literally the first thing you see when opening the eula page lmao
idk i cant read it since i dont really want to put my security questions in
cuz lazy
if you've made the "thing" you're providing, then you're good to go
now we have to define copies of the game
it doesnt say you cant modify the game and give it for free
how bout you keep on reading lmao
it literally does on the first line
weird spoken, but kinda does
You may not distribute any Modded Versions of our Game or software
Mods are okay to distribute; hacked versions or Modded Versions of the Game client or server software are not okay to distribute.
mhm
¯_(ツ)_/¯
things like buildtools or paperclip
i cant read it rn cuz im to lazy to login
if it wouldn't badlion, lunar, etc wouldnt exist
it wants me to login to view the page duh
"duh" no it does not lmao
lol
it does
anyway
neither am i
its asking me to login
¯_(ツ)_/¯
I feel like doing this ```java
public ItemStack[] pvpKit() {
ItemStack[] items = {
new ItemStack(Material.IRON_SWORD)
};
return items;
}
https://account.mojang.com/documents/minecraft_eula
this doesn't require login at all
because they are not distributing the modded client/server itself, they modify an already downloaded existing genuine jar so yeah it's ok
it does
doesnt require me to login
wtf its not asking me now
doesnt... as you see here
🧢
im not capping
lol
that's what they all say
yep
lmao
im not kidding
doesnt ask me either
of course
anyway, it's irrelevant now
IT FUCKING ASKED ME
excuses
and continue with my question
if you say so :/
dont know dont care
If you make any content available on or through our Game, you agree to give us permission to use, copy, modify, adapt, distribute, and publicly display that content. This permission is irrevocable, and you also agree to let us permit other people to use, copy, modify, adapt, distribute, and publicly display your content
lol imagine if mojang asked modders of closed-source mods/plugins to open source everything
lulw
it could happen
pissing plugin
hm?
if you distribute something like a client...
you give them perms to distribute/use/whatever it?
yea
so you're actually allowed to tho
?
i mean, if not this wouldnt make any sense
???
RealRivex what are you talking about
they can take your content and use it themselves in the game
yea
that does not mean you can distribute a client
yeah it would?
no?
why should they be allowed to use my private on-my-pc mod-code?
you can distribute client/server mods/plugins/patches/addons/whatever
not a modified client/server
because it is not your creation anyway either
Would all use Getter and Setters for kits?
If you make any content available on or through our Game
define any content. could be everything tho
you could say its not your code?
they don't really define it iirc
your content
something they have not made
you didn't make the client itself, you made the modifications to the client
that's why you can distribute patches
yeah, and this client contains MY content. and if not with distributing, how would you make it available to otherse on or through the game?
but not the client itself
What can I put in the constructor EntityTypes<? extends EntitySilverfish> entitytypes
so wait a sec... if ...
how would you make it available to others
#help-development message
#help-development message
just and idea...
if i make an installer than injects it into the Minecraft-Code on installation, it's allowed?
what do you think buildtools does lol
i think yeah just as long as it doesnt contain the mc code
thats greyzone movement at finest
ngl
how can that be allowed if it's strictly meant to inject/modify that code lmao. i mean.. it comes out with the same ending
love laws
you are distributing your content
your content are said modifications
not the client itself
the client is not your content
the mods is
Check out Paperclip if it's a server jar
it is not
Well then have fun lmao
it contains a big fucking .patch file lol
that is applied to the vanilla jar
the patch file contains the modifications done to the server, it's not the server itself
.patch is a git thing isnt it
yeah
yeah cuz i seen it in github app
which uses git
i think
like when u look at the changes in commits i think
fun fact, in any commit on github, you can add .patch or .diff at the end of the url to look at the "raw" commit/diff

Cool kids uses git diff
can i change the texture that a projectile uses
like change the texture of a thrown snowball to the texture of a potateo
Who can tell me the name of the pufferfish in version 1.12? I did not find it.
If Ur talking about the fish entity's then it doesn't exist
1.12 didn't have pufferfish other than the item
raw fish with id 3
as i said in general
and ye, its an item not an entity
also, https://i.imgur.com/2kTARjC.png its not out of beta :P
It is
U sure
positive
oof
Eh but loads of people have like everyone
So that's why I thought it was out of beta
I could be wrong but last I heard they were just expanding the range
meh, my alts have it now also, so maybe it is out
idk
Idk I saw a YouTube vid saying everyone has it and my friend has said that to
hmm, yeah. apparently it was released a few hours ago
About 12 hours ago
Restart your client I guess? I went on the browser version and it was available there
i am on my phone
hm. just having an "above me" if i click on my profile but i cant change it >:(
Lana rhoades is hot
Lol
You can’t change it on mobile yet
quick question, whats the difference between Bukkit.broadcastMessage and java for (Player target : Bukkit.getOnlinePlayers()) { sendMessage(e.getPlayer(), target, msg); }
practically there is none I guess
one question
how can i move an item in a specific slot in a gui to player inventory after it close
? just get the item in that slot and add it to the players inventory
No it is implemented differently
with NBT items
What do you mean?
But it acts the same
yes but it's no different to the players
like, i have bunch of custom NBT
and thats seem broken
As long as your getting the itemstack and adding it to the players inventory there should be no issues
^
can you give example
what are the main differences between spigot 1.16.5 and spigot 1.17?
i want to port my plugin to the latest version but i am not sure if itll break
one line is ok
declaration: package: org.bukkit.inventory, interface: Inventory
Ok so i am trying to learn how to use MySQL and im using this guide
https://www.spigotmc.org/wiki/connecting-to-databases-mysql/
But i am getting java.lang.NoClassDefFoundError: com/mysql/cj/jdbc/MysqlDataSource I have this dependency in my maven <!-- https://mvnrepository.com/artifact/mysql/mysql-connector-java --> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>8.0.24</version> </dependency>
The home of Spigot a high performance, no lag customized CraftBukkit Minecraft server API, and BungeeCord, the cloud server proxy.
did you shade it
?
if not it expects the class there
shaded
Sorry im new to using maven what is shaded
basically what it does is include the classes in the plugin so that the plugin can use them
i personally dont use maven. dat bad gecko?
since if you don't have them shaded, it will expect them (from either spigot or another plugin) at runtime
im making a custom craft table, and when i exit the gui, the item gone, is there anyway more efficent than get every item in the GUI slot and put it back to player inv?
except result slot anyways
i see hypixel skyblock
Does this look right?
https://paste.md-5.net/vokefujexe.xml
well it updated fine but im still getting the error
java.lang.NoClassDefFoundError: com/mysql/cj/jdbc/MysqlDataSource
What do i need to do to shade it?
I copied the plugins thing what else do i need?
sorry im new to maven i dont know how this works
im making a custom craft table, and when i exit the gui, the item gone, is there anyway more efficent than get every item in the GUI slot and put it back to player inv?
jsut ask dont be argressive
first of all why ask again
i need help
snd without me thinking tol much rn, i dont thinkt there id
spamming this page isnt helping anything ive gone over it
the itemstackmethod doesn't seem efficent
it's not the same page
loop over every item slot
it's another instruction, compare the hyperlinks lol
high ping players can dupe easily
that's exactly what i done
You could prevent the dupe by comparing the inventories before and after
With the dupe prevention it's a pretty ok solution I guess
yea
and remove added items or taken itemd
Guys i need quick help
Thats where the problem is:
public class Command {
}
apackage me.sat7.bustaMine.Commands;import java.util.*; import org.bukkit.command.*; import org.bukkit.entity.*; import org.bukkit.*; import me.sat7.bustaMine.*;
This is what it shows:
Starts w/Line 13
i dunno what to do why does it expect smth there
Hello, how do I change the player's name? I've seen all the threads of spigot, bukkit, but almost all of them are recommended to use api or plugin and I haven't found an answer in GameProfile myself, profile#gameName exists but setName doesn't exist.
changing players name in-game?
is developing a spigot plugin on run time live possible?
i don't think so
Ok i ran clean install and it said build success but im still getting the error
pom.xml:https://paste.md-5.net/nusobuqufo.xml
u cant use /nick cmd
wdym?
you would need a plugin which can code a plugin
wait
wdym2?
plugin codes plugin? xD
didn't meant you
i mean in an ide
oka
nope not possible
first google result
ohhh
how did you find this?
I Couldn't find this
learn to google
Just Fucking Google It helps you help others to use Google and search on their own!
wow i do not like the nms changes very much
It's a good conversation topic. I don't know why you guys don't use nms. I heard using nms will damage the data or shut down the server, so what makes it so?
Can somone please help with this i still cannot figure it out. Here is my pom.xml https://paste.md-5.net/nusobuqufo.xml. I ran clean install and it showed build success but im still getting the error
you dont know why or you dont know why not?
I don't know why nms damage data and shutdown server
you didnt shade anything... just ran the plugin itself
and how
well yeah you can damage the server with the spigot api too lmao
it's just that nms is the base server code and a bit more dangerous in that sense
spigot is slower but gives you many safety precautions
Didn't you ask this yesterday? Without proper modification no
Well how do i actually shade it? it showed [INFO] Replacing original artifact with shaded artifact. [INFO] Replacing C:\Users\Kidalder\Plugins\MobPoint\target\MobPoint-0.0.1-SNAPSHOT.jar with C:\Users\Kidalder\Plugins\MobPoint\target\MobPoint-0.0.1-SNAPSHOT-shaded.jar
thanks you
but i wanted to hear more people about it
let me show you an example of shading
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.6.1</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<executions>
<execution>
<id>shade</id>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
</execution>
</executions>
<configuration>
<relocations>
<relocation>
<pattern>com.github.Redempt.Crunch</pattern>
<shadedPattern>Crunch</shadedPattern>
</relocation>
</relocations>
</configuration>
</plugin>
</plugins>
</build>```
this will take the classes under com.github.Redempt.Crunch and remap them to Crunch in the final jar
hmmmm like Exception? try catch
so youre not directly modifying player data
or nbt
i.e. the PDC api
each plugin has its own namespace
to prevent naming collisions
Ok, How would i fix a classnotfound with shading?
take the classes you need and remap them to something
start with the package name of the classes you need
just mysql, right?
yes
this is the error java.lang.NoClassDefFoundError: com/mysql/cj/jdbc/MysqlDataSource
so for pattern put mysql, and for shadedPattern you can put whatever you want the classes to be under in the final jar (not that it will make much of a difference)
so you can just put mysql again
Ok
prevents clutter in the NBT stuff as well when plugins are removed 🙂
It should, PDC doesn't get saved into the NBT directly does it? o.O
sure does
why are you shading MySQL?
I am trying to fix the error
https://paste.md-5.net/kitafiqibu.xml does this look right @sage swift
you do know spigot has MySQL shaded in it already? o.O
That would be Silly thing to do cause if you were to update ur server and a plugin didn’t enable cause it errors on the new Version it would wipe pdc
The guide said not to use that because its outdated
Which guide?
yeah as outdated as the rest of spigot lmao
The home of Spigot a high performance, no lag customized CraftBukkit Minecraft server API, and BungeeCord, the cloud server proxy.
Didn’t it update with 1.17
its not and it does not
?optimize
probably could have, but I find it ironic that the guide states it was never intended for the public which this is incorrect lmao
Optimise - Bukkit.shutDown()
of course spigot doesnt have optimize shortcut lmao
cannot resolve symbol :(
That’s a paper thing
Oh lmao
System.exit(0); 
Ah. Well the shaded driver is intended for the public to use despite what that guide says, otherwise it wouldn't be shaded in, in the first place since you know spigot doesn't use mysql 🙂
but yeah probably should use the updated driver though 😉
System.halt(69);
Not sure if it has been recently updated for the driver being shaded in
so you could check what spigot has shaded in first before adding more work on yourself lol
Bukkit.getServer().spigot(). restart();
while(true)
as frostalf already said, spigot contains mysql
Well how do i use it then?
import the right shit i guess
good guess!
Yeah real helpful, have any idea where the shit might be located?
100 points to griffindor
probably added to your dependencies
Ik but what dependecy do i use
it doesn't get relocated, just depend on the proper mysql dependency and it will pick it up from spigot when your plugin loads
spigot
EnumInteractionResult result = player.d.a(player, world, nmsBlock, hand,
MovingObjectPositionBlock.a(new Vec3D(player.locX(), player.getHeadY(), player.locZ()), EnumDirection.a(evt.getBlockFace().toString().toLowerCase()),
new BlockPosition(location.getX(), location.getY(), location.getZ())));``` i love nms so much, especially when `playerInteractManager` turns into `d`!
tok
i don't understand java
i dont knoe what it does
;D
noice
That’s really cool
& does it also remove the blocks?
from the shulker? yeah
good but why do you need nms for that
call fake interact so the placement of stuff like stairs slabs torches etc is correct
as if the player is placing it
otherwise i have to do many block-specific calculations for different kinds of blocks
so it works well even with worlguard and similar?
yeah it essentially just fakes a block placed
that's so cool 👍
technically it sets a block in the offhand and then forces the player to place it but we won't talk about that
hi, how use a custom schedule bukkit ?
if i do Bukkit.getScheduler().scheduleSyncDelayedTask(Bukkit.getPluginManager().getPlugin("MYPLUGINNAME"), BukkitRunnable(() -> {
@Override
public void run() {
player.sendMessage("hi");
}
})); its a error
And that is?
what are you even trying to do
i would doing a schedule and in 10 secondes this schedule execute a code "player.sendMessage("hi")"
EDIT: nvm i cant specify on one error. simply everything is wrong
ok so how can i do ?
What do you want to do?
Schedule a message every 10 seconds?
or a message in 10 seconds
O_O
its that
Right
Take a free java course. It will take some time but it's worth it on the long run
so as the others said just about everything is wrong
That is probs a good idea
?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.
Ohhh wow nice command. Good bot
but i am willing to explain this example
sololearn has an mobile app afaik
Bukkit.getScheduler()
// Returns the Bukkit scheduler ^^
.runTaskLater(
// Will schedule a task to be ran later
plugin,
// This the instance of your plugin. This has been passed through the constructor
() -> {
player.sendMessage("Hi");
}
// This is a lambda function. It cuts down on the Runnable code + is better in other ways
, 20*10);
// This is the delay in TICKS, so 20 tps * 10 seconds = 200 ticks
Obviously you can remove the comments, but that is to explain it
thank you 👍
🥄
🖕
so i can replace 20*10 by 200 ?
yes
what x) ??
that was for NNYa
ok xD
spoonfeeding is bad, m'kay
he now has a block of code and doesn't know how or why it works, despite your best efforts at commenting it
he will also probably come back in 0.35 milliseconds asking "how to get plugin"
you'll end up writing his entire plugin for him at this rate
tru
no - he will probs just plop in the
Bukkit.getPluginManager().getPlugin("MYPLUGINNAME")
?spoon
Spoonfeed a newbie for a day and they'll come back with more questions. Teach them to find their own answers and you'll both be better off: you won't get stuck answering the easy questions and they'll be much more productive than before.
I GET IT
spoonfeed more and I'll go TOTALEN KRIEG on you
👀
how can i cancel the schedule ?
yes but i would cancel this schedule if the player have a damage
so i do public void EntityDamaged(EntityDamageEvent e) {
if(e.getEntity() instanceof Player) {
Player playerre = (Player) e.getEntity();
//cancel the schedule
now write him a class with a uuid -> task map and all of the necessary code to make it run
Try write the code yourself now, if you're done and it doesn't work you can ask for help here
But we probably can't write the code for you
declaration: package: org.bukkit.scheduler, interface: BukkitTask
yes but idk how do it
thx
first, you learn java, so you have an inkling of a clue of what you're doing and how to do things
then the responses we give here to your questions will be actually meaningful to you
basically, what you need to do is take the return value of the scheduler's run methods, which is a BukkitTask, store it in a map keyed by UUID or Player to associate it with a player, and in the damage event handler, retrieve the element corresponding to the damaged player, and if it exists, cancel it
however I'm willing to wager that literally none of this means anything to you
Can you get the Task from the id? i forget
you can
i think? you can cancel it by the id, that's for sure
but, an int or a bukkit task, it doesn't matter
you need to store it anyway
yeah
#scheduleBlaBla returns an int with which you can cancel the task
it returns BukkitTask
yep
which is what most people do for whatever reason
aren't the schedule methods deprecated
umm
runTasks returns BukkitTask
just some
brilliant
ok but how have this id ?
i guess they assume it is more efficient to store int than the BukkitTask
basically, what you need to do is take the return value of the scheduler's run methods, which is a BukkitTask, store it in a map keyed by UUID or Player to associate it with a player, and in the damage event handler, retrieve the element corresponding to the damaged player, and if it exists, cancel it
idk what BukkitTask actually represents though, it may be just the integer
an object like BukkitTask is just a 4/8 byte reference
depends on what BukkitTask contains
i'm not sure what it wraps over; could just be the int and the instance of the scheduler
but i guess it wouldn't matter since the extra resources used to store the BukkitTask IF THERE ARE ANY are so small that you can't even notice them
well i mean, to store a reference type, you just need a reference
and collections only store reference types, generally
ok thx
sure, but the object still exists
yeah, but it's bound to exist anyway
and takes his place in the heap
as it's probably used elsewhere in bukkit
so that object's footprint isn't attributable to you storing it
only the reference is
Hello quick question:
Is it possible, if you want to use custom sculls, that you can somehow use your own created heads?
Thank you in advance
and on the contrary, if you were to store the int in a collection, you'd need to wrap it in an Integer
possible
which would only exist just because you need to wrap it
but if not it will be thrown away afterwards if nothing refers to it anymore if the gc doesn't decide to go on vacation
so that object's footprint is attributable to you storing it
What do you mean by
own created heads
i'd believe that bukkit holds a ref to it until it either runs or gets cancelled
but either way, it won't use more resources than an Integer
^^
so in conclusion if bukkit holds the ref to the bukkittask somewhere in the background it would technically be better by storing the ref to the bukkittask
if not, either goes
^
but I also see no reason to jump between task and int and integer and back so I usually go with the BukkitTask ref
You can, for example, implement heads from the minecraftheads.com site into your plugin in order to be able to set them as blocks or player heads. However, since I haven't found the head I want, I wonder if you can also use heads that you have created yourself.
the texture needs to exist on mojang's servers
^^
by self-created heads I mean pixelated heads
i use minecraftheads.com
the texture, still, needs to exist on mojang's servers
you can't display arbitrary textures
set the skin for yourself and voíla it will be on the mojang servers
what you do is you give the skull an URL that points at the texture on mojang's server
oh oh ok
you can make that happen by f.e changing your own skin to the texture you want
and then changing it back
old skins are retained on mojang's servers even after you stop using them
okay
I'm not sure if this head exists on Minecraftheads. May I send a picture here in the chat to show you what kind of head I would like? Maybe you know a head that would look like this
ok
we aren't the mojang database
jeff is too kind
something like this should be on the front of the head. But in red
does any1 have a custom currency plugin "template" with placeholders to show player bal?
Wdym - just hook into the vault api
no we don't have premade plugins for you to copy
someone on the spigot forums might have your "template" but I wouldn't count on it
Or some help for an simple custom currency with 1 placeholder
ok too bad but thanks anyway :D
no... I replied to the wrong message .-. xD
So if I changed my skin now for that head, and then went back to my normal skin, would the head I need still be in the Minecraft database and I could use it?
and how could I then access the head?
im not sure
correct me if im wrong, but I think you can access old textures of a player's skin
i don't think that is an astronaut
Among us I guess
AMOGUS
and how?
But these little fellas are in fact astronauts
that clearly isn't among us, it has no foot
it'd be pretty difficult to put feet on a cube
^^
new theory: the shield of among us character isn't actually a shield or a mouth, it is the eye
many fan animations would disagree with this theory
among us makes me want to holocaust 2.0
it's so fucking annoying and it's everywhere
say what
it actually strengthens the theory tho, the 'shield' shape changes as part of facial expression
i'd have to like make backups and shit and ensure it doesn't nuke my data
too much effort
lots of software sucks
It's a cartoon-ish drawing style. How would you draw impressions without face? :D
Just aim for ireland
my WUNDERWAFFE cannon will lay waste to your cities
lmao
I only accept face reveal to prove the theory wrong 😈
btw NNYa - i finished the translation plugin like last week
i hate async tho
i just find it stupid
threading is a world of its own myeah
Then run things sync 🧠
you'll get more used to it as you do more shit in a concurrent environment
but it will always be ass to some extent
#multithreadservers
You will be happy to know that your block of code made the cut
lol
use forEach instead of for on languageCodes 🤡
.whenCompleted((result, e) -> {if (e != null) e.printStackTrace();}); 🙂
you know what
https://github.com/olijeffers0n/XLang
Roast me
yeah you probably want to do some exception handling
yeah
i don't do that because it's for pussies
-.-
you cant see when there is error in cfs
ignore the error
cuz you know
nah
just go on
cf
try catch ignore
embrace the error
i mean
bully the error
cremate the error
let it live in the dark abyss of another thread, never to be truely accepted onto main
how to bully/cremate the error if you dunno if it is there
it is like
schrodinger cat
if it is that bad it will have to yell louder
punch into the future
bad errors should be in all caps
name your listener classes XXXListener
name conventions >:(
Server:WARN - YOU MORON THERE IS AN ILLEGAL ARGUMENT EXCEPTION OVER HERE
did i?
that's the spirit
i thought about changing the name but i couldn't find the refactor button
https://github.com/olijeffers0n/XLang/blob/master/src/main/java/com/oli/xlang/headapi/HeadApiInterface.java missleading name
Hello
new language?
nah
how is that a misleading name
it literally interfaces with the api

so you could name everything XXXInterface then right?
YES I SHOULD HAVE
have you tried the error logic in the main class
?
the one that disables your plugin, in particular
try {
Class.forName("com.github.pemistahl.lingua.api.LanguageDetectorBuilder");
}catch (ClassNotFoundException ignored) {
getLogger().severe("______________________________________________");
getLogger().severe("YOU DO NOT HAVE THE LANGUAGE LIBRARY AVAILABLE");
getLogger().severe("You are Running: " + Bukkit.getVersion() + ", You must have <= 1.16.5");
getLogger().severe("If you are running 1.16.5 you may need to update your build as you do not have the 'libraries' feature");
getLogger().severe("______________________________________________");
Bukkit.getPluginManager().disablePlugin(this);
return;
}
what bout it
