3ea33fb...bbc4a31
commit bbc4a31aa83572258226f303ab767f8546de64fb Author: Joonas Rikkonen <poe.regalis@gmail.com> Date: Tue Mar 5 13:08:38 2019 +0200 Fixed missing item names in the extra cargo menu. Closes #1218 commit dd18bd163e05e8ba4718c0e98083e50ef0a0157e Author: Joonas Rikkonen <poe.regalis@gmail.com> Date: Tue Mar 5 13:04:54 2019 +0200 Fixed a compiler error in RespawnManager commit 904700eda3e4da5468208bd7553a803e9f41234e Author: Joonas Rikkonen <poe.regalis@gmail.com> Date: Tue Mar 5 12:56:29 2019 +0200 Autorestart/spectating fixes (closes #1219): - The server owner and spectators don't trigger autorestart. - The owner is allowed to spectate even if spectating is disallowed in server settings. - Fixed "play yourself" always toggling to true when a round ends. commit 9710612256875d5a788fb34371ca8ea6dd61b749 Author: ezjamsen <ezjames.fi@gmail.com> Date: Tue Mar 5 10:10:25 2019 +0200 dropped the point at which damage sprites appear slightly.
This commit is contained in:
@@ -430,13 +430,6 @@ namespace Barotrauma
|
||||
}
|
||||
CurrentLocation.SelectedMissionIndex = missionIndex;
|
||||
|
||||
//the destination must be the same as the destination of the mission
|
||||
if (CurrentLocation.SelectedMission != null &&
|
||||
CurrentLocation.SelectedMission.Locations[1] != SelectedLocation)
|
||||
{
|
||||
SelectLocation(CurrentLocation.SelectedMission.Locations[1]);
|
||||
}
|
||||
|
||||
SelectedLocation = location;
|
||||
SelectedConnection = connections.Find(c => c.Locations.Contains(CurrentLocation) && c.Locations.Contains(SelectedLocation));
|
||||
OnLocationSelected?.Invoke(SelectedLocation, SelectedConnection);
|
||||
|
||||
@@ -522,6 +522,10 @@ namespace Barotrauma
|
||||
{
|
||||
maxX = Math.Min(maxX, ruin.Area.X - 100.0f);
|
||||
}
|
||||
else
|
||||
{
|
||||
maxX = Math.Min(maxX, ruin.Area.X - 100.0f);
|
||||
}
|
||||
|
||||
if (entity.IsVisible(worldView)) { visibleEntities.Add(entity); }
|
||||
}
|
||||
@@ -546,6 +550,26 @@ namespace Barotrauma
|
||||
spawnPos.X = (minX + maxX) / 2;
|
||||
}
|
||||
|
||||
if (minX < 0.0f && maxX > Level.Loaded.Size.X)
|
||||
{
|
||||
//no walls found at either side, just use the initial spawnpos and hope for the best
|
||||
}
|
||||
else if (minX < 0)
|
||||
{
|
||||
//no wall found at the left side, spawn to the left from the right-side wall
|
||||
spawnPos.X = maxX - minWidth - 100.0f;
|
||||
}
|
||||
else if (maxX > Level.Loaded.Size.X)
|
||||
{
|
||||
//no wall found at right side, spawn to the right from the left-side wall
|
||||
spawnPos.X = minX + minWidth + 100.0f;
|
||||
}
|
||||
else
|
||||
{
|
||||
//walls found at both sides, use their midpoint
|
||||
spawnPos.X = (minX + maxX) / 2;
|
||||
}
|
||||
|
||||
spawnPos.Y = Math.Min(spawnPos.Y, Level.Loaded.Size.Y - dockedBorders.Height / 2 - 10);
|
||||
return spawnPos - diffFromDockedBorders;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user