Search:

Type: Posts; User: NathanWick

Search: Search took 0.16 seconds.

  1. Replies
    1
    Views
    155

    Collision Testing Code isnt working.

    For some reason the ball is still going off the top of the frame. Im not sure why.





    import java.awt.Color;
    import java.awt.Dimension;
    import java.awt.Graphics;
    import java.awt.Image;
  2. Re: Getting the width and height of a frame without borders

    I am declaring the borderlessDimension before I declare the frame and set it Visible, let me try declaring it after

    --- Update ---

    Dude thanks so much! I feal like an idiot now haha
  3. Getting the width and height of a frame without borders

    So im using the this.getContentPane().getSize(); to set a Dimension variable called borderlessSize (because its supposed to contain the size of the frame excluding the borders) and then im setting an...
  4. Re: How to do a collision test with two JLables?

    I understand how to access the Width, Height, X, Y coordinates and everything, however how would I used those in order to test whether or not the two objects are colliding?
  5. Re: How to do a collision test with two JLables?

    yeah but how would i do that?
  6. How to do a collision test with two JLables?

    I'm making a game where a ball bounces around the screen, and i was wondering how you would test if the ball (just a jlabel with an icon) collides with another square in the middle of the...
  7. Re: How do I export an JLabel image with my game?

    Thank you so much :D!
  8. How do I export an JLabel image with my game?

    I made a game where basically, a ball (A JLabel with the icon set to a ball image from my computer) bounces across the screen, and when you click it, the speed increases. When I exported the game, it...
Results 1 to 8 of 8