From PsyHelp
Contents |
How PsyPets Was Made
I get this question, or variations, more than I thought I would, so here's a sort of history of PsyPets! I've always kind of been interested in Psychology, especially how the brain works, and why people are the way they are, human behavior, all that. Not enough to switch majors from Computer Science into Psychology, but enough to poke at things on-line, and ask questions of friends who have switched from Computer Science to Psychology :P
For whatever reason I got to thinking about Psychology one day while talking to Aileen (known in PsyPets as whasit, and also infamous for switching from CS to Psych :) heh). I was thinking that, like there are primary colors, there should be primary traits of human personality. Just like with only red, green, and blue (if you want to talk about light) you can make up any color in the visible spectrum, I should be able to take some basic traits of personality, and combine them in various ways to make up all observable personalities. It turns out other people have thought similar things, and I was able to find out about some theories about it.
Being interesting in programming, this of course would be a fun thing to simulate, so I thought I should code a little something with people that do things based on personality theories. At the time I was learning all about PHP and MySQL, so I decided to mish and mash it all together into a game.
If they were going to be people, or pets, or whatever (I'm not sure how I got to pets exactly), they would need to have some needs fulfilled in order to survive, so I did a little research to remind me how Maslow's Hierarchy went, and started to code. I remembered Maslow's Hierarchy particularly for a few reasons, I would guess... for one, it's very simple and straight forward, meaning it should be relatively easy to code. I'm also a big fan of Occam's Razor, so simple makes me happy in that respect as well. After poking around on-line I was also reminded that, compared to most psychologists of his time, Maslow was a pretty optimistic guy, and for a game with cute little pets that sounded good. Finally, self-actualization is a fantastic excuse for leveling-up, and everyone likes to level up :)
So that's how I started to code, starting with only your house and a pet. I just kind of built from there based on what made sense to me... for example, if a food need is to be met, then you'll have to feed the pet. Add a grocery store, food items, etc. Eventually there was a storage, and pets did things on the hour, etc, etc...
It's all kind of a blur from there :) At first I just had my friends playing, but shortly after I allowed players to create events (it used to be that only I could create events), I advertised PsyPets on a couple game directory sites, and now look at it! A veritable metropolis of PsyPettery!
Or some such :) And that's more or less a story of PsyPets.
I know some HTML and I want to make a game - how do I do it?
I'm a CS major, so programming isn't foreign to me :P Once you learn C or Java, most of the other programming languages out there are very similar, such as PHP, which PsyPets is written in. In fact, PsyPets was my first PHP project... which in some respects is cool, but it also means that lots of the early code is done very amaturishly :P
Besides being a CS major, I've been programming since elementary school, so I've had lots of practice at making a computer do what I want :) I'm not saying you've had to have been programming since you were young, but it does make some things easier in just dealing with computers in general - installing weird programs, knowing how Windows works, etc. There's a lot to know about how a computer does it's computer thing, and the more you know, the easier things will be for you.
Anyway, PHP - definitely - is the thing to learn for making crazy, dynamic web sites. It doesn't take much experience with HTML to realize that the pages you write can't change. Take the "My House" page in PsyPets as an example. The inventory can be sorted and rearranged. You can gain and lose items, mail them to people, put them in storage, etc. That's not something you can do with just HTML. That's where PHP comes in (well, and databases, but let's not worry about those yet :P). There are other languages for doing stuff like this. ASP, JSP... C#, I think, but I haven't really worked dealt with that much.
But you definitely have to know HTML to work with these - PHP is not a replacement! Also, you can't really use DreamWeaver or FrontPage to make a page if you don't know what's going to be on the page :) You have to the write HTML in pieces, and let the PHP code put it all together.
It's a really weird and different way of thinking, which is why programming experience in general is helpful.
If you haven't worked with C or Java, or even BASIC, I'd recommend learning C or Java (but not BASIC :P). for one thing, PHP is very similar to C, so it's easy to learn PHP once you know C. But also, writing C programs is easier to set up on your computer than writing PHP scripts. You can't use PHP on GeoCities or anything - you typically need to pay someone to host a site that supports PHP. Writing C programs is always free :)
I want to learn PHP. How can I do that?
If you already know C or Java, and want to learn PHP, I can recommend a few sites.
First, you need a web host that will run PHP scripts - virtually every paid host will do this.
Another alternative is to set up your own computer as a web server. This is where years of experience at using a computer comes in. You need to feel safe installing programs, and preferrably using the command prompt. Yes, DOS (or Linux, if you swing that way).
I'm not going to go into detail on how to set up your computer as a web server - Google it :) - but I can provide a few links that should get you started:
- If you need a web server, Apache is free, and runs on virtually every OS known to man. Their site also has instructions for setting up PHP to run with Apache, etc (it's not built-in).
- Once you have a web space set up, php.net is the best PHP reference. They even have some tutorials for first-time PHPers. Like this one.
I don't know how to program at all. How can I get started?
Learn C or Java or something similar. You can always find tutorials on-line, but the best way to learn really is to take a class.
If your high school offers AP classes, AP Computer Science is the way to go. You'll even get college credit (if you do well on the AP exam). You can also take college classes. Even if you're not in college, college classes are an option. Back in 9th grade (or maybe it was just before 10th?), when all I knew was BASIC and a pinch of Pascal, I took an Introductory C class at a community college. Just make sure you at least have a good grasp on Algebra - especially if you're thinking about taking a college class while in High School - before taking a Computer Science class. A programming background will also make your life easier, even if it's just BASIC, or the scripting language used by RPG Maker, or the like. If you understand how to do those if...else blocks, some basic loops, and can deal with variables, you should survive an introductory C class just fine.
So: some more links:
- For learning how to write C++, Google will find you many tutorials, like this one.
- If you want to start compiling C/C++ programs on your computer, you'll need to download and install a compiler. You can buy one, such as Microsoft's Visual C++, but Bloodshed Dev-C++ is very good, especially considering that it's free.