Merge branch 'master' of http://github.com/juanjp600/Barotrauma
This commit is contained in:
@@ -36,6 +36,7 @@
|
|||||||
category="Machine"
|
category="Machine"
|
||||||
type="Controller"
|
type="Controller"
|
||||||
linkable="true"
|
linkable="true"
|
||||||
|
disableitemusagewhenselected="true"
|
||||||
>
|
>
|
||||||
|
|
||||||
<Sprite texture ="railgunetc.png" depth="0.8" sourcerect="182,0,61,97"/>
|
<Sprite texture ="railgunetc.png" depth="0.8" sourcerect="182,0,61,97"/>
|
||||||
|
|||||||
@@ -926,6 +926,8 @@ namespace Barotrauma
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (SelectedConstruction == null || !SelectedConstruction.Prefab.DisableItemUsageWhenSelected)
|
||||||
|
{
|
||||||
for (int i = 0; i < selectedItems.Length; i++ )
|
for (int i = 0; i < selectedItems.Length; i++ )
|
||||||
{
|
{
|
||||||
if (selectedItems[i] == null) continue;
|
if (selectedItems[i] == null) continue;
|
||||||
@@ -934,6 +936,7 @@ namespace Barotrauma
|
|||||||
if (IsKeyDown(InputType.Use)) selectedItems[i].Use(deltaTime, this);
|
if (IsKeyDown(InputType.Use)) selectedItems[i].Use(deltaTime, this);
|
||||||
if (IsKeyDown(InputType.Aim) && selectedItems[i] != null) selectedItems[i].SecondaryUse(deltaTime, this);
|
if (IsKeyDown(InputType.Aim) && selectedItems[i] != null) selectedItems[i].SecondaryUse(deltaTime, this);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (selectedConstruction != null)
|
if (selectedConstruction != null)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -134,6 +134,13 @@ namespace Barotrauma
|
|||||||
private set;
|
private set;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[Serialize(false, false)]
|
||||||
|
public bool DisableItemUsageWhenSelected
|
||||||
|
{
|
||||||
|
get;
|
||||||
|
private set;
|
||||||
|
}
|
||||||
|
|
||||||
public bool CanSpriteFlipX
|
public bool CanSpriteFlipX
|
||||||
{
|
{
|
||||||
get { return canSpriteFlipX; }
|
get { return canSpriteFlipX; }
|
||||||
|
|||||||
Reference in New Issue
Block a user