Follow Slashdot blog updates by subscribing to our blog RSS feed

 



Forgot your password?
typodupeerror
×

Procedural Programming- The Secret Behind Spore 277

imashoe writes "Ever wonder how Spore works under the hood? The game seems to be insanely huge and how is it that there can be an infinite amount of different creates created in the game? The answer is Procedural Programming."
This discussion has been archived. No new comments can be posted.

Procedural Programming- The Secret Behind Spore

Comments Filter:
  • Well, no (Score:5, Funny)

    by ucblockhead ( 63650 ) on Sunday August 05, 2007 @11:33AM (#20122353) Homepage Journal
    Given that I've only seen videos of someone else playing "Spore", I have to say, no, I don't wonder how it works. I wonder when the hell it'll be done.
    • Re:Well, no (Score:5, Funny)

      by zn0k ( 1082797 ) on Sunday August 05, 2007 @11:43AM (#20122471)

      I wonder when the hell it'll be done.
      $ apt-cache showpkg spore
      Package: spore
      Versions:
      1.0
      Description Language:
      File: /var/lib/apt/lists/spore.maxis.com-i386_Packages
      MD5: b7b55c3327e373b0abee0ccb25902a2b
      Dependencies:
      1.0 - dukenukem3d
    • Vaporware (Score:3, Insightful)

      by IdahoEv ( 195056 )
      Someone with a subscription needs to tag this story Vaporware.

      I remember first getting excited about in-game videos of spore something like two years ago. It's starting to feel like we're getting nukem'd again.
      • Nah. Spore will come out sooner or (probably) later. Then it will feel much more like Black and White...
      • I can think of one big difference- I've never seen a video of DNF gameplay, while there's a new Spore demo vid every few months.
        • Videos of DNF were released in 1998 and 2001. The most recent one I saw was based on the Max Payne engine. Before then it had been based on the Quake II engine, and before that the Unreal engine. The switch to the Max Payne engine seems not to be mentioned in the Wikipedia article, so I might have imagined it.

          When Duke3D was released, the engine was a fair bit behind its main competitors but it was fun because of the detailed artwork (especially the huge, complex levels) and the main character's one-lin

          • Re: (Score:3, Interesting)

            by Movi ( 1005625 )
            Wrong. Duke Nukem Forever was first started using a heavily modified Quake 2 Engine(much like in spirit of Half-Life which used a heavily modified Quake 1 Engine), then near the end of development cycle a switch to the Unreal Engine was decided, with most of the work done scrapped.
            By the time they were anywhere close to beeing done UT2k3 was out, so they decided to use Unreal Engine 2. As far as i know they either use the updated Unreal 2 Engine (and inherited the fixes from UT2k4) or are working with Unr
            • Re: (Score:3, Funny)

              by TheLink ( 130905 )
              Wrong? He did say quake 2 first then unreal.

              Heavily modified or not it's not really that big a deal since it's heavily not here yet ;).

      • Re:Vaporware (Score:4, Informative)

        by MindStalker ( 22827 ) <mindstalker@gmai ... com minus distro> on Sunday August 05, 2007 @12:43PM (#20123117) Journal
        Oh come on, its only been 2 years. A lot of games have taken 3 years sense their first showing to the public till release. DNF is going on 11 years. No comparison really.
      • Someone with a subscription needs to tag this story Vaporware.

        I'm not sure which would be worse ... to nukem (is that a verb?) or to "Master of Orion 3"-em (wonderful ambition but painfully dull to play).

        Spore seems like one of those projects that, if it remains vapor too long, should spark some "Linus of gaming" to start an open-source take on the whole thing. What I love about the concept of Spore is that its so modular - add some standards and it should be possible to share all the bits and pieces o

  • by Anonymous Coward on Sunday August 05, 2007 @11:37AM (#20122393)
    to generate one meaningful article about it? since apparently it's good at increasing noise by putting out fluff pieces as this one.

    --
    captcha: uncouth. Quite.
  • not really (Score:3, Funny)

    by clubhi ( 1086577 ) on Sunday August 05, 2007 @11:39AM (#20122421)
    Actually I never even heard of Spore.
  • Eh? (Score:5, Informative)

    by MrSteveSD ( 801820 ) on Sunday August 05, 2007 @11:39AM (#20122427)
    I really feel like the person who wrote the article doesn't know what he is talking about.
    • by thegnu ( 557446 ) <(moc.liamg) (ta) (ungeht)> on Sunday August 05, 2007 @11:47AM (#20122511) Journal
      Girl: You got Spaghetti Code in my Perl!
      Boy: You got Perl in my Spaghetti Code!
      BONA FIDE REVIEWS: our content makes as much sense as our ads.
    • Re:Eh? (Score:5, Informative)

      by mmacdona86 ( 524915 ) on Sunday August 05, 2007 @11:51AM (#20122567)
      Yes, the distinction that they are probably trying to make is that between procedural or algorithmic content generation and the more common situation where content is created individually by artists.

      The talk about procedural versus object-oriented programming is moronic bs.
      • Re:Eh? (Score:4, Insightful)

        by TheGeneration ( 228855 ) on Sunday August 05, 2007 @01:00PM (#20123247) Journal
        The biggest fault with that article is that the author doesn't take into account who his audience will be. If you are going to write an article on the "breaking news" that the creators of Spore have gone to the future year of 1987 to use Pascal to write a mutliplayer online game, well... chances are the only people who will want to read your article are programmers. So don't bother trying to explain Ryu's fireball to us, we got that back in 1990 when Ryu spit out his first fireball in front of our eyes. Instead give actual details that are worth reading to your potential audience.
      • Re:Eh? (Score:4, Informative)

        by MrSteveSD ( 801820 ) on Sunday August 05, 2007 @01:31PM (#20123559)

        Yes, the distinction that they are probably trying to make is that between procedural or algorithmic content generation and the more common situation where content is created individually by artists.


        Yeah, that would be something interesting to talk about. Whoever wrote the article probably isn't the man to do it though. Did you ever play Kreiger? http://www.theprodukkt.com/kkrieger#20 [theprodukkt.com] They managed to cram a 3D first person shooter into 96k. It relies heavily on procedurally generated content.
    • Re: (Score:3, Interesting)

      by tundra_man ( 719419 )
      Yes I would have to agree. The method of programming being discussed is more akin to a Finite State Machine (FSM) in which you describe various states, events which cause state transitions and of course the define what all happens during the transition. It is a valid programming methodology and is used in telephony and other places. One popular application for working with such code was Rational ObjecTime which became part of the Rational Rose product before Rational was bought by IBM. Where FSM has trouble
    • Re: (Score:2, Funny)

      by ultranova ( 717540 )

      I really feel like the person who wrote the article doesn't know what he is talking about.

      Nah. Procedural programming is indeed what made a project of this complexity possible. Just try to program Spore in line-number Basic, I dare you.

  • Crap alert (Score:5, Informative)

    by VeryProfessional ( 805174 ) on Sunday August 05, 2007 @11:39AM (#20122429)
    This article reads like pure garbage. Procedural programming [wikipedia.org] simply refers to any form of programming in which procedure calls are made... ie. any mainstream imperative programming language. Does anybody really believe that games fill up multiple DVDs because there are too many IF statements? Editors, wake up please.
    • Re:Crap alert (Score:4, Insightful)

      by el_womble ( 779715 ) on Sunday August 05, 2007 @11:49AM (#20122549) Homepage
      I think the author was confused. What they actually meant was functional programming. In fact I know the author was confused. How did they not make the connection that the 4 CD PS1 games had a lot of FMV?

      An excellent example of a little knowledge doing a lot of harm. It reads well enough that my non coding tech friends could read it, and then tell me I'm a fuck-gnut for not using a procedural language...

      Still, I'm going to assume that the eds know what they're doing and are actually just trying to get an argument blaring on this no news sunday.
      • Which itself is hardly revolutionary given that functional programming has been around for four decades.

        The comments about Civilization are particularly annoying.

      • bzzt, wrong. (Score:5, Interesting)

        by Inoshiro ( 71693 ) on Sunday August 05, 2007 @01:55PM (#20123781) Homepage
        They meant procedural content generation, like L systems [wikipedia.org], used to make believable looking plants that grow and change over time.

        It's all about repeated iteration over a particular type of finite automata with a particular string.. Easily done if you've taken your 3xx/4xx graphics an theory classes, but perhaps past what most technology reporters are capable of.

        So, to summarize:
        * C is an example of procedural programming.
        * Haskell is an example of functional programming.
        * L-systems are an example of procedural content generation (content generated by a procedure, in a deterministic fashion).

        • Thank you! (Score:3, Informative)

          by quax ( 19371 )
          The beauty of /. is that even an absolute crap article will in most case get somebody to point out what actually was newsworthy about the item. So to summarize: It seems that the game allows the user to create their own procedural content generation [wikipedia.org] through the use of editors.
        • Re:bzzt, wrong. (Score:5, Insightful)

          by fireboy1919 ( 257783 ) <rustyp AT freeshell DOT org> on Sunday August 05, 2007 @06:33PM (#20125723) Homepage Journal

          So, to summarize:
          * C is an example of procedural programming.
          * Haskell is an example of functional programming.
          * L-systems are an example of procedural content generation (content generated by a procedure, in a deterministic fashion).
          To continue the summary (and clarify):
          * Marshmallows do funny things if you lower the pressure enough.
          * Cheeseburgers are often considered delicious
          * Like the above comments, programming language type is a red herring. Procedural content generation is a misnomer. It just means that the content is mostly programatically generated on the fly instead of being simply rendered.

          It's all about repeated iteration over a particular type of finite automata with a particular string.

          And then then string is the content, isn't it? Interesting point here is that this is something of a continuum. You could make your procedures more complex, and then require less content to produce the something. On the other hand, you could go the other way and have absolutely every piece of content actually be written in your programming language.
          When you think about it that way, it becomes a lot more obvious.
          You're talking about whether most of the work is going into the content creation, or into the rendering engine.

          If most of the work is in the engine, it's really easy to make lots of new kinds of content since you don't have to do as much work to make the content. However, making a powerful engine sure requires a lot of work, doesn't it? You have to make your engine handle absolutely every special case that you could ignore if it wasn't normally applicable to a very specific content instance.
    • Re:Crap alert (Score:5, Insightful)

      by geeknado ( 1117395 ) on Sunday August 05, 2007 @11:53AM (#20122605)
      I think that part of the issue here is that they've both confused the concept of procedural programming(and I'd be shocked if most games weren't programmed procedurally) with procedural generation [wikipedia.org] then proceded to give a better description of the first.

      It's not that they're wrong that Spore is innovative this way(assuming it's ever more than vaporware), but rather that they do an exceptionally poor job of describing the way it works...The distinction here isn't between gated logic trees and 'actions', it's between static and dynamic content.

      • Re: (Score:3, Informative)

        by init100 ( 915886 )

        I think that part of the issue here is that they've both confused the concept of procedural programming(...) with procedural generation then proceded to give a better description of the first.

        Exactly. And procedural generation isn't hard to understand (at least conceptually), he could just have given a brief on fractals, since they are a well-known example of procedural content generation. A tiny piece of code generates a nice-looking picture. And regardless of how much you zoom in, it never becomes pixelated, as new content is generated on the fly. The Mandelbrot set is an excellent example.

    • Agreed, the original article is crap.

      What is "procedural" about Spore is its game and interface design. Much of it is conceptually procedural. It is comparable to the sort of parameterization that you might find in a 3D design tool (Solidworks, Inventor, etc.)

      I'm almost certain that it is implemented mostly in C++ and other modern, mostly OO languages.
      • by kabz ( 770151 )
        It would read a lot better if he had said 'procedural rendering'. In that case, it conveys the idea that code is used to generate what you see, rather than fixed data files.

        Here's a Wikipedia linkie [wikipedia.org]. And yup, you've guessed it, there's a picture of Spore.
    • Re: (Score:3, Funny)

      This article makes baby von Neumann cry
  • hype (Score:2, Insightful)

    There is no way spore is going to live up to the hype they keep generating. Even if it is a moderate financial success people will view it as a failure because of expectations. as far as procedural programming is all bull, they're franticly animating to fix the impossible procedural animation system. My prediction is that it will be delayed and be a disappointment to anyone who is expecting the greatest game ever.
  • Inifinite Creates? (Score:5, Insightful)

    by eldavojohn ( 898314 ) * <eldavojohn@gma[ ]com ['il.' in gap]> on Sunday August 05, 2007 @11:43AM (#20122461) Journal

    The game seems to be insanely huge and how is it that there can be an infinite amount of different creates created in the game?
    The word infinite gets abused quite a bit.

    I think you meant to say 'seemingly infinite' or 'infinite for all intents and purposes.'

    I've tried to think of mental exercises to challenge people with a concept of something being infinite. For example, if you had an object of infinite mass with no gravity, would it be possible for us to exist alongside this infinite object?

    Infinity has interesting properties and I challenge the use of 'infinite' in this summary. The article uses cautious words:

    Procedural programming essentially shrinks the technological world, allowing us to fit a lot more information in limited space, and allowing this information to interact in near infinite ways.
    The basic theory of how one would store infinite states of data instantly disqualifies any device I know of. Computers, game systems, etc. are ultimately storing data in a binary on/off form. You can story many bits of data and come up with many states very quickly. You cannot, however, store an infinite amount of states on a finite amount of bytes. There's just no way to do it. A very large amount of different states? Of course. But not an infinite amount.

    For the purposes of speculation, what would be the best way to give a user a seemingly 'infinite' number of states? Well, the obvious choice (and what random number generators on computers seem to favor) is to use time. Time is infinitely divisible (although the representation of that depends on decimal precision) and it is (seemingly) never ending. So one would base the resulting states in the game off of when a user entered input. It is still very easy to show that this is a many-to-one mapping. You can divide time down to a small enough unit that they are technically different moments yet the hardware that captures the analog input cannot discern between them.

    I think that this concept of 'infinite' states is desirable to gamers. And it's the states that you find yourself in in a game that were clearly not thought out by the developers that makes a game special. When you have a large freedom of configuration pitted against players with that same freedom, you have the core success behind real time strategy games where players would build cities and armies and pit them against each other.

    I don't think this claim can ever be made when a digital machine is being used. I guess you could design a program that would adjust to the size of the machine and extrapolate the amount of precision it used to measure the moment at which the user clicked the remote button and then stamped this number on the create's forehead (or some other form of uniqueness). But, I do not know enough about how the CPU acquires the time stamp. If it's a quartz crystal, this is only accurate to the number of vibration the crystal makes per second with electricity pumped through it. I have good reason to believe you will always encounter some theoretical issue or barrier when trying to achieve truly infinite implementations. Best to leave that word where it belongs: in mathematicl proofs and scientific theories.
    • For example, if you had an object of infinite mass with no gravity, would it be possible for us to exist alongside this infinite object?

      Yes. Because for there to be an infinite object that would necessitate that the Universe be infinite. Now I am aware that the infinite object should completely fill the infinite universe.
      However infinite + 1 = infinite. So in that "+ 1" there is room for me. It could be argued that there should also be an infinite amount of empty space left over in the infinite universe
    • I think the author meant infinite crates. [slashdot.org]
    • Re: (Score:2, Insightful)

      by OpCode42 ( 253084 )
      Time is infinitely divisible

      This may not be as true as you think. Planck time [wikipedia.org] is the shortest amount of time that has any meaning.
    • by Fractal Dice ( 696349 ) on Sunday August 05, 2007 @01:58PM (#20123811) Journal

      The word infinite gets abused quite a bit.

      I agree ... but you really need a good catchy word for "cannot have all possible states represented even if you harnessed every grain of sand in the universe".

      According to one of the talks, a Spore world is about an 80K data structure when compressed. 2^640000 is a really big number. My fuzzy back-of-the-napkin count gives something like 2^240 hydrogen atoms in the universe. I think hard math either needs to learn to share the word infinite or it had better file a trademark :)

  • The obvious (Score:2, Insightful)

    by Anonymous Coward
    The article author has no clue.
  • by Asgerix ( 1035824 ) on Sunday August 05, 2007 @11:47AM (#20122515) Homepage
    Perhaps the author is confusing Procedural Programming with Procedural Generation [wikipedia.org]?
  • by SolusSD ( 680489 ) on Sunday August 05, 2007 @11:49AM (#20122535) Homepage
    use a functional programming language. prove mathematically that your functions are correct. and technically, it should be fairly easy to write compilers that automatically thread the program due to the nature functions are written in a functional programming language. i encourage everyone, especially the writer of this article, to read up on it. Haskell (a programming language) is a good place to start.
  • by Anonymous Coward on Sunday August 05, 2007 @11:49AM (#20122537)
    "The basics of sequential programming are all object oriented."

    That pretty much captures how well the author understands programming.
  • What the writer is describing is NOT procedural programming but rather some sort of event-driven programming.
  • Article Sucks (Score:5, Insightful)

    by jlarocco ( 851450 ) on Sunday August 05, 2007 @11:55AM (#20122627) Homepage

    That article is terrible. It reads like a 9 year old trying to explain something he doesn't understand.

  • by loconet ( 415875 )
    wtf is going on here? Did he just explain functions?
  • by tcopeland ( 32225 ) <tom@th[ ]sleecopeland.com ['oma' in gap]> on Sunday August 05, 2007 @12:05PM (#20122727) Homepage
    ...that is, this game [mobygames.com] which had an "infinite" universe. The book Infinite Game Universe [amazon.com] has some good discussions of this sort of thing, too.
    • Mission: Thunderbolt was always my favorite. Not just the maps varied between plays, but also the creatures you encountered and when you encountered them. You could play a game and not see a single Icky Lump but find a Disruptor Pistol, then play a new game and see thousands with no Disruptor Pistols in sight.
  • Functional (Score:5, Interesting)

    by hey ( 83763 ) on Sunday August 05, 2007 @12:06PM (#20122737) Journal
    *Functional* programming sometimes seems like magic. Maybe that's what they are talking about.
    Its not new but still cool.
    http://en.wikipedia.org/wiki/Functional_programmin g [wikipedia.org]
  • The game seems to be insanely huge and how is it that there can be an infinite amount of different creates created in the game?
    It's not possible to have an infinite amount of states in a finite state machine (like our turing machines [wikipedia.org]).

    There will at most be 'a lot' of different combinations.
    • Exactly. to have an infinite amount of states takes an infinite amount of memory to represent the possible states. you're pretty much limited to less than 2^(2^32) states on a 32-bit machine. and in practice you'd never get anywhere near that.

      People don't realize that a computer is just a container for a state. all the abstract layers of software and OS and whatnot are just a mechanism to move it to the next state.
  • Is something that has been in use a long time - so it's not new. Anybody familiar with the classic programming languages Basic, Pascal, C and many more can't help that they feel familiar here.

    Of course - since many today tend to do object oriented programming (for good and bad) the procedural programming may seem "fresh" for some.

    And there are other programming areas that can be considered too;

  • by whitroth ( 9367 ) <whitroth@5-cent . u s> on Sunday August 05, 2007 @12:40PM (#20123067) Homepage
    who literally know *zip*. I just dipped my toes in the article, and lines like "procedural programming is ... object oriented..." snapped any suspenders of belief I had in the article.

    Of course, it'll be smaller and faster than Objectionably-oriented software....

                mark
  • 3 times, and I still can't make sense of it.

    The author can't be talking about procedural programming in the classic sense. On a re-read, I suspect that "procedure" is somehow equivalent to "action". Especially the part about building weapons from components.

    The implication is that "Spore" (whatever that is) has a calculus of action. Which (almost) makes sense. I imagine (again, back to the weapon example), that a cartridge contains "x" grams of explosive, that yeilds a force, acting on the ballistic compone
  • What the hell is this article talking about? I can tell that the author either doesn't know how to program, or he doesn't know how to break it down into non-tech speak. Either way, the article doesn't make much sense.

    As for procedural programming... I'm not sure how it would be possible to write an interactive multi-player procedural program without using the concept of an object. Especially when there is customization at the level that Spore claims to have. I really think perhaps the author of the arti
  • Comment removed (Score:5, Interesting)

    by account_deleted ( 4530225 ) on Sunday August 05, 2007 @01:02PM (#20123267)
    Comment removed based on user account deletion
  • by Afecks ( 899057 ) on Sunday August 05, 2007 @01:18PM (#20123435)
    A little help please? Does anyone have a slashdot-editor-to-enlgish translator?
    • Re: (Score:3, Funny)

      by cowens ( 30752 )
      No, they are already speaking in enlgish. We need an enlgish-to-English translator.
  • From the description, this doesn't sound like procedural programming. It sounds like a rule engine. One of those things where there are rules that fire if the current situation meets all the preconditions. Multiple rules can fire simultaneously, and you need conflict-resolution logic to to choose which one to use when there's a conflict. If rules fire that want to set both "turn=right" and "turn=left", then some priority system or random choice has to pick one. And some hysteresis may be needed to preven

  • I can't believe this made it to slashdot. I can understand confused articles about patent law, copyright law and politics, but this is supposed to be a web site that appeals to people who have some clue about how computer software works. The article referred to is a pile of drivel, full of technical errors written in something that is a long way from coherent English. Maybe this belongs of the OMG!!! version of slashdot, but certainly not anywhere else.

  • ...numerical numbers, or am I confusing it with visual graphics?
  • by IonOtter ( 629215 )
    I just wanna play God! [vgcats.com]

    Why do you abuse my games so? - Will Wright
  • The article is plagued with incorrect semantics and definitions(CS Discipline).
    It's sad and troublesome to witness Slashdot plastering (posting?) this article.
    It talks against the editors and the site in general.
  • As a game programmer, I'm actually offended by this article. Why do I get the feeling it was written by a football jock who used to bash me (and other game programmers) up at high school? I was going to list the mistakes made in the article, but realized the entire article (even its name) is wrong. I spent 5 minutes looking around Slashdot for a "Bury" button, can someone contact the Slashdot President and tell him to launch a preemptive military strike on any future articles of this quality.
  • by Cafe Alpha ( 891670 ) on Sunday August 05, 2007 @03:06PM (#20124299) Journal
    ... and COBOL

    Yes I noticed poster tagged the article "wrong."
  • Anyone recall that 'game'/screensaver?

    it would generate unique animated fish of uncountable variety, and show them swimming around, and you could breed pairs together to generate realistic children and such...

    I tried running it on a 486 once, unfortunetly, it was so much faster than the system is was designed for, it didn't work (first thing on program startup was a benchmark, seeing how many minutes it took to generate a fish... since it took less than one minute, it crashed with a divide by zero)
  • by Dormann ( 793586 ) on Sunday August 05, 2007 @05:04PM (#20125147)
    • Programs use if statements
    • The more complex the program, the more if statements
    • FF7 filled 4 CDs with if statements
    • Spore is even more complex than FF7
    • Spore must be using some new programming paradigm
    • I'm confused about what the paradigm is or what it's called, but I'm sure it uses fewer if statements
  • by S3D ( 745318 ) on Sunday August 05, 2007 @11:45PM (#20127215)
    The link form TFA no gives:

    We appreciate the honest feedback and correction regarding the content of this article. While it was well intentioned, it was inaccurate and for that we apologize. Accordingly this article has been removed.

    Something not good going with slashdot choice of article lately.
  • Article pulled (Score:3, Informative)

    by gatesvp ( 957062 ) on Monday August 06, 2007 @02:26AM (#20127793)
    Well fellow /.ers, the article was pulled (anyone have an original for laughter purposes?) I'm oddly proud of the /. community for successfully cleaning cruft from the vast sludge of the internet. If only with could do this stuff for mainstream media... like any of us bother any more :)

The explanation requiring the fewest assumptions is the most likely to be correct. -- William of Occam

Working...