This is the second post of the series, you can read the introduction of the series in the first post.
Project 13
I will talk about a prototype called “DJ Machine” (Project 13), that I started while Spring Up Harmony (PCX360) was being approved for Xbox Live Indie Games. I was looking for something fun and that could only be done with XNA. I was playing DJ Hero at that time and logically started to create a simple program playing with the turntable (see image below). Nick Gravelyn already did some research on it and this information was very useful to get something working very quickly.
I didn’t want to make a clone of DJ Hero because I could not afford licensing many interesting songs and don’t want to compete with the AAA guys. After a few crazy ideas, I finally came up with the idea of manipulating a machine using the turntable. Each part of the turntable (scratch, buttons, euphoria, fx dial) activates/moves a section of the machine. Some of the inspiration came from a very old game called Night Shift where the player controls a worker that must take care of a machine and quickly becomes overwhelmed by the amount of elements requiring attention.
Screenshots and Video of DJ Machine
Here are a screenshot and a gameplay video of my prototype:
I removed the sounds in the video as I do not own the rights to some of them:
I suppose this requires some explanation. Refer to the image of the turntable while I explain the gameplay for those not familiar with the controller. The player is supposed to build objects using the “DJ Machine”. Of course, it’s still very abstract because of the programmer art.
Square items are coming from the left on the gray path. They stop at the first black square. Here, the player has to scratch with the corresponding button and direction (for example, blue scratch up, green scratch down). There are between one and three scratches to do per item.
When all the scratches for an item are done, the item moves to the next black square on the top right. Here, the player must spin the knob as fast as possible.
The item is then transformed in a shape (yellow circle, blue star or red octagon) that falls down the screen.
The player then controls the dark red claw with the cross fader (if the cross fader is on the left, the claw moves to the left, the player must move the cross fader back to center to stop the claw).
The player must move the claw below the shape items on the right and use the euphoria button to close the claw (keep euphoria button down) and catch the item.
He then moves the item to the corresponding area on the left and drop it by releasing the euphoria button.
There is also a penalty if the player activates elements when not needed. For instance, if he scratches when there is nothing in the top left section of the machine, the machine gets stucked and can’t be used for a few seconds.
You can also see the crosses on the top left (one is red, two are white on the screenshot). They represent the errors made by the player. After three errors, the game stops.
On the right, there is, from top to bottom the time, the score and the number of objects succesfully made. If the player drops an item when not on the proper location with the claw, the object is lost.
That’s basically it. The game was supposed to be played in short sessions where items come faster and faster.
I also planned another game mode where the player first choses between different music styles (techno, rap, funk…) and then scratches and mixes with proper sound samples on an abstract background. I named this game mode Freestyle DJ. Here is a gameplay video:
Sadly, without sound, it’s not very exciting but it is actually working pretty well. There is two short music loops that the player could mix with the cross fader, scratches play sound effects and fx dial speeds up/slows down the music.
The graphics in the background are made from Spring Up Harmony’s algorithm.
Design Document (notes)
Here is a copy of my design notes. I just translated the bits in french and added comments in blue. It’s in chronological order, it means that ideas on top have no connections with “DJ Machine” prototype and were discarded:
Byala 80 pts (a game (strange) name with a price: I think I made a mistake by pricing Spring Up Harmony at 240 pts at the beginning, so I precised very early I’d put the next one at 80 )
Musical Arts (other idea : just playing music with nice backgrounds : not really a game, but gave birth to the freestyle game mode)
Platform game playable with turntable (first game idea: platform game (inspiration: Donkey Kong Country (LINK) that is playable with drums))
Playable with guitar? drums?
Original rendering : squares, blobs, glow (Inspiration: the Sony PS3 dashboard but I finally used Spring Up Harmony’s algorithm as a starting base)
Night Shift (from here, I’m going toward the design described above, citing my main inspiration)
A cube comes to a platform, after 1 to 3 scratches, it goes in step 2, after fx dial, it goes in step 3. Movement with XFader, player has to make the cube fall in the right hole with euphoria (this is the sentence that resumes it all )
Show a message to the player if he’s playing with a pad.
Classic “Freestyle DJ” game mode
Choices betwee left/right handed and buttons on the left/right (same as in DJ Hero)
Different difficulty levels: Tutorial, Easy, Medium, Hard, Expert and Hardcore
Game over because of three errors or machine full if player does not play fast enough
Restrictions of the free version: Only 4 difficulty levels out of 6, DJ Machine sessions only 3 minutes long, Freestyle DJ sessions only 1 minute long.
Here is a early prototype screenshot I used to set up of the gameplay:
Why I didn’t complete it, and thoughts
I started this project mostly for fun, to try to see how was working the turntable. I hesitated to complete and release it on XBLIG. I didn’t, because:
The market share is very small. According to numbers (DJ Hero, DJ Hero 2 and consoles) I could find, I estimate between 1.5 and 3% of xbox players have turntables (probably many DJ Hero 2 players also own DJ Hero 1). Also, XBL Indie Games are approved by other developers and you need multiple votes by creators to get your game on XBox Live. Therefore, I would need actual XBLIG developers to have turntables (well, that’s not entirely true as the game would be playable with only a pad too, but they would not fully test the game and might not want to try it). I already had to remove french support in Spring Up Harmony because I could not find two or three french-speaking developers. I honestly think there are more developers speaking french than developers with a working DJ Hero turntable.
Gameplay variety is very low. People might argue that DJ Hero also have few variety, but it’s of course in the musics and leaderboards that the players find variety even if the gameplay is roughly always the same. In DJ Machine, only speed brought variety.
However, now that the DJ Hero series will not be completed (LINK), DJ Hero players might love to be able to use their turntables again.
Today, I still don’t plan to work on this prototype again, but who knows.
Feel free to comment and share ideas and talk about your unfinished projects in the comments section.
You can also follow me on twitter or facebook.
The development of Spring Up XNA has been going pretty well last week.
Here is a new video, please note that it is still not the final art, just placeholders for now :
You can see the following:
New ways of using the physics engine in the levels (joints, gravity…)
Small improvements on the background : slight halo around targets, bloom reacting to matches, especially when hitting sparkling balls (the sparkling balls are part of a modification of gameplay from Spring Up PC/Mac. I will talk about it later. This is also the reason I cropped the borders of the video ).
New particle effects (code in place, art also not final)
These days, I also implemented the sound effects (I just recoded the wavs available in the original version), improved the level editor, added many types of objects (bumpers, shrinkable balls, motors, splines…), added player score with statistics…
Globally, it’s going well, but I am having difficulties in level design. I find it very hard to innovate in each level but I still have a few interesting level prototypes in place.
Box2D is a 2D physics engine created by Erin Catto. On Win/Mac, I used a very early version of Box2D (it was released nearly two years ago!). I just made a few specific changes for the game. Of course, as I told in a previous article, XNA games must be made in C# and Box2D is made in C++. I could find multiple open-source projects of ports of Box2D in C#. They are based on the last version of the C++ engine and a lot of changes occured since I developed Spring Up!. It means that to use a C# port, I have to adapt a lot of my physics code. But this is a good thing for the following reasons:
I will have the new version of the engine : there are probably some debug and optimisations.
New features : can be used to improve the game
Lots of C# code already written, I won’t have to port it myself.
Among the two or three C# ports available, I decided to go with Box2D.XNA. This port is written by Brandon and Nathan Furtwangler and they are doing a very good job! They are very active: when I fixed them a bug, they put it back in the code base in less than a day and they port the changes of the C++ version very quickly.
Compared to the old C++ engine I was using previously, the new version has been greatly improved, here are some examples:
Dynamic/Static/Kinetic types are included on bodies, no need to play with infinite mass directly.
Collision filtering is now included in the API. I developed my own system in Spring Up! but throw it away in C#.
Motors are included. I also developed basic motors myself in C++.
More joints types: only one type was available.
Collision detection includes polygons, not just only circles and rectangles.
As I’m still working with the level editor, I started to include new features in Spring Up! Here is a simple video showing a new possibility made with Box2D.XNA (showing motors, complex shapes, joints and collision detection).
As you can see, the gameplay does not seem that interesting in this sample but it’s just made to test the dynamics for now. I will concentrate on level design later and I am sure I will face a lot of difficulties.
In conclusion, if you need 2D physics in your game, use Box2D, and if it’s for XNA, use the Box2D.XNA port!
I am mostly working on the level editor. I was not sure when I started this project that I would need a specific level editor. But Spring Up! X360 needs some serious changes in the level design to improve the quality and to adapt to the X360 platform, therefore I need this new level editor. Working on tools with C# is great : it’s really powerful and efficient! Technically speaking, the level editor is just a Game Component (DrawableGameComponent XNA class) of the Game. When the “Editor” component is created, all the new mouse and keyboard shortcuts are available.
As you can see in the video, here are some features implemented: create, move, rotate and delete items and targets. You can set up objects as static, dynamic or with a motor. There is also a snap feature. And as the game is running at the same time, you can play directly in the editor.
You can also see some of the new shapes that will be available in Spring Up! XNA : a triangle and pentagon.
I spend some time trying to create an interesting visual effect in the background of Spring Up! XNA. The backgrounds of the PC/Mac versions are not really nice. I tried to do something more abstract and animated depending on the flow of the game. GeometryWars 1 and 2 did a very good job at that. While trying to develop an effect, I came up with many different results. I uploaded a video of one of this effect (you can see it in full res here).
Of course, feedback is very much welcomed (negative, positive, ideas…).
I personally have some concerns about a few things:
Black background, is it too simple?
When background is colorful, I think the player might not see the “real game” because it attracts the eye.
Colors are a bit too much “programmer art”. I made also some black and white tries that were nice too.
I have many variables available to tune this effect and each one of them really changes the final result. Basically, the algorithm here is a grid of particles that are animated and lit depending on the velocity and position of the moving elements around them.
I will also probably add thin trails behind objects. For boxes, I will try to attach multiple trails to every corner.
I also have a bloom effect I did for fun before starting this project, I might try to add it in Spring Up!, probably on the trails, maybe on the background too.