<<

IntroducingIntroducing PNFGPNFG

FFéélixlix MMaarrttinineeaauu PPNNFFGG

 IInn aa nnuuttsshheell:ll: – A layer on top of Narrative Flow Graphs PNFG – – Compile to get the NFG

NFG PPNNFFGG

 TThhee GGooaall – Make it easy to produce NFGs for complex narratives PNFG

NFG OOvveerrvvieieww

 FFeeaattuurreess ooff tthhee PPNNFFGG lalanngguuaaggee  IImmpprroovveemmeennttss  WWhhyy itit isis imimppoorrttaanntt  OOtthheerr aapppprrooaacchheess – – TADS  PPoossssibibilitilitieiess ffoorr tthhee ffuuttuurree PPNNFFGG

 SSyysstteemm OOvveerrvvieieww

PNFG

Graphic nfg File Representation

Play the narrative

NFG PPNNFFGG –– TThhee FFeeaattuurreess

 TThhee uusseerr ccaann uussee ddififffeerreenntt ccoonnssttrruuccttss ttoo ccrreeaattee tthheeirir nnaarrrraattiviveess – A) Rooms – B) Objects – ) States – D) Actions PPNNFFGG –– TThhee FFeeaattuurreess

 TThhee uusseerr ccaann uussee ddififffeerreenntt ccoonnssttrruuccttss ttoo ccrreeaattee tthheeirir nnaarrrraattiviveess – A) Rooms . Represents the physical locations in our narrative . Act as containers for the objects . We define actions inside rooms PPNNFFGG –– TThhee FFeeaattuurreess

 TThhee uusseerr ccaann uussee ddififffeerreenntt ccoonnssttrruuccttss ttoo ccrreeaattee tthheeirir nnaarrrraattiviveess – A) Rooms . Represents the physical locations in our narrative . Act as containers for the objects . We define actions inside rooms

– The Player is also a room  RRoooomm:: PPNNFFGG –– TThhee FFeeaattuurreess

 TThhee uusseerr ccaann uussee ddififffeerreenntt ccoonnssttrruuccttss ttoo ccrreeaattee tthheeirir nnaarrrraattiviveess – B) Objects . The entities that the player can interact with PPNNFFGG –– TThhee FFeeaattuurreess

 TThhee uusseerr ccaann uussee ddififffeerreenntt ccoonnssttrruuccttss ttoo ccrreeaattee tthheeirir nnaarrrraattiviveess – C) States (binary) . Can be associated with either rooms or objects . Room Example : A bedroom is lit or unlit . Object Example : A door is locked or unlocked PPNNFFGG –– TThhee FFeeaattuurreess

 TThhee uusseerr ccaann uussee ddififffeerreenntt ccoonnssttrruuccttss ttoo ccrreeaattee tthheeirir nnaarrrraattiviveess – D) Actions . Used to make the narrative progress . We move stuff around . We set states PPNNFFGG –– TThhee FFeeaattuurreess

 MMoovveemmeenntt aaccttioionnss :: PPNNFFGG –– TThhee FFeeaattuurreess

 SSttaattee--aaltlteerriningg aaccttioionnss :: PPNNFFGG

 UUssiningg PPNNFFGG – 1) To generate a graphical representation of the narrative flow graph

. . . PPNNFFGG

Output for a trivial narrative PPNNFFGG

 UUssiningg PPNNFFGG – 2) To generate the corresponding nfg file PPNNFFGG

 RRuunn inintteerrpprreetteerr wwitithh tthhee ggeenneerraatteedd ffileile ttoo ““pplalayy”” tthhee nnaarrrraattivivee PPNNFFGG

 PPNNFFGG TTooddaayy – Allows do define simple narratives . First part of “Return to ” – Limitations . The inconveniences of the language . The NFG explodes rapidly IImmpprroovviningg PPNNFFGG

 LLaanngguuaaggee eennhhaanncceemmeennttss – An explicit move hierarchy – Having a “hint” action – Adding counters – Automatic message generation for rooms . “You enter room x” . “You leave room x” IImmppoorrttaannccee ooff PPNNFFGG

 MMaakkeess itit eeaassyy ttoo ccrreeaattee nneeww nnaarrrraattiviveess  SSeerrvveess aass aa vvaalidlidaattioionn ffoorr tthhee eennttiriree nnaarrrraattivivee ffloloww ggrraapphh aapppprrooaacchh OOtthheerr AApppprrooaacchheess

 11)) IInnffoorrmm – “A Design System for ” – Created in 1993 – Need the following to create works: . . Library OOtthheerr AApppprrooaacchheess

 11)) IInnffoorrmm – Hundreds of “interactive fictions” are available

– Uses the Z-Machine to run games . Virtual Machine created in 1979 . The inform games are made for the Z-Machine . Also runs games from . So, you need a Z-Machine interpreter OOtthheerr AApppprrooaacchheess

 11)) IInnffoorrmm – Features a customizable parser . Resolves ambiguities . Can ask for clarification on inputs ("Which key do you mean...?") . Deals with pronouns . Deals with vagueness . Deals with conversation . Supports five languages OOtthheerr AApppprrooaacchheess

 11)) IInnffoorrmm – Full object orientation – Message passing – Data encapsulation – Creation / Deletion of objects at run-time OOtthheerr AApppprrooaacchheess

 11)) IInnffoorrmm – Rooms are defined as classes

A room in Inform OOtthheerr AApppprrooaacchheess

 11)) IInnffoorrmm – Object is a construct – You define how an object react to actions OOtthheerr AApppprrooaacchheess

 11)) IInnffoorrmm – Obviously a tried and tested approach – User Manual has 572 pages and is available on Amazon OOtthheerr AApppprrooaacchheess

 22)) TTAADDSS – Text Adventure Development System – Created in 2001 – Object-oriented – Latest version uses HTML for formatting

– Compiler / Library / Interpreter Combo OOtthheerr AApppprrooaacchheess

 22)) TTAADDSS – Room is a class

Sample room in TADS OOtthheerr AApppprrooaacchheess

 22)) TTAADDSS – Objects extend library classes

Objects in TADS OOtthheerr AApppprrooaacchheess

 IInnffoorrmm aanndd TTAADDSS aarree oobbvvioiouusslyly ttwwoo vveerryy ggoooodd ssyysstteemmss ttoo ccrreeaattee nnaarrrraattiviveess  WWhhyy ddoo wwee nneeeedd PPNNFFGG ?? OOtthheerr AApppprrooaacchheess

 NNeeitithheerr IInnffoorrmm oorr TTAADDSS wweerree ccrreeaatteedd wwitithh tthhee rreeqquuirireemmeenntt ooff aannaalylyzziningg nnaarrrraattiviveess  TThhisis isis oouurr uultltimimaattee ggooaall !! OOtthheerr AApppprrooaacchheess

 WWoouuldld bbee vveerryy nnicicee ttoo bbee aabblele ttoo ccoonnvveerrtt IInnffoorrmm oorr TTAADDSS ttoo ppnnffgg ffileiless  BBeeffoorree wwee ccaann aatttteemmpptt tthhisis,, tthhee lalanngguuaaggee nneeeeddss ttoo mmaattuurree FFuuttuurree WWoorrkk

 AAdddd aannootthheerr lalayyeerr ttoo aannaalylyzzee tthhee nnaarrrraattivivee ffloloww PNFG ggrraapphhss wwee pprroodduuccee – Find dead ends in narrative – Derive properties NFG . Complexity of narrative – Find the steps that leads to the solution ? ANALYZER PPoossssibibilitilitieiess -- PPNNFFGG IIDDEE PPoossssibibilitilitieiess -- PPooppuulalarritityy

 TThhee tteexxtt bbaasseedd aaddvveennttuurree ggaammee sseeeemmss ddeeaadd inin AAmmeerricicaa  NNoo tthhee ccaassee eevveerryywwhheerree eelslsee !! PPoossssibibilitilitieiess -- PPooppuulalarritityy

 AA SSyysstteemm tthhaatt ooffffeerrss sseerrioiouuss vvaalidlidaattioionn aanndd aannaalylyssisis oonn tthhee nnaarrrraattivivee mmigighhtt bbee vveerryy uusseeffuull ffoorr ddeevveeloloppmmeenntt ……  ……aanndd vveerryy ppooppuulalarr !! PPNNFFGG

 PPrrooggrraammmminingg lalanngguuaaggee ffoorr tteexxtt bbaasseedd ggaammeess  IItt isis wwoorrkkiningg rrigighhtt nnooww  WWee uussee itit ttoo pprroodduuccee – A graphical representation – A “playable” nfg file PPNNFFGG

 MMyy ggooaalsls oonn sshhoorrtt tteerrmm :: – Implement new improvements – Think of other improvements RReeffeerreenncceess

 The Inform home page http://www.inform-fiction.org/

 The TADS homepage http://tela.bc.ca/tads/