(69f7a4d52) Fixed: Index out of range error in DoctorTutorial if proceeding too fast to the submarine. Added: Prevention of tooltip drawing when tutorial content is running
This commit is contained in:
@@ -471,6 +471,8 @@ namespace Barotrauma
|
||||
|
||||
public static void DrawToolTip(SpriteBatch spriteBatch, string toolTip, Rectangle targetElement)
|
||||
{
|
||||
if (Tutorials.Tutorial.ContentRunning) return;
|
||||
|
||||
int width = (int)(400 * GUI.Scale);
|
||||
int height = (int)(18 * GUI.Scale);
|
||||
Point padding = new Point((int)(20 * GUI.Scale), (int)(7 * GUI.Scale));
|
||||
|
||||
@@ -369,7 +369,7 @@ namespace Barotrauma.Tutorials
|
||||
|
||||
double subEnterTime = Timing.TotalTime;
|
||||
|
||||
bool[] patientCalledHelp = new bool[] { false, false, false };
|
||||
bool[] patientCalledHelp = new bool[] { false, false, false, false, false, false };
|
||||
while (subPatients.Any(p => p.Vitality < p.MaxVitality * 0.9f && !p.IsDead))
|
||||
{
|
||||
for (int i = 0; i < subPatients.Count; i++)
|
||||
|
||||
@@ -405,6 +405,7 @@ namespace Barotrauma.Tutorials
|
||||
private void ReplaySegmentVideo(TutorialSegment segment)
|
||||
{
|
||||
if (ContentRunning) return;
|
||||
Inventory.draggingItem = null;
|
||||
ContentRunning = true;
|
||||
LoadVideo(segment);
|
||||
//videoPlayer.LoadContent(playableContentPath, new VideoPlayer.VideoSettings(segment.VideoContent), new VideoPlayer.TextSettings(segment.VideoContent), segment.Id, true, callback: () => ContentRunning = false);
|
||||
|
||||
Reference in New Issue
Block a user