Skip to content

Commit

Permalink
First commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Apress committed Oct 24, 2016
0 parents commit 2c6e364
Show file tree
Hide file tree
Showing 1,789 changed files with 171,041 additions and 0 deletions.
Binary file added ARC Source Code/UFOs Chapter 1/Art Assets/Cow1.png
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.
Binary file added ARC Source Code/UFOs Chapter 1/Art Assets/Cow2.png
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.
Binary file added ARC Source Code/UFOs Chapter 1/Art Assets/Cow3.png
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.
Binary file added ARC Source Code/UFOs Chapter 1/Art Assets/Tractor1.png
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.
Binary file added ARC Source Code/UFOs Chapter 1/Art Assets/UFO.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
22 changes: 22 additions & 0 deletions ARC Source Code/UFOs Chapter 1/Classes/UFOAppDelegate.h
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

36 changes: 36 additions & 0 deletions ARC Source Code/UFOs Chapter 1/Classes/UFOAppDelegate.m
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 ARC Source Code/UFOs Chapter 1/Classes/UFOGameViewController.h
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

0 comments on commit 2c6e364

Please sign in to comment.