Adjust cleanup after launching from station in lesson 7
This commit is contained in:
parent
27780bdc0f
commit
dae8593131
@ -152,6 +152,7 @@ this.startUp = function()
|
||||
{
|
||||
this._setFrameCallback("");
|
||||
player.ship.setMultiFunctionText("oolite-tutorial",null);
|
||||
this._resetShips(station);
|
||||
}
|
||||
|
||||
|
||||
@ -419,16 +420,21 @@ this.startUp = function()
|
||||
|
||||
}
|
||||
|
||||
this._resetShips = function()
|
||||
// exception parameter used to avoid removing the station the
|
||||
// player is docked with
|
||||
this._resetShips = function(exception)
|
||||
{
|
||||
for (var i=this.$shipList.length-1;i>=0;i--)
|
||||
{
|
||||
if (this.$shipList[i] && this.$shipList[i].isShip)
|
||||
{
|
||||
if (!exception || exception != this.$shipList[i])
|
||||
{
|
||||
this.$shipList[i].remove(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// just in case a role has been defined out by OXP
|
||||
this.$roleFallbacks = {
|
||||
|
Loading…
x
Reference in New Issue
Block a user