#server-plugins-read-only
1 messages · Page 91 of 1
yeah attach a command to a npc so when I click him it does something
I believe so
What is it? :D
Does anyone have the plugin documentation they could send me? Thanks :D
Nope, you will have to develop it
Just ask chatgpt to make you a npc plugin for hytale and to run a command when its clicked
You can even run a UI in the background
Can someone explain asset packs? When I unzip it, will it get loaded? Are they required to be in a zip?
I made over 150 plugins with chatgpt and they work
After testing some, it seems we can't use animated sprites on the HUD. When you pause they begin acting normally, though. Has anyone found a way around that? (Other than programmatically changing the texture, which gets resource intensive)
Can I take get() from CompletableFuture in ECS is it possible to do this after some asynchronous task?
Does anyone know of a mod to add floating text with images to a hub server?
yeah we also have the same problem. It seems, that you cannot upload custom mods to hytale servers at the moment. is that correct?
Anyone know why this keeps spamming my console when running a local server?
[2026/01/20 20:47:17 SEVERE] [World|default] Took too long to run pre-load process hook for chunk: 92ms 854us 900ns > TICK_STEP, WorldChunk{x=-33, z=-4, flags=00000000000000000000000000000100}, Hook: com.hypixel.hytale.server.core.modules.block.BlockModule$$Lambda/0x000000a3d29d5058@7c0035dd
[2026/01/20 20:47:17 SEVERE] [World|default] Took too long to run pre-load process hook for chunk: 91ms 209us 799ns > TICK_STEP, WorldChunk{x=-33, z=-3, flags=00000000000000000000000000000100}, Hook: com.hypixel.hytale.builtin.blocktick.BlockTickPlugin$$Lambda/0x000000a3d29091a0@795131d6
[2026/01/20 20:47:18 SEVERE] [World|default] Took too long to run pre-load process hook for chunk: 320ms 240us 200ns > TICK_STEP, Has GC Run: true, WorldChunk{x=-18, z=-27, flags=00000000000000000000000000000100}, Hook: com.```
I'm using AbstractCommandCollection to register a command and subcommands, but is it possible to make the base command also do something when executed?
Any news on official documentation?
Either your processor is struggling to keep up, or a plugin/mod is causing slowdowns most likely
i am!
Hmm, shouldn't be my processor I've got a good one..
Hey yall, anybody know how to get PlayerInteractEvent working? Trying to detect a right click with my custom item, but it's just not registering
I've got the same, don't think it's an issue
What plugins/mods are you running? There may also be profiling mods available but I'm not sure yet
None, I've just pulled down the plugin template repo and just getting started here
Average 150ms isn't bad but if it's happening often could be a symptom
So for Simple Claims mod, anyone know in the config where it is to allow people to use that perm?
Seems to have gone away after running in debug mode...
I'm having trouble getting the text from a UI to modify what's written in a JSON file. Can someone please help me?
Thanks for your help though!
does someone know where I can find the inventory .ui file?
Been a consistent issue for many people. I've seen some attempts to remedy this by reading server packets, but I haven't tried it myself.
guys someone have 1 guide for creaiton mod?
Hey guys, is there a way to get self written mods onto our server?
Guys, any one know, how to change Anchor value in java?? For text is easy ui.set("#d1.Text", "Lvl 1");, but for anchor lot of mess
Put them in the mod folder
Guys, I'm trying to make a mod that uses the Stone Planter to automate planting, so that when it reaches the final stage it returns to the initial stage and the resources are placed in the chest below, but my code isn't working.
well our curseforge mods are working but self written is not working on the server
And your mod works on like a test server?
Have you got a manifest.json in the top-level of the JAR?
What is the main difference between a plugin and a pack. And can I convert a pack into a plugin?
Does anyone know why my world with friends isn't working out for me?
Not a lot. They both get bundled the same way - the only difference is whether your manifest says it includes assets. Which answers your second question - yes
See: wiki[dot]hytaleservers[dot]host/Plugin_Manifest
yes we do have that
is in the manifest everything that we need? like also the API and stuff
this is the test server 😄
Have a look at the page I linked above (are you getting any errors in the console?)
So the mod hasn't worked before? Check your logs it normally tells what is wrong and else try to get a template mod and test and export that to see if that works since the template should work either way without changing
pfff can't get it to function even through intercepting server packages
If the template works check what is different between yours and the template.
It sounds simple and its also the easiest way to check where your issue is
I am losing my sanity.
How do I replicate setting an asset, but with no change?
im sorry, what page are you talking about?
Looks like you're offline or our services are unavailable. Click Play again to launch Hytale in offline mode.
If you need to check the manifest: wiki[dot]hytaleservers[dot]host/Plugin_Manifest
link install?
thx
yeah well the console doesnt really give any errors anymore, we tweaked it the whole day and it should be working but the commands do not work ingame
So the plugin/mod loads but you dont see the command?
ok, I have the following:
this.getEventRegistry().registerGlobal(BootEvent.class, (event) -> {
for (BlockType block : BlockType.getAssetMap().getAssetMap().values()) {
if (!"Open_Container".equals(block.getInteractions().get(InteractionType.Use))) continue;
try {
Field interactionsField = block.getClass().getDeclaredField("interactions");
interactionsField.setAccessible(true);
Object interactionsObj = interactionsField.get(block);
if (!(interactionsObj instanceof Map<?,?> interactionsMap)) continue;
Map<Object, Object> modifiableMap = new HashMap<>(interactionsMap);
modifiableMap.put(InteractionType.Secondary, "Yht_QuickerStacker_QuickStack");
interactionsField.set(block, modifiableMap);
} catch (NoSuchFieldException | IllegalAccessException _) {
System.out.println("Error modifying interactions for block type: " + block.getId());
continue;
}
}
});
The interaction I add works fine, but only when I am holding a block in my hand while attempting to interact with a chest. If I don't hold anything or hold an item, it doesn't work. Is this a bug, or am I missing something? Entire code and assets are available on github under YouHaveTrouble/QuickerStacker if anyone needs all details
yeah pretty much
I would understand if it didn't work with unarmed only, but it fails with items aswell
Would you recommend a plugin or a pack?
They’re really the same thing. Do you have code, assets or both?
Okay that a different story already then the mod doesnt work 
Did your register the command in your setup of the mod? I didn't deep dive into commands yet so idk if you got to register it aswell in the manifest
I got both, but really really wanna do it inside an ide instead the asset editor. But I'm always confused due the lack of an full documentation...
yeah well we will try to tweak it a little bit more. thank you guys so far
has anyone figured out how to open the inventory with a custom ui alongside it?
hytale plugins are easier to configure than minecraft plugins? or not
In that case you want to set IncludesAssetPack to true in your manifest and also set a Main class. You then put all the assets in the resources directory and they'll get copied into the JAR as part of your build process.
also where can i see hytale plugins
Does anyone know if I can set the environment for an entire world?
Curseforge or github. I have some open source ones in my profile. It's harder than Minecraft mainly cause its not a fully fleshed api or docs just yet and its a different system ecs vs ooc
Does someone know how to use custom things from plugin code(interactions for examples) in asset editor?
I've tried this before, but I guess some properties inside my .json file are wrong. Is it possible to put logic inside my pack using the asset editor like some java files?
Yes it's basically the same thing in the other direction. As long as you've set a Main class you can copy the compiled Java classes (.class files) in - I would probably try and get it working in the IDE though, that seems much easier
where i can find hytale plugins api?
Tanks mate❤️ ❤️ ❤️
Having some major issues with teleporting players between worlds. We’ve tried a ton of solutions but all have problems. This is relevant primarily because as a network, we have to warp people from hub to lobby to game world, and it’s causing some major complications for us. Any tips? The main issues showing up are:
-rubber banding
-spawning in the air in a falling state
-other players unable to see each other correctly (stuck in same place running, floating, etc)
-Desync issues in general
there isnt an official one, you will need to decompile the server
Decompile the JAR. There's no real official docs yet. Otherwise, there's a bunch of AI-generated docs that are normally wildly inaccurate or community-based wikis
We're maintaining one at: wiki[dot]hytaleservers[dot]host but it's only got a starter's guide and then some very in-depth stuff
Ive made a server on shockbyte and i want to have the settings to not lose items when a player dies does anyone knows how to do it
did anyone figure out how to make custom templates for worlds and use them for instances?
Did you get any errors or did it just not load the assets? If you had IncludesAssetPack set to false (or not set at all) then it would have just ignored the assets but the code should have at least loaded
can someone please mod controller support in
if anyone knows anything that might be wrong, please @ me, I likely won't be able to see otherwise
has anyone figured out how to have custom ui alongside something like the inventory like a bench
No error even the log looked fine. Somehow the icon wont be rendered and I cant place my custom bench...
Maybe try again and make sure IncludesAssetPack is set to true in your editor. Also, what are you using to build? Gradle?
How do i save data into a file or something like that
im trying to save inventories but where and how???
You just do it yourself. You can use the Codec library (part of the HytaleServer JAR) to do it, or you can do it with any library for reading/writing files
but where do i save the json for it to be persistent
By convention, in a folder alongside your mod. For example if your file is MyMod.jar inside mods/, you would create a MyMod folder also in mods/
Anyone working on Hardcore Factions with Archer Bard Warrior ETC?
Is that the same for plugins??
mods == plugins
yes
do most people use the built-in codec or own libs
mods in hytale work in server side, so are plugins too 😄
I think most people probably use Codec because it's convenient. I personally would use Jackson
Yeah I switch to IntelliJ so I could use the Hytale plugin. For building I used the pre defined build task of gradle.
Before switching to IntelliJ everything was fine. After switching to IntelliJ I didnt edited any code, but my plugins ist working properly anymore. I guss I have to stick to the asset editor for now until I find a solution..
how do I make an item change its id when I press something? like a rainbow pickaxe that change its color every time break a block
Ive made a server on shockbyte and i want to have the settings to not lose items when a player dies does anyone knows how to do it
I suppose to be really pedantic, the mod would be the entire package (e.g., code and assets) and plugin would be just the code. But for most intents and purposes, server-side mods (which are currently the only type of Hytale mods) are plugins.
plugin reload sitll not working?
It should be fine but I don't know what the Hytale plugin is doing. Personally I've just set everything up with a normal gradle project:
wiki[dot]hytaleservers[dot]host/Creating_your_first_server_mod_(plugin)
Dont change the Id. Just change the texture.png based on an event
hmm, suppose I want to change the blocky model, is it possible?
Someone have documentation with examples?
For?
Yo i have in my host:
hytale-downloader
17 minutes agp
logs
2 minutes ago
mods
2 minutes ago
Server
2 minutes ago
universe
mods = minecraft plugins or ?
Hytale plugins
Mods and plugins are one and the same
has anyone figured how to clone a world from a template?
how can i have a plugins folder
there are no plugins, its all mods, you put them in the mods folder
okay thanks
Server side modding 🤓
lol
server side modding == plugins
Hytale server plugin in java
but with assets == mods
No 🤓
I have a guide for creating a hello world project but it doesn't go further than that yet. That should at least get you to the point where you can find other resources or use decompiled JARs:
wiki[dot]hytaleservers[dot]host/Creating_your_first_server_mod_(plugin)
there are no client side mods, only server side mods, so either we call everything mods or everything plugins cause they work exactly the same
where i can find documentation?
there isnt any official documentation, you can either decompile the server or you use unoffical resources
Holy AI
does anyone know a good way to put items into a slot?
I made custom slots and Idk how to put items into them. I know how to put the images in certain areas, but I'm not sure about how to use the actual item as a part of my UI the built in way
aaaaaaaa
How exactly do I safe my progress inside the Asset Edito?
Anyone else working on tech mods? Working on a power API currently.
guys i dont speak english, but im trying understend and talk
are there any interactions we use to check if you press f on an block?
is plugin reload still broken?
help erro
Accept my friend request
curseforge com/hytale/mods/hyskills-easy-custom-skills
Changes:
*New XP bar at bottom of screen that updates to current skill being trained.
*New command /skillstogglebar which will hide the HUD bar at the bottom.
*Delete confirmation when deleting a requirement, trigger, unlock and locked.
*Delete confirmation for deleting entire skills.
*Issue with reorder of triggers and requirements fixed.
*QOL "Click here" text added to requirements, triggers and unlock pages to make it obvious.
*Save check on requirements, triggers and unlocks not having types added.
*stat_mining_speed renamed to stat_blockbreak_speed as it affects all blocks.
*Swim and climb have addition "is moving" toggles to stop abuse of skills.
*Scrolling reset when setting values bug fixed.
*Ability to modify stats of offline players is enabled again.
*Searching for items/entity can now be selected in multiples and saved.
*MHUD has been implemented so multiple HUDS work.
*Settings page added to /skillsadmin to toggle xp bar and notification on or off by default for new users.
*Item in hand backup check added.
*Duplicate chat notifications on level/xp gain.
*Issue with stamina regen applying level as reward when set to every level fixed.```
Ive made a server on shockbyte and i want to have the settings to not lose items when a player dies does anyone knows how to do i
An error has occurred
Please try reloading the launcher. If the problem persists, contact support.
is prefabs still blockymodel?
wow this chat has deteriorated quickly in the last 5 minutes lol
i have the same thing. says no user is logged in. how can i fix that
Anyway to block mob spawning in defined areas? or do i have to add plugin first?
does anyone know how or know a guide or open source example project that gives a block a custom UI that can edit components of the block that you open with F, thanks
I'm having trouble logging into some Hytale servers; I get the error (0) time out for inactivity and Connection aborted by poor
nvm i fixed it 
Anyone know who wrote the HyChunks site?
Hey guys is there any docs or anything i can read to understand the hytale plugin system
Anyway to block mob spawning in defined areas? or do i have to add plugin first?
Ive made a server on shockbyte and i want to have the settings to not lose items when a player dies does anyone knows how to do it
My hud is kicking me out of server when moving to a different instance/through portal, any ideas any1?
what i got to do to get a kiss around here
I'm having trouble logging into some Hytale servers; I get the error (0) time out for inactivity and Connection aborted by poor
One of my mods is crashing my game only when I try to place seeds, anyone know what causes it
MWAH
debug
suppose it's possible you're not updating on the right context? I assume it works fine UNTIL you move through the portal.
worlds run in separate threads. So I would assume perhaps making sure all the work being done properly transfers over to the new world's thread. world.execute is all I know so far.
Yeah it does, I load into the game just fine, I'm assuming on the factor as to how my UI is updating but I don't know what checks to make so it doesn't when loading to anotheri nstance
How do I fix it?
Have you checked your error logs?
It’s not giving me any, just freezing my game and leaving sorts it
Is there an event from stopping a user to pick up Rubble stones ?
it only disconnects you right? The server doesn't crash?
Do I need\or are there exist any different interaction classes? I find use of SimpleInstantInteraction only, does it enough for every purposes?
Yeee just disconnects me
you would have to do that with custom interactions
If I have a ready spawn how can I put it in. I just put it in my host and it will work? Do I need any plugins?
Okay
Ive made a server on shockbyte and i want to have the settings to not lose items when a player dies does anyone knows how to do it please???
Anyone know if there's a reference thing for replacement mask tags, or what the tag for rocks are?
I've made a custom sallow sapling (so I can actually get renewable goldenwood), and I just removed the bottom blocks... since apparently it will just not spawn the prefab if any blocks will replace those that are not allowed to be replaced.
Soil is the only tag I'm aware of, and it could be because I haven't even looked at the world generation stuff, so if anyone knows what they are or where to find them would appreciate.
go to curseforge for hytale and search keep inventory and put this plugin by KingsDev in your mods folder 🙂
Hi, I'm following Kaupenjoes Hytale Modding Tutorial, and after he decompilesServer on inteliJ.
There is no HytaleServer-src.zip folder for me. IDK if it's in a different location but I only have some jar files and a different folder. Any help would be appreciated. Did I need to download this beforehand or something and where from?
If I have a ready spawn how can I put it in. I just put it in my host and it will work? Do I need any plugins?
Yeah I think the HytaleServer-src.zip was a mistake. They don't ship that anymore
You don't actually need it though
Mods I’m using are better stats, eyespy, gone fishing, vein mining, over stacked and simply trash
I don't? So I can just continue then?
Yep
If it just disconnects, from the tutorial/video I was watching on youtube about UI -- Might be modifying client UI directly? Which is not allowed? The example shown kicked him immediately after the UI was "modified" so I want to wager there's a different way for you to handle your UI
?
I just managed to crash my game so hard it reinstalled itself wtf
Thanks so much.
Where does the server store the assigned permissions?
hytale-docs pages dev
where do i find that sorry
put periods instead of spaces
Is there a way to tier up also Container typed Items?
Or any other Way I can store specific Items in a Structure (maybe with a custom interface design?).
is there a way to grab a ray from where the player is looking, like hooking into the creative laser pointer?
its the best one I found so far, another pretty goold one is hytalemodding dev, tyhere are no official docs
does anybody know how to change itemstack description dynamicly?
so im running a dedicated server and i had just restarted it like 10 minutes ago and saw there was a mini update on the client at least and now i get a "no world available to join" error when trying to connect
What function is used to create an NPC?
If I have a ready spawn how can I put it in. I just put it in my host and it will work? Do I need any plugins?
bump
I figured I can just make the description and name appear when hovered, but im not sure if that is necessary.
Is there a built in method is what im wondering
Hi, does anybody know how to play item animation through Hytale's API? I've added animations into the blockbench model, and i wonder how can i play them directly from the code
Where do i put my prefab files within my server files to make them usable in the server?
guys is it possible to open a link from the ui?
Does anyone know how to get the item the player currently has selected in their inventory?
is there a way to get the player who placed a block on placeblockevent?
You have to create a prefabs folder
Where? Root?
Yes
sorry if it's noob question, very new to java
.updatePosition
can I write actual specific coordinates?
eg. I want player at 0, 100, 0 with 0 yaw 0 pitch
@dense yacht left a comment on the coins mod, it completely stopped loading on update.
Ty ❤️
Guys, be careful when making UIs, when ending the server, it reverts the file back to the way it was before it was started for some reason. Maybe it opens it for read or something? I just lost a bit of progress because of that
Is there an existing interaction already in place that could be overwritting or just a complet new one that would need to be assinged in the assist aswell ?
Does anyone know why holder is null here? (Async command)
PlayerRef targetPlayerRef = playerArg.get(context);
String achievement = achievementArg.get(context);
Holder<EntityStore> holder = targetPlayerRef.getHolder();
assert holder != null;
AchievementData data = holder.ensureAndGetComponent(SimpleAchievements.achievementDataType);
ArrayList<String> obtainedAchievements = data.getObtainedAchievements();
obtainedAchievements.add(achievement);
data.setObtainedAchievements(obtainedAchievements);
Hii I don't exactly know where to post this but does does anyone know of any way of getting the HytaleServer.jar to run on an ARM build of the Java 25.0.1 JDK?
I have a Windows ARM device (Snapdragon X Elite) and I noticed the game performance on this device is sort of rubbish due to heavy use of emulation. I've managed to make the client run via an arm build of the Java JDK by replacing it in the game files, but whenever I join a single-player world it tries to launch HytaleServer.jar with that same ARM JDK, which causes the local server to crash since it uses x86-64 binaries which in turn locks the player out of single-player worlds entirely.
I've gotten around this by loading the client natively via the ARM Java JDK while running a server locally using an x86-64 build of the Java JRE. This is way more performant but still a massive workaround, if anyone knows of get the HytaleServer.jar to run that would be greatly appreciated since that means more devices could run this game at a high performance.
guys how can i change a ItemStack's display name
anyone has a list of effect ids?
I cant see it in the prefab list...
you can do it with EntityEventSystem<EntityStore, InteractivelyPickupItemEvent>
To confirm my prefab file should be a .json file?
Idk, for me it says "Object reference not set to an instance of an object"
It's a very simple scoreboard UI, so I'm probably just loading it wrong, been trying to get it working for like 4-5 hours now 🤣
But this event isnt firing on picking up rubble ?
Hi! Someone have a lobby mod for server?
yeah it is
Is it possible to play effect (like swing) in programmatically written Interaction? Are there any limitations compared to JSON?
your_name.prefab.json
I've found the culprit but its not going to be fun news for anyone on ARM, turns out HypixelServer.jar relies on a library that currently only supports a handful of architectures and OSes. R.I.P a Windows on ARM release of this game I guess
Is it possible to detect wether the user has opened the map?
my username?
Oh true my bad cancelling just doesnt prevent the rubble from disappearing
Oh no i see, prefab name
anyone able to build a spawn?
its like that.. but its not showing in the list
Added u, i can help ya out.
Hi! Someone have a lobby mod for server? Please :<
yeah to stop it from disappearing you wíll need to cancel another event. not sure which one atm tho
I found the issue... prefabs FOLDER cant have capital letters..
Okay so there is one atleast as to your knowledge ?
Want to prevent the pickup / the rubble disappiering
i have seen mods preventing people from picking up rubble entirely, yes
Which interaction would that be as in the assit editor i only see the throw interaction
I'm trying to detect when a player interacts with a specific item in hand, but placeblockevent doesn't return the player, playerinteractevent is deprecated + registering doesn't return the event's class for some reason and PlayerMouseButtonEvent returns Item instead of ItemStack (I need the itemstack for the item's metadata) do you have any solution?
Did you find the fix for this?
Group {
LayoutMode: Right;
Anchor: (Top: 20, Height: 60);
Group #MyPanel {
Background: (Color: #313131);
Anchor: (Left: 20, Top: 20, Width: 400, Height: 400);
Padding: (Horizontal: 20, Vertical: 10);
LayoutMode: TopScrolling;
Label #Title {
Style: (FontSize: 32, Alignment: Center);
Text: "A Hytale Server";
}
Label #Name {
Style: (FontSize: 18, Alignment: Center);
Text: "Player: Loading...";
}
Label #Ping {
Style: (FontSize: 18, Alignment: Center);
Text: "Ping: 0ms";
}
}
}```
The title name and ping are not centered. How can I fix this?
does anyone know some effect ids?
uhhh idk turns out i didnt update my server properly so nvm
Is it possible to play animation effect (like swing) in programmatically written Interaction? Are there any limitations compared to JSON?
Alright then im going to go for that
i did the same thing lol
I'm trying to detect when a player interacts with a specific item in hand, but placeblockevent doesn't return the player, playerinteractevent is deprecated + registering doesn't return the event's class for some reason and PlayerMouseButtonEvent returns Item instead of ItemStack (I need the itemstack for the item's metadata) do you have any solution?
can some1 test a function with me real quick on my devserver? no friend online 🙁 (only takes like 3 minutes)
is there any information out there about @DropdownBox from the Common.ui how to set the values for it?
i usually look that up in hytale ui builder but cant find the element there
var world = Universe.get().getDefaultWorld();
var headRotation = playerRef.getHeadRotation();
var transform = new Transform(new Vector3d(15.5, 188, 0.5), headRotation);
playerRef.updatePosition(world, transform, headRotation);
not really having luck with this
nothing happens
printing out each one does give correct info though
am I doing something wrong or missing something?
To teleport a player you add a Teleport component to them
How do I save data to a player? Do I need to add a component to them?
Yea that works
you speak some funny words wizard
(new to java so gl to me haha)
thanks at least I know in which direction to look
OK... so I have this:
package me.maemoon.plugin;
import com.hypixel.hytale.codec.Codec;
import com.hypixel.hytale.codec.KeyedCodec;
import com.hypixel.hytale.codec.builder.BuilderCodec;
import com.hypixel.hytale.component.Component;
import com.hypixel.hytale.server.core.universe.world.storage.EntityStore;
import java.util.ArrayList;
import java.util.List;
public class AchievementData implements Component<EntityStore> {
public static final BuilderCodec<AchievementData> CODEC = (BuilderCodec.builder(
AchievementData.class,
AchievementData::new
)
.appendInherited(new KeyedCodec<>("Obtained_Achievements", Codec.STRING_ARRAY), (e, s) ->
{
e.obtainedAchievements = new ArrayList<>(List.of(s));
},
(e) -> {
return e.obtainedAchievements.toArray(new String[0]);
},
(e, p) -> {
e.obtainedAchievements = new ArrayList<>(p.obtainedAchievements);
})
.add().build());
private ArrayList<String> obtainedAchievements;
public ArrayList<String> getObtainedAchievements() {
return obtainedAchievements;
}
public void setObtainedAchievements(ArrayList<String> obtainedAchievements) {
this.obtainedAchievements = obtainedAchievements;
}
@Override
public Component<EntityStore> clone() {
AchievementData copy = new AchievementData();
copy.obtainedAchievements = this.obtainedAchievements;
return copy;
}
}
How do I actually add the component to each player and then modify the data?
Have you registered this component
Uhh in my main code I have
getEntityStoreRegistry().registerComponent(
AchievementData.class,
AchievementData::new
);
do not forget codec
I'm new to java too, came from C++, but I had to do that so I found that you have to add a teleport component to a player, if that confuses you, you should maybe read how the Hytale ECS works. But in the meantime here is the snipped from the hytalemodding website:
public static void teleportPlayer(Player player, int x, int y, int z) {
World world = player.getWorld();
if (world == null) return;
world.execute(() -> {
if (player.getReference() == null) return;
Store<EntityStore> store = player.getReference().getStore();
Teleport teleport = Teleport.createForPlayer(world,
new Vector3d(x ,y, z), // Target position
new Vector3f(0, 0, 0) // Target rotation (pitch, yaw, roll)
);
store.addComponent(player.getReference(), Teleport.getComponentType(), teleport);
});
}```
Thats the wrong registry method
Use the one with the codec param
If you need headRotation just add a function param, you can also change the param to use Vector3i, a little bit cleaner imo
The one that goes Class, string, Codec
@mellow tendon i found a way to handle Interactions without the need of any json files. i managed to recreate your QuickStacker in just one single class
Guys anyone else noticing that, on a dedicated server, when there are a lot of players online (I have 8 atm), less mobs or even none spawn at all?? Any idea how to fix this?
Does anyone know how would I check if a player has OP? Is it a special permission string or it has another function?
Been having alot of Api issues on PlaceBlockEvent and stuff when i try make custom world lock when trying to protect the claim via PlaceBlockEvent and stuff for my server, (can't even get the debug to detect it) does anybody know what i can do to get it to work someone also reported on other discords of claim plugins there has been issues with certain protection systems does anybody have a easy fix for this?
just saw this snippet a moment ago
just need to figure out how to get player from playerRef in this case
also I come from web development so this is ENTIRELY new for me haha
sorry pietru wrong ping
meant to ping @wintry dawn 😂
gib gh repo
i dont know how to use gh ;(
Do you already have a Store<EntityStore>
time to learn!
Or a ComponentAccessor
you basically install github plugin in idea, log in with your account and go vcs -> share project on github
that simple.
this is where I am at now with the snippet nikola shared
public void start() {
try {
getEventRegistry().register(PlayerConnectEvent.class, event -> {
var playerRef = event.getPlayerRef();
var playerUUID = playerRef.getUuid();
Player player = store.getComponent(ref,Player.getComponentType());
teleportPlayer(player, 15.5, 188, 0.5);
});
} catch (Throwable t) {
Universe.get().sendMessage(Message.raw("Brother it failed with "+ t));
}
}
public static void teleportPlayer(Player player, double x, double y, double z) {
World world = player.getWorld();
if (world == null) return;
world.execute(() -> {
if (player.getReference() == null) return;
Store<EntityStore> store = player.getReference().getStore();
Teleport teleport = Teleport.createForPlayer(world,
new Vector3d(x ,y, z), // Target position
new Vector3f(0, 0, 0) // Target rotation (pitch, yaw, roll)
);
store.addComponent(player.getReference(), Teleport.getComponentType(), teleport);
});
}```
can i just send you the class for now? xD
sure
Thanks got it implemented that way 😄
ignore the player player part in start() as I literally just started using this
Just get the PlayerRef using the store PlayerRef playerRef = store.getComponent(playerEntityRef, PlayerRef.getComponentType());
Is it possible to add tabs to existing workbenches in the asset editor? For instance if I wanted to add a new tab to the alchemy bench, for new categories of recipes.
playerEntityRef in this case is Ref<EntityStore>
send fq on dc. i cant friend you
just send the class here, just wrap it in ```
I have playerRef from the event already no?
I need player from playerref now
unless I am being dumb
I program everything myself so wont be a problem
public class InteractEventSystem extends EntityEventSystem<EntityStore, Pre> {
protected InteractEventSystem() {
super(Pre.class);
}
@Nullable
@Override
public Query<EntityStore> getQuery() {
return PlayerRef.getComponentType();
}
@Override
public void handle(int i, @Nonnull ArchetypeChunk<EntityStore> archetypeChunk, @Nonnull Store<EntityStore> store, @Nonnull CommandBuffer<EntityStore> commandBuffer, @Nonnull Pre event) {
Ref<EntityStore> ref = archetypeChunk.getReferenceTo(i);
Player player = store.getComponent(ref, Player.getComponentType());
PlayerRef playerRef = store.getComponent(ref, PlayerRef.getComponentType());
String blockName = event.getBlockType().getId().toLowerCase(Locale.ROOT);
if (!blockName.contains("chest") || player == null) return;
Inventory playerInv = player.getInventory();
if (playerInv == null) return;
World world = player.getWorld();
if (world == null) return;
WorldChunk chunk = world.getChunk(ChunkUtil.indexChunkFromBlock(event.getTargetBlock().x, event.getTargetBlock().z));
ItemContainerState containerState = (ItemContainerState) chunk.getState(event.getTargetBlock().x, event.getTargetBlock().y, event.getTargetBlock().z);
ListTransaction<MoveTransaction<ItemStackTransaction>> transaction = playerInv.getCombinedHotbarFirst().quickStackTo(containerState.getItemContainer());
}
}
Only thing this causes are client/server desyncs tho
getEntityStoreRegistry().registerSystem(new InteractEventSystem());
register it with this in your main
yeah that is most basic way and will not work with what I have planned
You can intercept the Interact packet and nullify its data before it gets sent to the server, then update the client back, its fixed all issues for me
sadge
PlayerRef is not the same as Ref<EntityStore> tho, didn't fiddle with the events without an ECS system so idk exactly but look for a way to get the Ref<EntityStore>
I want to replace the click with a charging interaction, so when you click it stacks to the chest you clicked, if you hold it stacks to all nearby chests
could try typing /spawning populate
it needs actual charging type interaction
that will repopulate your world
ahh yeah that would not work with my way
from what I see it's just playerRef.getReference();
btw does anyone know if there is a way to rebind certain buttons in the playerinventory? like the memory-UI button for example
can i shedule non static methods?
by the way ya'll, I still have that mystery bug (?) to explain, bumping it because it's really really odd behavior
Ok, so now I have getEntityStoreRegistry().registerComponent(AchievementData.class, "Achievement_Data", AchievementData.CODEC);
and now the plugin is failing to load because e.obtainedAchievements is null?
Codec:
public static final BuilderCodec<AchievementData> CODEC = (BuilderCodec.builder(
AchievementData.class,
AchievementData::new
)
.appendInherited(new KeyedCodec<>("Obtained_Achievements", Codec.STRING_ARRAY), (e, s) ->
{
e.obtainedAchievements = new ArrayList<>(List.of(s));
},
(e) -> {
return e.obtainedAchievements.toArray(new String[0]);
},
(e, p) -> {
e.obtainedAchievements = new ArrayList<>(p.obtainedAchievements);
})
.add().build());
I never tried it, but it seems possible. ```java
PlayerRef playerRef = ...;
var ref = playerRef.getReference();
Player player = ref.getStore().getComponent(ref, Player.getComponentType());
Is it possible to play animation effect (like swing) in programmatically written SimpleInstantInteraction? How to apply it? please help
animation neds to be defined in the json of the interaction
Well there ya go, now use it in the var player = store.getComponent(playerRef.getReference(), Player.getComponentType());
Heya, Im running hytale server on my pterodactyl pannel and when i went to switch the auth mode to Encrypted i got the following message, did i miss somthing?
[EncryptedAuthCredentialStore] Cannot save credentials - no encryption key available
Extract the getReference() to a variable looks like a null check here would be good
Whats the full error?
So I have to combine JSON and Java class? Timing (animation duration, delays) also configured only in json or is it possible to do it programmatically?
[2026/01/20 22:49:39 SEVERE] [Simple Achievements|P] Failed to setup plugin Maemoon:Simple Achievements
java.lang.NullPointerException: Cannot invoke "java.util.ArrayList.toArray(Object[])" because "e.obtainedAchievements" is null
at me.maemoon.plugin.AchievementData.lambda$static$1(AchievementData.java:27)
at com.hypixel.hytale.codec.builder.BuilderCodec$BuilderBase.lambda$appendInherited$1(BuilderCodec.java:965)
at com.hypixel.hytale.codec.builder.BuilderField.validateDefaults(BuilderField.java:217)
at com.hypixel.hytale.codec.builder.BuilderCodec.validateDefaults(BuilderCodec.java:669)
at com.hypixel.hytale.component.ComponentRegistry.registerComponent(ComponentRegistry.java:388)
at com.hypixel.hytale.component.ComponentRegistry.registerComponent(ComponentRegistry.java:368)
at com.hypixel.hytale.component.ComponentRegistryProxy.registerComponent(ComponentRegistryProxy.java:38)
at me.maemoon.plugin.SimpleAchievements.setup(SimpleAchievements.java:42)
Whats the default value of obtainedAchievements?
You can parse the json file using Gson
Ohhh I guess I didn't set a default value... I guess it needs to be an empty ArrayList
Array
Are you trying to save an arraylist through that codec? Is that working?
Oh I see you're doing some conversion, you really shouldn't be doing that
java.lang.NullPointerException: Cannot invoke "com.hypixel.hytale.component.Ref.getStore()" because the return value of "com.hypixel.hytale.server.core.universe.PlayerRef.getReference()" is null
Store<EntityStore> store = playerRef.getReference().getStore();
got this now
getEventRegistry().register(PlayerConnectEvent.class, event -> {
var playerRef = event.getPlayerRef();
var playerUUID = playerRef.getUuid();
Store<EntityStore> store = playerRef.getReference().getStore();
var player = store.getComponent(playerRef.getReference(), Player.getComponentType());
teleportPlayer(player, 15.5, 188, 0.5);
});```
I'm instead need to configure JSON programmatically, add certain effect or increase animation duration to apply on an item
There are post deserialize events you can attach to the codec and do your conversion like that, just store the string array as a regular string array
Can we give NPCEntities data that persists across restarts?
And then you have another user-friendly array
Oh, I get it now, I don't know if it's possible to change an item dynamically
it's called components
Yeah through components
why does punching a chest count as interaction
So, I exported my mod and now it won't show up in my worlds asset editor. The one I made it in, literally why? all that progress lost? Does anyone know a fix to this?
I know this is the wrong channel but people in #discussion are genuinely so off topic I need smart people
Everything with any item is an interaction sent by the client
Punching with fists is a Primary interaction
ahh okay. so i have to filter for that if i only want something to trigger on the "press f" interaction
That's so sad, I want to make dynamic items with RNG like attack speed [2-5%] 🥴
Thats Use
is there an InteractionType enum?
Hey. I am looking for a plugin / mod that allowes me to alter the Teleport Visualization on the map / compass.
The teleporters crafted by players should only be visible to the player that made it. So if Player X makes a portal, it won't show up at all for Player Y without being added to a "whitelist". If they are added to the "whitelist", the Teleporter will show up on the map and compass for both players.
Does anyone know of a mod / plugin that can do that?
Yes thats exactly whats its called
nice thanks
If I wanna make my bench placeable which property do I have to check in the asset editor?
I went to restart my server on a hosting service, and it started to crash like this. Could someone help me?
pastebin com/XmLXFtJn
oh seems the issue is store because it hasn't been attached yet on join
so ig I need to change this somehow
what would punching with an item be?
Primary interaction
so punching is always primary
Hmm, maybe the playerRef.getReference() is too early in that event, I'm not sure
But if you right click with items it does fire Secondary interaction unlike with fists
I am thinking maybe something simpler
what if I just modify the player's json file to change position?
PlayerConnect is wayyy to early for you to be doing that
so punching with fist counts towards primary but right-clicking with fist doesnt count towards secondary
Use PlayerReady
Yes thats exactly right
hey, we apologize for this. we fixed the problem today and it should not occur again
will try, thanks 😄
I don't think that's safe, use PlayerReady event like notnotnotswipez said
is there a way to check if a player is sneaking?
Yep, movement component, one sec
I don't see player ready btw
unless I am missing something
MovementStatesComponent
Then .getMovementStates
thanks ^^
PlayerReadyEvent
ig rentry is missing this event
Rentry?
MovementStatesComponent movement = playerEntityRef.getStore().getComponent(playerEntityRef(Ref<EntityStore>), MovementStatesComponent.getComponentType());
if(movement != null)
{
if(movement.getMovementStates().crouching)
{
//whatever
}
}
Anyone also got the Problem when editing Chests that the Chest is then:
Cannot perform OpenContainerInteraction interaction on unsupported BlockState type null
Also why is the Block now called: Furniture_Crude_Chest_Small_State_Definitions_CloseWindow
Yes significantly
some hytale api reference site
I'm trying to detect when a player interacts with a specific item in hand, but placeblockevent doesn't return the player, playerinteractevent is deprecated + registering doesn't return the event's class for some reason and PlayerMouseButtonEvent returns Item instead of ItemStack (I need the itemstack for the item's metadata) do you have any solution?
Are you not programming in an IDE?
Just start typing PlayerReadyEvent it should suggest the class and you can import it
I am and I am COMPLETELY new to this 😂
sorry
I got the class but it doesn't return getPlayerRef so now I need to figure out what it does
Would anyone be able to share an example repo demo'ing how to add a new block via server mod. I'm following <hytalemodding>.<dev>/en/docs/guides/plugin/creating-block but I'm clearly missing something critical
You need the literal PlayerRef ?
I need Player player
Theres .getPlayer on that event
pvp is so good
You might just have to listen for the packet haha
Lowkey is more straightforward than any event and is significantly more versatile
Very easy to do too
Does anyone know if this function affects fluids as well? Or are they stored seperately from blocks
public static boolean performBlockDamage(@Nonnull Vector3i targetBlock, @Nullable ItemStack itemStack, @Nullable ItemTool tool, float damageScale, int setBlockSettings, @Nonnull Ref<ChunkStore> chunkReference, @Nonnull CommandBuffer<EntityStore> commandBuffer, @Nonnull ComponentAccessor<ChunkStore> chunkStore) {
return performBlockDamage((LivingEntity)null, (Ref)null, targetBlock, itemStack, tool, (String)null, false, damageScale, setBlockSettings, chunkReference, commandBuffer, chunkStore);
}```
I don't think you can damage a fluid lol
F I hate that
I'd imagine not, I think since all blocks can be water-logged its not similar to minecraft's programming where fluids are actual blocks. Thanks though :)
Ok I fixed that but now it's saying that holder is null? (This is in CompletableFuture of an AbstractAsyncCommand, if I send more than this discord seems to block my message for some reason):
PlayerRef targetPlayerRef = playerArg.get(context);
String achievement = achievementArg.get(context);
Holder<EntityStore> holder = targetPlayerRef.getHolder();
assert holder != null;
AchievementData data = holder.ensureAndGetComponent(AchievementData.getComponentType());
You can run it back in sync with world.execute()
What, I said that it probably doesn't affect fluids and you confirmed lol or am I reading this wrong
Which function do I use to create an interaction with an NPC? The one that says "press F"?
You can just get the Ref<EntityStore> from the PlayerRef and from that you can get the Store<EntityStore>, no need to get the holder, but I think that should be working
Idk this games strange sometimes
does anyonehave an event ready made for detecting an entity death?
@Override
public void accept(PacketHandler packetHandler, Packet packet) {
if (packetHandler instanceof GamePacketHandler handler){
if (packet instanceof SyncInteractionChains chains){
SyncInteractionChain chain = chains.updates[0];
InteractionChainData chainData = chain.data;
if (chain.interactionType == InteractionType.Secondary){
// Check me!
var playerRef = handler.getPlayerRef();
// Have we got a block pos? Refresh the players chunk to prevent desync
BlockPosition blockPosition = chainData.blockPosition;
if (blockPosition != null){
playerRef.getChunkTracker().removeForReload(ChunkUtil.indexChunkFromBlock(blockPosition.x, blockPosition.z));
}
// Then cancel me!
chains.updates = new SyncInteractionChain[0];
}
}
}
}
I've formatted this to make it easier to understand, obviously you probably don't want to cancel every single secondary interaction, this is just to show you what you might want to do
Here is the setup I got in the end for on player ready event to teleport to a set location
if anyone ends up needing it in discord search
public void setup() {
this.getEventRegistry().registerGlobal(PlayerReadyEvent.class, readyEvent::onPlayerReady);
}
public static class readyEvent {
public static void onPlayerReady(@Nonnull PlayerReadyEvent event) {
try {
var player = event.getPlayer();
teleportPlayer(player, 15.5, 188, 0.5);
}
catch (Throwable t) {}
}
}
public static void teleportPlayer(Player player, double x, double y, double z) {
World world = player.getWorld();
if (world == null) {return;}
world.execute(() -> {
if (player.getReference() == null) {return;}
Store<EntityStore> store = player.getReference().getStore();
Teleport teleport = Teleport.createForPlayer(world,
new Vector3d(x, y, z),
new Vector3f(0, 0, 0)
);
store.addComponent(player.getReference(), Teleport.getComponentType(), teleport);
});
}```
oh tysm
You make a class that implements PacketWatcher and register it in main like:
PacketAdapters.registerInbound(new ThePacketWatcher());
How can I make it so that clicking on a specific NPC executes a command or function?
Which function do I use to create an interaction with an NPC? The one that says "press F"?
Is anyone encountering this error: 'getPlayerRef()' is deprecated and marked for removal?
Make a system that extends NpcSystem.OnDeathSystem or whatever its called
also a deathComponent although idk if its used
so playerdeath and entity death are seperate?
Thats what the system watches its just a watcher on the DeathComponent
ahhh i see mb
is that possible to make some plugin whitout the Hytale API ? i wanted to do a Soil_Grass propagation but it look like not possible without the API ?
They're the same thing, I just said that class to make it easier for you, but they're just a
RefChangeSystem<EntityStore, DeathComponent>
With a NpcEntity query
@tranquil tendon the /auth thing worked!!! Thank you
No problem!!! happy to help :D
so quick question im trying to use aternos for server hosting to my mates with mods but it just doesnt load me into the world
like it says its just timing out
// Save the location on the first run
if (firstRun) {
final TransformComponent transformComponent = targetRef.getStore().getComponent(targetRef, TransformComponent.getComponentType());
Preconditions.checkNotNull(transformComponent, "TransformComponent");
Teleport teleport = Teleport.createForPlayer(transformComponent.getTransform());
context.getInstanceStore().putMetaObject(REWIND_LOCATION, teleport);
context.getState().state = InteractionState.NotFinished;
return;
}
Does anyone have an idea why my player's TransformComponent is rarely right? I am running this inside a SimpleInteraction, and the player rotation is always (0, Y, 0), the yaw component is always set (albeit a previous rotation, not the current one), and the pitch and roll are always 0.
alguem pode me ajudar?
nao estou conseguindo jogar. Assim que saio do spown, o jogo para de responder, todos os blocos que quebro, nao é contabilizado. Na aba Network os parametros de Sent e Received estao em 1 B/s.
oque posso fazer?
Player getUUID deprecated?
Its on the UUIDComponent
Thanks 🙂
hmm, now I'm getting Assert not in thread!:
PlayerRef targetPlayerRef = playerArg.get(context);
String achievement = achievementArg.get(context);
Ref<EntityStore> ref = targetPlayerRef.getReference();
Store<EntityStore> store = ref.getStore();
AchievementData data = store.ensureAndGetComponent(ref, AchievementData.getComponentType());
Thank you for all your help btw
Anyone know if theres some way to check who threw a projectile?
Wherever this is needs to hop to the world thread with world.execute
// Save the location on the first run
if (firstRun) {
final TransformComponent transformComponent = targetRef.getStore().getComponent(targetRef, TransformComponent.getComponentType());
Preconditions.checkNotNull(transformComponent, "TransformComponent");
Teleport teleport = Teleport.createForPlayer(transformComponent.getTransform());
context.getInstanceStore().putMetaObject(REWIND_LOCATION, teleport);
context.getState().state = InteractionState.NotFinished;
return;
}
Does anyone have an idea why my player's TransformComponent is rarely right? I am running this inside a SimpleInteraction, and the player rotation is always (0, Y, 0), the yaw component is always set (albeit a previous rotation, not the current one), and the pitch and roll are always 0.
Is it possible to visualize all components? Like a tree?
The head rotation is somewhere else
Hello everyone, I'm currently working on a mod that allows a mount to fly. However I'm having some issues with it. After some tweaking I managed to make a hawk be able to be mounted but as soon as my player gets on top, he refuses to fly ^^'. Any ideas ?
MovementStates other = mountMovement.getMovementStates();
other.flying = true;
mountMovement.setMovementStates(new MovementStates(other));
this is something I tried but it doesn't seem to work either
Which function do I use to create an interaction with an NPC? The one that says "press F"?
Can you make an NPC mine for you? Are you able to control an NPCS actions
Theres a HeadRotation component that might be more accurate
Its in the defintion of the entityrole, you can check the shopkeeps
@uneven tide This was addressed to you I forgot to reply
Ok, i'ii try, thanks
Im having an issue seemingly out of the blue where my dedicted server is crashing due to a tilled soil block,,? anybody else have this issue before?
I'm wondering the same thing, for having an NPC sort my chests
Anyone figure out all the different ui elements we can use yet?
I mean I don't see why not but I doubt theres an actual already built-in internal way to get NPCs to mine and stuff like that
You should be able to control where an NPC wants to go and what animations it plays, from that point its just like your own custom guy to do whatever you want with
Could just call sort on nearby ItemContainers or whatever when he walks near one and play an animation
How do I actually get the world in an AbstractCommand? I've tried this:
PlayerRef targetPlayerRef = playerArg.get(context);
String achievement = achievementArg.get(context);
Ref<EntityStore> ref = targetPlayerRef.getReference();
Store<EntityStore> store = ref.getStore();
Player player = store.getComponent(ref, Player.getComponentType());
World world = player.getWorld();
but I get Assert not in thread! when I try to get the player
I send you a pm
You cant getComponents like that when you're in an improper thread for it, you can get the world UUID from the PlayerRef and then use Universe.get to get the world
Could anyone walk me through creating a UI that opens when you interact with an NPC?
I think I finally got it working! Thank you :)
A quick question on chat gpt told me it should be do able in the in game world editor and also using the Java API
Idk how true this is I’ll check it out in a bit lol
Shouldn't just this work?
Player player = (Player) context.sender();
World world = player.getWorld();
I don't know if sender would return the entity, probably the PlayerRef
And the target player is an arg not the sender
i'll lkook into it thanks
o right I did miss that part
guys plssss i need help to place 2 spawn can someone help pls i search on all the net but nothing
is it possible to show the player inventory and a CustomPage at the same time?
Is there a decent mod repo for hytale yet? Something searchable? Any live map mods in progress?
With server version updates (without using the downloader), do I pretty much just need to replace the Assets.zip, HytaleServer.jar, HytaleServer.aot, and the Licenses directory?
Hello guys!
Does
playerComponent.getPageManager().setPageWithWindows(ref, store, Page.Bench, true, yourWindow);
Work for your purpose?
i'll try it
hey i have a question would it be possible to create a world system for minigames essentially making the worlds as small as possible to shrink memory use
Was excited to visit https://monterodev[.]com/ but unfortunately they block block proxies 🥹
Has anybody else encountered the RED ❌ error when messing with ui? Im trying to put it into my ui, but images from items get changed into red ❌ . Anyone know why?
Sorry jajaaj, and thanks 😊
Anyone else having this problem while trying to use the AOT cache?
[0.081s][warning][aot] This file is not the one used while building the shared archive file: 'HytaleServer.jar', timestamp has changed
[0.082s][error ][aot] An error has occurred while processing the AOT cache. Run with -Xlog:aot for details.
[0.082s][error ][aot] shared class paths mismatch (hint: enable -Xlog:class+path=info to diagnose the failure)
[0.087s][error ][aot] Unable to map shared spaces
Anybody know any alternatives to EyeSpy that allow users to disable the HUD?
Already tried a new download/replace but still same message
Attack On Titan is a pretty good anime
guys my server is failing to boot, can someone help me solve that?
It's probably out-of-date. I would say it's not actually worth using
afaik just make sure your plugin also is treated as an asset pack in your manifest.json
Thx
Already did, seems a problem with the uploaded one on hytale's servers
how do i send the log?
In that case, unless they check for licences, I think the only files required for a server update are:
Assets.zip
HytaleServer.jar
HytaleServer.aot (I assume)
The rest of the files are configs/mods/universe really, I bring this up because I'm working on my own automation system
Oh? I have a bool set to IncludesAssetPack = true.
is that what you mean? Cus im still having this issue if thats the case
aot is optional and doesn't need to be used or included
Ah yeah, I haven't gotten around to messing with UIs myself but that's the part I had read about needing to be done, and getting the red Xs if that boolean was false
im renting a server in a brazilian host and i've put around 30 mods that our group thought cool and im trying to open it but it shuts down after i click to open the server
Any idea what the aot actually is?
ok!
AOT = Ahead-of-Time (cache). It's a cache of the classes that will be loaded when the server is running. It's used to speed up boot times and doesn't really optimize or improve anything else. Given startup times are fast anyway, I'd say it's pretty pointless
How to add translation files?
aot is a cache
beat me to it
I'm trying to find the component that determines the time required to consume a given item. I want to make custom food that is really quick to eat. Anyone figure this out?
Thanks, java is not my language lol, coming from C++ mainly
That's odd. Yeah. That bool is set to true but there are still red ❌ everywhere.
I have items that don't have red ❌ but Im trying to put them in my custom UI and they come up like that.
Im taking the file path from an item and putting it inside the UI. Maybe it's not loading properly right but like.
Maybe it's a reference error, like it has to be a soft reference or somethign wack
I'm having trouble listening to the ItemDropEvent. I've registered the event in the setup function of my plugin. I've set a breakpoint for setCanceled to true, but it never triggers. I've tried changing the priority, but without success.
Has anyone ever managed to listen to this event?
getEventRegistry().register(EventPriority.FIRST, DropItemEvent.class, event -> {
event.setCancelled(true);
});
No worries 🙂 It's also a pretty recent thing anyway. This isn't really its use case - it's more for big enterprise Java apps that take 30s to a few minutes to start up (there it actually makes a notable difference).
try registerGlobal() maybe
Thats an ECS event, not registered or listened for the same as the other ones
i did it and now shows that a lot of things are missing dependencies, can i get those dependencies from other place?
@pine holly forgot to mention you
registerGlobal is for the keyed event like PlayerReadyEvent. DropItem is not a keyed event.
i can't figure it out how can i get the window instance, but im trying to do something like the spawn entity page (when the "items" tab is open)
show the creative inventory to select an item and my custom ui page at the side
Make a class that extends
extends EntityEventSystem<EntityStore, DropItemEvent.PlayerRequest>
if player.getUuid is being removed what do i use instead i'm trying to make a game lifecycle management system also for profiles
Oh im not sure if thats accessible
UUIDComponent
😔
👼
Looking for a Developer for Hytale Server
We’re seeking a dedicated developer to help manage and develop an up-and-coming Hytale server. The ideal candidate should be experienced in:
• Java Programming (for server-side development)
• Ubuntu Linux (server management)
• WinSCP (file transfer)
• Git (version control)
• Database Management (MySQL, MongoDB, etc.)
• Server Optimization & Performance
•Basic Security & Backup Knowledge
If you’re passionate about Hytale and have experience managing game servers, send me a message! Further details and responsibilities will be provided upon contact.
Ok, thanks i will try it.
Any of you figured out a way to make the height shrink to size of content?
and have you used ItemGrid before? I've seen it has a SlotClicking event, but I don't know how to get the slot clicked
I haven't messed with making custom UIs
custom uis are kinda weird rn
me sale error algun consejo
can you show me an example because the docs im looking at have no examples and ive been flying blind and been stuck on this for hours
Have you got a Store<EntityStore> in the context you're working with
chains.updates = new SyncInteractionChain[0]; it seems that blocks still get placed, since I was running it in world.execute I tried packetHandler.getChannel().eventLoop().execute(() -> {
chains.updates = new SyncInteractionChain[0];
});
but it still is placing. is there any different packet I might need to listen for to prevent blocks from placing?
Running in world execute? Why?
What I sent cancels every secondary action (Including placing) just fine for me
I’m looking for a SkyWars or BedWars plugin. Does anyone have an existing one they can share?
I need player object to get item in hand
Oh I see, it would be too late then if you're running world.execute unless you cancel it outside of the world.execute
i removed a mod that let me get my arrows back but it wasnt working
I'd need to know if the item is the one I have to cancel tho... so don't think that's possible?
There might be a different way to get the inventory
You might have to keep a cache on or something
Is --backup-frequency in seconds, minutes...?
no i'm just trying to make a arena setup system for creating new arenas im just trying to toggle arena setup for the player and for the arena data file to save the creator's uuid and name thats it
You are not running with an event or any form of context at all? Not even a command?
What have you got available to you
yes its toggled with a command
Okay, what class is being extended, AbstractPlayerCommand?
hay algun servidor activo 24/7 donde hispano para jugar
So you do have a Store<EntityStore> and a Ref<EntityStore>
UUIDComponent uuidComp = store.getComponent(ref, UUIDComponent.getComponentType());
yeah i just figured it out right before you sent this
im incredibly tired ive been working on this for like 12 hrs 😭

In a UI, is it possible to use native game images? For example, an image of an item? Without having to import and load it in the plugin?
yep
If you don't mind, could you assist me on how i do that? Im struggling with that
i apologize for the hassle idk why i didnt think to use the component i was thinking about minecraft and its crazy because i use ECS for my minecraft server 💀
How to load language translation files?
Everythings components here
Anybody adverse in fixing issues causing a server to crash? everything was fine then suddenly the server gets errors restart the server then it happens again shortly after
NPCPlugin.get().validateSpawnableRole(def.type);
Object result = NPCPlugin.get().spawnNPC(
store,
def.type,
def.groupType,
position,
rotation
);
if (result == null) {
LOGGER.atWarning().log("Failed to create '%s'", def.id);
continue;
}```
How can I make this NPC interact like some objects in the game that require pressing F?
hy guys, anyyone knows how create hytale mods? i can find the documentation for APIs, but without success :/
look at the server.jar and already existing mods
mods or plugins, whatever
I've tried searching everywhere and I can't find anything concrete that works.
damn
theres a site with basic documentation but its not official idk if i can send the link here tbh
so, how you starting creating plugins? you are debuggind and coding?
UICommandBuilder commandBuilder=..; commandBuilder.set( " #ItemIcon.ItemId", ItemId);
ItemIcon #ItemIcon { Anchor: (Width: 64, Height: 64, Bottom: 5); Visible: true; }
yes, bro, i want, thank you
there are tons of sites
thanks!!
yeah
ik i said this earlier but i really want to know if it would be possible to create a world system for minigames essentially making the worlds as small as possible to shrink memory use because i created a whole server instance system for large minigame servers kinda like hypixel but memory use would be astronomic with the default worlds
who's got some info on how to despawn recently spawned entities for a plugin?
where da patchnotes at just had an update
Dude, I think you’ll have to try to understand how the world-creation engine works and whether it exposes any API that you can use to manipulate it in some way. But honestly, I don’t really know — without documentation, it’s complicated
anyone got a mod that produces crash reports?
@stark tulip do you know how i can implement that using hyui?
Hi there is there api to make tab complit for my commands?
Is there a straight forward way of accessing HytaleWhitelistProvider or overriding AccessControlModule in general without reflecting my way in
ItemIcon/etc aren't directly supported natively by HyUI but you can just Page/HudBuilder.detatchedPage/Hud().fromFile("YourUIFile.ui").editElement(cb -> { .. edit stuff}).show/open
git/Buuz135/Advanced-Item-Info/blob/main/src/main/resources/Common/UI/Custom/Pages/Buuz135_AdvancedItemInfo_SearchItemIcon.ui
git/Buuz135/Advanced-Item-Info/blob/main/src/main/java/com/buuz135/advancediteminfo/AdvancedItemInfoGui.java
you can use my template if you need
Doesn't seem like it
github.com/system32developer/Hytale-templates/
That's unfortunate :(
You want to unregister AccessControlModule? You might be able to just turn it off
I mean that'd be great too
Actually I don't think the registries would unregister what they've already registered
Just reflect it'd be safer
Where are plugins registered - so I don't have to dig
The PluginManager in HytaleServer
my world wont load because there's a duplicate plugin but i cant find it, can somebody help me please?
Actually theres a static PluginManager instance available with .get
private ComponentType<EntityStore, FireComponent> fireComponent;
public FireSystem (ComponentType<EntityStore, FireComponent> fireComponent){
this.fireComponent = fireComponent;
}
@Override
public void tick(float v, int i, @NonNullDecl ArchetypeChunk archetypeChunk, @NonNullDecl Store store, @NonNullDecl CommandBuffer commandBuffer) {
FireComponent fireComponent1 = archetypeChunk.getComponent(i, fireComponent);
}
@NullableDecl
@Override
public Query getQuery() {
return Query.and(fireComponent);
}
}```
it says that i am not passing the correct arg:
Required type: FireComponent
Provided: Component
Alright, this'll be interesting, ty
ty! ❤️
bruh i love you
whats the difference between packs, plugins, and mods? ive seen kaupenjoe's vid on the diff between packs and plugins, but not sure where mods fall into that
plugins/mods are basically interchangeable ngl
I am ot sure if i can just cast
just made it a custom item and non placeable
ah i see. was confused by the naming because everywhere i look i see people calling em plugins but ingame i just see mods. ty!
you shouldn't need to pass it by constructor why not make a static component type on FireComponent?
@Nonnull
public static ComponentType<EntityStore, PlayerCrawlComponent> getCrawl() {
return crawlComponent;
}
I got my model to show up, and i can spawn it in game but i cant get the NPC part to work.
I've coped the NPC role of a kweebec, into my own Assets, using the asset editor. but in the npc part of the entity spawn menu it doesn't show up
True since its only the component Type not an actual object
How do I get the player from BreakBlockEvent?
Yeee exactly!
Makes sense, however should I cast it since I am having an error
FireComponent fireComponent1 = archetypeChunk.getComponent(i, fireComponent);
How can i make an command with arguments?
It depends on how you set it up I guess, but you can try it out and see what happens
Does anyone know how the ui component CharacterPreviewComponent works?
Like I can use this to get item id:
event.getItemInHand().getItemId()
But can I get the player who is holding that item id maybe?
Since the updates i know servers needed a refresh. is there a way to do chunk refreshes for the chunks that have been discovered?
what does archetypeChunk return? like what is archetypechunk a representation of?
does anyboady know how to make custom logic for blocks? i want to have a block that can connect to others and detect how many of them there is to make something simmilar to magic storage from terrazra
bumping this because im just now encountering this issue, where would issues like this be reported because im starting to encounter a lot of them
|Is --backup-frequency in seconds, minutes...?
if possible, I haven't tried it yet on fluids it is through the UpdateBlockDamage packet. I will try it tomorrow as I will go t bed soon
you know what I will try it right now I have some spare time
store.putComponent(
npcRef,
DisplayNameComponent.getComponentType(),
new DisplayNameComponent(Message.raw(def.nameplate))
);
Nameplate nameplate = store.ensureAndGetComponent(npcRef, Nameplate.getComponentType());
nameplate.setText(def.nameplate);```
Is there any way to customize the NPC's nameplate?
how can I add a custom translation property for my custom item? I created Server/Languages/en-US/items.lang
but it isnt working and there is also nothing showing up in the asset editor
minutes
--backup-frenquency 30 = every 30 minutes
has anyone figured out UI and want to share some code or walk me through it?
nvm got it working
When Slimefun in hytale
Did anyone figure out particle effect spawning yet
Also are status effects a thing yet?
ParticleUtil
What docs are there for hytale modding because there are a lot that just give a couple examples but I haven't seen any proper docs if they exist yet.
Status effects? They get applied when you eat things
like, I wanted to have players heal while at spawn with a visible indicator
How to fix the RAM leak? I have a 8GB server and it hits max ram with only two people on lol
So I figured the status effect would be best solution
sadly for fluids it's not possible, the reason is that they are seen as Empty aka air and the client then ignores those packets just tried. It's not like minecraft where it would still display them
EffectControllerComponent and you can add effects from that
you are the best man
need to put you in my hall of fame in the world if I ever end up finishing this server
Haha
I feel like I have half of my api interface options from you
how do I make off-handable items with the asset editor?
Ahhh, makes sense I figured since you can log fluids into most blocks and they have their seperate commands in a lot of the util classes. Thanks for trying tho! :)
did anyone made plugin/mod for void type of world?
how do i check if a player is op?
yes
also fun```
[SessionServiceClient] Failed to request authorization grant: HTTP 403 - invalid token
Opinions wanted:
almost done with my pluginLibrary i think, so far what it does:
for asset makers that dont know java or node system or how to make jar files or anything like that it will inject their ores using simple xml sheet with simple rules and/or templates (like only injecting this ore near mithril) it probes all installed mods during world generation for any mod that has the exact directory and xml file in said directory to compile a list of ores it needs to inject, you can teleport to the ore types by using the oreID (it will probe ungenerated chunks up to 32 blocks away safely or 512 blocks of pregenerated biomes/zones) and you can teleport to any biomes (if within 512 blocks) to test teleporting to the ore in biome locked ore types. it will have a GUI that loads all biome types that the world has in its AssetModule meaning support for custom biome injections as well (not tested), there is a ui for the guide and a ui for the biome list with filters and a ui for oretypes i plan to add teleport buttons in the UI to tp to the nearest ore of that type and biome of that type instead of having to use the /cog tp --biome= commands anyone have anything else they would like to see in this "Library" that is relative to ore generation and testing?
the hot reload (/plugin reload) doesn't work on plugins with assets?
i need to restart the server everytime?
bump
Hello. I need an opinion. A server with 16GB and 4 Linux cores can support how many players?I have my console showing a lot of errors in chunck red, and there is only ME in the world
if your plugin has assets, you will always get the "failed to reload plugin" message in chat but it still successfully reloads
still no way to make a custom ui or change the chest ui to add a scroll function and have more slots?
You need a UUID for the proper check which is:
PermissionsModule permissionsModule = PermissionsModule.get();
Set<String> groups = permissionsModule.getGroupsForUser(uuid);
if (groups.contains("OP")){
}
life saver once again
also you may replace "OP" with HytalePermissionsProvider.OP_GROUP in case they change it 
Ah thats where the constant is
you just improved code from our god :O
there is any way to copy the errors on diagnostic mode?
or just if (PermissionsModule.get().hasPermission(context.sender().getUuid(), "*")){ // } but idk
Can someone help?
Is there a way to make a custom ui or change the chest ui to add a scroll function and have more slots?
public void onPlayerMouseButton(@Nonnull PlayerMouseButtonEvent event) {
MouseButtonEvent mouseButton = event.getMouseButton();
if (mouseButton == null || mouseButton.mouseButtonType != MouseButtonType.Right) {
return;
}
if (mouseButton.state != MouseButtonState.Pressed) {
return;
}
Item itemInHand = event.getItemInHand();
if (itemInHand == null || !LOBBY_ITEM_ID.equals(itemInHand.getId())) {
return;
}
Player player = event.getPlayer();
if (player == null) {
return;
}
player.sendMessage(Message.raw("§aVocê usou o Seletor de servidores!"));
}```
You have a alternative solution for this?
If its a custom item just add your own secondary interaction
The mouse events don't fire
The watering can is a good simple example of how to do that
and always use english for messages and logs
Is it an item from the game itself? By "custom item," do you mean an item created by assets?
do you have the code how to do that?
Yeah if you have a item made specifically for the purpose of your server you can just add a secondary interaction
The watering can is built-in to the game, you can look at the item definition in the AssetEditor
I'll look into how I can do this quickly, do you have any recommendations?
Not really other than just look at the watering can item
Where can I look at this watering?
Yes, I have it open. I thought you were talking about a specific item.
Yeah I was, the watering can
hey @civic zephyr sorry for the mention you helped me before and your clearly super knowledgeable i really want to know if it would be possible to create a world system for minigames essentially making the worlds as small as possible to shrink memory use because i created a whole server instance system for large minigame servers kinda like hypixel but memory use would be astronomic with the amount of servers i know i can create empty worlds but i really want to like reduce the amount of total chunks to a minimum idk if i can change the world size or anything like that
How do i fix a prefab that I am pasting in seems like it is pasting via -a, aka no air blocks, I need the air blocks.
Im not entirely sure what you mean by "make the worlds as small as possible"
In memory? I mean void worlds wouldn't take up that much
like literally just enough chunks to load the arena and thats it
how do you Disable block breaking in adventure mode but allow interacting with things like chests and doors
If the chunks haven't got any blocks in them then it should be negligible
You should be able to cancel the BreakBlockEvent
Although im not sure how efficient the worlds are, I think it would be possible to have a few concurrent minigames running with how the games setup now as different worlds
Would need a few threads on your CPU to get that handling well
What method are people loading UI up together with the gameui? Trying to make it so it loads up at the start but also not too early to the point it doesn't kick me.
I made pvp fun again with my mod hide health bars available on modtale
really? see my mind is on mc i wasn't sure how it worked, also do you think it would be possible for me to make a world loader i want to compress the worlds as much as possible data wise with a compression algorithm with a high ratio and quick decompress because i want to be able to have players be able to change the game their playing on the fly without being redirected to another server tbh im not sure how quick world loading is on the game yet im just starting to play around with it and if its slow i want to have a plan ahead for possibly making it faster
Wym by world loader?
idk if you know this you know slime world manager?
No I don't
You might be able to save additional memory by deleting chunkrefs of chunks you don't need but I have no idea how stable that is
well its a plugin for mc that uses a more modern compression to compress world data for quick loading/unloading mainly for minigames actually it was created by one of the hypixel team members from what i heard and im trying to just think of methods to speed off world loading/unloading
the compression vanilla mc worlds use rn is older than me and prob you as well XD
Hytales architecture encourages multiworld so im sure whatever they've done is pretty efficient regarding space management, memory usage in Hytale servers is pretty high right now anyway even in a singular world instance with low playercounts
how do i fetch a uuid to teleport in java
opa
im trying to use the container templates, etc... with the common ui, but not going anywhere.
isnt supposed to be like that?
$Common = "../../Common.ui";
$Container = "../../Common/Container.ui";
... a lot of ui code ...
Group #BasicKitCard {
Background: (TexturePath: "../../Common/OptionBackgroundPatch.png", Border: 8);
FlexWeight: 1;
Anchor: (Right: 8);
LayoutMode: Top;
Padding: (Full: 12);
... more ui code
$Common.@PrimaryTextButton #VipKitBtn {
@Text = "RESGATAR";
@Anchor = Anchor(Height: 40);
}
me and a few friends used 15gb i was like "wtf" seeing that ngl makes me worried on how many instances a bigger server can handle i wonder if i can make the worlds load with the chunks with blocks only and stop any further chunks to load i have a whole lot of memory rn but if i cant figure out something im going to need an insane amount for a minigames server
Theres a leak or something, im sure they'll fix it eventually
i hope so
Is there a list of which values can be used for custom assets/blocks? or like how to properly fill out the information for it
anyone know how to hot reload plugins?
anvils not a bad format actually, its just not optimal for all setups -- slime is specifically designed for minigames, and can make assumptions that mc/anvil cant
should be able to use /unload and /load group:name or something along those lines
/plugin reload
ik thats what i said also im thinking of 1.8.8 ngl back then it was GZIP compression
it still is gzip compression -- but thats not the biggest optimization, gzip is a good format, and is fast to decompress, and all of the savings slime makes are because of how the data is laid out iirc(allowing for compression algos to perform better)
anyone know if you can check for multiple events in a single system, or is it one event to one system?
hey, i am new to hytale and want to create a server to play with 2-3 friends, is there a way to do this without having to pay for a server?
theres a option LZ4 if i'm not mistaken
though mc does have support for uncompressed chunks, lz4(recently), and zlib
Does anyone know how to get the Tags on an object?
Example some blocks have
"Tags": {
"Type": [
"Soil"
]
I have a handler for when a block is placed, if the block is of a certain type I want to perform an action on it
How do i change the default spawn for new players on my server?
I have tried /setspawn - it says it sets it but they still do not spawn there
Do I need a plugin to do this?
"Failed to apply CustomUI HUD commands" Does anyone know how to solve it?
though basically all mc worlds use gzip, because the other ones it supports are locked behind a rarely used config option
whats the base filepath for all base game blocky models? i think im either dumb or blind and cant find it 😄
Any chance anyone knows the difference between an EntityEvent and an EcsEvent? Seems like there are only two of the former, and that they are handled at the Plugin level vs the System level, but unsure of why they exist / if there is a benefit here.
Entities events are entities events , entity components events are entity component events, ECS is entity component system
jk am dumb, forgot theyre all zipped up so thats why i couldnt find when trying to open them in blockbench xd
I managed to create the item, but I'm still unsure how to create a custom interaction. Is it possible for me to set up a secondary action within my own plugin?
can any on help me, which event Hytale expose when right click to use a racipe page?
Interaction.CODEC.register
With your interaction class
Ok, i'ii try
i was playing kitpvp on a server and 2 people started dueling with lightsabers 💀
In your assetpack you have to define a RootInteraction which contains your Interaction inside
Okay, I'm looking for how to do this.
Just make a new RootInteraction asset
Guys, in Server/HytaleGenerator/Assignments/Plains1/Plains1_Iron.json I edited it and added my ore, but even after using /worldgen reload or /worldgen reload --clear, the ores don’t generate naturally. They only generate if I create a Plains1 instance, so didn't work in worldgen v1? Or does it only work with Java?
And inside that RootInteraction asset put in:
{
"Interactions": [
{
"Type": "YourCustomTypeThatYouRegisteredInCode"
}
]
}
Interaction.CODEC.register("LobbyUseItem", LobbyUseItemInteraction.class, LobbyUseItemInteraction.CODEC);
Unique asset ID = LobbyUseItem ?
Im not sure what you mean by that
The thing you registered here would be put into your RootInteraction asset under the type
what is the best way to find documentation? obviously the hytale server manual is great but it doesn't cover everything. Currently just using the decompiler and going through different packages to try and find what I need
I'll try setting the unique asset ID as LobbyUseItem then, my current code looks like this:
Interaction.CODEC.register("LobbyUseItem", LobbyUseItemInteraction.class, LobbyUseItemInteraction.CODEC);
Interaction.getAssetStore().loadAssets("SQH:LobbyCore", List.of(new LobbyUseItemInteraction(LobbyUseItemInteraction.DEFAULT_ID)));
RootInteraction.getAssetStore().loadAssets("SQH:LobbyCore", List.of(LobbyUseItemInteraction.DEFAULT_ROOT));
Whats all this other stuff for?
i found a site with good docs the navigation sucks tho ill dm you it
You just need the register
I'm having a problem with my NPC spawn command. Its body is facing the direction the player is looking, but its head always points in the same direction. Does anyone know which API I can use for this?.
Okay, I'll remove it.
How can i get a PlayerRef from a BreakBlockEvent's handle method? The provided arguments for the method are ArchetypeChunk<EntityStore>, Store<EntityStore>, CommandBuffer<EntityStore>, and BreakBlockEvent. just looking at the methods on all of these i didn't see anything that would give me the playerRef for the player that broke the block.
can any on help me, which event Hytale expose when right click to use a racipe page?
Hi, on the Hytale plugin API, what is the correct (recommended) way to retrieve a player's stable identifier (UUID/ID) from a Player object? getUuid()/getUid() are marked as deprecated on my end.
archeTypeChunk.getReferenceTo(index)
Index being the first int its providing you
UUIDComponent uuidComp = store.getComponent(ref, UUIDComponent.getComponentType());
@civic zephyr showed me this
That should give you a Ref<EntityStore>
Guys, can someone tell me if in the current version of Hytale it's still not possible to generate mod ores naturally?
it should be possible
I only managed to make it work by generating it in worldgen v2, did you know how can I make it w v1?
it does. is there a way to turn it into a actual PlayerRef type? i want to run a command which requires a PlayerRef rather then just a Ref<EntityStore>.
var playerRef = store.getComponent(ref, PlayerRef.getComponentType());
thanks
Ref in that context being the Ref<EntityStore>
that worked. thank you!
does anyone know if there is a way to save prefabs locally when saving from a server? instead of having to go into the server files to do it.
impossible unless you make a plugin and setup a ftp server on your pc and literally send the files to your pc
is there any docs for hytale oauth api already?
well i assume there can be a client side mod to do that too haha
That wouldnt be out of the question... guess i need to hire a dev lol
What event do I need to use to handle interactions with npcentities? (F)
unless the client side mod can connect to your server i doubt it ngl
how? Minecraft has mods like schematica
how would it not be possible for the client to see whats in the box and store it to local memory
I've looked into this more and you can just get the item in question with:
chain.itemInHandId
No need to hop to the world thread
the same way it does in a solo world
Im not sure if theres an event for that
Been on a server and they had it
maybe NPCInteractionSystems
An event or a custom interaction
I pressed F on an npc and got an ui
idk what they used
Yeah thats a custom interaction
You have to define those in the entity role or maybe you can jank it with a component add but its easier to just make a new role
Look at the shopkeep roles, they do it, I do it on my death corpse NPCs to open their inventory
mhm I see
thanks for now 😄
nah ur right im thinking of possible protections they might have put in place for it and the client has mods? i thought mods only work in the actual server the game loads when you play
Does anyone have any useful documentation regarding NPC spawning?
Use
NpcPlugin.get().spawnEntity
You have to fetch the role (behavior) and model
Yes, I'm using it, but the NPC's head always comes facing the same way, lol, the body facing one way and the head facing the other.
What role and model?
And how are you creating the model?
i know this isn't the correct chat, but here people may know the answerr better, what is the id for the tp command? i want to add permissions for all players to tp <player> <player> in my server, but i only got to add tp world to it, since it appears each variant have it's own id
Nobody has made public client mods yet... but its always possible to make client mods for games right?
Ive played plenty of games with no mod support that has mods, if only a few..
teleport.other
ofc its possible but idk what it would take to do it
thanks!, i'll test
the current built in mod system its its probably not possible to do a schematica type mod that would work on a server
I believe it actually registers the full permission string as
hytale.command.teleport.other
are mods still built in gradle
anyone know how to set the damage of a block independent of a tool being used? i know about ::setDamage, but that only sets that damage instance of the tool, how would i modify the blocks damage amount itself
The block breakage?
yeah, like the abilty to set the amount that the block is broken, independent of mining it
thanks, yes, where can i get this ids? in case i need to add more commands for every one
basically i want to set the block's damage to 0 after the player damages it to a certain amount, so it never breaks
Im just looking at the source
yeah it would likely then be way too expensive to have a dev on hand to maintain it.. i wanted it as an insurance so i could save prefabs from clients i build stuff for to prevent them from claiming i never delivered, but if its that intense i would never be able to justify the cost.. anyway thank you guys for your input..
im almost 100% sure someone will be able to do it but realisticly its probably going to take some serious time and effort to make it happen
more money than its worth
Finally my community server is actually doing better lol... got some CF officials in their and a lot of people working on projects
would be easier just to keep recordings like i already do lol
the code is obfuscated, but minecrafts code was obfuscated until recently and we got a lot of client mods, took a lot of dedicated people though. I'm not sure if obfuscated c# is any easier/harder to work with than obfuscated java, and having an unobfuscated server may reduce motivation to mod the client
honestly if sold it would prob be profitable i can imagine anyone would want to save their builds but i think something like that would probably be considered hacks in a way
most of the code is handled on the server end anyways too, from the server end we can control the UI too so I don't see much use for a client side mod
Client mods are doable but not really required since a lot can be done with just server sided API
var chunkStore = world.getChunkStore();
var chunkRef = chunkStore.getChunkReference(ChunkUtil.indexChunkFromBlock(blockX, blockZ));
var chunkComponentStore = chunkRef.getStore();
BlockHealthChunk blockHealthComponent = chunkComponentStore.getComponent(chunkRef, BlockHealthModule.get().getBlockHealthChunkComponentType());
BlockHealthChunk has a few useful methods like .repair(xyz) or whatever
On a seperate note, idk why these guys dont support custom fonts on the client, its truly moronic
yeah ik its just going to take entirely too much time to do im almost 100% sure someone will make it happen
Im not seeing an easy helper method to set the damage exactly, but you can get the damage map yourself
eh i mean there are a lot of qol mods people like using on vanilla servers, plus graphical mods like shaders and lod, and cheats of course
Anyone have an example of mouse click event working?
The mouse click events don't fire
They're broken, the client never sends the proper packet
ok lol didnt think so. I had no errors and just nothing was happening
One thing I am working on, which now I have to take the long way is that the game doesnt support custom fonts on the client which limits a lot of things
ah ok that is a good use case for a client side mod, totally get that. I wonder why they don't support that... brand consistency?
someone was asking if there was a client side schematica type mod or if it was possible to make one
also great case for client side mod
Smth tells me they just didnt pay attention to it... cause surely they have copied so many systems from mc, they wouldnt just omit such a useful one
Especially for modding... cause custom fonts allow all sorts of things
I really wanna ask how do i boost an entity up, like make it jump?, I looked that the player's code but just couldn't find it
Set its velocity probably
I think I've tried that yesterday and it didnt' work, i took the Velocity Component and set it upward but the player just stood still, i think there's a function that makes entity to jump but I couldn't find it
I forgot its name but you could update the movement component or smth as well
ive seen images on ui alr im sure theres a way to do it
There is, you make a custom UI and render it from there
I just am stupid cause I can do any kind of coding but my brain is not working with ui files whatsoever
Where would I find the Damage Event System in the decompiler?
Theres something about the player that only responds to direct velocity packets
com.hypixel.hytale.server.core.event.events
So I need to send a jump velocity packet to the client?, but how do i do that 🤣
Heres how I do it but this is definitely not the most optimal way:
playerRefComponent.getPacketHandler()
.write(
new ApplyKnockback(
PositionUtil.toPositionPacket(transformComponent.getPosition()),
yourVelocity.x,
yourVelocity.y,
yourVelocity.z,
ChangeVelocityType.Add
)
);
Do you know how to get the players transform component? I assume you do since you seem familiar with the Velocity component
Its just TransformComponent
yeah i learned about it a little bit, thank you very much
Im wondering if i should switch my server over
Over to what?
PlayerMouseButtonEvent triggers only when the mouse is visible on the screen, which I've found to only be the case when you change player camera--it's done in-game with /player camera. Problem is that you must pass an argument to the player camera command, which set the camera to a top-down or a sidescroller view.
my brrain brokey
You dont need a "client side" mod anything... theres a schematic mod by thirtyvirus on cf.. Just download it to ur mods folder and toggle it on in worlds settings.
Is there a way to fetch the block that a laserpointer tool is looking at via a plugin?
anyone know where to go about finding vanilla gathertypes and/or creating your own?
ahhhh gotcha
Im down but I suck at making mods rn xD
Does anyone know if it's possible to leave more mobs to spawn? And is there a way to increase the life and damage of mobs here in Hytale?
nvmmmmmm @quiet ermine is a brand new account made today
yea idk alt or not its just weird
thats so cool bruh. I saw on yt someone recreated the end xd
yo when i click sign in it says with the same identifier
can we get a vc in this server man
thats for your world only we were talking about for servers
Is it possible to make a UI button or something else so that it doesn't require entering a command to open it?
What's the best current resource on how to save/load custom data?
Slowly going insane here
Anyone knows how I get the closest NPCEntity to the player?
Or the NPCEntity the player is looking at, only successfully get the block the player is looking at rn
I think SQLite should be used on the server side, if at all possible.
There's a getTargetEntity in the TargetUtils package, you could try that.
I mean more like, isn't there something built in for custom data? Otherwise yeah I'd use my own database
I just assumed, I'm also interested in this)
There are custom resources that you can register
That looks goood thank you
Does anyone know if it's possible to leave more mobs to spawn? And is there a way to increase the life and damage of mobs here in Hytale?
I have a map open, with more than 15 people, but it doesn't seem to spawn properly, any tips?
Sure
More NPC Spawns on Curseforge
Do note it will drastically increase spawnrate of mobs
Is there a good documentation that tells what each method does yet? Anything I can find isn't even remotely saying what the methods do yet
Like, wth does ArchetypeChunk do or check?
And another thing, it's all very easy, it would be interesting to have a mod that helps increase life, mob attacks...
There is one called hydifficulty, but it is very buggy, and crashes a lot...
Other than that, do you know if there is another mod?
There is no official documentation at all, only attempts made by modders
My lord this is tough to figure out. I already wasn't very good at Java but with no docs I'm so blind I can't even start where a tutorial hasn't been at yet
I feel you i read the code for a few days before starting on my plugin
I reading it rn and I'm so lost
Use OpenAI or Anthropic CLI tools to create an extensive server development documentation and you can ask tailored questions
Real?
OpenAI has a free trial atm
How would I start with that? Thats a bit out of my knowledge
Well, Archetype is like, basically, a container that has multiple "entities" with the same component and system, so it's more efficient
have the devs said anything about whether/when they are going to produce docs?
Search "Codex" and install is easy. And just have it point to the HytaleServer.java and it will decompile and research
vineflower
abstractions and ECS in general is a very diferent paradigm and harder imo to understand
Wow, thats pretty good use for AI ngl. Thanks!
There are also youtube videos that explain some concepts.
There are tons for Assets but barely any for Plugins that touch on some of the most juicy things. Like UI, and Events. Or it's just not enough atm.
I use it to decompile how to do certain systems for combat, custom weapons via BSON data
Does anyone know how to disable mouse lock?
Regardless, thanks for the help there. I'll def look into it
How do I handle player death to teleport them to a different world? When I add a Teleport component in OnDeathSystem, it conflicts with the RespawnPage and crashes. Should I listen for when the player clicks Respawn instead? Is there a way to skip the respawn screen entirely?
youtube[dot]com[slash]@TroubleDEV this guy has some stuff :v
How is hydifficulty buggy?
Oh yeah I saw one of his starter videos.
probs a dumb question, but i cant use getScheduler. is there a way to delay things?
There are a lot of SEVERE errors in the console, which causes it to crash constantly, and the things that the plugin says it does, like multipliers, don't work either.
Have you tried hyfixes? These crashes prob caused by vanilla
Man lookin through this game code is rough. Props to yall who can figure all this stuff out just by reading through this stuff xD
You search through the jar
anyone know if i can get a list of the items a block drops? ive found out how to get the drop list id, but not the list itself
pfft I wish Icould just read the java class files and understand it easily
Ew Python. OUT
ive been using CompletableFuture::delayedExecutor but no idea if thats the intended way to delay stuff or not, ive found it works similar to a bukkit scheduler
Started with mc modding way too long ago, this is great
hey now it was a good starting point... then I never left
I am a C# dev so not too much of a curve but still, I work on distributed systems so this is foreign
I could never get into MC modding the way I wanted to. My coding skills in general are just barely enough to have passed college for IT. So I'm tryna use my freetime and hype of the game to finally learn coding the way I intended
But even with severe errors within the server, and using hyfixes, will it work correctly? I don't think so, because that's an error in the mod
dumb question, how do i check if the user's on ground?, like currently touching the ground, i couldn't find any function in the player class too
Tbh I always wanted to do more but found myself needing to make/find tools to make the stuff i wanted. This seems like a better start anyways
Does anyone know why multiple times a day I have to continue re authenticating on startup? I have persistence set to encrypted
I have that same problem
omg it worked, youre such a life saver <3
first person to awnser me in here lmfao
glad it worked, i know how it feels to throw a question at the void and get nothing back
Yeah same for me. Like I wanna make A UI or atleast learn how too. But to do that I first need some png asset for it. Thiis is just an example but usually it starts to compound more where I need to make more assets just to "practice" and I personally don't like doing things just for the sake for practice, even if It's badly built, I wanna make something I'm gonna use, or atleast know why I should replace it later on
I want to have a custom collision handler
public class CollisionHandler implements IBlockCollisionConsumer {
@Override
public Result onCollision(int blockX, int blockY, int blockZ,
Vector3d direction, BlockContactData contactData,
BlockData blockData, Box collider) {
LOGGER.atInfo().log("Collided");
...
}
However I'm not entirely sure how to register this custom handler can someone point me in the right direction?
Is there a dedicated place for server support? I'm using pterodactyl and it has to auth every time the panel runs, Any way to bypass this atm?
For my college senior project, me and some friends made a Unity Game, and I maybe redesigned player movement 3 times, but I each time I intended for that to be how the game felt. It was never an experiment to try and see what sticks
/auth persistence Encrypted ?
java.lang.RuntimeException: Failed to get hardware UUID for Linux - all methods failed
Docker doesn't have access to UUID
Hey, can someone help me? I don't know why the recipe isn't working json {"Recipe": { "TimeSeconds": 4.5, "KnowledgeRequired": false, "Input": [ { "ItemId": "Weapon_Longsword_Copper", "Quantity": 1 }, { "ItemId": "Weapon_Longsword_Iron", "Quantity": 1 }, { "ItemId": "Weapon_Longsword_Cobalt", "Quantity": 1 }, { "ItemId": "Weapon_Longsword_Thorium" }, { "ItemId": "Weapon_Longsword_Adamantite" } ], "BenchRequirement": [ { "Type": "Crafting", "Categories": [ "Weapon_Longsword" ], "Id": "Weapon_Bench", "RequiredTierLevel": 3 } ] }}
i dont think there's another way to persist right now tbh so might just have to do device auth every time 😿
HytaleServer.SCHEDULED_EXECUTOR is a static field
I deleted my world in /universe/worlds/world but every time I run the server it keeps recreating the files for the world? Where is hytale seeing that saved data so I can truly delete the world?
Hytale saves all data through files right? doesn't use a database, etc
I haven't tried this, but there is a --auth-mode offline flag, maybe it works?
deathComponent.setShowDeathMenu(false); but you might have to do some stuff with system Ordering with the getDependencies override
let's try 🙂
There is a .cache folder, you could try deleting that.
anyone know where in the manifest i need to put my sound files and json to be reckognized?
i mean the manifest folder not the manifest.json of course
err rescource folder
ah, yeah, the server requires access to the hardware uuid of the machine its running on
anyone familiar with SoundUtil? how would i send a simple sound to every player?
For anyone looking to setup Hytale on Pterodactyl (as of now) that runs into:
java.lang.RuntimeException: Failed to get hardware UUID for Linux - all methods failed
Add a mount for your eggs sourced at: /etc/machine-id and /sys/class/dmi/id. The UUID will be passed and allow verification automatically.
Thank you @severe pulsar and @mortal gate for the attempted help!
Pterodactyl doesn't by default allow that because of docker (what it runs on)
idk, I would google it
the term you would want to look for is "hardware uuid" along with why its not present in docker
Also if you update the wings to latest they already patched the issue
hey i just figured it out, in server config.json whatever the default world is gets created when server is run if it doesn't exist. Apparently it gets created before plugin code runs
wings update 1.12.1 if you want to google
So brand new to modding for any game but have been looking forward to hytale since the trailer. Was wondering how hard is it gonna be to make custom instanced dungeons similar to Yungs fortress of the undead mod?
Any help would be appreciated
Is there a standard built-in way of storing custom data and saving to disc, or should I just use my own database?
Yes there is the asset store
Theres already a signature for sending a sound to every player in SoundUtil its the one that doesn't take a ref parameter
and background database async .
I'd suggest Hytale's Multi-Threaded Architecture Explained by TroubleDEV and their ECS video as well.
Haven't played with that mod in ages, but over all adding new prefabs and instanced worlds is pretty easy
Any good/clear tutorials or links you know of?
Well that is encouraging! So is there info out there for doing so? If there is could you point me in the right direction?
Just to make sure are you talking about a Procedural dungeon world or just randomized dungeons in the main world?
Was thinking more like hand crafted instanced dungeons you have to craft a crystal and put in the portal to reach
Well that's even better! One moment, While I haven't personally worked in that section of modding yet (I've been creating more ECS systems) I can def point in you a in a direction
Appreciate your time
I don't see any 1 to 1 tutorial around for that quite yet.
So I can point you in a direction in the asset editor.
Here are somethings to look at in the base game, maybe you can reverse engineer it.
Server/GameplayConfigs/Portal
Server/HytaleGenerator/WorldStructures/Portals_Taiga.json
Server/Item/Items/Portal/PortalKey_Hederas_Lair.json
Thanks a lot! I'll start digging into this tomorrow! Have a good one!
what mods should i use for my server?
Hola! Entra a mi bio, allí tengo un servidor español factions, survival y parcelas!
all of them
i think this channel is English only
Heya does anyone how someone would go about making a top down mod? Aka u see things from the top
is there a way to get a players ip?
no why would you need that
ipbans
Ipban is useless, but yes, I think there is a way to get the player IP
that would be so messed up if there was a way to get a users ip lol
not really
you can in mc
No? that's like basic information about connections
no there isnt
How do I edit roles so for example Klops_Merchant instead of opening his shop, opens my shop? What is the "Type": "OpenBarterShop" referencing in the code?
i mean even if there was no way to get the ip from the plugin side you can still get it from the network logs on the server
You know an IP is required for a connection between two peers on the internet right?
yeah, doesn't change the fact that the API does not allow mods to use the IP
Even if is not possible via hytale api, would still be possible via reflection, the socket/datagram must be declared somewhere
it totally does
that would work, yes
If that's your point, maybe you are right and there is no way to get the player IP via API, but is still possible to get it somehow.
ipbans are still useless. use hwip instead
Its also almost undoubtably possible to get their ip anyways
Yes, ipbans are definitely useless, I must agree.
one router restart and i have a new ip lol
maybe for you but a 13yo troll that doesn't know well enough it works
var handler = playerRef.getPacketHandler();
var channel = handler.getChannel();
SocketAddress socketAddress;
if (channel instanceof QuicStreamChannel quicStreamChannel) {
socketAddress = quicStreamChannel.parent().remoteSocketAddress();
} else {
socketAddress = channel.remoteAddress();
}
if (socketAddress instanceof InetSocketAddress inetSocketAddress){
System.out.println(inetSocketAddress.getPort());
System.out.println(inetSocketAddress.getAddress().getHostAddress());
}
almost everyone in the gaming scene knows that your ip changes every time you restart your router
Thats just in PlayerReadyEvent but it should work fine anywhere the PlayerRef is valid
Yeah, at least I know it since I was 10 years old
I mean, the game is not free, just ban the account.
yeah UUID ban is actually more effective than ipban in paid games
dramatically more effective lol
the main reason its not as effective in mc is because there are so many leaked accounts available
it might have actually been nice if you couldn't... how long till we get adware mods like essential in minecraft
If you connect to a server theres no way your IPs gonna remain hidden from accessors of the server unless you've already connected with a VPN
i just wanna open a chest and suddenly i get 2min of unskippable ad
The "API" we're given is just the straight up server in its entirety so not really any sandboxing going on