Merge remote-tracking branch 'origin/master' into moStuff
# Conflicts: # Barotrauma/BarotraumaShared/BarotraumaShared.projitems # Barotrauma/BarotraumaShared/Data/clientpermissions.xml
This commit is contained in:
@@ -436,7 +436,7 @@ namespace Barotrauma
|
|||||||
|
|
||||||
InfoFrame.FindChild("showlog").Visible = GameMain.Server != null;
|
InfoFrame.FindChild("showlog").Visible = GameMain.Server != null;
|
||||||
|
|
||||||
campaignViewButton = new GUIButton(new Rectangle(0, 0, 130, 30), "Campaign view", Alignment.BottomRight, "", defaultModeContainer);
|
campaignViewButton = new GUIButton(new Rectangle(-80, 0, 120, 30), "Campaign view", Alignment.BottomRight, "", defaultModeContainer);
|
||||||
campaignViewButton.OnClicked = (btn, obj) => { ToggleCampaignView(true); return true; };
|
campaignViewButton.OnClicked = (btn, obj) => { ToggleCampaignView(true); return true; };
|
||||||
campaignViewButton.Visible = false;
|
campaignViewButton.Visible = false;
|
||||||
|
|
||||||
|
|||||||
@@ -743,7 +743,7 @@
|
|||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
<Content Include="$(MSBuildThisFileDirectory)Data\clientpermissions.xml">
|
<Content Include="$(MSBuildThisFileDirectory)Data\clientpermissions.xml">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
<Content Include="$(MSBuildThisFileDirectory)Data\ContentPackages\Vanilla 0.7.xml">
|
<Content Include="$(MSBuildThisFileDirectory)Data\ContentPackages\Vanilla 0.7.xml">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
<?xml version="1.0" encoding="utf-8" ?>
|
<?xml version="1.0" encoding="utf-8" ?>
|
||||||
<Permissions>
|
<ClientPermissions>
|
||||||
|
</ClientPermissions>
|
||||||
</Permissions>
|
|
||||||
@@ -197,7 +197,7 @@ namespace Barotrauma
|
|||||||
{
|
{
|
||||||
get { return !IsUnconscious && Stun <= 0.0f && !isDead; }
|
get { return !IsUnconscious && Stun <= 0.0f && !isDead; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public bool CanInteract
|
public bool CanInteract
|
||||||
{
|
{
|
||||||
get { return AllowInput && IsHumanoid && !LockHands; }
|
get { return AllowInput && IsHumanoid && !LockHands; }
|
||||||
@@ -303,11 +303,11 @@ namespace Barotrauma
|
|||||||
get { return needsAir; }
|
get { return needsAir; }
|
||||||
set { needsAir = value; }
|
set { needsAir = value; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public float Oxygen
|
public float Oxygen
|
||||||
{
|
{
|
||||||
get { return oxygen; }
|
get { return oxygen; }
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
if (!MathUtils.IsValid(value)) return;
|
if (!MathUtils.IsValid(value)) return;
|
||||||
oxygen = MathHelper.Clamp(value, -100.0f, 100.0f);
|
oxygen = MathHelper.Clamp(value, -100.0f, 100.0f);
|
||||||
@@ -331,7 +331,7 @@ namespace Barotrauma
|
|||||||
{
|
{
|
||||||
if (GameMain.Client != null) return;
|
if (GameMain.Client != null) return;
|
||||||
|
|
||||||
SetStun(value);
|
SetStun(value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -358,7 +358,7 @@ namespace Barotrauma
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public float MaxHealth
|
public float MaxHealth
|
||||||
{
|
{
|
||||||
get { return maxHealth; }
|
get { return maxHealth; }
|
||||||
@@ -367,33 +367,33 @@ namespace Barotrauma
|
|||||||
public float Bleeding
|
public float Bleeding
|
||||||
{
|
{
|
||||||
get { return bleeding; }
|
get { return bleeding; }
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
if (!MathUtils.IsValid(value)) return;
|
if (!MathUtils.IsValid(value)) return;
|
||||||
if (GameMain.Client != null) return;
|
if (GameMain.Client != null) return;
|
||||||
if (!DoesBleed) return;
|
if (!DoesBleed) return;
|
||||||
|
|
||||||
float newBleeding = MathHelper.Clamp(value, 0.0f, 5.0f);
|
float newBleeding = MathHelper.Clamp(value, 0.0f, 5.0f);
|
||||||
if (newBleeding == bleeding) return;
|
if (newBleeding == bleeding) return;
|
||||||
|
|
||||||
bleeding = newBleeding;
|
bleeding = newBleeding;
|
||||||
|
|
||||||
if (GameMain.Server != null)
|
if (GameMain.Server != null)
|
||||||
GameMain.Server.CreateEntityEvent(this, new object[] { NetEntityEvent.Type.Status });
|
GameMain.Server.CreateEntityEvent(this, new object[] { NetEntityEvent.Type.Status });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public HuskInfection huskInfection;
|
public HuskInfection huskInfection;
|
||||||
public float HuskInfectionState
|
public float HuskInfectionState
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
return huskInfection == null ? 0.0f : huskInfection.IncubationTimer;
|
return huskInfection == null ? 0.0f : huskInfection.IncubationTimer;
|
||||||
}
|
}
|
||||||
set
|
set
|
||||||
{
|
{
|
||||||
if (ConfigPath != humanConfigFile) return;
|
if (ConfigPath != humanConfigFile) return;
|
||||||
|
|
||||||
if (value <= 0.0f)
|
if (value <= 0.0f)
|
||||||
{
|
{
|
||||||
if (huskInfection != null)
|
if (huskInfection != null)
|
||||||
@@ -449,7 +449,7 @@ namespace Barotrauma
|
|||||||
get;
|
get;
|
||||||
set;
|
set;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Item[] SelectedItems
|
public Item[] SelectedItems
|
||||||
{
|
{
|
||||||
get { return selectedItems; }
|
get { return selectedItems; }
|
||||||
@@ -466,6 +466,12 @@ namespace Barotrauma
|
|||||||
get { return focusedItem; }
|
get { return focusedItem; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Item PickingItem
|
||||||
|
{
|
||||||
|
get;
|
||||||
|
set;
|
||||||
|
}
|
||||||
|
|
||||||
public virtual AIController AIController
|
public virtual AIController AIController
|
||||||
{
|
{
|
||||||
get { return null; }
|
get { return null; }
|
||||||
|
|||||||
@@ -13,7 +13,6 @@ namespace Barotrauma.Items.Components
|
|||||||
|
|
||||||
private float pickTimer;
|
private float pickTimer;
|
||||||
|
|
||||||
|
|
||||||
public List<InvSlotType> AllowedSlots
|
public List<InvSlotType> AllowedSlots
|
||||||
{
|
{
|
||||||
get { return allowedSlots; }
|
get { return allowedSlots; }
|
||||||
@@ -55,13 +54,15 @@ namespace Barotrauma.Items.Components
|
|||||||
public override bool Pick(Character picker)
|
public override bool Pick(Character picker)
|
||||||
{
|
{
|
||||||
//return if someone is already trying to pick the item
|
//return if someone is already trying to pick the item
|
||||||
if (pickTimer>0.0f) return false;
|
if (pickTimer > 0.0f) return false;
|
||||||
if (picker == null || picker.Inventory == null) return false;
|
if (picker == null || picker.Inventory == null) return false;
|
||||||
|
|
||||||
if (PickingTime>0.0f)
|
if (PickingTime > 0.0f)
|
||||||
{
|
{
|
||||||
CoroutineManager.StartCoroutine(WaitForPick(picker, PickingTime));
|
if (picker.PickingItem == null)
|
||||||
|
{
|
||||||
|
CoroutineManager.StartCoroutine(WaitForPick(picker, PickingTime));
|
||||||
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -104,6 +105,8 @@ namespace Barotrauma.Items.Components
|
|||||||
|
|
||||||
private IEnumerable<object> WaitForPick(Character picker, float requiredTime)
|
private IEnumerable<object> WaitForPick(Character picker, float requiredTime)
|
||||||
{
|
{
|
||||||
|
picker.PickingItem = item;
|
||||||
|
|
||||||
var leftHand = picker.AnimController.GetLimb(LimbType.LeftHand);
|
var leftHand = picker.AnimController.GetLimb(LimbType.LeftHand);
|
||||||
var rightHand = picker.AnimController.GetLimb(LimbType.RightHand);
|
var rightHand = picker.AnimController.GetLimb(LimbType.RightHand);
|
||||||
|
|
||||||
@@ -151,7 +154,8 @@ namespace Barotrauma.Items.Components
|
|||||||
private void StopPicking(Character picker)
|
private void StopPicking(Character picker)
|
||||||
{
|
{
|
||||||
picker.AnimController.Anim = AnimController.Animation.None;
|
picker.AnimController.Anim = AnimController.Animation.None;
|
||||||
pickTimer = 0.0f;
|
picker.PickingItem = null;
|
||||||
|
pickTimer = 0.0f;
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void DropConnectedWires(Character character)
|
protected void DropConnectedWires(Character character)
|
||||||
|
|||||||
Reference in New Issue
Block a user