From 3147089b765502695abd0567b3479c45db1cb321 Mon Sep 17 00:00:00 2001 From: Eric Walch Date: Thu, 28 Jun 2012 11:42:00 +0000 Subject: [PATCH] - relocated the shipScoopedOther, so that it fires for any pod, not only for those with content that stay in the hold. - Activated the 'old atmosphere' until we can merge with shady planets, were the new atmosphere does work. git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@5037 127b21dd-08f5-0310-b4b7-95ae10353056 --- src/Core/Entities/OOPlanetEntity.m | 2 +- src/Core/Entities/ShipEntity.m | 5 +---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/src/Core/Entities/OOPlanetEntity.m b/src/Core/Entities/OOPlanetEntity.m index a1d8b839..e2a50c5d 100644 --- a/src/Core/Entities/OOPlanetEntity.m +++ b/src/Core/Entities/OOPlanetEntity.m @@ -26,7 +26,7 @@ MA 02110-1301, USA. #if NEW_PLANETS -#define NEW_ATMOSPHERE 1 +#define NEW_ATMOSPHERE 0 #import "OOPlanetDrawable.h" diff --git a/src/Core/Entities/ShipEntity.m b/src/Core/Entities/ShipEntity.m index 78ecc93a..9d843935 100644 --- a/src/Core/Entities/ShipEntity.m +++ b/src/Core/Entities/ShipEntity.m @@ -10594,13 +10594,10 @@ Vector positionOffsetForShipInRotationToAlignment(ShipEntity* ship, Quaternion q [cargo insertObject:other atIndex:0]; // places most recently scooped object at eject position [other setStatus:STATUS_IN_HOLD]; [other performTumble]; - // Eric: next event is not yet documented on the wiki. Do we need it? or could we place the existing 'shipScoopedOther' from above here, - // after the cargo script has fired and expose type and amount of the cargo object in JS? - // [self doScriptEvent:OOJSID("shipScoopedCargo") withArguments:[NSArray arrayWithObjects:CommodityTypeToString(co_type), [NSNumber numberWithInt:co_amount], nil]]; - [self doScriptEvent:OOJSID("shipScoopedOther") withArgument:other]; [shipAI message:@"CARGO_SCOOPED"]; if (max_cargo && [cargo count] >= [self maxAvailableCargoSpace]) [shipAI message:@"HOLD_FULL"]; } + [self doScriptEvent:OOJSID("shipScoopedOther") withArgument:other]; // always fire, even without commodity. [[other collisionArray] removeObject:self]; // so it can't be scooped twice! [self suppressTargetLost]; [UNIVERSE removeEntity:other];