-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Apress
committed
Oct 24, 2016
0 parents
commit 2c6e364
Showing
1,789 changed files
with
171,041 additions
and
0 deletions.
There are no files selected for viewing
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// | ||
// GameCenterAppDelegate.h | ||
// GameCenter | ||
// | ||
// Created by Kyle Richter on 11/14/10. | ||
// Copyright 2010 Dragon Forged Software. All rights reserved. | ||
// | ||
|
||
#import <UIKit/UIKit.h> | ||
|
||
@class UFOViewController; | ||
|
||
@interface UFOAppDelegate : NSObject <UIApplicationDelegate> { | ||
UIWindow *window; | ||
UINavigationController *navController; | ||
} | ||
|
||
@property (nonatomic, strong) IBOutlet UIWindow *window; | ||
@property (nonatomic, strong) IBOutlet UINavigationController *navController; | ||
|
||
@end | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
// | ||
// GameCenterAppDelegate.m | ||
// GameCenter | ||
// | ||
// Created by Kyle Richter on 11/14/10. | ||
// Copyright 2010 Dragon Forged Software. All rights reserved. | ||
// | ||
|
||
#import "UFOAppDelegate.h" | ||
#import "UFOViewController.h" | ||
|
||
@implementation UFOAppDelegate | ||
|
||
@synthesize window; | ||
@synthesize navController; | ||
|
||
|
||
#pragma mark - | ||
#pragma mark Application lifecycle | ||
|
||
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { | ||
|
||
// Override point for customization after application launch. | ||
window.rootViewController = navController; | ||
[window makeKeyAndVisible]; | ||
|
||
return YES; | ||
} | ||
|
||
|
||
#pragma mark - | ||
#pragma mark Memory management | ||
|
||
|
||
|
||
@end |
48 changes: 48 additions & 0 deletions
48
ARC Source Code/UFOs Chapter 1/Classes/UFOGameViewController.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
// | ||
// GameCenterGameViewController.h | ||
// GameCenter | ||
// | ||
// Created by Kyle Richter on 11/14/10. | ||
// Copyright 2010 Dragon Forged Software. All rights reserved. | ||
// | ||
|
||
#import <UIKit/UIKit.h> | ||
#import <CoreMotion/CoreMotion.h> | ||
|
||
|
||
@interface UFOGameViewController : UIViewController <UIAccelerometerDelegate> | ||
{ | ||
float accelerationX; | ||
float accelerationY; | ||
UIAccelerationValue accel[3]; | ||
|
||
BOOL tractorBeamOn; | ||
|
||
IBOutlet UILabel *scoreLabel; | ||
|
||
UIImageView *myPlayerImageView; | ||
UIImageView *currentAbductee; | ||
UIImageView *tractorBeamImageView; | ||
|
||
NSMutableArray *cowArray; | ||
|
||
float movementSpeed; | ||
float accelerometerDamp; | ||
float accelerometer0Angle; | ||
|
||
CMMotionManager *motionManager; | ||
|
||
float score; | ||
} | ||
|
||
@property(nonatomic, strong) CMMotionManager *motionManager; | ||
|
||
|
||
-(void)spawnCow; | ||
-(void)updateCowPaths; | ||
-(void)abductCow:(UIImageView *)cowImageView; | ||
-(void)finishAbducting; | ||
-(void)movePlayer:(float)vertical :(float)horizontal; | ||
-(UIImageView *)hitTest; | ||
|
||
@end |
Oops, something went wrong.