Archive for the ‘Ace Attorney Online Converter’ Category

Hiatus over, more development on the way

Tuesday, December 21st, 2010

Where I’ve been

So I took November off to create an “important work of literary fiction”, as part of the National Novel Writing Month initiative. Ok, so it was a trash sci-fi novel. As if the world needs another one of them, right? It was a blast, and I did manage to meet my word count. Now that I am starting to recover from the insanity of trying to write 50,000 words of creative goodness in such a short amount of time, I am going to be getting back into PyWright stuff!

The engine itself

I continue to assert that the engine is “mostly done(tm)”. There are some definite shortcomings which I want to close before I stamp a big old 1.0 on it. The last release, 0.980, broke a lot of games because it started using an international Phoenix Wright font file, instead of the screenshot character set directly from the game. This was to enable users to choose their own font files, as well as support multiple languages. Well, the font file had different spaces encoded in it than the image file did, so it stretched out the text, and ruined carefully aligned work such as Turnabout Substitution. This is the biggest bug in 0.980. Other bugs include: valid resolutions not appearing on the list, and some dissapearing arrow problems. I need to squash these things down before I add anything new.

Some new things I am thinking about are better expressions, reconfigurable controls, better (faster) 3d, and some more builtin stuff to help aai type games be easier to make.

AAO Convert

I’ll be including an early version of the aao converter soon. It is still missing a lot of things, I’m sure, but working on it alone and trying to track down all the issues will take an infinite amount of time I think. Each time I work on it I make a large step of progress, but it’s a hard project to keep momentum with. Still, it’s really close now. The slowest part of the conversion process is downloading all of the audio and graphics, but fortunately it only has to do this step for new art and music.

Hopefully there will be some new stuff ready when/if the court-records.net forums ever come back online!

AAO conversion – revealing anew the complexities of phoenix wright

Thursday, October 28th, 2010

It continues to amaze me how complex these systems (Phoenix Wright emulators) can be. Each one is trying very hard to reverse engineer the original games and make something that can replicate the experience in a pleasing way. There are also concerns about how well people can actually use the systems to realize their vision for a fan case, as well as how far off the beaten track you are able to go in terms of new features that weren’t in the original games. Though every developer who has embarked on a journey to create a Phoenix Wright engine has had the exact same template to work from, the amount of ways to approach the problem are many.

As I write a converter from Ace Attorney Online to PyWright, I am surprised at how often an assumption I made was wrong. Just today I realized that the code I was outputting for cross examinations was missing a lot of things. The cursory job I had done with them before seemed to work for my first test, and I left it alone for a while. But it turns out my simple test was the only accurate cross exam converted. A lot of the code it outputs needed to be reversed – it was putting the failure message right after the statements, causing it to show the failure every time. Also, the labels for certain situations were in the wrong places, and the counciler messages were tricky to get just right as well.

In the process, I even found one area of AAO I can improve on. The “RetourCI” command in AAO appears after a failure message, such as presenting the wrong evidence, or pressing a statement without text defined. (I think in AAO you HAVE to have text defined in order to press, no?) Anyway, the argument passed to RetourCI seems to always be the first line of a cross examination. I could be wrong, but this means that in all AAO games, if you present the wrong evidence, it will restart the cross exam from the begining, instead of continuing the next statement. Correct me if I’m wrong, but I couldn’t find any controls to make RetourCI go to the next statement. But when I convert, I can easily translate “RetourCI” into “resume” which is the PyWright command for exactly that behavior. It might be something unas could add in the future :)

Anyway, my point is, even though the general idea behind a Phoenix Wright engine is very simple; when you start getting into details it’s astounding how much hidden complexity there is, and how many different ways there are to approach those problems. I discovered this when I first wrote PyWright, but I am discovering it even more, as I explore someone else’s ideas and approaches.

I think writing another zelda engine would have been easier :)

Anyway, I think I am approaching the home stretch with the AAO converter. Barring any real showstoppers, it should be ready in a week (along with PyWright 0.977, knock on wood). Also, it is tuned for aao v5, but when unas upgrades he often updates all of the games automatically. A good way to ensure your game will be able to be converted, even when he switches to v6, is to make a backup. You can do this by opening your game in play mode, in aao, and then saving the web page html. In firefox, you can do this by file->save page as->web page, complete. Make a folder for it to keep it tidy.

Ace Attorney Online has expressions!?

Thursday, March 18th, 2010

I am officially impressed. I have not been that up to date with AAO. I’ve played a few games here and there, but I was too focused on my own engine to really pay attention to how other great developers have approached this domain. I knew that AAO was basically an editor, and that it used javascript somehow to play the cases. But I didn’t realize how advanced it really is. It would be a mistake to write it off just because it is focused on an editor instead of having a full scripting language.

Anyway, the feature that kind of floored me today, is one of the last features I have to implement in order to convert games from AAO to PyWright with 99% accuracy. (I say 99%, as that last 1% of compatibility may or may not be there – it’s hard to know without testing every single AAO game in existence) This feature is expressions. Expressions in AAO allow a developer to have almost a mini scripting engine, interacting with variables and doing math on them. You can increment variables with “set x = x + 1″, you can do booleans with & and |, and you can do very complex math such as the “%” operator. It also follows the general order of operations like most programming languages with expressions engines do. Not what I expected from an easy-to-use, true casemaker.

PyWright has no expression engine. (more…)

0.960 and some other stuff

Friday, March 12th, 2010

To coincide with Turnabout Substitution’s third demo release (congrats to Ping’ and his team for all of their hard work!) PyWright has received a minor version bump. It is almost exclusively fixing bugs related to Turnabout Substitution and how far that game pushes the engine; although most of the fixes are generic problems anyone could run into.

The binaries on the download page have been updated to 0.960, or you can update by going to the download section from PyWright’s main screen. If you update from the engine, don’t forget to close and restart the engine after the update.

Note: If you have a version of PyWright prior to 0.95, you may have been confused when I said 0.95 was out, as your engine didn’t automatically update to it. I might not have made this clear, but 0.95 uses new binaries, so the only way to update is to download the full package again. If you haven’t updated PyWright yet, and are still using beta 10.94, head there and grab the shiny new 0.960.

Some other changes in 0.960 are related to the Ace Attorney Online converter. For those paying attention, I put a version of DramaticaXIV2’s hilarious AAO case, Ace Attorney Online: The Game, on PyWright’s game download section. It’s still very buggy, but mostly works. Download it and play around, if you dare.

I already have a load of new fixes for 0.970 planned, most of which are related to the scary 0.95 in which I allowed feature creep to roll me over. I added so many things I was bound to leave bugs and irritations in my wake! There are also some things which AAO games need, such as the password control, in order to be more accurately converted, so that kind of stuff will be there as well.

Finally, I am working on the test game which was supposed to come out closer to 0.95’s release, but isn’t out yet. It will have some examples of how to emulate AAI in PyWright, as well as demonstrate how to use all of the new features. Note that, emulating AAI is not going to be that close to the real game at this time. Version 2.0 may be able to handle it better, but for now it’s just an emulation. If you want true AAI support, pwlib is probably going to be a better choice, if version 1.2 of that ever comes out.

Yep so that’s my progress in a nutshell. 2.0 is still on the shelf, looking at me forlornly with it’s extreme features, but I am not ready to tame the beast. I hope that somewhere I will find a good way to transition smoothly into that.

Gif 2 Strip, AAO converter soon

Friday, January 8th, 2010

Hey all. I have been working slowly but steadily on the Ace Attorney Online converter. One issue I ran into, was that all of the graphics (or most of them) are GIF files, and GIF files in PyWright often need some extra work to make them compatible. I thought of fixing GIF support for PyWright – I don’t even know how possible that would be, without actually writing my own GIF loader. The bugs have to do with bugs in the libraries I am using. I may work on that eventually, but at the moment my time is better spent elsewhere.

To that end, here is the first version of the gif2strip program. It is currently a webservice, as it requires a few external programs making it a bit difficult to package. You just put a url of some gif file, and it will spit out a .png and a .txt that is ready for PyWright use. The AAO converter will run all of the gif files through there, making sure games have working sprites!

You can find the gif2strip program here:

http://pywright.dawnsoft.org/gif2strip/index.cgi

It’s not fancy but it does the job, and partially solves the issue with porting art, as gif files seem to be the easiest way for most artists to create animations.

Some progress on documentation has been made. The chapter on adding and removing objects from the scene has been posted. I would have to strap myself to the chair and have Franciska whip me to finish it in a timely fashion, but it will get done.

Finally, I am submitting a game for the TIGsource assemblee competition. The game uses the core of pywright beta 11, and I have been updating that as my game sees fit. It’s a very action packed shooter, with awesome 3d effects, and hundreds of sprites on screen. It doesn’t use wrightscript unfortunately, I couldn’t find a nice way to integrate that which wouldn’t slow me down too much. But the core is getting a nice set of optimizations and features. After the deadline, which is in a few days, I am going to get back to the wrightscript engine, and see if I can’t make some progress. I’m not into new year resolutions, but beta 11 this year? I hope so :)