coder0xff

Members

101

225 Neutral

• Rank
Member

2. The name of that floating-up fading number UI thingy?

When a numeric value appears above an opponent for the amount of damage you've done, and floats up slowly while fading out. Or when you gain XP, or earn money, or a myriad of other things. Is there a common name for this floating value thingy?
3. Mitigating the Effects of a Learning Curve

I'm a professional developer, but I find myself in a position where I'm using technologies, APIs, and languages that I have little experience with. Though I'm excited about the project, I'm honestly kind of dreading it. My project is a substantial one, and I'd like to do it right the first time. Are there any tips or tricks to help avoid making poor architectural and coding decisions, so I can avoid having to go back and redo things once I figure out the "proper way"? I have no problem with reading documentation and reference material, but it only gets you so far.
4. Building Projection Matrix Manually

http://www.codeguru.com/cpp/misc/misc/math/article.php/c10123
5. Force between two magnets when 'B' between them is know

Do you want to know the net force exerted on a point by two nearby magnets, or do you need to know the force between the two magnets? Your wording is kinda confusing.
6. Vector rotation and mirroring

Sin and Cos are what you need. I'm kinda fuzzy on what each of these variables represents (what's the difference between your hard coded 100 and texture.Width?). Another way: the origin of the sprite should be at its center (since it's mirrored through the origin, I assume)
7. Distance between AABB (cube centered at origin) and a line segment

I've already got a test to determine that the line segment does not intersect with the cube, but now I need to determine the distance. I've got a few ideas, but I'm looking for the fastest known solution. Any suggestions?
8. Camera rotation from mouse

assuming that X goes to the side, Y goes forward, and Z goes up [code]float pitchCos = Math.Cos(pitch); Vector3 offset; offset.X = Math.Sin(yaw) * pitchCos; offset.Y = Math.Cos(yaw) * pitchCos; offset.Z = Math.Sin(pitch); Vector3 lookat = offset + cameraPos;[/code]
9. Speculative contacts and AABB vs AABB

[code]separation.X = Math.Max(0, separation.X); separation.Y = Math.Max(0, separation.Y); separation.Z = Math.Max(0, separation.Z); distance = Math.Sqrt(separation.X * separation.X + separation.Y * separation.Y + separation.Z * separation.Z)[/code] naturally, if you're going to be doing a simple comparison, it's better to discard the square root, and have something like: [code]if (distanceSquared <= testDistance * testDistance) [/code]
10. Camera rotation from mouse

The easiest way: keep track of a yaw variable and pitch variable. When the mouse moves you increase or decrease the yaw or pitch, based on the X and Y movement, respectively. If you can't directly set the angle the camera is rotated to (or you haven't programmed it yet), reply and I'll show you how to compute the new look at coordinates based on yaw and pitch, or you can use the frustum building functions of the graphics library you are using to help you out. (Can you give some more details, please?) If, for some reason, you can't keep track of a yaw and pitch variables yourself (and the camera you are using doesn't let you get or set them) then its possible to take the look at coordinates, compute the current angle, change the angle, and then compute new lookat coords.
11. collision detection - arbitrary irregular "concave" objects

Concave collision is usually much slower than convex. 20x slower would not surprise me. You might want to look into something like "inner sphere tree." Unfortunately, pre-computation methods are geared towards static geometry, not skinned/animated models.