Online quest mode, fixed bug when swimming from hull to another, monitors with editable text, choosing exe in content package, monster quests, misc bugfixes

This commit is contained in:
Regalis
2015-07-30 18:52:20 +03:00
parent 5d0a453e23
commit c7dd6e55f0
53 changed files with 3477 additions and 219 deletions
@@ -39,12 +39,11 @@ namespace Subsurface.Items.Components
}
}
[HasDefaultValue(10.0f, false), Editable]
public float Capacity
{
get { return capacity; }
set { capacity = Math.Max(value,1.0f); }
set { capacity = Math.Max(value, 1.0f); }
}
[HasDefaultValue(10.0f, false), Editable]
@@ -54,7 +53,7 @@ namespace Subsurface.Items.Components
set
{
if (float.IsNaN(value)) return;
rechargeSpeed = MathHelper.Clamp(rechargeSpeed, 0.0f, maxRechargeSpeed);
rechargeSpeed = MathHelper.Clamp(value, 0.0f, maxRechargeSpeed);
}
}
@@ -196,9 +195,16 @@ namespace Subsurface.Items.Components
spriteBatch.DrawString(GUI.Font, "Recharge rate: " + (rechargeSpeed / maxRechargeSpeed), new Vector2(x + 30, y + 100), Color.White);
if (GUI.DrawButton(spriteBatch, new Rectangle(x + 50, y + 150, 40, 40), "+", true))
rechargeSpeed = Math.Min(rechargeSpeed + 10.0f, maxRechargeSpeed);
{
item.NewComponentEvent(this, true);
rechargeSpeed = Math.Min(rechargeSpeed + 10.0f, maxRechargeSpeed);
}
if (GUI.DrawButton(spriteBatch, new Rectangle(x + 250, y + 150, 40, 40), "-", true))
{
rechargeSpeed = Math.Max(rechargeSpeed - 10.0f, 0.0f);
item.NewComponentEvent(this, true);
}
}
public override void FillNetworkData(Networking.NetworkEventType type, Lidgren.Network.NetOutgoingMessage message)