Duece of All Trades
Blog of the Duece of All Trades, Jack of None. All about starting projects, continuing projects, and an interjection of random thoughts.
Jump Roping with Vivi
My next new project has been determined. In playing Final Fantasy 9 for my wife, I decided to start a side file to get everything. For this file I’m using an Emulator, just so I can have Save-State capabilities (save anywhere at anytime). I got to the first ‘mini-game’ of FF9, which is a jump roping competition.
You control your character as some girls swing a jump rope for you, and the more jumps you get the better the prize. It starts out easy enough, with about 1 jump a second, then after 20 jumps increases to 3 every 2 seconds. At 200 the beat changes to a heartbeat rhythm: J.J…J.J…J.J… And the best prize is when you get 1000 jumps.
My idea was just to use a macro program, plug in the timing, and let it go at it, with some minor adjustments due to bad estimations. However, sadly this is not the case. I’m using AutoHotkey, and I have a pretty basic script:
$space::
;Return to previous SaveState
SendInput {F3 down}
Sleep 50
SendInput {F3 up}
Sleep 5000
;Get into position
Loop 2
{
SendInput {s down} ;s is the accept button on my emulator
Sleep 50
SendInput {s up}
Sleep 3000
}
;First 20 jumps
Loop 20
{
SendInput {s down}
Sleep 50
SendInput {s up}
Sleep 735
}
return
Unfortunately, while waiting 735 milliseconds nails that first jump, it is way to long to make the second jump. The second jump requires waiting 710ms, the third 682, 4th: 651 etc. I set up some variables as counters to decrease this time more and more as it goes on. The 8th jump requires the same length of time as the 7th, and the 9th requires a bit more time than the 8th. I’m still working on the 10th, trying to figure out if it needs more or less time than the 9th. And here I thought this macro would be easy.
This is where my project idea comes in. Instead of me working each number, I’ll let a simple program do it for me. Here’s the basic setup of that program:
Start
Check if In-Process file exists
If so
Load values
If not
Set default values
Write macro code to file
Prompt user to run test
Read in from user how many jumps were successful
Increase the number of times the first unsuccessful jump was unsuccessful
Randomize the wait time for the first unsuccessful jump
This will use a Gaussian Randomization and the width based on number of fails
Repeat from Writing macro code
If user prompts, write an In-Process file
End
Why the In-Process file? It will make it easier to edit certain key areas where the timing changes dramatically. This way the computer will work on one jump at a time, and should do a better job estimating each one than I can. So let me stop yapping about it and actually program it!
The first Critical Point
Most of my failures occur when I come across a critical point, where everything seems to be going wrong, the end result doesn’t appeal to me, and there is a much easier interest waiting for me.
In this case, it was the misspelling of my blog! I had done a lot of research to make sure that the proper domain names were available, as well as space on Wordpress, Tumblr, and Twitter. And it was all for “Duece” instead of “Deuce”. When I realized my mistake at 1am last night, that very well could have been the end of it. Especially since I was told that others have already taken the idea of Deuce of All Trades. However, luck and foresight saved this blog from just fading into non-existence in the following ways:
- First, The entire point of this blog is about acknowledging how often I fail, and trying hard to pass through the tough points, and not being ashamed of letting myself be exposed.
- Secondly, the deuceofall domain name is still available, and I should be buying it soon. Also, wordpress and tumblr still have my name open.
The first one is what really carried it, because I had decided to take a look anyways, and if everything did fail, I could always think of a new way to make it work, and overcome the impassable barriers.
I also want to mention, that I’m seriously considering moving to WordPress. I’ve had some blogs on there before (that I no longer pay attention to), and its system is quite nice. Tumblr, while new and spiffy, seems nice, but just doesn’t have the functionality that I want for the real site. I’m experimenting now with possibly moving my posts over smoothly.
"This is our Lego NXT Robot: The Archer. Not the prettiest machine on the runway, and I was calling it a mongrel until we got the sensors up and working properly (it was quite honestly agoraphobic). But to see the end result working as originally planned - amazing! Thanks to Tom for uploading the video."
I’ve just been followed by Jentian, and after taking a quick look at her blog got addicted myself. She’s a student at Aukland University of Technology, and her blog is about her adventures whilst obtaining a Bachelor of Creative Technologies. Her posts are fun and descriptive, and usually contain video as in the post above. The quote included is her posting the video of her groups robot finding its way to the admin office! The start of this robots life began at this post on a creative new chess piece.
PS, finished getting code to work right:
pre {border: solid 1px #000055;
font-size: 75%;
line-height: 95%;
color: #E46060;
margin: 10px;
padding:10px;
background: #EEEEEE}FFXII - Finale
Well, I pushed through and finally made it through the game… That was painful. But where did it go wrong?
Main Character -
First off, who’s the main character? We go through a few controllable characters before we get control of the first character that will persist to the end of the game, Vaan. And he’s whiny and useless. We’re told to feel sorry for him (note I’ll talk about the telling not showing later). Then he’s joined by another character Penelo, who’s the token bossy girl in children shows. They go around a bit, doing useless tasks that don’t have anything to do with anything, and will soon be forgotten. Finally Vaan sneaks into a place and steals a magic stone, but his escape is interrupted by a pair of Sky Pirates:
Oh! So here’s the main character, he even has the wit to tell us so we know. Unfortunately, this is all the real character development we get for a long time, and these two are the most fleshed out of all the characters. Eventually we add a fallen princess and a framed guard into the mix, but as much as the story tells us it’s about Ashe, the princess, it still focus’ on Balthier and Vaan.
The problem here, is that while we were playing with Vaan and Penelo, the antics were childlike, granted they are children, but not enjoyable. When the rest of the party shows up, they are adults, and act like it, and have adult problems. Adult problems like an impending war (Ashe et al), dealing with species prejudices & being kicked out of your home (Fran), and having an insane and controlling father (Balthier). Unfortunately, the children stick around with the real characters through the rest of the game. There is no growth from them, it is not a story of them maturing. Instead, through the entire game, the feeling one gets from them is the same feeling as going to the grocery store, and one of your companions brought their young child. It’s just annoyed babysitting.
Finally, the characters at the end of the game are no different from who they were at the beginning, no growth in any way.
Graphics -
I’m sorry, the graphics are the same as the online FF, FFXI. Which were terrible. FFXI was worse in almost every way then most of the Free to Play MMO’s out there. I couldn’t stand the graphics and when I saw FFXII had them still, I was sorely tempted to not pick it up. Granted there’s a lot of detail that went into the scenery, but it didn’t make it look better, just grainy. Some locations that you get to at the end of the game are prime examples. A large pier in the middle of an ocean, if you sat and looked at one part it looked amazing. As background, however, it was too cluttered, and didn’t make me want to stop and look at it. Everything had detailing, little curvy lines running all around in various patterns, including the doors to the slums. Why would someone put in a year of work on making this hugely innate door for places that have no money?
Story telling -
As I said, this game tells, not shows. We’re told that the kids are orphans and we should feel sorry for them. Now Naruto of Anime fame has similar past history troubles, but we learn he’s parent-less, and hate his original antics, but by the end of the first episode, we see his pain and truly start to get interested in him. Vaan, however, has no feelings, and shows nothing. His antics are just childlike and he never learns. So of course we feel nothing for him. The same goes for almost all of the other characters. In fact, the only characters that we get shown anything instead of told is Balthier due to his constant wit, and Fran who actually shows us very rarely how she feels about being forsaken by the forest.
Secondly, the actual story. I’m not even sure what that story is. Apparently due to the bad guy, the main character’s home kingdom was overthrown and war is about to break out, and the bad guy is on the verge of taking over the world. The princess of the fallen kingdom must save the world. In order to do this, we have to wander all over hunting ancient technology. In doing so, the time between plot takes so long, that you tend to forget what’s going on, or where you are supposed to be going. In fact, if you take a break for a week, it’ll take an hour or two with a walk through to figure out what part of the game you were at. My wife, who only saw the last 3-4 hours, which happened to be the most exciting and captivating part, was thoroughly bored, and confused by how bad the script was.
Script -
Everyone in this game talks in some sort of accent and script that at best is hard to understand, and the subtitles miss a lot of words. Further, most of the actors perform some very wooden voice roles. Worse of all is the children (who are in their teens), who are just annoying. The only enjoyable bits are Balthier, whose wit makes the small parts of plot enjoyable, and at the very end, one line from the bad guy. We finally get to the final boss, and he turns to us and says “Who are you?” Let’s be honest, we NEVER run into him, he’s off manipulating the world into war so he could take over, while we spend the whole game on the ground in various dungeons. It’s not like we thwart any of his other plans, so he get’s no warning when we show up. Unfortunately, after that line, he starts dribbling on like he knows who we are. Alas, can’t have any fun in this game.
Music -
Now the music wasn’t that bad. Definitely not memorable. I can’t honestly remember any of the music, including the opening or closing. However the best part of it, is that it wasn’t obnoxious. Granted it wasn’t memorable, but it stayed right where it belonged, in the background. Did it do a good job of showing the mood? Well better than the script did.
Reviews -
So I ended up looking FFXII up on Wikipedia, and to my surprise, FFXII got really good reviews. The lowest ranking was 9 out of 10 from the many sources. And the ones who had something bad to say, said about the music. Somehow they got it completely backwards compared to my review. To be honest, this game was the second to last plug in the tub, preventing me from buying FFXIII (the last being the huge price of a PS3). At the end, I feel the Final Fantasy series plateau’d between 6-9 and has been going downhill since. If I ever get the chance to play 13 I will, but I can’t have any hopes. Especially since 14 is another MMO, which I feel has no place in the Series.
Let’s see if Square Enix can pick up again, or will it just be lost?
FFXII
On a less pedantic note, I started finishing FFXII again. Final Fantasy 12 is by far one of the hardest games for me to get through. Our forced main character makes Tidus from Final Fantasy 10 look cool (which is extremely difficult), and the game lacks any sort of reasonable character development.
I first got the game when it came out… got to just outside Archades, and ended up stopping. Years later I went back in, had no idea what was going on, and restarted (oh the pain), and got a bit further until I couldn’t stand it anymore and set it aside. So today I put it back in, and as I was loading the game, I had a serious doubt on whether I beat the game and my save file was right before the final boss, or if I was still in the middle of the game. That doubt scared me, as I was sure that if I did beat it, I couldn’t remember a thing about the end, which seemed particularly fitting for the game.
Turns out I was just in the middle. I seem to remember thinking that I was nearing the end and doing some last minute side quests, but based on the walkthrough I’m using (to help me remember which parts are supposed to be important), it seems like I still have a long ways to go.
Though in good news, I finally got the airship in this game… unfortunately it’s like FFX and FFX2 where you can’t actually fly it, just choose destinations.
The only thing keeping me interested in this game, is that once I beat it, I can store it on the shelf and never have to think about it again… I envy my childhood when Squenix (my play on Square Enix) was good.
Game Creation: Backstepping
I’m going to discuss one of my favorite puzzle creation techniques: Backstepping. There are two forms of this, ie Puzzle Growth & Solution Growth.
Puzzle Growth
This technique is best used on puzzles where the solution is easily created, much like a Sudoku game. The random creation of a completed sudoku board is an extremely easy process, that for a computer takes less than a blink of an eye. So the issue here is creating a challenging initial setup that has only one solution (the one already figured out). The algorithm for doing so is fairly simple. The first step is to randomly select a cell that still has a number in it, and remove it. Secondly, a solver needs to be run to insure that there is only one solution. If there are more than one solution, then that cell needs to have that number in it, so a different cell is chosen. If there is still just one solution, then a different cell is chosen to repeat the process. When the puzzle gets to the point that nothing can be removed without breaking the game, then that will be the initial state of the puzzle to present.
There are a few dissatisfying aspects to this basic concept. First of all, this doesn’t give an accurate difficulty rating for the puzzle. For example, imagine a basic Mah Jong game (matching tiles) where the goal is to, instead of clearing all the tiles, get to a specific pair and clear those, and have all the remaining tiles beyond those add to the score. In this case, the Puzzle Growth would start with a clear board, insert a pair of tiles randomly on the board such that they don’t block an empty space (IE, _ _ _ _ -> _ 1 _ 1 -> 2 1 2 1 is insolvable). This would build up until all the tiles are placed. Unfortunately the goal tiles might end up being immediately matchable.
This problem can be solved by using a more robust solver. In the Mah Jong game, the solver could record how many steps it takes to get the goal tiles to match, and each additional tile pair would get 3 choices, the one leading to the larger walk to the goal being preferable. In the Sudoku game it requires using Human Strategy.
The Human Strategy Solver
In the Sudoku case, a basic brute force solver will always work and always work fast. However, it only shows that there *is* a solution, not how hard it would be for a human to reach that goal. So using a Human Strategy Solver would be the preferable case. A Human Strategy Solver solves the puzzle emulating how a human would. For Sudoku, one of the basic strategies is to look at all of a given number and see if that number can only exist in one spot in a block/row/or column. The HSS would rate this level of solution with a low difficulty value. More technical strategies, like the X-Wing and Swordfish strategies would return a larger difficulty value. When it runs, it tries all of the lowest strategies first, before trying a higher strategy, and once it finds something with a higher strategy, jumps back down to the lower ones instead of continuing with the highers. This way, the solver can provide the shortest, least complicated path to the solution, and give an accurate report on the number of difficult strategies needed. This report determines what level the puzzle is presented as.
With an HSS created for the puzzle type, it can also be used in the Puzzle Growth technique. As mentioned before, instead of just removing one part and checking, multiple positions can be removed and the one that leads closer to the proper difficulty rating can be chosen.
Solution Growth
This technique is not used on a pre-existing solution, but to create the solution in the first place. Consider the connections game, where for each color, there are two pumps that need to be connected, and all the available space on the board needs to be filled. However, the creation of the solution is very difficult. So instead of randomly choosing a spot and a connection type, a more complicated technique is required. In this case, let’s consider Solution Growth using the Connections game as a guide. First start with a grid of nothing but walls. Insert randomly pairs of pumps (such that they are right next to each other and connecting). Now cycle: Randomly choose a pump, and move it into one of the walls, leaving a connecting pipe behind. Remove all connecting pipes and run the solver. If there is no solution, or too many solutions, then undo the move, and move elsewhere. What this means is, that we start with a trivial solution, and we grow it into a more interesting solution. When the solution is found, in this case, we can just remove the connecting pipes, and present that as a puzzle. No need to grow the puzzle as well. Likewise, the HSS works wonderfully here as well, presenting the easiest set of strategies to solve the mid-solution, allowing the Grower to make things more complicated.
Conclusion
Now, this technique of starting at the finish (or with an empty slate), and letting the puzzle grow from that will not always work. For example think of the Solitaire game Klondike. The solution is easy, 4 piles of ordered cards, but trying to grow the initial state on that would be almost imponderable. In addition, Klondike games are not guaranteed to have exactly one solution, or any solution at all. So in this case, a simple randomization of the cards and a layout is easily accomplished, without the hassle. However in purely logic stepping puzzles (like Sudoku and Connections), this technique works wonders.
On a personal note, I seem to have fallen in love with this technique, as it is the first technique I turn to. Perhaps because the first step is to create a good solver before working on the puzzle creation aspect, and I do love programming solvers!
Stylishly Dumb Revelations
In Ragnarok Online, each character sprite has an associated palette. What this means is, that for each pixel in the image, instead of having a color, it instead points to a specific cell in a color table. Thus, if you take the image and point it to a different color table, you end up with the same image except with different colors. The following two images are an example of this:
![]()
These are the same image, but they are attached to different color tables, one specifying a row of colors being purple, the other green. Now this opens up endless coloring possibilities, and all a server needs to do to add those colors is to add an additional palette on the server, and link to it in game.
Currently, the best tool I’ve found in editing these palettes is Photoshop, however that is far from perfect. For the palette, there are 32 rows of 8 cells. Each row corresponds to a different location on the characters image. In the previous example, there is a single row consisting of 8 colors that defined the major color of the robe (either purple or green). Each row ranges from the brightest highlight to the darkest shadow, allowing shadowing effects to carry over from one color scheme to the next.
Now, choosing the 8 colors for an area is the tricky part. To show this, I’ll display the charts representing the Red/Green/Blue colors in the previous examples:

In the Purple chart (to the left), you may notice the lines of the three colors are almost perfectly straight. This leads to a fabric-y feel, whereas the Green chart (to the right) has much curvier lines. The curvy lines tend to create sharper contrasts between the levels of shadows. In these cases, when looking at the images, the purple cape looks like a more natural fabric, and the green cape looks like polyester or nylon or such.
So, when choosing colors, not only must the basic color be chosen, but an idea of the material being colored should be in mind. Consider the following:
![]()

In both cases the brightest color (#1) and the darkest color (#8) are the same, but the way to get from one to the other differs. The straight lines become a more believable fabric, while the curved lines look better on metallic surfaces.
Working in Photoshop, when viewing a color, you get a 3 dimensional view of where that color lies in the color space. IE the ‘X’ value could be Red, the ‘Y’ value could be Green, and the ‘Z’ value could be Blue. (I say could be, because it actually works in Hue/Saturation/Luminosity, but don’t worry about that here). So to construct a curve through the 8 points in a color row, it would curve to various degrees in all 3 dimensions. I had wanted to make a website that could take this 3D curve, and allow the user to pull on a specific color until they get it where they want it. Unfortunately, the Physics and Computer Science behind designing such a model is very highly complex.
This brings me to the dumb revelation… Why not just use the charts like the ones I have here to allow the user to control the curves of the three components?
Connections Clone
Let me preface this by saying that tumblr’s post editing isn’t quite up to the variety I want. It gives me an option to view the html, but every time I do, it undoes my changes.
Oh well, on with the post. Today I got a good chunk done on my Connections Solver. The Connections game is featured at Core Concepts occasionally. The idea of the game is to connect the two Pumps of the same color together, while making sure every other tile on the board is filled with a pipe.
In creating a clone of this game, I am starting out with a solver. The idea is that I’ll start with a board full of blocks, and randomly put in pairs of pumps. Then, I’ll move one of the pumps in the direction of a block, leaving a pipe behind. Then, I’ll treat that as a finished game and see if my solver can solve it. If not, I’ll undo that move and try a different one. If so, then I’ll choose a random pump and repeat. Note, that my solver will solve in a logical (as opposed to a brute force) method, so that if a solution is found, then it is guaranteed to be a unique one.
Following is my code so far on this solver. Hopefully it won’t be completely atrocious looking in tumblr.
Listen While You Work
Well, it’s time to get to work again. I’m trying to catch up to Webcomics Weekly, a hilarious podcast talking about Webcomics. More importantly, they are very motivating, and have a lot of information that can be applied across the board, not just webcomics. The four hosts: Dave Kellett, Scott Kurtz, Kris Straub, and Brad “Wigwam” Guigar are very knowledgeable about their field, and building business online. Now, of course, not every piece of information can be applicable to every aspect of every field, but the majority of their information works for all. At this point, most of the listeners don’t even care if they stay on the webcomics topic, due to how fun they are to listen to. In that same vein, it’s very motivating to have that podcast playing while you draw or do other similar work.
This is just what I’m doing now!
the Hatter is my Hat-Material collecting Sniper from LuminaRO. Tonight I transed him into a High Archer, and finally into a Sniper. Of course his color scheme is slightly influenced by Johnny Depps’ performance as the Mad Hatter in the new Alice in Wonderland.
In LuminaRO, there’s a number of custom headgear quests available. One of my previous characters started as the headgear collector, but as a Dancer, wasn’t able to solo in most of the needed areas. For some strange reason, I have a need to have just one character do all the collecting. I could be crazy!
I’ve been working on the Hatter for a few days now, and finally completed his Pre-Transcendant levels by hunting Anolians. Soon, I’ll be on my way to hunting headgears and being cool~
Though, got to get my priorities straight… The first thing this character needs is a top hat.
