Created
January 18, 2014 19:24
-
-
Save pbrewczynski/8494986 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
- (IBAction)historyUISliderValueChanged:(id)sender { | |
float sliderValue = ((UISlider *)sender).value; | |
NSUInteger sizeOfHistory = self.game.historyOfActions.count; | |
NSUInteger index = floor(sliderValue * sizeOfHistory); | |
NSLog(@"index %d" ,index); | |
NSLog(@"%@ index: %d ", self.game.historyOfActions[index], index); // Problem when historyOfActions is empty! | |
//NSLog(@"Value : %f self.game.lastActionDescription %@ ", ((UISlider *)sender).value, | |
// self.game.historyOfActions); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment