14 March 2012

Rcmdr on Ubuntu

On Windows, R comes with its own GUI, but on Ubuntu, GUIs such as Rcmdr have to be installed manually.

Software sources

Add a local CRAN mirror to Ubuntu, e.g. http://cran.stat.ucla.edu/, which corresponds to USA-California 2. Remember the mirror you add, because it will be the only one that will be allowed by Ubuntu to fetch software packages. Anyway, add /bin/linux/ubuntu/oneiric at the end of the URL (change oneiric for your ubuntu version). This should give the screenshot below:

Then execute:

sudo apt-get update
sudo apt-get install r-base r-base-dev

Installing Rcmdr in R

sudo R

Then in the R command line:

install.packages("Rcmdr")

Then, finish the installation of Rcmdr by installing the missing dependencies:

library(Rcmdr)

A popup appears, select "CRAN mirror" (not "local folder"), click OK, and the console should start printing lines like below:

Loading required package: tcltk
Loading required package: car
Loading required package: MASS
Loading required package: nnet
Loading required package: survival
Loading required package: splines
also installing the dependency 'matrixcalc'

trying URL 'http://cran.stat.ucla.edu/src/contrib/matrixcalc_1.0-1.tar.gz'
Content type 'application/x-tar' length 8436 bytes
opened URL

...

The downloaded packages are in
 '/tmp/Rtmp6X20rs/downloaded_packages'

And the Rcmdr window should appear. To run Rcmdr in the future, type library(Rcmdr) in the R command prompt. Ctrl-A then Ctrl-R to run everything.

Encountered errors

An error like package 'Rcmdr' is not available (for r version 2.13.1) pops up if R was installed from the Ubuntu repository. The current version (as of March 2012) is 2.14.2. sudo apt-get update, then sudo apt-get install r-base r-base-dev should fix this. If you have the same error with not available (for r version 2.14.1), it may be that no CRAN mirror was added in the software sources to download Rcmdr from.

Sources

04 March 2012

The Beautiful Road: A Writer’s Guide to Putting Gameplay First

Notes from a CGVW talk by Dave Kosak, a Blizzard quest designer, at UC Irvine on February 22nd 2012. Original talk called "The Beautiful Road: A Writer’s Guide to Putting Gameplay First" delivered at GDC Online 2011.
TLDR: When gameplay comes first, story-telling must make it beautiful, not suffocate it. There are different ways than text to convey story and characters.

The problem

Games can be story-driven (RPG or interactive fiction), gameplay-driven (Blizzard's "gameplay first"), technology-driven (early games on Kinect, or to show off a 3D engine like Crysis), or money-driven (Zynga). How can stories be included in gameplay-driven games?

Looking at other media, telling a story requires different amounts of time: books take 10 hours, movies 2 hours, sitcom episodes 20 min. Books are walls of text, movies have long scripts, and sitcon episodes have at most 3-page scripts.
In MMOs, it's hard to display walls of text: there's a limited amount of screen and UI real-estate, and players have a limited amount of attention. Players can pay attention to the story most in calm solo exploration, slightly less in group quests, even less in dungeon raids, and nearly not at all in intense PvP.

In Diablo, the core gameplay activity is kill -> loot -> sell -> repeat. Content designers should not obstruct the core activity, e.g. with cutscenes during game action. Instead, content designers should enhance the core gameplay activity. If gameplay is a road, content should be beautiful flowers on the side of the road.

Brevity is key. Example: the Red Dead Redemption mission called free the captured sheriff. When the player sees this line popping on the screen, and the minimap showing markers for sheriff, outlaws, and nearby weapons, she figures out herself what to do first: she could go save the sheriff, kill outlaws, or look for a powerful weapon. Moreover, the quest becomes an answer to the situation presented to the player: why has the sheriff been captured? Which kind of person is the sheriff?

Telling a story without a wall of text is possible through:

  • dynamic level design
  • dynamic environment aesthetics (changing to reflect quest progression/completion)
  • events triggered when player arrives
  • hints in NPC or enemy dialogues

Characters

Character geometry: balance between too few traits = cliche, and too many traits = too complicated + boring + harder to understand. Example: Sylvanas Windrunner is persistent, protective, and hard-hearted. When she becomes undead, all her traits are even more accentuated. Other example: Han Solo is cocky, scoundrel, and egocentric.

Interactions with other characters and the background of the character let us know, without the need for a wall of text, a character's traits. Ex: Han Solo leaves his friends when they need him, Luke meets him in a shady place, he owes money to Jabba.

Quirks are not traits: quirks are minor and only serve to further individualise a character. You can find a list of traits there.

  • 1-dim characters: enemies or minor allies. Ex: Hungry ogre.
  • 2-dim, with 1 expected and 1 unexpected = interesting: quest givers and companions. Ex: elf druid who is protective (expected) + violent (unexpected).
  • 3-dim: franchise characters such as Arthas = cocky + practical + naive. Only and exactly those 3 traits make him pick Frostmourne. When he turns undead, naive becomes power-hungry.
  • 4-dim: Freeman's character diamond. Often leads to contradictions between traits, also called masks, which can either be total pretense (clown pretends he's happy but is actually depressed), partially revealing, or representing a character's aspirations. Used in marketing personas and novels.

How to compel people to a character: Cf Writing screenplays that sell:

  • sympathy
  • jeopardy (we want Indiana Jones to survive)
  • talent/good at what they're doing
  • funny
  • heroic/noble
  • independent/do their own thing/own quirks
  • artistic/admires beauty (ex: Sherlock Holmes plays the violin)

Cliches can be used as a shortcut to establish a character. When established, take the cliche, and throw it away: Her eyes were as blue as the sky can become Her eyes sparkled like saphires on black velvet (jewels give a refined connotation) or Her eyes were the same milky blue as my mother's eyes were before I killed her (surprise and suspense!).

Social status shows differences between high-class people (smooth movement, complete sentences, slow speech, direct eye contact) and lower-class people. Body language also works. Cf the movie 300. Changing status generates interesting dramatic situations. Ex: the boss has high status at work, but when he's back home, he's low status obeying his wife.