Search:

Type: Posts; User: JakkyD

Search: Search took 0.08 seconds.

  1. Drawing a string without use of Main(String[] args)

    Basically I have this code and another program that rotates text around the screen and I'm trying to merge them. How do I draw a string to this code without the use of something like

    public...
  2. Replies
    2
    Views
    1,476

    Re: Prevent object going outside of screen?

    As you can see here as well



    // if the ball hits the left wall add to Player 2 score
    if ( BallXLoc <= 11 ){
    Player2Score +=...
  3. Replies
    2
    Views
    1,476

    Prevent object going outside of screen?

    I solved object going outside of screen by saying if the Y axis of paddle = top or bottom of screen then set the paddle's Y axis to the min/max so it can't go over.

    I have another query to do with...
  4. Replies
    6
    Views
    1,448

    Re: Has the ball hit my paddle?

    I am using this listener



    class Transaction implements KeyListener // When character typed
    {
    public void keyPressed( KeyEvent e) // Obey this method
    {
    ...
  5. Replies
    6
    Views
    1,448

    Re: Has the ball hit my paddle?

    Ahh my first post on this forum and it's a shambolic one. I apologise. I didn't call the checkCollisions(); function while running the main program loop.
    I added this and now it's working fine.
    ...
  6. Replies
    6
    Views
    1,448

    Has the ball hit my paddle?

    Hi all, I'm creating a game of Pong and I'm having trouble seeing whether the ball has hit the paddle. My game so far has a ball that bounces around the screen, and a paddle on the left which can be...
Results 1 to 6 of 6