Last active
December 11, 2015 06:08
-
-
Save LearnCocos2D/4557102 to your computer and use it in GitHub Desktop.
Scrolling tilemap API from KoboldTouch. It covers practically every need: scrolling to or by position or tile coordinate. Moving with speed, duration or instantly. Check out KoboldTouch at: http://www.koboldtouch.com
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
/** Scrolls to the coordinate (in points) instantly. */ | |
-(void) scrollToPosition:(CGPoint)position; | |
/** Scrolls to a tile coordinate instantly. */ | |
-(void) scrollToTileCoordinate:(CGPoint)tileCoord; | |
/** Scrolls by a certain distance (in points) instantly. */ | |
-(void) scrollByPointOffset:(CGPoint)pointOffset; | |
/** Scrolls by a certain distance (in tile coordinates) instantly. */ | |
-(void) scrollByTileOffset:(CGPoint)tileOffset; | |
/** Scrolls to the coordinate (in points) with a given duration (in seconds). */ | |
-(void) scrollToPosition:(CGPoint)position duration:(float)duration; | |
/** Scrolls to a tile coordinate with the given duration (in seconds). */ | |
-(void) scrollToTileCoordinate:(CGPoint)tileCoord duration:(float)duration; | |
/** Scrolls to the coordinate (in points) with a given speed (in points per frame). */ | |
-(void) scrollToPosition:(CGPoint)position speed:(float)speed; | |
/** Scrolls to a tile coordinate with the given speed (in points per frame). */ | |
-(void) scrollToTileCoordinate:(CGPoint)tileCoord speed:(float)speed; | |
/** Scrolls by a certain distance (in points) with the given duration (in seconds). */ | |
-(void) scrollByPointOffset:(CGPoint)pointOffset duration:(float)duration; | |
/** Scrolls by a certain distance (in tile coordinates) with the given duration (in seconds). */ | |
-(void) scrollByTileOffset:(CGPoint)tileOffset duration:(float)duration; | |
/** Scrolls by a certain distance (in points) with a given speed (in points per frame). */ | |
-(void) scrollByPointOffset:(CGPoint)pointOffset speed:(float)speed; | |
/** Scrolls by a certain distance (in tile coordinates) with a given speed (in points per frame). */ | |
-(void) scrollByTileOffset:(CGPoint)tileOffset speed:(float)speed; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment