Fix index out of bounds exception for off world aircraft.

This commit is contained in:
Matthias Mailänder
2020-05-30 17:40:57 +02:00
committed by Paul Chote
parent 507ce40ad2
commit 607d9b2d5c

View File

@@ -853,6 +853,9 @@ namespace OpenRA
var cell = CellContaining(pos);
var offset = pos - CenterOfCell(cell);
if (!Ramp.Contains(cell))
return new WDist(offset.Z);
var ramp = Ramp[cell];
if (ramp != 0)
{