Jump to content

World.setBlockToAir makes invisible buggy blocks


ashjack

Recommended Posts

if I run World.setBlockToAir in a piece of code, the blocks removed turn into invisible glitchy blocks that cause me to bug up and down until I come off of them. This happens if I run the code on the server side (!world.isRemote) and as I suspected, did nothing if run on the client side.

 

I have just realised what is causing the problem as I was about to write the next paragraph, but I still don'y know how to fix it:

 

This code is run from within the actionPerformed function within a GUI window, which is of course client sided. Short of sending a packet, how could I run this code without it making glitchy invisible blocks?

Link to comment
Share on other sites

No, if you set it to air on the server the engine should handle it and send the client the update packet.

Post your code.

...

This code is run from within the actionPerformed function within a GUI window, which is of course client sided. Short of sending a packet, how could I run this code without it making glitchy invisible blocks?

He runs the code from a GUI, so he has to send a packet to the server to set the block to air.

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
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.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.