miniDooM: And There was Motion (and Polygons!)

So I finally decided to stop stalling and got around to installing and using some screencast capture software on Ubuntu. Here's the result:

Now for the analysis:

First, the image. A few things of note:

  • There's still the white noise effect in the background, probably killing the gif's framerate.
  • The red Doomie is automatically following the green Doomie with it's head. I did try to control both Doomies at once, but after a couple pityful takes decided to automate it.
  • No, there's no collision with the map.
  • Yes, the Doomies do sort themselves based on position.
  • You can see the intersection code in action.
  • Finally, it is noticeable that the green Doomie's head starts bouncing in a weird way. That's the head's animation going out of synch with the body's animation. Working on it.

Secondly, I've done the gif screencast recording with the following:

  • Linux: I'm using Byzanz, with a custom script that allows selecting a window for the recording.

    You can install it under Ubuntu 12.10/12.04/11.10 or Linux Mint 13/12 using the following terminal commands:

    sudo add-apt-repository -y ppa:fossfreedom/byzanz
    sudo apt-get update
    sudo apt-get install -y byzanz

    Once installed, the following command will record a GIF screencast:

    byzanz-record --duration=15 --x=xPos --y=yPos --width=width --height=height outputFilename.gif
    • xPos & yPos: X and Y coordinates on the screen
    • width & height: Record area width and height

    The output file will be written to the directory the command was run from.

    For more help, you can run this command:

    byzanz-record --help

    You can check the upubuntu.com article I got this from if you like.

    As for the script that lets you select an specific window and it automatically sets the position and size:


    # Delay before starting

    # Sound notification for recording start/end
    beep() {
    paplay /usr/share/sounds/KDE-Im-Irc-Event.ogg &

    # Duration and output file
    if [ $# -gt 0 ]; then
    echo Default recording duration 10s to /tmp/recorded.gif
    D="--duration=10 /tmp/recorded.gif"
    read X < <(awk -F: '/Absolute upper-left X/{print $2}' <<< "$XWININFO")
    read Y < <(awk -F: '/Absolute upper-left Y/{print $2}' <<< "$XWININFO")
    read W < <(awk -F: '/Width/{print $2}' <<< "$XWININFO")
    read H < <(awk -F: '/Height/{print $2}' <<< "$XWININFO")

    echo Delaying $DELAY seconds. After that, byzanz will start
    for (( i=$DELAY; i>0; --i )) ; do
    echo $i
    sleep 1

    byzanz-record --verbose --delay=0 --x=$X --y=$Y --width=$W --height=$H $D

    For the original script, as well as a couple other scripts, you can check the askubuntu.com post I got this from.

    The rest of the thread has alternatives to Byzanz.

  • Windows: Use LICEcap. Seriously, it's pretty sweet.

So that's all for now. On to collisions!

No comments:

Post a comment