Search the Community
Showing results for tags 'video games'.
Computers are good at math, right? So it follows that video games should be able to do plenty of physics calculations while you run around shooting zombies and stuff, right? Well, the thing is, they have to do a lot of calculations - and they have to do them really, really fast. Take, for example, some game based on a large map, with somewhere around a hundred players, all trying to shoot each other to death. Handled naively, every time a player shoots, the game would have to continuously test if the bullet is intersecting any player on the whole map at any given point along its path. And even handling one single player isn't easy! It's gotta check if it hit the player's foot, leg, other leg, hip, abdomen, shoulder, arm, other shoulder, other arm, neck, head... And then it gets even more confusing when you suddenly have an impenetrable pan on your back blocking some bullets. Now, check for all of these intersections somewhere between twenty and a hundred and twenty times per second, for every single bullet, for every single player. Basically, it's kinda hard for even fast computers to keep up, while remaining accurate. But that's where humans and their fandangled logic comes in! Now, how could a bullet possibly hit someone, if it's practically in a different time zone from them? Short answer: it can't! (Unless you have teleporting bullets, in which case you should be selling the technology for billions, not shooting people with it). So, take this giant map, and split it up into anywhere from a few to a bunch (so specific, I know) of little bitty squares. Now, as players move around, you've gotta keep track of which square they're in, which takes a bit more work. But now, when you have a bullet (or a few thousand) flying through the air, there's no way it's going to hit someone that's not within either its own zone, or maybe one of the adjacent zones. Now you've gone from checking every player in the game, to between zero and a handful! Much easier! These same sorts of logical assumptions can be made for all sorts of locality-based applications, like virtual lighting (really, do you want to simulate a billion photons shooting around a room?), more advanced collision detection (we've done point-like bullets hitting round-ish parts of bodies, but what about really complex, non-convex things hitting each other?), as well as odd things like splitting up a group of points into non-spiky triangles (or tetrahedra). That actually has applications in fluid dynamics, modelling the density of stars in galaxies, and a bunch of other things way over my head.
Ever since I heard about this blogging assignment, this was the first idea to come to mind. I used to play the game Super Mario Sunshine frequently in my childhood. The game stars Mario in a tropical setting, using a water-fueled jetpack to hover over large gaps for a few seconds. Using this jetpack, he can hover over characters and spray water on them to clean them off. Sounds harmless enough, but I wanted to see just how powerful this water pack could be. Many have assumed that Mario weighs somewhere around 165 pounds, so I will be using this for my calculations. Converting this to kilograms, we get 74.8427 kg. In order to calculate the force needed to hold Mario in place in the air, we need the force exerted by gravity on Mario. Using the equation Force = Mass * Acceleration, we can plug in the numbers 74.8427 kg for mass, and 9.81 m/s2 for acceleration due to gravity. This gives us a force of 734.206887 Newtons of force. In order to compare this device to something realistic, we need to determine its pressure. One way of doing this would be to find its PSI, or Pound-force per Square Inch. Since we have an answer in newtons, we can convert this to PSI using a different value for pressure, Newtons per Square Meter. This requires us to find the area of the water stream. Assuming that the stream of water is perfectly circular, and that its diameter is equal to the diameter of the nozzle at its widest point, all we need is the area of the nozzle. To do this, I can measure based on an actual model taken directly from the game's files. Doing this, I compared the backpack to Mario's official height of 5'1", and scaled it accordingly. Then, I measured the nozzle's diameter, and got a measurement of 30 centimeters. Using the equation Area = Pi * Radius2, substituting in .15 m for radius, we get an area of .070686 m2. The pressure unit is Newtons per Meter Squared, so dividing 734.206887 N by .070686 m2 will give us a pressure we can convert to PSI. This gives us 10386.90269 N/m2. Converting this to PSI gives us...1.5 PSI. This seems pretty underwhelming. For comparison, some garden hoses are rated for maximum PSIs of 150. Did I do something wrong? That's about all the time I have for now. Let me know what you think, and if there are any ways I could improve or simplify my calculations! For now, I'll leave you a video of a real-life water jetpack. See you next time!
Recently I was playing video games with my brothers and their friends when they decided to move the party to another house. We were all set to go when suddenly someone mentioned the TV involved. This was soon drawn out into a long conversation about why old video games don't work well with new TV's, but work perfectly fine with old ones. Why is that? Well, the problem I am mentioning is called input lag, which is the loose definition for any large difference in time between the input to a hardware device and its associated output. For example: hitting a button on a game controller and waiting a second before the TV displays the action. Many of my brothers' friends noted that this input lag was almost never seen with old cathode ray tube TV's, while it can be often seen with liquid crystal display or plasma. The reason this occurs is because of the difference between the analog signals of old video game consoles, and the digital signals of new TV's. When an old video game controller is pressed, the controller takes information and packages it in an analog signal to be sent to the TV. The TV then accepts this signal for display. Old TV's used analog display, so they could simply unpack and use the information. However, new TV's use digital systems, and must first demodulate the data (which includes changing the carrier wave) to be unpacked. They also nowadays store video information, which previous TV's did not. As a result, your original smash bros. game may not perform as well as you'd like unless you fish something archaic out of a trash heap. Good luck with that buddy.