Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x

Game Programming

Game programming is the software development of video games. Game programming requires substantial skill in software engineering as well as specialization in simulation, computer graphics, artificial intelligence, physics, audio programming, and input. Like other software, game development programs are generated from source code to the actual program by a compiler. Source code can be developed with almost any text editor, but most professional game programmers use a full integrated development environment (IDE).

Share tech news, updates, or what's on your mind.

Sign up to Post

Hello,

As the title states, I am making a simple game program for a introductory Computer science course.  In the game, there are several GContainers which take the form of blackholes slowing boucing around the screen.  There are also several "planets", which are GOvals that are pushed around the screen towards a destination.  I just added some code which should check for a collision between the blackholes and the planets.  However, according to a println command I put in, the blackholes and the planets are constantly overlapping, which I don't think is true.  

This is the code to check for collision between the black holes and the planets:

 
 public void checkBlackholeCollision(BlackholeGame blackhole, GOval planet){
        double distance = getDistanceOfBlackholeAndPlanet(blackhole, planet);
        double overlapped = (SIZE/2 +(blackhole.getWidth()/2) - distance);
        if (overlapped>0) {
            gameIsLost = true; 
        }
    }

Open in new window


This the code to get the distance between the two:

private double getDistanceOfBlackholeAndPlanet(BlackholeGame blackhole, GOval planet){
        return GMath.distance(blackhole.getX(), blackhole.getY(), planet.getX() + SIZE/2, planet.getY() + SIZE/2);
    }

Open in new window


This is the code for the blackhole's general collision:

public void checkCollision(BlackholeGame blackhole) {
        double x = blackhole.getX();
        double y = blackhole.getY();
        double size = blackhole.getWidth();
  

Open in new window

0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE
LVL 4
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Hi
In my music, opinion blog, that supports user uploads, with Adsense income,
can I say that my users may only enter one of my contests if they are "considerably active and respected members of the blog?"
Does Google let publishers go who require bloggers to participate?

Thanks
0
Hi

I'm going to file my blog trademark again. Lame, but I neglected to do the final step one time, because I was so annoyed with the seeming endless ( unstoppable) billings. It felt like a Nigerian scam. Truly, I was suspicious and concerned.

Anyway, forget about it. I'm going to file again and there are 3 options. Does it matter which one I use? - for a blog name trademark? Also, would a logo filing be done later? The costs are complicated?  What will they be?

This is the initial page - notice the feeling-to-be-never-ending fees,      here

Thanks
0
Hi
To test my media website, I'd like to use music video mp4's and mp3's. ( as many as possible)
Maybe film students keep them somewhere, to compare? They make tons. K-12 Schoolers?

I can't use No Doubt, Nirvana, Pearl Jam, Ed Sheeran, Kevin Federline  and Beastie Boys, New Kids, apparently.

Google only finds converters and streams. Aren't they more trouble than it's worth?

What would you say?

Thanks
0
I want develop a IOS and ANDROID  ludo game. So I want to know What languages and tools i need to use to develop LUDO GAME.
Where can play maximum number of players with good speed.
What will be the best server for my game.
0
Hi,

So, I reached the PGL opening season playoffs in Starcraft.

Starcraft Remastered is out, but I'll only play it if there are lots of players.

This is a granddad game, let's face it.

Does it have any traction? Do I need my Starcraft 1 CD?
Thanks
0
I am looking for advice as to what software and camera(s) can be used to create an image on a PC screen of a chair (for example).
The image on the screen should be able to be rotated in real time by operation of a slider control or mouse as if the
 chair were on a turn-table and the turn-table was being rotated. The image would reveal a  view from every angle of rotation.
I imagine that a 3D camera would be needed and that a minimum of 3 "pictures" would need to be taken, the pictures then somehow would be "stitched" together and viewed with a viewer.
I am a Windows C++ application programmer with little or no experience and a very modest budget for this  kind of software, hardware or terminology and would appreciate some general information as to what Windows software or hardware is needed.
I am not seeking information on Game programming as such although I imagine there is some relevant information to be gained from that topic area.
0
The probability formulas are to be used for wagering on harness racing. There are 6 types of wagerings:

1. Win: You wager on that a certain horse will win the race, and there might be 12 horses in the field.
2. Place. You wager on that a certain horse will end 1st, 2nd or 3rd in the race.
3. Twins: You wager on that two horses in the field will end 1st and 2nd irrespective of the order in the race.
4. Trio: You wager on that three horses will end 1st, 2nd and 3rd in exactly that order in the race.
5, Top 7 Pro: You wager on that 7 horses end 1st, 2nd, 3rd, 4th, 5th, 6th and 7th in exactly that order in the race.
6. DD: You wager on that a certain horse will win race 1 and a certain horse will win race 2.

So type 1-5 are for only one race, whereas type 6 is for 2 races.

Type 1 is not difficult: If there are 12 horses in the race, then each horse has a 1/12th chance to win (8.3 %) if they would have exactly the same capability.

What would the function be for the other five types, assuming there are always 12 horses in the field?

Logically the order of most easy to most difficult would be this:

2. Place
1. Win (difficulty/probability 8.3 %)
3. Twins
6. DD
4. Trio
5. Top 7 Pro

Which formulas could I enter in this online probability calculator for example?:

http://stattrek.com/online-calculator/probability-calculator.aspx
0
Hi
I have set up a project with a freelancer, and he needs access to my wp-admin - as it is my blog.

Do I give him my Godaddy password, or is there a system for giving external people access to parts of my account?

I gave him my Google password for Adsense. Was that a mistake?

Should I be worried. He is in India. I doubt he is in the Indian Freelancer Mafia. He looked like a decent guy in his pic.

Thanks
0
I am working with my son learning javascript by following a book called '3D Game Programming for Kids'. It is an awesome book, explains thing nicely and we were doing great until we got to the following bit of code that we absolutely need to continue the book. It is supposed to add four trees to the screen but when I place this bit of code in the main code our original avatar does not even show up anymore so i know that the only problem was with this section of code with the tree not with the rest of it. I will show you this section of code (that I copied exactly from the book) and then then entire avatar code so far. Any help is very much appreciated as we are completely stuck and cannot move forward and I really need your help to help my son learn but I'm learning at the same time. Thanks! :)

This is the Tree code:

***********

makeTreeAt(500, 0);
makeTreeAt(-500, 0);
makeTreeAt(750, 0);
makeTreeAt(-750, 0);

function makeTreeAt(x, z) {
  var trunk = new THREE.Mesh(
    new THREE.Cylinder.Geometry(50, 50, 200),
    new THREE.MeshBasicMaterial({color: 0xA0522D})
    );
 
  var top = new THREE.Mesh(
    new THREE.SphereGeometry(150),
    new THREE.MeshBasicMaterial({color: 0x228B22})
    );
    top.position.y = 175;
    trunk.add(top);
   
    trunk.position.set(x, -75, z);
    scene.add(trunk);
}

**********************************************************


Here is the entire code for the avatar with the tree code added:

0
Free Tool: Path Explorer
LVL 10
Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Hi

In the Newsmag Wordpress demo page  here
it has a nice Newsmag header area

Can that exact header rectangle be a graphical banner I've made? or text only? I seem to remember it being text only.

Can this theme be a blog?
Thanks
0
Hi

I have done Adsense before on a blog, and broke the payment threshold just? once.

I think I once saw on their TOS that Adsense is only allowed through regular browsing.
This is a reasonable requirement, and my first blog was a discussion.

If on my new discussion, I want to do a serious prize contest, like $50 K, for a submitted audio track, am I allowed to say that only serious, well respected, active members on the site can submit tracks for peer-review via my permission? What might be the surrounding issues?
Thanks
0
Hi
If a Facebook post has 2 Thousand+ smiles, frowns and such, do all of them receive new comments?

Thanks
0
Hi
I'm doing a new website.

The last time I did a blog, I think some people found out my real name, and I was ticked off. Did they do a whois on my domain?
How do you do that? I have Godaddy.
How can I, in-fact, be completely anonymous? (totally, so the Kremlin can't even track me down) CIA, FBI, Vlad the impailer, or Garry Kasparov

Thanks
0
I want to be a Game play Programmer. to be GPP I need to study in a good university.Good universities want good $$$.i want start my career for some years or some time.which career is best that give me more $$$.
1.Java EE/Java Developer
2.Mobile App Developer
3.UI/UX Designer
4.Internet Advertiser
0
How do I code for a robot and soccer ball for my game?
0
When making games how do you find out how many programming codes you will need?
0
Hi

If my friend and I want to cover
Baby one more time,
Do a video,
How good can hair additions be?
If I look like attachment, can hair extensions approximate Britney in 'Baby one more time'
I live in Wilmington, NC, which is a film town, so I'm sure I can find people to do it if it's possible.
?
I need schoolgirl, Britney long flowing, or pigtails hair.

Thanks
securedownload.jpeg
0
Hi

In Starcraft 2, the better players can build a base at their natural expansion immediately, but when it's me, it expects Vespene gas.

How do I expand instantly without gas?

Thanks
0
What does it mean to be "Always On"?
LVL 4
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Hi
I am getting a Jupiter - 80 keyboard for my new band, but there are quite a few places to buy it from.
The one I have now has broken buttons, and is still under warranty.
I've sent for a mail-it-back-and-get-a-refund, but I have to buy a new one somewhere else.

I can find a new one for $2499 on
Full Compass
Is there a better option somewhere else?

Thanks
0
Hi

My new Jupiter-80 is okay, as a Synth keyboard.

I am used to my clavinova's perfect piano setting.
I can only get hints of my Jupiter's piano setting. It seems to always work in halves, upper and lower.
How do I make it ALL piano, no synth?

Thanks
0
Hi

I have ordered a Jupiter 80 keyboard for my band.

It seems very advanced.

Does anyone know if it can do chord recognition, and appropriate bass note addition? I may have missed it in the sheet.

Thanks
0
I'm learning Unity. I'm using Unity 5.5.
I created a new project.
I'm trying to create a new scene.

At the bottom left of my unity window there's a message that says "New Scene in play mode is not supported. Exit play mode and try again."

Anyone know, How to get out of play mode?
0
Hi

I've asked several dropbox questions.
But, not if dropbox is the only way to do large file upload and download (MRI image files (needs size of CD)
Is there a way to send it to my web-space, a directory, to wait there until needed?

Thanks
0
Can you please make this so that arrows come after him?
squaier--updated-
0

Game Programming

Game programming is the software development of video games. Game programming requires substantial skill in software engineering as well as specialization in simulation, computer graphics, artificial intelligence, physics, audio programming, and input. Like other software, game development programs are generated from source code to the actual program by a compiler. Source code can be developed with almost any text editor, but most professional game programmers use a full integrated development environment (IDE).

Top Experts In
Game Programming