APDevTeam / Movecraft

The original movement plugin for Paper. Reloaded. Again.
GNU General Public License v3.0
122 stars 74 forks source link

Cruise signs not working #620

Closed JoshuaCulwell closed 7 months ago

JoshuaCulwell commented 7 months ago

Describe the bug Cruise signs are not working in 8.0.0 Beta 2. For some reason if signs are initialized as "Cruise: ON" and they are clicked a message is displayed saying cruise has been turned off and the sign changes to off but then the sign will not switch from "Cruise: OFF" to "Cruise: ON" again.

To Reproduce Steps to reproduce the behavior:

  1. Create a craft that is able to cruise.
  2. Add a "Cruise: OFF" sign
  3. Pilot the craft
  4. click on the "Cruise: OFF" sign
  5. See error

Expected behavior When a craft is being piloted and a cruise sign is clicked it will enable cruise in the direction of the sign.

Versions (please complete the following information):

parsec42 commented 7 months ago

I have the same problem.

TylerS1066 commented 7 months ago

I believe this was probably fixed in #618. Can you try running this dev build on 1.20.4 to verify the issue is gone?

JoshuaCulwell commented 7 months ago

I just set up a 1.20.4 server and used the dev build you gave. The signs are working better than before (release sign doesn't make me edit when I click on the sign) however the cruise signs are still not working. If the sign is set to "Cruise: ON" before piloting the craft it immediately switches to "Cruise: OFF" which changed from before where it wanted me to click on it to change it to off. No matter what I do I cannot seem to make it switch from "Cruise: OFF" to "Cruise: ON" though. Ascend and Descend signs are working.

Edit: I am also using EssentialsX and SlimeFun4 plugins as well which I know used to not have conflicts years ago but may have a conflict now. I'll try running it without either of those plugins. Edit 2: Still does not work after removing the other plugins.

JoshuaCulwell commented 7 months ago

After reviewing the code line 63 in the "CruiseSign.java" file checks if it is directional. It seems the signs must be placed on the side of a block to be a directional instance and not on top of a block. Cruise signs do work if they are placed on the side of a block and not on the top of a block where I guess the block data is not an instance of Directional. Based on this, cruise signs work but only under the condition that they are placed on the side of a block.

Thank you for checking this bug and providing the 1.20.4 dev build.

Side note: while messing around with this I found that helm signs cannot be destroyed in this version unless the block it is attached to is broken. Not sure if this was already known but is just a very minor thing I noticed.

TylerS1066 commented 7 months ago

Based on this, cruise signs work but only under the condition that they are placed on the side of a block.

Ah yes, I should have mentioned that.

Side note: while messing around with this I found that helm signs cannot be destroyed in this version unless the block it is attached to is broken. Not sure if this was already known but is just a very minor thing I noticed.

Huh, that probably makes sense. I'll file another issue to track that behavior.