Newsletter | Advertise | App Shop | CONTACT | Twitter | LinkedIn
     
Friday, February 10 2012  
Welcome to SymbianOne - symbian OS, UIQ, meego, Qt, series 60 programers, S60, wireless developers, device makers, and mobile industry architects



HomeNewsJobsArticlesApp ReviewsDirectoryMagsAboutLBSEVENTSDevices
Give SymbianOne a Like on facebook
Free IT Wireless / RCR Wireless News / Total Telecom / Symbian Search / AnyGeo Blog / Twitter
Connect

SymbianOne - symbian S60, UIQ and mobile tech news

↑ Grab this Headline Animator

E-Newsletter

Symbian newsletter
 Subscribe to the free SymbianOne Monitor Newsletter
SymbianOne in Ovi store

Site Sponsor

spatial media tech publications 

Cool Videos


Useful Stuff!

Getting Started with Internet Explorer Mobile
Getting Started with Internet Explorer Mobile


The Enterprise Goes Mobile

 

Mobile Tech Reviews

Symbian Software Reviews 

Main Menu
Home
News
Jobs
Articles
App Reviews
Directory
Mags
About
LBS
EVENTS
Devices

Social Bookmark
GISuser facebook group

gisuser on twitter 


 

 

Harpsichord Riddle: SoProMach In Action Print E-mail
Written by SymbianOne   
Wednesday, 14 December 2005
One of the challenges facing Somusar, the developer of the SoProMach, is how to best explain its code generation technology. The recently released Harpsichord Riddle has been designed to showcase SoProMach on S60. Richard Bloor takes a look at the game and the technology that created it.

The goal of The Harpsichord Riddle is to unlock the spell cast by three treacherous witches. This spell locks the protectors of Lady Cordelia in limbo within the walls of several mysterious castles. The game requires the player to travel to various locations, over water, through fog and listening to fragments of music to solve a riddle, which is the key to the prison.

The game play in The Harpsichord Riddle is straight forward, each move involves an image generally accompanied by text and sound. At the end of each move the player either continues to the next move or is offered a set of choices about where to go next. A fairly familiar format.

From a technology perspective the game consists of a data driven story engine that displays and plays the elements of a scene, offers the player choices and then, when the player has made their choice, loads the next scene. The engine itself is capable of playing both linear (fixed path) and non-linear (random path) stories, although the Harpsichord Riddle only uses the linear features.

To create the game the following elements were required:

  • A textual description of the story, defining the script and flow, created in Microsoft Word.
  • Image files for each scene, as bitmaps.
  • Sound file for each scene, in both MIDI and WAV format (MIDI for the distributed version, WAV for use in the emulator version).
  • A SoProMach "stamp" for the application and its associated project files.

From these files the primary output of the SoProMach generator is the C++ game application and a set of resource files used by the story engine to play the story. In addition SoProMach creates all the related project files required in a S60 C++ project, text localization (*.loc), project definition files (*.mmp and bld.inf) and the installation package definition (*.pkg). SoProMach also automatically runs the standard S60 build tools, thus providing straight-through conversion of input descriptions into ready-to-install *.sis files.

The diagram below shows the inputs to and outputs from SoProMach.

To illustrate in some more detail. The following specification defined the behavior of an additional scene which displays a "hole" in a lake the player crosses in a rowing boat at one point in the game. The player is given the choice of avoiding the hole (and taking a longer route to the games conclusion) or rowing into it (and taking a shorter route to the end of the game).

@ BeginRoom(water_hole)

: rText=
Further on, you encounter an impossible hole in the water, reflecting what appears to be a cloudy sky. You smell some metaphysics, here. A strong temptation attracts you to enter the hole...

: rLinks=dream_1@Enter hole,fog_4@Bypass hole

@ EndRoom

The SoProMach can work from a specification written in more natural English, its only basic requirement is that the specification uses consistent language and constructs to define the logic.

It is this specification that SoProMach uses to create the project assets. The main three are the application, its header file and its resource file.

In S60 it is possible to define most user interface elements using resource file (which allows the UI to be altered without recompiling the application). The resource file code from the "water hole" specification is:

RESOURCE ARRAY r_hrd_query_room_water_hole_choice
{
items =
{
LBUF { txt = qtn_hrd_room_water_hole_link0; },
LBUF { txt = qtn_hrd_room_water_hole_link1; }
};
}

RESOURCE DIALOG r_hrd_query_room_water_hole_choice_box
{
flags = EGeneralQueryFlags;
buttons = R_AVKON_SOFTKEYS_OK_CANCEL;
items =
{
DLG_LINE
{
type = EAknCtListQueryControl;
id = EListQueryControl;
control = AVKON_LIST_QUERY_CONTROL
{
listtype = EAknCtSinglePopupMenuListBox;
listbox = LISTBOX
{
flags = EAknListBoxMenuList;
height = HRD_QUERY_LISTBOX_HEIGHT;
width = HRD_QUERY_LISTBOX_WIDTH;
array_id = r_hrd_query_room_water_hole_choice;
};
heading = qtn_hrd_your_choice_prompt;
};
}
};
}

While in the game application the following lines of code are created:

bgImages[KRoomIdWaterHole] = KBitmapWaterHole;

texts[KRoomIdWaterHole] = KTextBlockWaterHole;

soundFiles[KRoomIdWaterHole] = KSoundWaterHole;

choices[KRoomIdWaterHole] = KChoiceWaterHole; // water_hole

links[KRoomIdFog3][1] = KRoomIdWaterHole;
links[KRoomIdWaterHole][0] = KRoomIdDream1;
links[KRoomIdWaterHole][1] = KRoomIdFog4;

In addition, SoProMach adds the scene narrative and choice options to the application *.loc file. It also adds with detail of image and sound file to the bld.inf, *.mmp file, and *.pkg file.

Clearly there is a significant amount of effort involved in creating the original story engine stamp for SoProMach, however once that had been completed the ability to create story book style games has become trivial from the C++ development point of view.

The same story engine and SoProMach software factory could also be used for a wide range of other applications where the content could be divided into "pages" to relate some form of "story", such as:

  • Soap operas
  • Product guides
  • Repair manuals
  • Travel guides
  • Quizzes
  • Questionnaires

Unfortunately SoProMach is not sufficiently sophisticated to create the games image and sound files from a textual description, that job still requires human designers!

The Harpsichord Riddle is an entertaining, if not overly demanding, story game, and is quite good value at $9.99. It will take a few hours to solve, but its fixed linear nature means that once the riddle is solved there is little incentive to revisit the game.

While Somusar undoubtedly hope to make some money from sales of the game its primary purpose is to showcase the SoProMach technology. Code generation offers a option to developers who are creating application which contain repeated elements of processing. However, with RAD tools for Symbian platforms such as S60 and UIQ due to be released in 2006 SoProMach will face some interesting competition from tools which have more obvious benefits. Nonetheless, SoProMach has been successfully integrated with Eclipse, and Somusar expect to have it running within Carbide.c++ in the future.


To find out more about SoProMach visit the Somusar Web site at www.somusar.com. The Harpsichord Riddle is available here from the SymbianOne shop, the game offers limited play until registered.

Last Updated ( Wednesday, 14 December 2005 )
 


Share

Submit Your Mobile Tech News


Social Media Strategies

Social Media Strategy Workbook: This Workbook will help you to define your goals and audiences and to decide on the channels that make the most sense for you. Ready to figure out what social media means for you and your own organization? This Social Media Planning Workbook will help you to define your goals and audiences and to brainstorm the channels that make the most sense for you.  

Social Media Marketing: How to Build a Socially Armed Team: It's not only the responsibility of the marketing department to engage customers anymore, it's the entire organizations responsibility, and social media has made consumers even more accessible.

Social Media Marketing: 12 Essential Tips for Success: With all the hype surrounding social media and consumer–generated content, marketers need clear and simple information to make sense of this new and powerful trend. 

Contribute to the SymbianOne Symbian Search!

SymbianOne Sponsored Links and Events

     LBSZone.com - for developers interested in mobile location-based services
    Geospatial & LBS News - Stay abreast of geospatial technologies with daily updates

    See Your Message Here

    Featured Symbian Career

    Featured Careers...

      Post your Symbian Career Ad for free at SymbianOne!



      Syndicate


      WINKsite
      add to google reader
      Subscribe in NewsGator Online
      SymbianOne Feedster
      Technocrati
      SymbianOne Bloglines
      AvantGo

      SymbianOne on AvantGo!
      Get Daily Updates!


      SymbianOne FeedBlitz

      Popular Stuff!

      Must Read Articles
    • Top Symbian Features and Spotlights at SymbianOne for 2008
    • Lightning Notes from Symbian Partner Event 08
    • Symmetric Multiprocessing A Developer Support Perspective on the Symbian Foundation
    • The Platform Promise: S60 Devices From Samsung 
    • Tools & SDKs
    • Five reasons to develop for Sony Ericsson UIQ 3-based phones
    • UIQ Tips, Tricks, and Code
    • UIQ 3 Docs and Tools
    • UIQ 3 SDK Download
    • Developer Tools in the news
    • tools and Tips for LBS developers


    • NewsFeeds


      Symbian one RSS feed Add the SymbianOne RSS feed to your reader 

      Get daily email updates:


      by FeedBurner

       


       

      Top of 

Page

      (c)2003 - 2008, SymbianOne - All rights reserved