Merge pull request #122 from JenyaRostov/takeallhotkey
Hotkey to Take All action in containers
This commit is contained in:
commit
4b917e8c2f
@ -3,7 +3,8 @@
|
|||||||
"groups": {
|
"groups": {
|
||||||
"camera": { "name": "Camera" },
|
"camera": { "name": "Camera" },
|
||||||
"voice": { "name": "Voice" },
|
"voice": { "name": "Voice" },
|
||||||
"building": { "name": "Building" }
|
"building": { "name": "Building" },
|
||||||
|
"inventory": { "name": "Inventory" }
|
||||||
},
|
},
|
||||||
"name": "Open^#ebd74a;Starbound",
|
"name": "Open^#ebd74a;Starbound",
|
||||||
"binds": {
|
"binds": {
|
||||||
@ -15,6 +16,11 @@
|
|||||||
"group": "camera",
|
"group": "camera",
|
||||||
"name": "Zoom In"
|
"name": "Zoom In"
|
||||||
},
|
},
|
||||||
|
"takeAll": {
|
||||||
|
"default": [],
|
||||||
|
"group": "inventory",
|
||||||
|
"name": "Take All From Container"
|
||||||
|
},
|
||||||
"zoomOut": {
|
"zoomOut": {
|
||||||
"default": [{
|
"default": [{
|
||||||
"type": "key",
|
"type": "key",
|
||||||
|
@ -18,6 +18,7 @@
|
|||||||
#include "StarStatusControllerLuaBindings.hpp"
|
#include "StarStatusControllerLuaBindings.hpp"
|
||||||
#include "StarWidgetLuaBindings.hpp"
|
#include "StarWidgetLuaBindings.hpp"
|
||||||
#include "StarAugmentItem.hpp"
|
#include "StarAugmentItem.hpp"
|
||||||
|
#include "StarInput.hpp"
|
||||||
|
|
||||||
namespace Star {
|
namespace Star {
|
||||||
|
|
||||||
@ -265,6 +266,7 @@ void ContainerPane::update(float dt) {
|
|||||||
m_script->update(m_script->updateDt(dt));
|
m_script->update(m_script->updateDt(dt));
|
||||||
|
|
||||||
m_itemBag->clearItems();
|
m_itemBag->clearItems();
|
||||||
|
Input& input = Input::singleton();
|
||||||
|
|
||||||
if (!m_containerInteractor->containerOpen()) {
|
if (!m_containerInteractor->containerOpen()) {
|
||||||
dismiss();
|
dismiss();
|
||||||
@ -296,6 +298,10 @@ void ContainerPane::update(float dt) {
|
|||||||
fuelGauge->setPotentialFuelAmount(totalFuelAmount);
|
fuelGauge->setPotentialFuelAmount(totalFuelAmount);
|
||||||
fuelGauge->setRequestedFuelAmount(0);
|
fuelGauge->setRequestedFuelAmount(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (input.bindDown("opensb", "takeAll")) {
|
||||||
|
m_containerInteractor->clearContainer();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user