about summary refs log tree commit diff stats
path: root/data/maps/daedalus/rooms/Rainbow Purple.txtpb
blob: 1f585ddb0811c7bf964f6be7c4b5d4fb7129daa9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
name: "Rainbow Purple"
panel_display_name: "Rainbow"
panels {
  name: "THEME"
  path: "Panels/Smiley Rooms/purple2"
  clue: "theme"
  answer: "fruit"
  symbols: QUESTION
  display_name: "THEME (Purple)"
}
al.String.Symbol */ .highlight .bp { color: #003388 } /* Name.Builtin.Pseudo */ .highlight .fm { color: #0066bb; font-weight: bold } /* Name.Function.Magic */ .highlight .vc { color: #336699 } /* Name.Variable.Class */ .highlight .vg { color: #dd7700 } /* Name.Variable.Global */ .highlight .vi { color: #3333bb } /* Name.Variable.Instance */ .highlight .vm { color: #336699 } /* Name.Variable.Magic */ .highlight .il { color: #0000DD; font-weight: bold } /* Literal.Number.Integer.Long */
//
//  ValuableObject.m
//  Cart Collect
//
//  Created by Starla Insigna on 8/9/11.
//  Copyright 2011 Four Island. All rights reserved.
//

#import "ValuableObject.h"
#import "GameMode.h"
#import "SimpleAudioEngine.h"

@implementation ValuableObject

- (id)init
{
    self = [super init];
    if (self) {
        // Initialization code here.
    }
    
    return self;
}

- (void)collideWithCart
{
    GameMode* gameLayer = ((GameMode*) sprite.parent);
    [gameLayer setScore:gameLayer.score+self.pointValue];
    
    [[SimpleAudioEngine sharedEngine] playEffect:[[NSBundle mainBundle] pathForResource:@"Item1" ofType:@"wav"]];
}

- (void)collideWithFloor
{
    GameMode* gameLayer = ((GameMode*) sprite.parent);
    [gameLayer setLives:gameLayer.lives-1];
    
    [[SimpleAudioEngine sharedEngine] playEffect:[[NSBundle mainBundle] pathForResource:@"Damage1" ofType:@"wav"]];
}

- (int)pointValue
{
    @throw [NSException exceptionWithName:NSInternalInconsistencyException reason:[NSString stringWithFormat:@"You must override %@ in a subclass", NSStringFromSelector(_cmd)] userInfo:nil];
}

@end