Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • December 04, 2016, 06:28:14 PM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: The little bug who grew up to become a feature  (Read 4403 times)

Eóin

  • Charter Member
  • Joined in 2006
  • ***
  • Posts: 1,401
    • View Profile
    • Donate to Member
The little bug who grew up to become a feature
« on: April 05, 2010, 02:23:42 PM »
This is a cool little story about a programming arithmetic bug which caused such a cool effect it became a feature. It's a post Bug or feature? from Shawn Hargreave's blog.


Stephen66515

  • Animated Giffer in Chief
  • Honorary Member
  • Joined in 2010
  • **
  • Posts: 3,129
    • View Profile
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #1 on: April 05, 2010, 05:08:28 PM »
Wow, such a cool feature caused by such a small accident in the coding stages!  :Thmbsup:

f0dder

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,029
  • [Well, THAT escalated quickly!]
    • View Profile
    • f0dder's place
    • Read more about this member.
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #2 on: April 05, 2010, 05:56:11 PM »
Nice bug :)

Hadn't see the Shawn Hargreaves name for a long time, brings back memories of DJGPP+Allegro days.
- carpe noctem

JavaJones

  • Review 2.0 Designer
  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 2,717
    • View Profile
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #3 on: April 05, 2010, 09:34:05 PM »
Hehe, cool story. :)

- Oshyan

Daleus

  • Supporting Member
  • Joined in 2007
  • **
  • Posts: 146
    • View Profile
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #4 on: April 07, 2010, 08:23:25 AM »
Interesting story.

Without trying to be too philosophical about it, I wonder if there is a lesson to be learned from the story when considering AI.

It would be prudent when working on Artificial Intelligence projects, that we not mistake coding errors for human behaviour.

And that's about as deep as I can go - the thought just popped into my head when reading the blog post.

Please, return to your normally scheduled aspirating.

Daleus, Curmudgeon-at-Large

housetier

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • default avatar
  • Posts: 1,321
    • View Profile
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #5 on: April 10, 2010, 05:49:42 PM »
Quite a remarkable story of how subtle differences in rules can lead to completely unexpected behavior  :Thmbsup:

nharding

  • Member
  • Joined in 2006
  • **
  • default avatar
  • Posts: 36
    • View Profile
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #6 on: April 11, 2010, 05:41:49 PM »
Although it wasn't a bug, one of the first games I wrote was Hyperball for the Atari ST. You control a spaceship and fire at a puck to score goals by guiding it into the opponents score line. I had reasonably accurate physics (I think the conservation of angular momentum was just hack rather than correctly implemented from memory), which give the masses of the ships compared the projectiles you fired meant it was better to ram the puck than to fire shots at it. So I made it so that it wouldn't ram the puck (unless the player started to do so, and which case I would up the aggressiveness of the AI). It worked well, but since it would use prediction, so it would work out how far the puck was from the ship, what the movement vectors would be when the shot would get there etc, that it was almost impossible to beat the AI. I just added a difficulty level, on hardest difficulty it would run the AI code every other frame, (it originally ran every frame), and would just run it less often on the easier levels.

All the code was in 68000 assembly language, I miss programming in assembly language now (well I don't miss x86 assembly language that much :))

Neil Harding

Deozaan

  • Charter Member
  • Joined in 2006
  • ***
  • Points: 1
  • Posts: 7,713
    • View Profile
    • The Blog of Deozaan
    • Read more about this member.
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #7 on: September 21, 2010, 09:01:44 PM »
It's a really cool story, but I wonder how that bug made it through testing. :-\


Josh

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Points: -5
  • Posts: 3,395
    • View Profile
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #8 on: September 21, 2010, 09:08:35 PM »
Is this how Find-And-Run-Robot came to be?

f0dder

  • Charter Honorary Member
  • Joined in 2005
  • ***
  • Posts: 9,029
  • [Well, THAT escalated quickly!]
    • View Profile
    • f0dder's place
    • Read more about this member.
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #9 on: September 22, 2010, 03:38:53 PM »
It's a really cool story, but I wonder how that bug made it through testing. :-\
Testing?
- carpe noctem

Deozaan

  • Charter Member
  • Joined in 2006
  • ***
  • Points: 1
  • Posts: 7,713
    • View Profile
    • The Blog of Deozaan
    • Read more about this member.
    • Donate to Member
Re: The little bug who grew up to become a feature
« Reply #10 on: September 23, 2010, 03:25:47 AM »
It's a really cool story, but I wonder how that bug made it through testing. :-\
Testing?
Er... Sorry, I don't know what came over me. I'm not sure what I was thinking. ;)