mirror of
https://github.com/PixelGuys/Cubyz.git
synced 2025-08-03 19:28:49 -04:00
make / open chat
This commit is contained in:
parent
d47a4ab62a
commit
137b7e4706
@ -287,6 +287,11 @@ fn openChat() void {
|
|||||||
gui.openWindow("chat");
|
gui.openWindow("chat");
|
||||||
gui.windowlist.chat.input.select();
|
gui.windowlist.chat.input.select();
|
||||||
}
|
}
|
||||||
|
fn openCommand() void {
|
||||||
|
openChat();
|
||||||
|
gui.windowlist.chat.input.clear();
|
||||||
|
gui.windowlist.chat.input.inputCharacter('/');
|
||||||
|
}
|
||||||
fn takeBackgroundImageFn() void {
|
fn takeBackgroundImageFn() void {
|
||||||
if(game.world == null) return;
|
if(game.world == null) return;
|
||||||
renderer.MenuBackGround.takeBackgroundImage();
|
renderer.MenuBackGround.takeBackgroundImage();
|
||||||
@ -351,6 +356,7 @@ pub const KeyBoard = struct { // MARK: KeyBoard
|
|||||||
.{.name = "openInventory", .key = c.GLFW_KEY_E, .pressAction = &openInventory, .gamepadButton = c.GLFW_GAMEPAD_BUTTON_X},
|
.{.name = "openInventory", .key = c.GLFW_KEY_E, .pressAction = &openInventory, .gamepadButton = c.GLFW_GAMEPAD_BUTTON_X},
|
||||||
.{.name = "openCreativeInventory(aka cheat inventory)", .key = c.GLFW_KEY_C, .pressAction = &openCreativeInventory, .gamepadButton = c.GLFW_GAMEPAD_BUTTON_Y},
|
.{.name = "openCreativeInventory(aka cheat inventory)", .key = c.GLFW_KEY_C, .pressAction = &openCreativeInventory, .gamepadButton = c.GLFW_GAMEPAD_BUTTON_Y},
|
||||||
.{.name = "openChat", .key = c.GLFW_KEY_T, .releaseAction = &openChat},
|
.{.name = "openChat", .key = c.GLFW_KEY_T, .releaseAction = &openChat},
|
||||||
|
.{.name = "openCommand", .key = c.GLFW_KEY_SLASH, .releaseAction = &openCommand},
|
||||||
.{.name = "mainGuiButton", .mouseButton = c.GLFW_MOUSE_BUTTON_LEFT, .pressAction = &gui.mainButtonPressed, .releaseAction = &gui.mainButtonReleased, .gamepadButton = c.GLFW_GAMEPAD_BUTTON_A},
|
.{.name = "mainGuiButton", .mouseButton = c.GLFW_MOUSE_BUTTON_LEFT, .pressAction = &gui.mainButtonPressed, .releaseAction = &gui.mainButtonReleased, .gamepadButton = c.GLFW_GAMEPAD_BUTTON_A},
|
||||||
.{.name = "secondaryGuiButton", .mouseButton = c.GLFW_MOUSE_BUTTON_RIGHT, .pressAction = &gui.secondaryButtonPressed, .releaseAction = &gui.secondaryButtonReleased, .gamepadButton = c.GLFW_GAMEPAD_BUTTON_Y},
|
.{.name = "secondaryGuiButton", .mouseButton = c.GLFW_MOUSE_BUTTON_RIGHT, .pressAction = &gui.secondaryButtonPressed, .releaseAction = &gui.secondaryButtonReleased, .gamepadButton = c.GLFW_GAMEPAD_BUTTON_Y},
|
||||||
// gamepad gui.
|
// gamepad gui.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user