Member

18

### Content Type

#### Developers

I want tohelp play agility ball every day now lol

More elective choosing madness. Seriously guys? Course guide still from the 2010-2011 school year? It would be great if it was all actually up to date so I know what I need to do to get a class. AP 3D Design, what's the prerequisite? Nobody knows because the course description doesn't say, and there isn't any obvious choice on the elective signup sheet. I've ended up emailing Mrs. Dyer to see if she can help, because she's the only one I've ever contacted that actually did anything.

Stupid braces. Stabbing me in the cheek when I yawn. I guess it's time to get the wire cut again.

First day of spring break and no homework? Definitely playing guitar.
5. ## Getting zero with division of two integers?

O ok, thanks guys, that was the problem. I assumed that because I was storing the result as a float that it wouldn't give me an integer result.
6. ## Getting zero with division of two integers?

I am trying to get health bars working correctly based on a ratio of the character's health to his maximum health. At first it works fine when his health is full, the bar is at it's full length. As soon as he has lost some health, the bar goes to zero even though the health value is not at zero. This is what I'm doing, copied directly from my code: IN MAIN GAME CLASS: spriteBatch.Draw(healthBar, new Rectangle((int)bottomGUIPosition.X + 520, (int)bottomGUIPosition.Y + 25, (int)(character.healthRatio * 200), (int)healthBar.Height), Color.White); spriteBatch.Draw(healthBarOutline, new Rectangle((int)bottomGUIPosition.X + 520, (int)bottomGUIPosition.Y + 25, 200, (int)healthBar.Height), Color.White); IN CHARACTER OBJECT CLASS: healthRatio = health / maxHealth; The variable healthRatio is a float, so I have no idea what the problem is. When the health is 145 and the maxHealth is 150, healthRatio should be set to .966667, but instead it goes to zero. The value is being updated in the character object every frame. I realize the code isn't very clean right now as too many things are hard coded in, but its just a prototype I started an hour or so ago, so please excuse the mess. Many thanks to whoever can enlighten me as to the cause of this issue.

Crap, the first thing I managed to do when I picked up my guitar is snap a string... Sweet, now I get to spend 30 minutes putting on new strings again.

Possibility of an mmo based on the Fallout series, sounds interesting.

Is anyone decent with some art program that would be interested in making some game art for a quick little game I'm going to start working on? I might look into porting it over to Android and/or iPhone after I finish a PC version of it depending on its popularity. It'll be a lot of top down, not too terribly detailed stuff.

Don't you just hate those times when your throat tries to choke you while getting a drink?

Insidious was actually a pretty good suspense/thriller or whatever movie, even if it was only PG-13

Apparently if you type graph and then an equation into Google, it will graph it for you.

Just saying it'd be nice to have a relationship where you don't find out in the end you were being led on.

Raining, great. Today is going to be a great day, you can already tell.

I am re-addicted to Kingdom Hearts

I've somehow managed to have an extra copy of Terraria. Anyone want it for $5 instead of the$9.99 it is on Steam right now? You could just give me \$5 on Tuesday or something and then I'll send it to your Steam account.

Whatever you do, do not go see The Devil Inside unless you enjoy major headaches and bad endings. It was decent until about the last 10-20 mins or so and the cameraman COULD NOT hold a camera still if his life depended on it. I had to leave once, and almost left twice because my head hurt so much. The camera trying to auto-focus didn't help either.
18. ## Using Maya for 2D Skeletal Animations, can't find working xml export script?

I'm using Maya for animating the 2D characters in a game I've been working on and I would like to be able to export the keyframe animations and the skeletal systems as some sort of an XML file so that I can read those keyframes in my game and have the game interpolate between them. The issue I've come up against is that I can't find a working exporter script for this. Could someone point me in the right direction, or is there a better method for visually creating these animations? I'm using C# with the XNA 4.0 API for the game and I previously did character animations by hard coding them into the game, but this was way too time consuming and looked horrible in the end anyways. I've heard that Zombieville USA used Maya to animate they're 2D characters, and I've read this page already as well on this, but they apparently used flash, which I don't have and don't have the money to pay for. If its relevant, I'm using the student edition of Maya. Any help would be appreciated.
19. ## Optimizing Procedural 2D Cloud Generation using Pre-drawn Cloud Particles, Any Suggestions?

I'm sorry, I don't understand at all what you mean.
20. ## Optimizing Procedural 2D Cloud Generation using Pre-drawn Cloud Particles, Any Suggestions?

Its not that big of an issue right now, because I don't plan on having 30 clouds on the screen at once but it bothers me that it only takes 30 or so clouds to make my fps drop by about half. There are no more than 20 particles in each cloud, so that's a max of only 600 particles on the screen. Is it just the fact that they are Texture2D objects and these aren't really processed all that fast. Should I try to combine all of the particles in the cloud into a single image representing the cloud before drawing, would that help at all. And even farther, would I just have an image that would hold all of the particles of all the clouds at once and update that every frame that more clouds are added in order to minimize the number of Texture2D objects that have to be drawn? I've also tried doing this with all of the transparency in the images taken out except for the edges because I want them to stay circles, but with no luck. The game ran just as slowly. I've already tried to minimize the number of new objects being created every frame but there are probably still a couple of places that could still be fixed. Here's a recording of what I mean so that you can visualize it correctly: Video And here's a link to the source if it helps: http://dl.dropbox.co...udsQuestion.zip Thanks in advance to anyone that can help me out! Most of the cloud generation code is in the cloud.cs file and there are a few other lines in the TerraCraft.cs file, you can find them easily by using the find tool to search for "cloud generation" as I've put a comment right above those lines with that in it so that they are easy to find. I don't want anyone to feel like I'm asking them to go scouring through my code for the next couple hours to fix this for me, so there it is, that's all that pertains to the clouds.
21. ## Optimizing Procedural 2D Cloud Generation using Pre-drawn Cloud Particles, Any Suggestions?

I haven't messed around much with modifying textures in game so I'm pretty clueless when it comes to that. What would be the most cost efficient way to go about combining multiple Texture2D objects into one while still keeping the positions of the original textures? I've seen the GetData and SetData commands used somewhat but I don't really understand how to use them myself.
22. ## Optimizing Procedural 2D Cloud Generation using Pre-drawn Cloud Particles, Any Suggestions?

Alright thanks for the tips! Now I can see about fixing some of those issues.
23. ## Reflect group of textures representing parts of character over a specified axis?

I have a character that's made up of multiple Texture2D objects. I have all the animations finished for when the character is facing left, and the animations will look exactly the same, but mirrored when he is facing to the right. I'd rather not have to go through all of the mins, maxes, angles, etc and change them accordingly. Would there be an easy way to just flip everything over a given axis vs the middle of the texture as SpriteEffects.FlipHorizontally does it? I've tried to mess with the GetData and SetData methods to figure out how they work in order to combine all of the textures into one and then using SpriteEffects.FlipHorizontally in the SpriteBatch method in order to flip it, but I can't quite get those to work right as I can't find a good example that can easily be changed over to XNA 4.0. All of the good examples I've found are in XNA 3.0 or XNA 3.1. If someone wants to just look at my source in order to help me out then here's a link : http://dl.dropbox.co...raftSource2.zip Thanks in advance to anybody that can help.
24. ## Reflect group of textures representing parts of character over a specified axis?

Alright, so I've gone through setting up when the begin and end spritebatch methods are called so I can avoid any errors of one being called twice before the other. I've got the scale matrix being passed in for both directions with the first parameter set to either -1 or 1 accordingly. Then I start it and it does absolutely nothing different from what it did before I used the scaling matrix. I know the begin method that uses the rotation matrix is being called because I haven't gotten an error yet, as it should give if that hasn't been called. I'm going to try searching up some examples of the scaling matrix being used and if I still can't get it to work then I'll try using a reflection matrix. I'm completely new to using matrices in this, but so far I've only seen them being used in examples in 3D environments. Since my game is all 2D, do these still work?
25. ## Reflect group of textures representing parts of character over a specified axis?

Thanks guys, I'll try this as soon as I get a chance.