add binding for old key X
This commit is contained in:
parent
ee8d0368bd
commit
240b406332
@ -16,4 +16,5 @@ player.attack="mouse:left"
|
|||||||
player.build="mouse:right"
|
player.build="mouse:right"
|
||||||
player.pick="mouse:middle"
|
player.pick="mouse:middle"
|
||||||
player.drop="key:q"
|
player.drop="key:q"
|
||||||
|
player.fast_interaction="key:x"
|
||||||
hud.inventory="key:tab"
|
hud.inventory="key:tab"
|
||||||
|
|||||||
@ -31,6 +31,7 @@ hud.inventory=Inventory
|
|||||||
player.pick=Pick Block
|
player.pick=Pick Block
|
||||||
player.attack=Attack / Break
|
player.attack=Attack / Break
|
||||||
player.build=Place Block
|
player.build=Place Block
|
||||||
|
player.fast_interaction=Accelerated interaction
|
||||||
player.flight=Flight
|
player.flight=Flight
|
||||||
player.noclip=No-clip
|
player.noclip=No-clip
|
||||||
player.drop=Drop Item
|
player.drop=Drop Item
|
||||||
|
|||||||
@ -92,6 +92,7 @@ hud.inventory=Инвентарь
|
|||||||
player.pick=Подобрать Блок
|
player.pick=Подобрать Блок
|
||||||
player.attack=Атаковать / Сломать
|
player.attack=Атаковать / Сломать
|
||||||
player.build=Поставить Блок
|
player.build=Поставить Блок
|
||||||
|
player.fast_interaction=Ускоренное взаимодействие
|
||||||
player.flight=Полёт
|
player.flight=Полёт
|
||||||
player.drop=Выбросить Предмет
|
player.drop=Выбросить Предмет
|
||||||
camera.zoom=Приближение
|
camera.zoom=Приближение
|
||||||
|
|||||||
@ -27,6 +27,8 @@ inline const std::string BIND_PLAYER_FLIGHT = "player.flight";
|
|||||||
inline const std::string BIND_PLAYER_ATTACK = "player.attack";
|
inline const std::string BIND_PLAYER_ATTACK = "player.attack";
|
||||||
inline const std::string BIND_PLAYER_BUILD = "player.build";
|
inline const std::string BIND_PLAYER_BUILD = "player.build";
|
||||||
inline const std::string BIND_PLAYER_PICK = "player.pick";
|
inline const std::string BIND_PLAYER_PICK = "player.pick";
|
||||||
|
inline const std::string BIND_PLAYER_FAST_INTERACTOIN =
|
||||||
|
"player.fast_interaction";
|
||||||
inline const std::string BIND_HUD_INVENTORY = "hud.inventory";
|
inline const std::string BIND_HUD_INVENTORY = "hud.inventory";
|
||||||
|
|
||||||
class EnginePaths;
|
class EnginePaths;
|
||||||
|
|||||||
@ -489,7 +489,7 @@ void PlayerController::updateInteraction() {
|
|||||||
if (interactionTimer > 0.0f) {
|
if (interactionTimer > 0.0f) {
|
||||||
interactionTimer -= static_cast<float>(engine->getDelta());
|
interactionTimer -= static_cast<float>(engine->getDelta());
|
||||||
}
|
}
|
||||||
bool xkey = Events::pressed(keycode::X);
|
bool xkey = Events::active(BIND_PLAYER_FAST_INTERACTOIN);
|
||||||
float maxDistance = xkey ? 200.0f : 10.0f;
|
float maxDistance = xkey ? 200.0f : 10.0f;
|
||||||
bool longInteraction = interactionTimer <= 0 || xkey;
|
bool longInteraction = interactionTimer <= 0 || xkey;
|
||||||
bool lclick = Events::jactive(BIND_PLAYER_ATTACK) ||
|
bool lclick = Events::jactive(BIND_PLAYER_ATTACK) ||
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user