Fixed SequenceEditor dependencies and lockup due to water crates being spawned on maps without water.
This commit is contained in:
@@ -43,7 +43,7 @@ namespace OpenRa.Traits
|
||||
{
|
||||
var inWater = self.World.SharedRandom.NextDouble() < info.WaterChance;
|
||||
var umt = inWater ? UnitMovementType.Float : UnitMovementType.Wheel;
|
||||
|
||||
int count = 0, threshold = 100;
|
||||
for (; ; )
|
||||
{
|
||||
var p = new int2(self.World.SharedRandom.Next(0, 127), self.World.SharedRandom.Next(0, 127));
|
||||
@@ -53,6 +53,8 @@ namespace OpenRa.Traits
|
||||
w => crates.Add(w.CreateActor("crate", p, self.Owner)));
|
||||
break;
|
||||
}
|
||||
if (count++ > threshold)
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -31,10 +31,6 @@
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Reference Include="IjwFramework, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\Ijw.DirectX\bin\IjwFramework.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="System" />
|
||||
<Reference Include="System.Core">
|
||||
<RequiredTargetFramework>3.5</RequiredTargetFramework>
|
||||
|
||||
@@ -4,7 +4,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using System.Drawing;
|
||||
using IjwFramework.Types;
|
||||
using OpenRa.FileFormats;
|
||||
|
||||
namespace SequenceEditor
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user