Removed some dead code.

git-svn-id: http://svn.berlios.de/svnroot/repos/oolite-linux/trunk@4183 127b21dd-08f5-0310-b4b7-95ae10353056
This commit is contained in:
Jens Ayton 2011-01-29 19:21:34 +00:00
parent 0c57476192
commit 10dce944f1
5 changed files with 7 additions and 73 deletions

View File

@ -1003,6 +1003,13 @@ static NSDictionary* instructions(int station_id, Vector coords, float speed, fl
- (void) pullInShipIfPermitted:(ShipEntity *)ship
{
#if 0
/*
Experiment: allow station script to deny physical docking capability.
Doesn't work properly because the collision detection for docking ports
isn't designed to support this, and you can fly past the back and
sometimes straight through.
-- Ahruman 2011-01-29
*/
if (EXPECT_NOT(ship == nil)) return;
JSContext *context = OOJSAcquireContext();

View File

@ -793,38 +793,6 @@ OOINLINE BOOL RowInRange(OOGUIRow row, NSRange range)
}
#if 0
- (BOOL) setBackgroundTexture:(OOTexture *)backgroundTexture
{
// autorelease instead of release here seems to prevent a crash on SDL builds when pausing and unpausing
// with GUI backgrounds installed. TODO: Apply a proper fix, this smells like hack - Nikos 20100519
[backgroundSprite autorelease];
backgroundSprite = nil;
if (backgroundTexture != nil)
{
backgroundSprite = [[OOTextureSprite alloc] initWithTexture:backgroundTexture];
}
return (backgroundSprite != nil);
}
- (BOOL) setForegroundTexture:(OOTexture *)foregroundTexture
{
// autorelease instead of release here seems to prevent a crash on SDL builds when pausing and unpausing
// with GUI backgrounds installed. TODO: Apply a proper fix, this smells like hack - Nikos 20100519
[foregroundSprite autorelease];
foregroundSprite = nil;
if (foregroundTexture != nil)
{
foregroundSprite = [[OOTextureSprite alloc] initWithTexture:foregroundTexture];
}
return (foregroundSprite != nil);
}
#endif
- (void) clearBackground
{
[self setBackgroundTextureDescriptor:nil];

View File

@ -343,14 +343,6 @@ OOINLINE BOOL ValidBindingType(OOShaderUniformType type)
}
}
/* Bad optimization - we need to be able to rebind entities when their
owner changes.
-- Ahruman 2008-04-19
*/
#if 0
if (EXPECT_NOT([value.binding.object weakRefUnderlyingObject] == [(id)target weakRefUnderlyingObject])) return;
#endif
[value.binding.object release];
value.binding.object = [target weakRetain];

View File

@ -190,26 +190,6 @@ MA 02110-1301, USA.
[self setLegalStatus: criminal_tendency + criminal_tendency * (gen_rnd_number() & 0x03) + (gen_rnd_number() & gen_rnd_number() & 0x7f)];
legal_index = 0;
if (legalStatus) legal_index = (legalStatus <= 50) ? 1 : 2;
#if 0
NSString *legalDesc = nil;
// Never used! What was intended? -- Ahruman 2008-11-10
switch (legal_index)
{
case 0:
legalDesc = @"clean";
break;
case 1:
legalDesc = @"an offender";
break;
case 2:
legalDesc = @"a fugitive";
break;
default:
// never should get here
legalDesc = @"an unperson";
}
#endif
// if clean - determine insurance level (if any)
[self setInsuranceCredits:0];

View File

@ -470,20 +470,7 @@ static NSString *NormalModeDescription(OOMeshNormalMode mode)
}
[materials[ti] apply];
#if 0
if (listsReady)
{
OOGL(glCallList(displayList0 + ti));
}
else
{
OOGL(glNewList(displayList0 + ti, GL_COMPILE_AND_EXECUTE));
OOGL(glDrawArrays(GL_TRIANGLES, triangle_range[ti].location, triangle_range[ti].length));
OOGL(glEndList());
}
#else
OOGL(glDrawArrays(GL_TRIANGLES, triangle_range[ti].location, triangle_range[ti].length));
#endif
}
listsReady = YES;