Board index » Present Evidence » Games

Page 1 of 1[ 7 posts ]
 


Making a Case MakerTopic%20Title

Gender: Male

Location: Lithuania

Rank: Suspect

Joined: Sat Oct 30, 2010 10:08 am

Posts: 3

Hi all,
I'm a hobbyist programmer and I somehow decided that I should try to make a case maker. However I am having some problems.

Firstly, I've noticed that some sprites (GUI elements) are missing in the "Media" section. For example, the continue arrow or the text box. What should I do about that? Should I draw (maybe cut from screen shots?) my own, or is there a richer gallery of sprites somewhere?

Secondly, while I am (temporarily) unable to find/write a library to properly load animated GIFs, I tried to load animations from a sheet. Apparently, gaps between frames are not uniform? Should I ask the user of my case maker to specify the coordinates of every frame in every animation? Or maybe loading from a sheet is not a required function?

Also, what form would be best for a case maker? I was considering a C++ API (since that hasn't been done, right?). Would a scripting language be better?

I'll surely post more questions here when I have any.
Thank you for your answers in advance.
Re: Making a Case MakerTopic%20Title
User avatar

Gender: Male

Rank: Prosecutor

Joined: Thu Mar 06, 2008 8:36 pm

Posts: 770

Hi, welcome to the wonderful world of casemaker-making :)

Yeah, you have stumbled on some of the very annoying issues that plague engine developers. Animated gifs are a really annoying format, but that is the best format the content is available in. I used python for my casemaker, and there were no animated gif libraries, so I had to resort to a converter that takes animated gifs and produces uniform-spaced sprite sheets. I used gifsicle. This could be done as part of the game when it loads a gif, if cross platform support isn't a concern. Another way (which you mentioned) is to have a text file which describes where the frames are, but this would take a lot of work to make for all the sprites. You could require the users to do this work.

You could also piggyback from some of the work that I did and use the sprite sheets and gif converter that PyWright uses. This might save some time. They consist of a sheet with uniform spaced frames, and a text file describing the size and layout of the frames.

You could also use some of the art that comes with PyWright that is missing from the archive. Also, henke needed some stuff for his flash case engine, you might ask him where he found any additional materials.

As for what form, we already have PyWright and pwlib with their own non-standard scripting languages, so something different might be interesting. The problem is most case authors are either programmers like yourself, who are interested in making their own engine rather than using someone elses; or they have very little programming knowledge. Also, the linear nature of phoenix wright makes a "script" concept feel natural.

But a c++ api could have scripting added later, and could make a good foundation. It's really up to you, and what would hold your interest to work on.

Good luck!
Creator of PyWright, the lovable case construction system!
Also visit the PyWright post.
Re: Making a Case MakerTopic%20Title

Gender: Male

Location: Lithuania

Rank: Suspect

Joined: Sat Oct 30, 2010 10:08 am

Posts: 3

Quote:
I used python for my casemaker, and there were no animated gif libraries, so I had to resort to a converter that takes animated gifs and produces uniform-spaced sprite sheets.
That's an interesting option. I think I've found a C++ library that can load gif animations though (haven't tried it yet). If that one doesn't work, I might do what you did.

Quote:
You could also piggyback from some of the work that I did and use the sprite sheets and gif converter that PyWright uses.
I could, but that doesn't feel nice. Anyway, I'm more interested in the process of making a casemaker, that the result, so sprites don't really matter much.

Quote:
But a c++ api could have scripting added later, and could make a good foundation.
That's exactly what I'm thinking. Whether I use scripts or not, I still have to write the core functions. Writing a scripting language could be a good exercise though. I once tried to write a programing language, but that didn't go too well. Script would be way easier..
Re: Making a Case MakerTopic%20Title
User avatar

AIGE/PWLib Casemaker Developer

Gender: Male

Location: Brazil

Rank: Ace Attorney

Joined: Sun Mar 09, 2008 3:38 am

Posts: 2731

The hardest part of making a casemaker isn't making the casemaker itself, but make the background engine itself. Once you get the core working, making the casemaker turns into something trivial to make (It work me 5+ tries and ~10 years to get AIGE, PWLib's core, to what it is today).

And considering the nature of how a casemaker works, it is mandatory that the flow is controlled by at least a simple scripting system. Every casemaker uses that principle (thus keeping it simpler to the user, instead of forcing him to use a lower level language and end up hitting the intestines of the underlying engine itself).

In PWLib for example, the approach taken is totally different from other solutions. First, the underlying engine is AIGE (made in pure c++). It exposes a programming language named AHLSL. PWLib is entirely written on AHLSL, thus leaving the complex work to the base engine (and hiding a lot of the render system complex stuff out of the way). So the programmer just uses PWLib as a library while making their code in AHLSL.
Other approaches took the "pw engine" as the core, thus leaving a simpler scripting system.

AHLSL being a more complete language adds to the difficulty, but it is needed because AIGE is not limited to PW development. Unless you target to make something else out of it, then a simpler scripting solution is fine (probably just a single flow system with at most an if/jump system and minimal flags/vars that's easy to make).

Also gifs are a pain, bad solution. I recommend sheets, way better to managed, thus harder to work with (considering the gif loaded directly).

I could help you with something considering I worked on AIGE in C++.
PWLib 1.2 Under Development

PWLib Casemaker (Version 1.1) at http://forums.court-records.net/viewtopic.php?f=36&t=8788
Re: Making a Case MakerTopic%20Title
User avatar

Programmer

Gender: Male

Location: Sweden

Rank: Bug Sweeper

Joined: Sun Mar 22, 2009 3:25 pm

Posts: 832

I am of the opinion that you should have strong enough skills in a language to be able to decide yourself if it is suitable or not. For example, I chose actionscript 3 not because I am an expert at it, but because I knew it would make it easy to do what I wanted, since it takes care of nearly all of the graphical stuff for me.

But I also weighted in the ease of access for the end user. Anyone would go to a website, but few will bother with downloading a special program, installing it and then fetching some cases. Some users drop out at each step, some because it's too hard, some because of laziness and then some just because it was too much of a hassle.

There is also the fact that the market is getting crowded, you need to find something to compete with. pyWright and PWLib offers customization and some rather advanced features. At least one of them has a full asset download service built in. But the true key is not features. It is the userbase and the actual games that you have to offer. Any project will fail if no one wants it. It is the same situation as for operating systems and game consoles, no 3rd party content, no userbase. And similarly, no userbase, no 3rdparty content.
Currently working on a redesign of cr.net itself! Come talk to me about it on Discord!
Re: Making a Case MakerTopic%20Title

Gender: Male

Location: Lithuania

Rank: Suspect

Joined: Sat Oct 30, 2010 10:08 am

Posts: 3

KSA_Tech, I agree that a script would feel natural here, but actually, I think I have a pretty good way to do without this. My casemaker has a kind of LISP-like structure. (Not that I know LISP). Should I elaborate?
While scripts have certain advantages, the ability to compile your own standalone executable is nice too. Also, as saluk said, "something different might be interesting".
Could you tell more about gifs? I mean, using a sheet isn't great too. What do you do about timing?
Thanks for offering help, but I'd rather do this myself.

henke37, it's interesting that you speak of ease of access and competition. Those are no doubt important things, but really I'm just writing a casemaker because it's an interesting thing to write.
Re: Making a Case MakerTopic%20Title
User avatar

AIGE/PWLib Casemaker Developer

Gender: Male

Location: Brazil

Rank: Ace Attorney

Joined: Sun Mar 09, 2008 3:38 am

Posts: 2731

The very reason I made AHLSL was to prevent the .exe recompilation at every bit of change i needed to do on my game flow, aside from the fact it hides a lot of the internal engine's stuff. And that was even before PWLib was created. Also AHLSL allows me to make a code once, then update the exe and the code still works. I can play Damion Shard on PWLib 1.2 without the need that the original author recompiles a new exe with the game. And microupdates on AIGE can be delivered without that need. But that is my opinion about the pros of a language system instead of direct API.

Curiously, when AHLSL was first developed, it looked just like what WrightScript is now: a one flow, one "function" per file scripting system. It is way limited when you start to work with, then I started updating it by adding functions and several other options. Today's AHLSL on AIGE 0.9.800a supports several other features. It evolved due to need, but keeping en eye on BACKWARD COMPATIBILITY (that is very hard to maintain actually). All the work is kinda rewarded when I fix a small bug on AIGE and i'm able to run either the PWLib 1.2 code, or the Strike Witches: Sky Guardians code, or some other test code just with an exe copy.

For AIGE, i used giflib (and no docs) to make AIGE supports gifs directly. The idea is to make giflib load the gif frames, then compose each frame into a sheet (or separated images if you prefer). The delay is stored onto the giflib's resulting structure (took quite a while to get it). Then with the frames and the times, you can make the animation as you wish (in my case, convert the values to a AIGE SAS Animation).
PWLib 1.2 Under Development

PWLib Casemaker (Version 1.1) at http://forums.court-records.net/viewtopic.php?f=36&t=8788
Page 1 of 1 [ 7 posts ] 
 
Display posts from previous:  Sort by  

 Board index » Present Evidence » Games

Who is online
Users browsing this forum: No registered users and 21 guests

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum
Jump to:  
cron
News News Site map Site map SitemapIndex SitemapIndex RSS Feed RSS Feed Channel list Channel list
Powered by phpBB

phpBB SEO