Slashdot Mirror


Crowther's Original Adventure Source Code Found

drxenos writes "I don't know how many of you are fans of old-school text adventures (interactive fiction), but Will Crowther's original Fortran source code has been located in a backup of Don Woods's old student account. For fans like me, this is like finding the Holy Grail."

12 of 309 comments (clear)

  1. A good example of how coding has progressed by Anonymous Coward · · Score: 5, Interesting
    Increased memory (both RAM & Disc storage) availability has allowed us to make our code more readable.
    I looked at the various FORTRAN files and am amazed at the spaghetti GOTO maze which, although messy, was probably the only way to do things in FORTRAN at the time with no structuring capability.


    A random example:

    IF(K.NE.1) MASK1="177*M2(K)
            IF(((A(J).XOR."201004020100).AND.MASK1).EQ.0)GOTO 3
            IF(S.EQ.0) GOTO 2


    Wow! Is that the opposite of self-documenting code or what?

    1. Re:A good example of how coding has progressed by SIGBUS · · Score: 5, Funny

      So maybe the inspiration for the "maze of twisty little passages, all alike" wasn't Mammoth Cave, it was the code itself.

      --
      Oh, no! You have walked into the slavering fangs of a lurking grue!
    2. Re:A good example of how coding has progressed by morgan_greywolf · · Score: 5, Funny

      Um, could you repost that please? It seems your original post got corrupted somehow. All I see is gibberish where the code should be.

    3. Re:A good example of how coding has progressed by LMacG · · Score: 5, Interesting

      Ah, the old computed GOTO. In the first line, the value of KQ is used as an index to the list of labels. If KQ=1, GOTO 5014, if KQ=2, GOTO 5000, etc. etc. If KQ is outside the range (0 or greater than 4), then no GOTO is performed, so you'd hit the PAUSE statement. Looks like it's essentially saying "this shouldn't happen".

      2027 is similar, there's just a lot more possible values. That rogue 1 is a continuation indicator, it would have been in column 6 on your punch card.

      --
      Slightly disreputable, albeit gregarious
    4. Re:A good example of how coding has progressed by fm6 · · Score: 5, Insightful

      Memory is not the issue here. Turbo Pascal was designed to run in a single 64K 8086 segment, and Pascal is the quintessential block-structured language. The real problem is that the designers of FORTRAN were totally ignorant of the principles of language design. They could hardly be otherwise: FORTRAN was the very first high-level language.

      But here's a sobering thought: Dijkstra launched his attack on the goto statement in 1968. Every programmer who's grown up with block structured languages would take it as a given that Dijkstra was right. But at the time, the concept was extremely controversial, and there was a lot of resistance — as evidenced by the fact that Crowther and Wood were still using computed gotos in 1976!

  2. Re:THIS IS A HOAX by pla · · Score: 5, Funny

    Who else would call FORTRAN a "text adventure"?

    Well, calling it a "programming language" certainly qualifies as "fantasy"... ;-)



    / Props to HPF, though
    // Still wouldn't use it unless forced to at gunpoint

  3. Re:Wow.... by Anonymous Coward · · Score: 5, Funny

    "Someone mind finishing the work for me?"

    Fine, fine.

    For fans like me, this is like finding the Holy Grail.

    Drxenos! Drxenos, King of the Nerds! Oh, don't grovel! If there's one thing I can't stand, it's people groveling! ...
    [slightly later]

    Behold! Drxenos, this is the Holy Grail of Computer Games. Look well, drxenos, for it is your sacred task to seek this Grail. That is your purpose, drxenos -- the Quest for the Holy Grail of Computer Games: Adventure. And it is written in FORTRAN.

    Wait, FORTRAN? Lord, you're kidding right?

    [significantly later]

    He says they've already got one!

    Yes, it's-a verry nice-a. It is-a coded in C.

    [substantially later]

    We are the Knights Who Say ... IP! IP! IP!

    Augh!!!! Stop it!

    [much later]

    What is the net speed of an unladen TCP/IP data packet using PPP over a 1200 baud modem?
    What do you mean? With or without parity, 7 or 8 bits, with or without flow control?
    What? I don't know all that! Auuuuuugh!!!

    [slightly later but a little further that the previously-mentioned "slightly later"]

    The Castle Stanford. Once we brave its maze of twisty little passages, all alike, our quest is at an end!

  4. Re:Why it was special... by ian_mackereth · · Score: 5, Funny
    I encountered it as an engineering undergrad, on a university Cyber 204 or 205 mainframe, the first computer I'd ever used. I had to hack extra console time via various means to complete it, using a mega flowchart I drew up as I went.

    When I finally finished it, the screen cleared and an operator in the computer centre was typing to me and asking me to come over to the centre. I figured I'd been sprung for all the extra time I'd 'arranged', but instead they gave me printout and iducted me into the Order of Wizards!

    A nerdy proud moment... (I wish I hadn't lost that printout in the intervening decades and moves.)

  5. Re:I must not be old enough by Mr.+Slippery · · Score: 5, Informative

    what the fuck does rock-climbing have to do with "ethics"?

    The same thing leaving a campsite better than you found it has to do with ethics, or not littering has to do with ethics. Altering the environment and depriving others of potential experiences is an ethical issue.

    A quick Googling will reveal that "climbing ethics" is not an invention of the Wikipedia author, but is an active area of discussion among climbers.

    --
    Tom Swiss | the infamous tms | my blog
    You cannot wash away blood with blood
  6. Re:A good example of how coding has progressed, by junge_m · · Score: 5, Interesting

    This is why the grandmaster of 'Literate Programming', Donald Knuth, has done a translation into his CWEB Language which is totaly devoid of jumps and other 'dirty' Fortan:
    http://www.literateprogramming.com/adventure.pdf

  7. The Fortran gods shall smite thee by White+Yeti · · Score: 5, Funny

    program smite_em
    c-----
          IMPLICIT NONE      ! Catch typos and un-initialized variables.
          integer       IERR_smite
          character*200 ch_name
    c-----
          write(6,1)
    1     FORMAT(/,' This is one smiting program!',/,
         &   '   Enter name of smitee --> ',$)
          read(*,fmt='(A)') ch_name

          DO while(.TRUE.)   ! Endless smiting loop.
             call smite(ch_name, IERR_smite)
             if(IERR_smite.GT.0) goto 20
          End DO             ! smite loop.
    20    CONTINUE

          write(*,*)' Done smiting.'
          if(IERR_smite.LT.0) then
             write(6,2) IERR_smite
    2        FORMAT(' ***Possible smiting error, IERR_smite = ',I)
          endif
          STOP
          END
    c-----
    c End of Main.
    c-----

  8. Original Zork source code in MDL by SimHacker · · Score: 5, Interesting

    Zork was the reason I got on the ARPANET, back around 1980 or so. I was using Bruce's Northstar BBS that had an adventure game that Bruce had written in Basic, and he told me how to play Zork: first, dial up the NBS TIP, connect to MIT-AI (the command was "@L 134", because the ARPANET had 8 bit host numbers, and AI was 134), and apply for an account to learn Lisp. Once that was granted, I connected to MIT-DM ("@L 70"), and logged in as URANUS, password RINGS, used :CHUNAME to change my user name, and waited until one of the two people playing Zork quit, to take their slot. Later somebody told me the magic words to use to get an account on DM, so I applied for my own account on DM, claiming that I wanted to "Learn MDL for calculus and algebraic applications". The source code to Zork was well hidden. DM ran a weird version of ITS that had some kind of file security or cloaking, it was rumored. I was always looking for the Zork sources, but never found it on DM.

    Years later I googled for a unique phrase that was only in the original DM version of Zork, and this URL popped up: http://retro.co.za/adventure/zork-mdl/

    The original MDL source to Zork is really beautiful code that's almost as fun to read as it was to play. I had discovered a bug in the InfoCom version of Zork, which turned out to be in the original sources. When you're fighting the troll who's wielding an Axe, you can give anything to the troll and he will eat it. So I tried "give axe to troll" and he ate his axe, then cowered in the corner! Better yet you can go "give troll to troll" and he will eat himself and disappear, unfortunately not clearing the troll flag that is required to leave the room, so if you try to leave it prints a message saying the troll fends you off with a menacing gesture, and stops you from leaving. Sure enough, in the original sources, there is a troll flag!

    -Don

    --
    Take a look and feel free: http://www.PieMenu.com