Added block data to FakeBlockAction and ShowGen, so BlockStates are saved and loaded.#1
Added block data to FakeBlockAction and ShowGen, so BlockStates are saved and loaded.#1KyGuy2002 wants to merge 9 commits intoCubitsDev:stagingfrom
Conversation
|
@KyGuy2002 Is this good for reviewing? Just seen you added another commit so want to check before continuing. |
|
Yes this should be all ready, I have tested it “in the lab” on my server but am yet to use it in a full scale show. I will be setting up a larger show soon, so maybe wait until then just incase. I will update you when I have done that, but if you want I can always just do another PR. Also, I’m going to be making another PR for improved docs soon as well. |
|
Alright, I tested it again, seems like it works as intended. I will probably update it again later with some more supported blocks and a few other things I noticed, but idk when I will do that. Its ready for review. |
|
Any update @CubitsDev ? This, #2 and #4 are all ready for review. Thanks |
src/main/java/network/palace/show/commands/showgen/GenerateCommand.java
Outdated
Show resolved
Hide resolved
| dataString = new StringBuilder("FENCE,"); | ||
|
|
||
| // True for included | ||
| for (BlockFace face : ((Fence) blockData).getFaces()) { |
There was a problem hiding this comment.
This should be switched to a switch case statement to avoid the if else if repetition.
There was a problem hiding this comment.
Your meaning the whole part, or just the // True for included part?
Im using instanceof so i dont think its possible to do that in a switch statemnt
…es, and all varients of commands work
|
I resolved all requested changes, and left a response to one of them @CubitsDev . Thanks |
The FakeBlockAction currently doesn't allow BlockStates such as orientation, faces, open/closed, etc. This causes these blocks to have the default states, which looks bad in many situations.
I have added block states to showgen, and parse them as with the other values.
Currently Saved States:
Stairs
Doors
TrapDoors
GlassPane
Fence
Other Small Changed:
In addition, I fixed the showgen by flipping a >= to <=, not sure why it was like this in the repo...
Also, the auto-update message on join wasn't working due to its listener not being registered, so that's fixed.
I updated the dependencies and incremented the minor version number.