Monday, December 24, 2007

Oy, the Equations

Thank god for Serebii.net. That site has absolutely everything I need to calculate shit out. It has the equations for stats, exp, and everything. So, I will say this. If, and only if (or as my MAT 101 teacher would say, iff), I can find sprites for all 493 (what a god awful number of Pokemon) Pokemon (front and back sprites), I will use all of them in the game. This adds quite some time to the development, but I get a feeling my game will be more popular for it.

New Approach, New Hope

Well, hello peoples of the internet. I'm sure I get, on average, zero readers per month, but that's alright. If anyone does read this, know that I have once again started this project, and I mean to see it through to the end, even if that does take a long time.

The last time I did anything with this game, I was using a windowed screen, and a large image as the background my character and the NPCs moved on. Well, this has changed. After two days of experimentation, I have created a tiled map system that works. It looked to have a lot of tearing, but that was because I was using blocks with hard edges and angles as my map. Well, I replaced them with threes and grass, and the tearing is gone. Well, not gone, but the human eye has trouble seeing it. You can still see the tearing, but you'd have to be looking pretty damn hard, and know what you're looking for.

Right now that is all I have- a tiled map that shows the area immediately around the player (or the center of the screen, actually), and moves smoothly just like the GameBoy games. Also, I have implemented a new structure of programming that I learned for a fantastic book all about game programming in Java.

So, I have a little day trip planned for tomorrow, and I am beat for today (been programming for several hours straight today and yesterday, plus a chopped onion is making keeping my eyes open somewhat painful), but on Wednesday, the programming keeps going. I am going to be putting the main character in at the center of the screen.

I need to fix my arrow key scrolling (a method of keeping it from going haywire is also keeping me from scrolling continuously), and then I start on the character. I need to resize my character images (there are many images). Then I need to import them and store them. After that I need to make it so that I can turn in place (I completely forget how I managed that little gem in my old code). Then I can start. I believe I can readily use a value that determines the movement of the map as the basis for determining when the character takes his steps. But gah, my eyes hurt, and my brain hurts. No more thinking about programming right now.

I still have a story to make. And i am still deciding whether or not I will include the newest Pokemon from the DS games. That will add a certain amount of difficulty. That would mean male and females of Pokemon (which I was planning to do), but also characteristic differences. Plus, I don't know if anybody has yet calculated the stuff like experience gains and stuff. I need that to be well documented if I am going to program it into my game. Whatever.

Food time. Later, peoples.

Monday, October 8, 2007

Thinking things through

Well, I just sat for a while on my bed, thinking about how things are going to be going down in the program. I don't think my old method will work. But, I have a new idea, one I know will work, although it may not give me quite the results I was looking for. I shall give it a try, however. It uses clips to clip a bit out of the overall image, and draw that to the screen. Then every time the player moves, the clip shifts to include the new portion of the image, and draw it to the screen.

I know for a fact that it was drawing the entire image area that was taxing the program. When I did something that caused the program to not draw the image, the character on the screen no longer flickered. It went back to flickering when the image was drawn on the screen once more. So now my objective is to make things work correctly.

I also have many other objectives with this recode. They all include making the game run and look better, of course.

Now I am trying to think of how I shall handle things with the different maps. to counter one issue, I think I might make the array three dimensional. The second Z layer would include the path values for the NPCs. I don't know if one 3d array is better than two 2d arrays, but I think it might be.

I plan on getting food soon, so programming later. I downloaded the beta of Netbeans 6. I'll do all of my work on there from now on. See ya later.

Sunday, October 7, 2007

New stuff

Alright, I have looked intently through my new Java book, and have come up with some new stuff to try to implement. The code is going to be rewritten from scratch, hopefully a little more smoothly than it was last time (an impressive feat, since the last recode went so much better than I ever could have hoped for).

In this recode, I am going to try to take some of the strain off of the GUI aspect of the program. Remember from last time, when I said my last attempt to take the pressure off the GUI was unsuccessful? Well, I think I found at least one of the ares where I messed up, and I know how to fix it in part. The rest I'll fix on the fly.

So, the things that I will cover: I am going to make it so that only the image visible in the screen is drawn. I am also going to do away with the collision array maps. This time, the collisions will get their values from an actual map feature, in which one set of variables of type A can be paired up with a variable from type B. This means that an Image file (the sprite) can be paired with a boolean, dictating whether or not I can walk across.

I think what will end up happening is that I will have two sprite two dimensional arrays for the entire board. One will include the background sprites, like the ground, and what type of terrain is there. The other will lay out things like buildings, and rocks, and people. This will be the array checked by the map.

Unfortunately, as I type, things are falling apart in my head. I cannot quite figure out how some things are going to work. Dammit, I'll just start coding right now, and hopefully, I will be able to figure them out on the fly. Later, people.

Friday, October 5, 2007

Some breakthroughs

I recently picked up a book ( a very large, yet reasonably priced one) all about Java, and the parts of it, and how they work. It is amazing, I tells ya. Already, I think the thing may have saved me thousands upon thousands of lines of tedious code. It is a godsend. I will be using it for quite some time, I think.

I think, when I get back to my dorm room (I am at home right now), I will download the new version of Netbeans onto my computer, and mess around with that for a little bit. Then, when I am comfortable, I will start something of another major rewrite of my code. I will first phase in part of my new idea for shortening the code, and then, bit by bit add other parts of my ideas.

So, I believe I shall have some new, and most interesting stuff to show for my hard work sometime in the next two or three weeks. I do not know how long it will take me to program, but I will be using stuff I have never touched before, so it might take a while to figure it all out.

I have to sort things out in my head right now, and keep them in my head for a few days, until I get back to my room and my computer (I really should have brought it with me, but I thought I needed the break from programming). But, once I have my ideas down somewhere, and I no longer am burdened with having to remember them, I will go through them here, for anyone who reads this to see.

Later, kids.

Wednesday, October 3, 2007

Hello, everyone

I do have a Facebook group for this purpose, but I can probably reach more people out here by doing this. So I'll take a moment to explain what I am doing it, then how I am doing it, and finally, I'll bring everyone up to speed on how much I have done.

I liked the Pokemon Gameboy games. They were fun, and took a long time to finish. Then they just kept on getting better and better. Yellow was my favorite for a while, because my level 100 Pikachu could take out the Elite Four by itself. But then Crystal came out, and I had a new favorite.

About a year ago, I took a computer programming course in my senior year of high school. It was in the Java programming language, and I placed somewhere near the top of my class. I got bored about halfway through, and decided I needed a bigger challenge. I knew there was a way to make a graphical user interface with Java, but I had no idea how to do it. Still, I started some work on the program.

As soon as I hit a wall, I stopped. I regret stopping, but I needed the time to do my other programs for the class. Well, eventually I learned how to make a GUI, and I made some fantastic stuff for my class. Then the year was over, and I was bored.

Over the summer I tried to make a complicated program, and almost finished it. This annoyed me. I decided arbitrarily to restart the Pokemon project. I did what took me weeks to do in a matter of hours, and I was convinced to keep on going with the project. And so here I am.

So, on to what I am doing. What I am trying to do, basically, is make a version of Pokemon for the computer, with whole new story lines, and new locations. I may or may not get around to new Pokemon. Sorry about that, but I am just one person. And I am doing everything by myself.

I am programming the entire thing in Java, and I am making all of the images in Photoshop. Then I shall stick it all together, and let it free over the internet. Perhaps. I still do not know how I am going to distribute this. It has to be free, of course, but I might just only give it to people who want it.

And lastly, here is what I have so far. I have the ways to draw the map (only one right now), the characters, and the background characters. The background characters move around randomly along preassigned paths. I have a collision array set up to make sure I don't go through trees and stuff. And it all looks pretty smooth in its native resolution.

That is currently my only problem. I can resize the game, and everything still works, but it begins to get choppy. I don't know enough about buffering right now to fix that. But I will get around to it, most likely in version two of the game.

I know that this will probably take me a couple of years to finish. That's okay. I need something to fill up my spare time. And I will be very happy when I am all done.

That's all for now. I'm not going to be programming tonight, because I have been doing so nonstop for the past few weeks. I need a break. And I need a break from typing, Jeez.