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

Author Topic: Tanktris - a Tetris clone [RC2 & Sourcecode released]  (Read 29000 times)

0 Members and 2 Guests are viewing this topic.

christoph

  • Full Member
  • ***
  • Posts: 102
    • View Profile
    • http://www.christoph-egger.org
Tanktris - a Tetris clone [RC2 & Sourcecode released]
« Reply #30 on: September 13, 2008, 02:04:15 pm »
Works great!

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Tanktris - a Tetris clone [RC2 & Sourcecode released]
« Reply #31 on: September 13, 2008, 02:08:13 pm »
Quote
Edit: Laurent, would it be a good idea to implement division by zero checks for Random()?

And then return what ?
In my opinion, getting a system exception is more obvious than a possible incorrect value, for the programer to fix his error.
Laurent Gomila - SFML developer

Tank

  • SFML Team
  • Hero Member
  • *****
  • Posts: 1486
    • View Profile
    • Blog
    • Email
Tanktris - a Tetris clone [RC2 & Sourcecode released]
« Reply #32 on: September 13, 2008, 04:39:12 pm »
Quote from: "christoph"
Works great!

Great. :)

Laurent:
You're obviously right. I didn't thought about that a C++ exception is thrown. Nevermind. :)

Laurent

  • Administrator
  • Hero Member
  • *****
  • Posts: 32498
    • View Profile
    • SFML's website
    • Email
Tanktris - a Tetris clone [RC2 & Sourcecode released]
« Reply #33 on: September 13, 2008, 04:50:18 pm »
It's not a C++ exception, it's a system interruption (unless you've turned on a compiler specific option to convert it to a C++ exception).
Laurent Gomila - SFML developer

 

anything