Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 20 Jan 2013
Offline Last Active Apr 03 2013 07:15 PM

#5046294 Can't figure out an unique and exciting idea for a computing project

Posted by on 24 March 2013 - 01:49 PM

I agree with Bacterius, what he said reminds of a quote from Jim Jarmusch:


Nothing is original. Steal from anywhere that resonates with inspiration or fuels your imagination. Devour old films, new films, music, books, paintings, photographs, poems, dreams, random conversations, architecture, bridges, street signs, trees, clouds, bodies of water, light and shadows. Select only things to steal from that speak directly to your soul. If you do this, your work (and theft) will be authentic. Authenticity is invaluable; originality is nonexistent. And don’t bother concealing your thievery – celebrate it if you feel like it. In any case, always remember what Jean-Luc Godard said: “It’s not where you take things from – it’s where you take them to.” ”

—Jim Jarmusch


I like the idea of combining different, supposedly unrelated things together and seeing what happens. But even if you do something straightforward like the Game of Life, think of how many people there are that wouldn't be able to code that! It's actually not very "common" at all. And 5000 words isn't that much; if something is common there must be a reason, talk about how people use in the real world, or it's impact. How the Game of Life relates to AI and biology or something. Here's a different angle, since it's so common, has it outlived its usefulness? Are people going to continue to find it interesting, or will they move on to a replacement of some sort?

#5046229 Pure virtual function use case question

Posted by on 24 March 2013 - 09:26 AM

Hi, I'm writing a Pong clone and sort of learning C++ at the same time. In the game I have one paddle controlled by the computer and one by the user, but for now I have just one Paddle class.


class Paddle
    Paddle(Position p);
    void setPosition(Position p);
    void moveUp();
    void moveDown();
    void moveTowardGoal(int goal);
    Position getPosition() const;
    int xpos;
    int ypos;
    int vel;


Now I want the moveUp/moveDown methods to move the paddle different distances depending if it's the AI paddle or the user paddle, so I was going to create two child classes, AIPaddle and UserPaddle. However, I am not going to be using polymorphism, as I need to be able to call the moveTowardGoal method, which would only be in the AIPaddle child class. My question is, since the moveUp/moveDown functions are in both child classes (with different implementations), is it "best practice" to declare them in the base class as pure virtual even if polymorphism isn't happening? Or should I just define separate moveUp/moveDown functions in each child class? I doubt it makes any difference performance- or conceptual-wise in this simple case, but as I said I'm trying to learn the C++ way of thinking about things so I'll have a blueprint if something more complex happens in the future.


#5046222 C++ Programming - What IDE to use ?

Posted by on 24 March 2013 - 09:01 AM

Vim, with gcc/minGW. smile.png