Friday, February 24, 2012

Friday Post 4

Today was a groundbreaking day for Trombone Hero. I officially have the trombone working! Using a test run, the trombone performed accurately and fluidly. I wanted to implement a mic to record breath sounds so that you would "blow" into the trombone, but I was having difficulty, so went back to the original plan of adding a button. Today I recorded the backing tracks for the trombone sounds to "Love Me Do".

Next time, I have to work out some potential timing issues with the projector screen and get the music mixed and implemented. After next week, I should be ready for presentation.

Today was a good day.

Friday, February 10, 2012

Friday Post 3

Today I finished up some loose ends on the coding, like getting the blobs to time right, and display different images on successful play or failure to hit a note. I decided to eliminate the average score and average accuracy values from the profile, since I didn't really think it was necessary to do.

On Monday I'm going to work on the controller. I'll be using a brush like metal conductor to get a better connection. I'll also be getting some help with the soldering. This weekend I'll have to get out and get a dremmel tool and some sheet metal.

I didn't follow the normal format because I'm a rebel yo.

Friday, January 27, 2012

Friday Post 1-2

Its a new semester, so now we're having Friday posts.

1. Last Friday was mainly an art day where I did the backgrounds for the title and play screens. I wanted to make a custom GUI, but because I got a new deadline (March 16) so I have to push forward with the more important things. Today I implemented all of my artwork, and wrote the script to generate the blobs. Then I had an issue with the sound and spent a while fixing that, which was a massive waste of time.

2. Next week I have to fix the blob positions so they time right with the recording. I'll also be working on the controller, and possibly recording some music. I want to have 1 song done for my presentation on March 16.

3. The new deadline means heavy prioritizing and a lot more stress to keep working.

Wednesday, December 7, 2011

Wednesday Post 9

1) Today I got the high score functionality in the game, including profile integration and the end of level screen. I also did a title screen. The High scores are flexible so that users can add their own songs if they like; it will automatically include them in the system.

2) Next week is the last of the semester, and there really isn't too much left as far as the skeleton of the game goes. The flow of gamestates is in place and everything SEEMS to be functioning properly. The one tail end from a hard days work today is that I need to calculate the average score and accuracy for the profiles. This should take maybe a half an hour. Next week I may work on my formal DFA for the game.

3) It seems that I made it on schedule, and although the game is basic, all the functionality I wanted in my design document is there. There is a lot of room for features, primarily in stat keeping and profile comparison, but I believe the design of the program is flexible enough to allow such additions if I choose to. Although they are not priorities, I may add them if I get all the graphics and sound implemented, toward the end of next semester.

The only other thing I want to add is possibly a custom GUI and get rid of swing; this would certainly make it prettier and theres a possibility that I could reuse a lot of the listeners/ActionPerformed methods I already have.

Wednesday, November 30, 2011

Wednesday Post 8

1) Lets look at the list I made for last week and see what I got done:

Scoring system
I implemented the scoring system, as described in the design document, but have not been able to test it yet. Next time I will test it with the game pad, which is why it resides in the "verify" column of the scrum board.

Investigation of skinnable swing elements
Custom LAF (look and feels) are surprisingly easy to integrate; just adding them to the classpath and a single call from the UIManager. However, for some reason the custom fonts are not working, so I have to investigate that further, which is now a task on the board.

High Scores/Profile integration
This part I started, but realized that I have no architecture for high scores besides the personal bests saved in the profile; these bests don't make sense either because they do not differentiate between difficulty levels. What I need to do is develop a completely new class that interfaces with the profile to not only record personal bests (on both difficulties) but allow comparison between other profiles and other bests. This will be the focus for next time.

Options Gamestate
I could not think of a single option that is absolutely necessary to the game, so I'm just skipping this for now.

Select level gamestate
I got this part all done except for displaying the personal bests, which is part of the problem from above. That's an easy fix though. Also, I can now select the difficulty levels.

2) Next week, I need to develop a new structure for high scores that make them easy to retrieve, sort, and compare. It will need to integrate with the profile. Along with this will be the end of song gamestate, which basically accumulates game data, calculates score, and reports it to the user and to the high score class.

If I have time, I need to write a python script to assist me in creating the song data files. The overall goal is to have a working example song by the end of the semester, with working profiles and high scores.


3) Nothing today.

Wednesday, November 16, 2011

Wednesday Post 7

1) Today I worked on getting gamepad input to work, which was a lot easier than I thought it would be. I'm using a library called JXInput, which sadly is not cross platform. I went ahead and set up some dummy "slide positions" for my normal gamepad so I could detect successful notes. What I thought would be super difficult really wasn't, and now its just a matter of optimizing the code so that the input is as accurate as possible.

2) As the semester wanes, the goal is to get a lot of the functional elements of the game done, and next semester will be primarily graphics and sound. The main things I need to do are:

Scoring system
Investigation of skinnable swing elements
High Scores/Profile integration
Options Gamestate
Select level gamestate


Over Holiday break I plan to finish up on the controller and get that fully integrated. I believe I can finish up what I have here in the next 4 weeks.

3) At the beginning, when I was switching around with engines, I thought it was a giant waste of time. One good thing that came from it though was I learned how to integrate jar libraries into my classpath and netbeans project, something I had no idea how to do before the engine shuffle. Today, I think this (and a little bit of luck with the documentation) is what I credit the success of JXInput.

Wednesday, November 9, 2011

Wednesday Post 6

1)  Today I made the progress bar, which proved to have its problems with the scaling. I also created a bitmap font class to create and display scalable bitmap fonts.

2)  Next week I'm going to finish up the HUD, then I'll go on to getting joystick input.

3)  Here is the bitmap font code :

package seniorproj;

import java.util.HashMap;
import java.awt.image.*;
import java.awt.*;

public class BitmapFont {

    private HashMap img_list;
    private int cell_size;

    public BitmapFont(int size, Color c){
        img_list=new HashMap();
        cell_size=size;
        //numbers
        for(int xx=48;xx<=57;xx++){
            BufferedImage b = new BufferedImage(size,size*2,BufferedImage.TYPE_INT_ARGB);
            Graphics2D g2 = b.createGraphics();
            g2.setFont(new Font("Arial",0,size));
            g2.setPaint(c);
            g2.drawString(Character.toString((char)xx),size/2,size);
            img_list.put(Character.toString((char)xx),b);
        }
        //uppercase
        for(int xx=65;xx<=90;xx++){
            BufferedImage b = new BufferedImage(size,size*2,BufferedImage.TYPE_INT_ARGB);
            Graphics2D g2 = b.createGraphics();
            g2.setFont(new Font("Arial",0,size));
            g2.setPaint(c);
            g2.drawString(Character.toString((char)xx),size/2,size);
            img_list.put(Character.toString((char)xx),b);
        }
        //lowercase
        for(int xx=97;xx<=122;xx++){
            BufferedImage b = new BufferedImage(size,size*2,BufferedImage.TYPE_INT_ARGB);
            Graphics2D g2 = b.createGraphics();
            g2.setFont(new Font("Arial",0,size));
            g2.setPaint(c);
            g2.drawString(Character.toString((char)xx),size/2,size);
            img_list.put(Character.toString((char)xx),b);
        }


    }

    public void render_string(Graphics2D g2,int x, int y, String str, float rw, float rh){
        for(int xx=0;xx