Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: Rectangle Object collides with Text object  (Read 2658 times)

0 Members and 1 Guest are viewing this topic.

enderboy768

  • Newbie
  • *
  • Posts: 9
    • View Profile
    • Email
Rectangle Object collides with Text object
« on: June 06, 2017, 07:23:44 pm »
I have made a little Pong project. I wanted to put a heads up display using sf::Text to it but it turns out the ball (not really, it's a rectangle from sf::RectangleShape) will get stuck when it went through the text. And apparently, the paddle got stuck too! Is there anyway I can make the HUD/the text kind of 'invisible' to the ball and the paddle? Thank you in advance!

Ionut

  • Jr. Member
  • **
  • Posts: 59
  • Guess Who's Back ?
    • View Profile
    • Email
Re: Rectangle Object collides with Text object
« Reply #1 on: June 06, 2017, 07:29:49 pm »
That's weird...can you show us the code?
Guess Who's Back ?

enderboy768

  • Newbie
  • *
  • Posts: 9
    • View Profile
    • Email
Re: Rectangle Object collides with Text object
« Reply #2 on: June 06, 2017, 07:49:33 pm »
Oops, my bad! The ball didn't get stuck to the HUD. It actually got stuck to the paddle when it was right behind the HUD (noob error!).

Ionut

  • Jr. Member
  • **
  • Posts: 59
  • Guess Who's Back ?
    • View Profile
    • Email
Re: Rectangle Object collides with Text object
« Reply #3 on: June 06, 2017, 07:59:11 pm »
Ok,I'm glad you figured it all by yourself ;D
Guess Who's Back ?

enderboy768

  • Newbie
  • *
  • Posts: 9
    • View Profile
    • Email
Re: Rectangle Object collides with Text object
« Reply #4 on: June 08, 2017, 10:46:41 am »
Hehe thanks  ;D