Added Block#allowConfigInventory
This commit is contained in:
@@ -967,7 +967,7 @@ public abstract class InputHandler implements InputProcessor, GestureListener{
|
|||||||
//consume tap event if necessary
|
//consume tap event if necessary
|
||||||
if(build.interactable(player.team()) && build.block.consumesTap){
|
if(build.interactable(player.team()) && build.block.consumesTap){
|
||||||
consumed = true;
|
consumed = true;
|
||||||
}else if(build.interactable(player.team()) && build.block.synthetic() && !consumed){
|
}else if(build.interactable(player.team()) && build.block.synthetic() && (!consumed || build.block.allowConfigInventory)){
|
||||||
if(build.block.hasItems && build.items.total() > 0){
|
if(build.block.hasItems && build.items.total() > 0){
|
||||||
frag.inv.showFor(build);
|
frag.inv.showFor(build);
|
||||||
consumed = true;
|
consumed = true;
|
||||||
|
|||||||
@@ -159,6 +159,8 @@ public class Block extends UnlockableContent{
|
|||||||
public int unitCapModifier = 0;
|
public int unitCapModifier = 0;
|
||||||
/** Whether the block can be tapped and selected to configure. */
|
/** Whether the block can be tapped and selected to configure. */
|
||||||
public boolean configurable;
|
public boolean configurable;
|
||||||
|
/** If true, the building inventory can be shown with the config. */
|
||||||
|
public boolean allowConfigInventory = true;
|
||||||
/** If true, this block can be configured by logic. */
|
/** If true, this block can be configured by logic. */
|
||||||
public boolean logicConfigurable = false;
|
public boolean logicConfigurable = false;
|
||||||
/** Whether this block consumes touchDown events when tapped. */
|
/** Whether this block consumes touchDown events when tapped. */
|
||||||
|
|||||||
@@ -51,6 +51,8 @@ public class ItemBridge extends Block{
|
|||||||
group = BlockGroup.transportation;
|
group = BlockGroup.transportation;
|
||||||
noUpdateDisabled = true;
|
noUpdateDisabled = true;
|
||||||
copyConfig = false;
|
copyConfig = false;
|
||||||
|
//disabled as to not be annoying
|
||||||
|
allowConfigInventory = false;
|
||||||
|
|
||||||
//point2 config is relative
|
//point2 config is relative
|
||||||
config(Point2.class, (ItemBridgeBuild tile, Point2 i) -> tile.link = Point2.pack(i.x + tile.tileX(), i.y + tile.tileY()));
|
config(Point2.class, (ItemBridgeBuild tile, Point2 i) -> tile.link = Point2.pack(i.x + tile.tileX(), i.y + tile.tileY()));
|
||||||
|
|||||||
@@ -11,4 +11,4 @@ android.useAndroidX=true
|
|||||||
#used for slow jitpack builds; TODO see if this actually works
|
#used for slow jitpack builds; TODO see if this actually works
|
||||||
http.socketTimeout=80000
|
http.socketTimeout=80000
|
||||||
http.connectionTimeout=80000
|
http.connectionTimeout=80000
|
||||||
archash=d78dce000f67845a757dca905de9209ad57106a9
|
archash=f1cd1594796e87b469da17d274f78a595e000c4f
|
||||||
|
|||||||
Reference in New Issue
Block a user