Archive for December, 2011

super simple level editor

December 13th, 2011 No comments

Phil and I were talking about level editing, and how to load them, and I realized that I already made a very primitive level editor in processing as well as a simple obj-C method to load those files. The file format assumes that you want to populate an array and that the array contains only zeros, each line of the level file looks like this scheme:


so you find in each line where in X and Y space to put the ID.

So here is the processing project:fleeItLevelEditor.pde and the method to load those files looks somewhat like this:

-(void) makeLevel:(int) level{
  int levelMap[100][100];
  int i,j;
  NSString *S=[[NSString alloc] initWithContentsOfFile:[[NSBundle mainBundle] pathForResource:[NSString stringWithFormat:@"Level_%i",level] ofType:@"txt"] encoding:NSASCIIStringEncoding error:NULL];
  NSArray *T=[S componentsSeparatedByString:@"\n"];
  for(NSString *L in T){
    NSArray *E = [L componentsSeparatedByString:@" "];
    int x,y,w;
    x=[[E objectAtIndex:0] intValue];
    y=[[E objectAtIndex:1] intValue];
    w=[[E objectAtIndex:2] intValue];
    NSLog(@"set element at pos:%i y:%i to:%i",x,y,w);

Cheers Arend


Categories: Uncategorized Tags:

Lecture 27 and 28

December 13th, 2011 No comments

The last two lectures, about finalizing and promoting your games, and contemplations about future endeavors, also the twitter example,

the lecture 27:Lecture 27 the pdf file:Lecture 27

the lecture 28:Lecture 28 the pdf file: Lecture 28

and the project :TweenTest

Cheers Arend


Categories: Uncategorized Tags:

Lecture 24 and 25

December 3rd, 2011 No comments

Since Lecture 24 was a Q&A session and a brief intro to a game, I add 24 to this one.

Please fill out this form: until 16th of December and next week we will do the feedback forms I got from the department.

We will also have a new Tutorium/Workshop on Sunday 4th 1.30 again at the BEACON center, just gather around 1.30 at one of the entrances of BPS and I will pick you up,

here is lecture 25:Lecture 26 the pdf:Lecture 26 and the example:showCG

Cheers Arend


Categories: Uncategorized Tags: