Spectating, fire, damaged limb sprites, water detector, engineer jumpsuit, new signal comp sprites, resharper cleanup (god knows what else, commit more often)

This commit is contained in:
Regalis
2015-11-10 22:22:26 +02:00
parent cd48d12be6
commit 4d949e3be1
89 changed files with 977 additions and 622 deletions
@@ -7,7 +7,7 @@ namespace Barotrauma.Items.Components
{
class Holdable : Pickable
{
//the position(s) in the item that the character grabs
//the position(s) in the item that the Character grabs
protected Vector2[] handlePos;
private List<RelatedItem> prevRequiredItems;
@@ -24,7 +24,7 @@ namespace Barotrauma.Items.Components
private bool attachable, attached, attachedByDefault;
private PhysicsBody body;
//the angle in which the character holds the item
//the angle in which the Character holds the item
protected float holdAngle;
[HasDefaultValue(false, true)]
@@ -115,13 +115,11 @@ namespace Barotrauma.Items.Components
AnimController ac = picker.AnimController;
Limb rightHand = ac.GetLimb(LimbType.RightHand);
if (!hitting)
{
if (picker.IsKeyDown(InputType.Aim))
{
hitPos = (float)System.Math.Min(hitPos+deltaTime*5.0f, MathHelper.Pi*0.7f);
hitPos = Math.Min(hitPos+deltaTime*5.0f, MathHelper.Pi*0.7f);
ac.HoldItem(deltaTime, item, handlePos, new Vector2(0.6f, -0.1f), new Vector2(-0.3f, 0.2f), false, hitPos);
}
@@ -104,7 +104,7 @@ namespace Barotrauma.Items.Components
if (character == null) return false;
if (!character.IsKeyDown(InputType.Aim)) return false;
//if (DoesUseFail(character)) return false;
//if (DoesUseFail(Character)) return false;
IsActive = true;
@@ -181,7 +181,7 @@ namespace Barotrauma.Items.Components
//ApplyStatusEffects(ActionType.OnUse, 1.0f, null, targ);
}
//if (character.SecondaryKeyDown.State)
//if (Character.SecondaryKeyDown.State)
//{
// IPropertyObject propertyObject = targetBody.UserData as IPropertyObject;
// if (propertyObject!=null) ApplyStatusEffects(ActionType.OnUse, 1.0f, item.SimPosition, propertyObject);
@@ -30,18 +30,18 @@ namespace Barotrauma.Items.Components
if (character == null) return false;
if (!character.IsKeyDown(InputType.Aim) || throwing) return false;
//Vector2 diff = Vector2.Normalize(character.CursorPosition - character.AnimController.RefLimb.Position);
//Vector2 diff = Vector2.Normalize(Character.CursorPosition - Character.AnimController.RefLimb.Position);
//if (character.SelectedItems[1]==item)
//if (Character.SelectedItems[1]==item)
//{
// Limb leftHand = character.AnimController.GetLimb(LimbType.LeftHand);
// Limb leftHand = Character.AnimController.GetLimb(LimbType.LeftHand);
// leftHand.body.ApplyLinearImpulse(diff * 20.0f);
// leftHand.Disabled = true;
//}
//if (character.SelectedItems[0] == item)
//if (Character.SelectedItems[0] == item)
//{
// Limb rightHand = character.AnimController.GetLimb(LimbType.RightHand);
// Limb rightHand = Character.AnimController.GetLimb(LimbType.RightHand);
// rightHand.body.ApplyLinearImpulse(diff * 20.0f);
// rightHand.Disabled = true;
//}