1 Replies - 200 Views - Last Post: 24 April 2013 - 07:30 PM Rate Topic: -----

#1 lifeinbinary  Icon User is offline

  • D.I.C Head

Reputation: 3
  • View blog
  • Posts: 158
  • Joined: 15-February 11

Objective-C build errors after an Xcode update.

Posted 24 April 2013 - 06:03 PM

I've just performed an update to xcode (automatic update that pops up from time to time). I tried running my game having made a few minor changes, and suddenly i'm getting build errors saying that my classes don't exist! None of them! The build errors happen at the @property declarations ex:

#import <Foundation/Foundation.h>
#import "cocos2d.h"
#import "Territory.h"
#import "Player.h"
#import "Dice.h"


@interface GameState : NSObject
{
    

}

typedef enum {
    SelectingTerritories,
    ReinforcingTerritories,
    AllocatingCommanders,
    AllocatingMilitaryBase,
    PlayingYears,
}GamePhase;

typedef enum{
    TurnOrderBidding,
    PlayingTurns
}YearPhase;

typedef enum {
    CollectingIMCs,
    CollectingArmies,
    DeployingArmies,
    BuyingCommanders,
    BuyingMilitaryBases,
    DeployingCommanders,
    DeployingMilitaryBases,
    BuyingCommandCards,
    PlayingCommandCards,
    InvadingTerritories,
    Fortifying
}TurnPhase;

typedef enum {
    ChoosingAttackingCountry,
    ChoosingDefendingCountry,
    Attacking
}InvadePhase;

-(id)init;


@property (retain, nonatomic) NSMutableArray *players;
@property (retain, nonatomic) NSMutableArray *turnBids, *turnOrder;
@property (retain, nonatomic) NSArray *territories;

@property (retain, nonatomic) Player *currentPlayer; // GETTING ERROR HERE - "Unknown type name Player"

@property (nonatomic) GamePhase gamePhase;
@property (nonatomic) YearPhase yearPhase;
@property (nonatomic) TurnPhase turnPhase;
@property (nonatomic) InvadePhase invadePhase;

@property (retain, nonatomic) Territory *attackingTerritory, *defendingTerritory; // AND HERE "Unknown type name Territory"

@property (nonatomic) int territoriesLeftToAllocate, numAtkDice, numDfdDice, atkLost, dfdLost, totalArmiesToAllocate, totalCommandersToAllocate, totalBasesToAllocate,currentYear,currentPlayerNum, numberField;

@property (retain,nonatomic) Dice *dice;




@end



When I remove these line from here... the same errors happen in the next .h file it tries to build! It's like all my Classes don't exist! I may sound dramatic but I'm having a nervous breakdown right now! Please help and tell me what's going on! Please!

Sam

This post has been edited by Atli: 24 April 2013 - 06:13 PM
Reason for edit:: Title updated to better reflect the question being asked. Please avoid using phrases like "Please help" in your titles.


Is This A Good Question/Topic? 0
  • +

Replies To: Objective-C build errors after an Xcode update.

#2 lifeinbinary  Icon User is offline

  • D.I.C Head

Reputation: 3
  • View blog
  • Posts: 158
  • Joined: 15-February 11

Re: Objective-C build errors after an Xcode update.

Posted 24 April 2013 - 07:30 PM

Well... It wasn't anything to do with the xcode update. Thank god I use GIT! I discarded all my modifications since my last commit (last night thank god!) and it now works :))))))))

I don't know what I did to make these classes not be visible but I must have done something wrong! What could have been the cause of this? Any ideas?

Gratefully relieved,
Sam
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1