przemykomo / simple-planes

Planes mod for minecraft forge.
GNU Lesser General Public License v3.0
28 stars 26 forks source link

Keybinding Issue #71

Closed Foozey closed 3 years ago

Foozey commented 3 years ago

If a keybinding to access the plane engine is the same as another keybind, one of the keybinds won't work at all. For example, if you have inventory set to [E] and access plane engine set to [E], either the inventory or plane engine won't work at all. This is annoying as sometimes you want to have the same keybind as something else.

przemykomo commented 3 years ago

Yes that's how keybinds in minecraft work.

Foozey commented 3 years ago

No, other keybindings that are the same don't work like that. For example, in your own mod, you have [Space] for boost, but also [Space] for jump, yet they both still work. It's just that specific keybinding. If you ride a horse in Minecraft, you can press [E] to open the inventory, yet you can also press [E] to open the normal inventory if you're not on the horse. This is how I'm trying to make it work with your mod because it matches vanilla the best. Pressing [E] should be able to open the plane inventory while you're in the plane, but opens the normal inventory if you're out of the plane.

przemykomo commented 3 years ago

Pressing [E] opens the inventory if the plane has chest. Notice that the horse doesn't have a different keybind for inventory, it uses the default one, just like the plane with chest does. The engine gui has to be a different keybinding (how would you open the chest with the same keybinding?) and one of the keybindings always has the priority and cancels the other one by opening the gui.

Foozey commented 3 years ago

Ah, sorry, you're right. That slipped my mind. Thank you for clarifying.