Picking items from outside the sub, replcaed fabricator.png with separate sprites for each machine, descriptions moved from itemprefab to the mapentityprefab base class, editortutorial progress
This commit is contained in:
@@ -9,7 +9,7 @@ namespace Barotrauma
|
||||
{
|
||||
private Camera cam;
|
||||
|
||||
private GUIComponent GUIpanel;
|
||||
public GUIComponent GUIpanel;
|
||||
|
||||
private GUIComponent[] GUItabs;
|
||||
private int selectedTab;
|
||||
@@ -21,11 +21,18 @@ namespace Barotrauma
|
||||
|
||||
private bool characterMode;
|
||||
|
||||
private Tutorials.EditorTutorial tutorial;
|
||||
|
||||
public Camera Cam
|
||||
{
|
||||
get { return cam; }
|
||||
}
|
||||
|
||||
public int SelectedTab
|
||||
{
|
||||
get { return selectedTab; }
|
||||
}
|
||||
|
||||
//public string GetSubName()
|
||||
//{
|
||||
// return ((Submarine.Loaded == null) ? "" : Submarine.Loaded.Name);
|
||||
@@ -125,10 +132,9 @@ namespace Barotrauma
|
||||
null, frame);
|
||||
textBlock.Padding = new Vector4(5.0f, 0.0f, 5.0f, 0.0f);
|
||||
|
||||
ItemPrefab ip = ep as ItemPrefab;
|
||||
if (ip != null && !string.IsNullOrWhiteSpace(ip.Description))
|
||||
if (!string.IsNullOrWhiteSpace(ep.Description))
|
||||
{
|
||||
textBlock.ToolTip = ip.Description;
|
||||
textBlock.ToolTip = ep.Description;
|
||||
}
|
||||
|
||||
if (ep.sprite != null)
|
||||
@@ -163,6 +169,13 @@ namespace Barotrauma
|
||||
|
||||
}
|
||||
|
||||
public void StartTutorial()
|
||||
{
|
||||
tutorial = new Tutorials.EditorTutorial("EditorTutorial");
|
||||
|
||||
CoroutineManager.StartCoroutine(tutorial.UpdateState());
|
||||
}
|
||||
|
||||
public override void Select()
|
||||
{
|
||||
base.Select();
|
||||
@@ -302,6 +315,7 @@ namespace Barotrauma
|
||||
/// <param name="gameTime">Provides a snapshot of timing values.</param>
|
||||
public override void Update(double deltaTime)
|
||||
{
|
||||
if (tutorial!=null) tutorial.Update((float)deltaTime);
|
||||
|
||||
if (GUIComponent.MouseOn == null)
|
||||
{
|
||||
@@ -420,6 +434,8 @@ namespace Barotrauma
|
||||
MapEntity.Edit(spriteBatch, cam);
|
||||
}
|
||||
|
||||
if (tutorial != null) tutorial.Draw(spriteBatch);
|
||||
|
||||
GUI.Draw((float)deltaTime, spriteBatch, cam);
|
||||
|
||||
if (!PlayerInput.LeftButtonDown()) Inventory.draggingItem = null;
|
||||
|
||||
Reference in New Issue
Block a user