Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Client side only entities.


Recommended Posts

With the client/server split I am having a little trouble knowing where to put my code. I am building a mod that lets players see their creations from schematic files in-game and can help them place the blocks in the correct locations to build large complicated projects when access to the raw map files are not available (like in a multiplayer environment). I have figured out that I am going to represent these planning blocks as entities (I call them "EntityGhostBlocks" due to their opacity not being set to 100%). This lets me not worry abut block replacement code and I keep the in-memory chunk block list pristine and in sync with the server. When a real block gets placed on the entity I remove it.


The issue is I wanted to set this up so a player could use this on a multiplayer server without any server side mods installed. My question is how do I get these entities to show up and be able to manipulate them on the client but not have them sent to the server?

Link to comment
Share on other sites

i have a theory of how you might be able to , it would be extremely hacky though as you would need to force the client side chunks to display your ghost blocks. the problem is it would have to some how change the communication between the client and server some how forcing the display. i think their is a cache of the chunks that are loaded , so you'd have to edit that on the fly before the render pass i think.


all just theory but the mod sounds great, hope you can get it working , and if not let me know i'll try to after i finish my current mod project

Link to comment
Share on other sites

The problem is that most of the block hooks (like onBlockActivated) aren't called on the client any more. You just don't get the feedback there. So unfortunately, I think that is not possible.


Of course they get called in client world.



Do not register your entities and just spawn them in your clientworld, and no one would see them except of you.


Link to comment
Share on other sites

Im also confused since 1.3


im having 2 entitys:

1 is a human one and its working fine.

The other one is a animal and that one isnt working anymore. Its now invisible for some reason (it was working fine with 1.2.5)


my Model, Render and Entinity files are in the common folder.



I also tried to implement IAnimal to the entityanimal. its getting visible then but its rendering as a human model O.o



Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing

    No registered users viewing this page.

  • Posts

    • and what is called OreFeatureConfig, while making ore gen
    • I have been trying to download Forge but the Windows Installer isn't coming up, I can see the installer one would use for Linux but no Windows, I have downloaded Java and Jarfix but nothing is working, can someone help?  
    • So I thought that when a capability is attached to an item/entity/etc... the capability will stay until whatever it's attached to is gone. But this doesn't seem to be the case, as when I printed to console whenever a capability is attached, it seems as though a new version of the capability is attached to an item every time I select it in my hotbar, hover over it in inventory, etc. Is this how it's supposed to work? If so, why?
    • Hi, I'm trying to set up a simple forge server just to play with a couple of my friends, but no matter what I do or try I cannot seem to get a Mods folder and for the actual forge part of the server to actually launch. Every time I try to launch the forge.jar via a .bat file I just get a bunch of errors [Errors below] I'm not sure what I'm doing wrong. If I can get some help that would be awesome, thanks C:\Users\User\Desktop\Server>java -Xms2G -Xmx6G -jar forge-1.12.2- nogui A problem occurred running the Server launcher.java.lang.reflect.InvocationTargetException         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)         at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:78)         at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)         at java.base/java.lang.reflect.Method.invoke(Method.java:567)         at net.minecraftforge.fml.relauncher.ServerLaunchWrapper.run(ServerLaunchWrapper.java:70)         at net.minecraftforge.fml.relauncher.ServerLaunchWrapper.main(ServerLaunchWrapper.java:34) Caused by: java.lang.ClassCastException: class jdk.internal.loader.ClassLoaders$AppClassLoader cannot be cast to class java.net.URLClassLoader (jdk.internal.loader.ClassLoaders$AppClassLoader and java.net.URLClassLoader are in module java.base of loader 'bootstrap')         at net.minecraft.launchwrapper.Launch.<init>(Launch.java:34)         at net.minecraft.launchwrapper.Launch.main(Launch.java:28)         ... 6 more C:\Users\User\Desktop\Server>pause Press any key to continue . . .  
  • Topics

  • Who's Online (See full list)

  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.