1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Two Factor Authentication is now available on BeyondUnreal Forums. To configure it, visit your Profile and look for the "Two Step Verification" option on the left side. We can send codes via email (may be slower) or you can set up any TOTP Authenticator app on your phone (Authy, Google Authenticator, etc) to deliver codes. It is highly recommended that you configure this to keep your account safe.

Tim Sweeney Interview

Discussion in 'News & Articles' started by hal, Aug 29, 2008.

  1. hal

    hal Dictator Staff Member

    Joined:
    Nov 24, 1998
    Messages:
    21,397
    Likes Received:
    13
    Tim Sweeney talks to GameDaily about all things Unreal Engine 3, including the adoption of the engine for use in television and film. Interestingly, he also reveals that the engine is now up to 2 million lines of C++ code for the engine and 150,00 lines of UnrealScript.

     
  2. elmuerte

    elmuerte Master of Science

    Joined:
    Jan 25, 2000
    Messages:
    1,936
    Likes Received:
    0
    lines of code doesn't tell anything except the number of times the "enter" or "return" key was pressed.
     
  3. JaFO

    JaFO bugs are features too ...

    Joined:
    Nov 5, 2000
    Messages:
    8,408
    Likes Received:
    0
    :lol: ...
    OTOH how what unit of measurement would be useful to measure the 'size' of a program ?
    Lines of code ?
    #number of classes or files used ?
    ...
     
  4. elmuerte

    elmuerte Master of Science

    Joined:
    Jan 25, 2000
    Messages:
    1,936
    Likes Received:
    0
    depends, what do you mean with "size"?

    size metrics for source code have only a useful relative meaning, but number of lines of file size is pretty much always a useless metric. Number of statements can be useful, memory size can be useful, compiled code size, etc. these can be useful
     
  5. Deapblade

    Deapblade New Member

    Joined:
    Jul 15, 2004
    Messages:
    223
    Likes Received:
    0
    Nothing, it's just plain stupid to 'measure' a program. A program has to fullfill the tasks it's written for in the most efficient way possible. Like elmuerte said, lines could mean anything: empty spaces, redundant code, programmer notes, actual useful code, etc.
     
  6. ShatteredX

    ShatteredX !?!

    Joined:
    Nov 25, 2000
    Messages:
    59
    Likes Received:
    0
    While the number of lines of code in a program is certainly not an accurate representation of how much actual "code" is present, it does give someone who is unfamiliar with programming some sense of how much thought and work goes into creating a game engine such as UE3.
     
  7. elmuerte

    elmuerte Master of Science

    Joined:
    Jan 25, 2000
    Messages:
    1,936
    Likes Received:
    0
    no it doesn't, there is no relation between required thought and the number of line of code that it resulted in.
    also, previously invested thought time for old solutions is not shown because those lines of code have been replaced.
     
  8. [SAS]Solid Snake

    [SAS]Solid Snake New Member

    Joined:
    Jun 7, 2002
    Messages:
    2,633
    Likes Received:
    0
    Also lines of code means nothing other than what elmuerte has stated, and gives the wrong impression of why code is complex.

    Code:
    for (i=0;i<j;++i) dothis();
    
    Code:
    for (i = 0; i < j; ++i)
    {
      dothis();
    }
    
     
  9. JaFO

    JaFO bugs are features too ...

    Joined:
    Nov 5, 2000
    Messages:
    8,408
    Likes Received:
    0
    That part of the development-process is interesting indeed.
    Imagine a program that needs 10,000 lines less code because someone found a better solution ...

    I think there is no real way to indicate the complexity of code to anyone who is not familliar with the subject at hand.

    // another example :


    Code:
    int addone(int i)
    {
       return i + 1;
    }
    
    main()
    {
    ...
      int i = 0;
      int j = 10;
      while (i < j)
      {
        doThis();
        i = addOne(i);
      }
    ...
    
    See ... I've added even more lines, the routine became even more complex (and has an increased chance of having bugs). It has not become 'better' code.

    // ---
    It is interesting to see what game-development tools are doing to 'traditional' Hollywood industry.
     
    Last edited: Aug 31, 2008
  10. MonsOlympus

    MonsOlympus Active Member

    Joined:
    May 27, 2004
    Messages:
    2,224
    Likes Received:
    0
    On the flipside less lines does not always make 'better' code either :)
     
  11. elmuerte

    elmuerte Master of Science

    Joined:
    Jan 25, 2000
    Messages:
    1,936
    Likes Received:
    0
    McCabe's Cyclomatic Complexity metric is quite a good indication of code complexity, and there are a few other good metrics when it comes to code complexity.
    But code complexity is something very different from source code size metrics.
     
  12. Severin

    Severin New Member

    Joined:
    Feb 8, 2008
    Messages:
    199
    Likes Received:
    0
    elmuerte is correct. 2 million lines of 'print' statements does not equal a complex piece of code neither does 20 million.

    With the case in hand though a fair chunk of that can be assumed to be complex code and not just 'print' statements. :)
     
    Last edited: Aug 31, 2008
  13. elmuerte

    elmuerte Master of Science

    Joined:
    Jan 25, 2000
    Messages:
    1,936
    Likes Received:
    0
    Everybody should know that assumptions are bad. Assumptions result in rockets blowing up, collapsing bridges, demoguy and darkpulse.
     
  14. Severin

    Severin New Member

    Joined:
    Feb 8, 2008
    Messages:
    199
    Likes Received:
    0
    If they managed to get UE3 up and running just by using prints then hats off to them I say.

    But your right you can't assume that its not. (though it almost certainly isn't :))
     
    Last edited: Sep 1, 2008
  15. elmuerte

    elmuerte Master of Science

    Joined:
    Jan 25, 2000
    Messages:
    1,936
    Likes Received:
    0
    doing that is much more complicated than doing it the "normal" way.
     
  16. Severin

    Severin New Member

    Joined:
    Feb 8, 2008
    Messages:
    199
    Likes Received:
    0
    There we disagree. As I said above no matter how long the list of prints, its still simple from a code perspective. The thought that would go into such a (insane) project and the end result (output) would be complex though.
     
  17. elmuerte

    elmuerte Master of Science

    Joined:
    Jan 25, 2000
    Messages:
    1,936
    Likes Received:
    0
    ok, then show me a program that only uses `print' and can list the number of lines in a file.
    remember, you can only use `print' in the source code, nothing else.
    erm.. is there even a print function in C? ok, you can only use `printf'
     
  18. Severin

    Severin New Member

    Joined:
    Feb 8, 2008
    Messages:
    199
    Likes Received:
    0
    :)
    I did say such a thing would be an insane way of coding.

    Print "1"
    Print "2"
    ...

    I was trying to be nonspecific about language and used quotes to make it distinct from BASICs Print statement.

    Edit..
    Oops my bad. I misread your challenge. Nope I cannot come up with a version that would read another file.

    More edit...
    For something graphical you could conceivably come up with something by overlaying prints at the same x,y coords... aggh i'm starting to take this premise seriously.
     
    Last edited: Sep 1, 2008
  19. 8-4-7-2

    8-4-7-2 New Member

    Joined:
    Mar 6, 2000
    Messages:
    6,962
    Likes Received:
    0
    There are tons of metrics. Usually they measure not so much the size of the program, but the complexity of its modules and its design. That is how many loops, checks, dependencies, etc. are present.

    But as said, that's still not all that useful to compare any project to any other project.
     
  20. niaz2

    niaz2 Banned

    Joined:
    Sep 3, 2008
    Messages:
    3
    Likes Received:
    0
    FINE SYSTEM

    HI

    THIS INTERVIEW IS FINE.
    THIS SYSTEM IS NICE.
     

Share This Page