Results 1 to 1 of 1
  1. #1
    Join Date
    Mar 2007

    Unanswered: Need Help Structuring Code

    Hey guys,

    I've just started out with VB and I am running through a fun project to teach it to myself. I have a question in reards to the correct or best way to structure code.

    Lets say we are interested in simulating a car. I want to model the process of starting the car and moving some distance. I have two choices:

    Do i model the cars movement in one block of code that treats the car as a single entity and use classes to define one object?


    Do I uses classes to define each compnent of the car such as left tire, engine...etc.

    i want to be able to create new cars easily, and to be able to use different tires, brakes, engines etc. Eventually be able to race 20 odd cars simultaniously. I also want damage and condition to be assigned to various parts of the car making it perform differently.

    Has anyone got any advice or another approach?
    Last edited by MatthewM; 04-12-11 at 22:31.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts