FingerTips Personalizer Framework (Personalizer Home)

FingerTips Personalizer, The Framework Design

2006


Table of Contents

Introduction
1. How This Document is Organized
1. Personalizer Fundamentals
2. Little Differences
2.1. Options
2.2. Bindings
3. A Featuristic Digression
3.1. I18N Issues
3.2. Memory Integrity
3.3. Portability of Profiles
4. Evolution and Biochemistry of Library Items
4.1. Analysis
4.2. General Considerations for Options and Actions
4.2.1. On the Origins
4.2.2. Names
4.2.3. Descriptions
4.2.4. Terms
4.2.5. Complexity Reduction
4.2.6. Relations
4.3. Action Definitions
4.4. Option Definitions
4.5. Option Type Definition
4.5.1. Built-in Types
4.5.2. The Definition
4.5.3. Considerations for creating an option type
5. Inside Preferences Memory
5.1. Options
5.2. Bindings
5.3. Sequences
5.4. Preferences Tagging
6. Configuration-Related Processes During Game Development
6.1. Personalizer-Related Metadata
6.2. Setup Screens Recommendations
7. Configuration-Related Processes on a Gamer's Computer
7.1. Game Installation
7.2. Game Launch
7.3. Game Uninstallation
8. Algorithms
8.1. 'Unmangling' Names of Library Items
8.2. Profile Matching
A. Reference Information
A.1. FingerTips Personalizer Framework On-Disk Files
A.2. Relevant Links
B. System Requirements
FingerTips Personalizer Framework Glossary

Introduction

Table of Contents

1. How This Document is Organized

FingerTips Personalizer Framework is a tool for game development that reinvents the process of configuring computer games for PC and possibly other non-console platforms. FingerTips Personalizer Framework (or Personalizer for short) is based on a persistent on-disk database that, on every gamer's computer, stores personalized gaming preferences for that person. Gaming applications access this persistent preferences memory in order to deduce initial defaults for in-game settings.

Personalizer standardizes the location of the persistent preferences memory and offers a common interchange language for describing game configuration nouns (options) and verbs (actions.) The main idea is to relieve gamers from the configuration burden and increase overall satisfaction from playing games.

The solution Personalizer suggests calls for cooperation across game development projects. The more games participate, the more profound the effect is. This happens because all Personalizer-aware games contribute to evolution and elaboration of personalized preferences on every computer used for games and all Personalizer-aware games have access to this source of configuration information.

Participation is Voluntary.

Figure 1. Participation is Voluntary.

At the implementation (real-life) level, the system has two main counterparts: the Application Programming Interface (some code we have written) that game developers use to conveniently access the persistent preferences memory and the persistent preferences memory itself (a set of files on disk.)

Persistent preferences memory consists of profiles. A profile is a container for preferences related to a single game. This is pretty standard. Where our system is concerned, the goal of every installed game is to review the existing profiles and either discover the initial defaults for gaming preferences or decide that no such discovery is possible and, consequently, generate a default profile. The design of Personalizer has been consciously driven to make the second situation much less probable.

The search a new game performs to identify suitable sources of configuration preferences is known as profile matching. Before Personalizer, game developers decided on the default settings and suggested that a person playing the game should know better - by implementing setup screens. Personalizer lets the game decide on default settings automatically by analysing configuration choices previously made by every particular gamer.

However, Personalizer also knows where to stop; being indeed a profoundly more advanced configuration system, it still leaves place for setup screens and even advises to continue implementing them. In a Personalizer-aware game, setup screens should serve to review the results of profile matching and make minor adjustments if necessary.

Persistent preferences memory would be impossible without an interchange language. To tell the truth, games do use different terms for describing semantically identical options and in-game actions, and sometimes use identical terms for describing semantically differing options and in-game actions. Personalizer offers a common vocabulary of configuration nouns and verbs known as the core libraries of options and actions. This configuration vocabulary has been derived (and is being updated) by analysing hundreds of existing games published over the last decade and, therefore, reflects the real needs of contemporary games in regards of configuration terms.

In a core library, every term corresponds to a single configuration item, such as in-game action ('Save', 'Load', 'Attack') or option ('Music Volume', 'Mouse Sensitivity'.) Every term has an associated definition that clarifies the semantics of the item. A Personalizer-aware game is expected to use terms from core libraries for describing as many configuration concepts as possible and at the same time closely follow the semantics of the vocabulary terms.

The potential of terms common to all games extends beyond simple reuse of identical options and in-game actions. When necessary, terms in the libraries can be linked into hierarchies in order to make possible fuzzy matching. For example, some games implement more elaborate settings, such as 'Mouse Horizontal Sensitivity' and 'Mouse Vertical Sensitivity', while the rest of them simple go with 'Mouse Sensitivity'. To Personalizer, these three options are related, so a game requesting 'Mouse Horizontal Sensitivity' can be treated with 'Mouse Sensitivity' setting created by another game. This is known as 'relations processing'. Implementation of relations processing has been moved to the next release of Personalizer.

This is just a glimpse at what Personalizer is capable of. This design document describes FingerTips Personalizer Framework and serves as implementation reference for Personalizer developers.

1. How This Document is Organized

We tried to keep chapters small and to the point. While we would like to believe that this document is a far cry from Unix man pages, please pay attention, repetitions are scarce here.

Chapter 1. Personalizer Fundamentals

Speaking abstractions, FingerTips Personalizer Framework is an information storage and retrieval system. It stores a person's gaming preferences and it provides access to these gaming preferences. Consequently, there are information structures and there are algorithms for accessing the information.

Personalizer maintains information structures as a set of disk files that, if present on a computer, must reside under a predefined location. The location of Personalizer files is fixed for all operating systems. For example, on Windows XP™, Personalizer files must reside under Documents and Settings\Username\My Documents\My Games\Personalizer. The location will be automatically determined by Personalizer API code at run-time.

A Personalizer-aware game being installed on a Personalizer-unaware computer must deploy Personalizer files from a package known as Redistributable Personalizer Core. Files from the redistributable core do not contain any gaming preferences, but they either establish the on-disk structure required by Personalizer-aware games or upgrade an existing installation.

Installing the redistributable core is mandatory for a Personalizer-aware game.

The information stored in the Personalizer on-disk files is of two sorts. First, the libraries that serve as the source of configurable items (options and in-game actions). The library of options holds core option definitions (the definitions that came with FingerTips Personalizer Framework) and custom option definitions (the definitions that came with concrete games and are specific to those games.) The library of actions holds core action definitions (the definitions that came with FingerTips Personalizer Framework) and custom action definitions (the definitions that came with concrete games and are specific to those games.) The third library stores core and custom option type definitions; it does not have its own value, but complements the library of options by defining data types that option values can follow. Information in the libraries contains building blocks for creating specific profiles with preferences.

The second sort of information is the information in the persistent preferences memory. The preferences memory consists of profiles. A profile is a container for preferences related to a single game. In the traditional model, every game stores configuration information in its own format and does not share this information with other games. Personalizer profiles all consist of definitions in the same language (have the same format) and use the same terms (coming from libraries of options and in-game actions) thus making automatic discovery of gaming preferences possible.

A Personalizer profile may contain any number of options, bindings, and sequences.

An option is a certain game setting that can be enabled, disabled, or assigned a particular value. The core library of options already includes a multitude of option definitions derived by analysing existing games; however, game developers are free to add options specific to their games by creating custom option definitions.

Game options come in variety of forms: switches, value fields, sliders, custom value sets, and so on. For example, you can enable or disable (switch) the mouse inversion, you can assign the mouse sensitivity on each axis (using sliders), you can set player name or a game server name using a text entry field, and crosshair presentation changes through a set of predefined values. Personalizer implements all the standard kinds of options (through the library of option types, see above) and also lets game developers add custom option types.

A binding is an association established between a hardware controller device (such as keyboard, mouse, or joystick) and an in-game action. An in-game action is simply any action initiated by the game player after the game launches. The core libraries of actions already includes a multitude of action definitions derived by analysing existing games; however, game developers are free to add actions specific to their games by creating custom action definitions.

Personalizer sequences are a simple scripting mechanism. Option assignments and action calls in a sequence are expected to be interpreted by the game successively. Most games will not implement interpretation of sequences, but the possibility is here.

Chapter 2. Little Differences

Table of Contents

2.1. Options
2.2. Bindings

In FingerTips Personalizer Framework, options and bindings are not exactly the same as in the traditional model. There are little differences important for the system overall.

2.1. Options

In Personalizer, the value of an option is not an authority beyond exception; instead, we say that options define gamer's preferences for certain aspects of gameplay. In particular, if a profile contains an option that the game does not implement, this option can be safely ignored. If the game does not support a specific option value, it can either round the value to the closest valid value or use the default instead. The most notable difference of Personalizer options is that some options (or, to be precise, option types) allow setting a value that holds several preferences in the order of decreasing favor. For an example, consider option 'Language' that specifies the preferred language of a person. In the traditional approach, you select a language from a predefined list using the game's setup screens. You do that manually and only have the choices the game developers provide. Personalizer states that a gamer can define 'Language' as a list of values, such as 'Spanish Russian English', and, if the game has a selection of languages to offer, it must interpret the list and select the first language down the list that is available. If Spanish is available, it would become the first choice. If not, consider Russian. Otherwise, just go with English (or, finally, the default language, whatever that is.)

2.2. Bindings

Binding associates one or more controls with a certain in-game action. This is so in the traditional model and even more so in Personalizer. However, in some cases it may be convenient or desirable to supply an action argument in order to modify the action's behavior. Action arguments are used to pass additional parameters in bindings. However, action arguments are not governed by definitions of actions as present in the library; instead, they are stored in the special Arg tag (see Section 5.4, “Preferences Tagging” for more information.)

Chapter 3. A Featuristic Digression

This chapter contains a number of sections dedicated to various features of Personalizer that may not be mentioned elsewhere in this document.

3.1. I18N Issues

Game development hasn't always been sensitive to localization needs. There are fine examples of games implementing multilingual interface, but there are also games that are only localizable through reverse engineering. As time passes, more games will incorporate the localizable approach and, as the result, multilingual interfaces will become a commodity. Personalizer is designed for localization in the sense that it does not stand in the way of localization. Like so many programming languages, it requires from the developer to use English for names of library entities (the matching algorithms won't work otherwise), but it says nothing about the interface language. Which means, you can make games that are Personalizer-aware and localizable.

3.2. Memory Integrity

FingerTips Personalizer Framework's Application Programming Interface automatically creates backup copies of important framework files (such as preferences memory, library data, and so on). These backups are known as snapshots.

Snapshots serve to restore preferences memory and the supporting files if corrupted due to an external factor such as hard disk crash or a virus attack. Snapshots are stored in the Snapshots Folder, with names formatted as creation timestamps, YYYY.MM.DD.HH.mm.ss. No two snapshots can be written within one second's span, so, if a snapshot exists already, the system will create the new snapshot one second further 'in the future'.

The Application Programming Interface will create snapshots when performing operations that change preferences memory files or the supporting infrastructure significantly. Initially, every snapshot is considered valid, but an external factor can damage the snapshot files, so the system automatically checks all snapshots for validity before reusing them.

The system automatically removes invalid snapshots older than one month and also stores only 5 most recent valid snapshots.

[Note]Note

The preferences memory persists and remains valid even in the event of direct deletion of the game files.

3.3. Portability of Profiles

Personalizer profiles are portable. The gamer can extract preferences for a certain game and reuse them on another system or share them with friends. Reusing preferences previously extracted is known as integration. Implementation of portable profiles has been moved to the next release of Personalizer.

An extracted profile is an XML document (independent of a Personalizer installation) that contains the actual preferences plus any related information required to integrate the profile back into a Personalizer installation.

Chapter 4. Evolution and Biochemistry of Library Items

Personalizer divides all library items into core items and custom items. Core items refer to option definitions and action definitions shipped as part of the framework. Custom items refer to game-specific option definitions and action definitions provided by the game developer as part of the game data.

One of the golden rules Personalizer sets is that custom definitions must only be created if necessary. The game developer must first of all make sure that a core library (of options or of actions) does not already contain a required entity before creating a custom definition. This rule exists for two reasons. First, the profile matching algorithm is only applicable if developers of Personalizer-aware games play along; second, the core libraries are derived by analysing hundreds of existing games and are a quality reflection of most games' needs.

This chapter describes the process we use to produce core libraries and the internals of library definitions.

4.1. Analysis

Personalizer development team reviews released games and game demos in order to maintain the coverage database. For every game, coverage database contains records for all options and bindings that game manifests, with every configuration item either mapped to an existing core library definition or marked as uncovered.

Uncovered configuration items from many games are linked through special group identifiers. Items in every group refer to concepts and entities that are semantically identical for all games of a genre. Put simply, items in a group describe the same thing, although the terms and approaches used may differ. When a group gains significant weight (the number of items in the group exceeds a predefined normalized threshold), our task is to assign an appropriate name and structure to that configuration entity and design a corresponding core library definition. Then all the items from the group are marked as covered and linked to than new core library item.

The main goal of the coverage to library design excercise is to keep the core libraries in good shape. By good shape we mean reflecting 90 plus per cent of existing configuration items common to many games. This way, profile matching has sense and the developers never have to create too many custom library definitions.

4.2. General Considerations for Options and Actions

Library definitons serve as building blocks for profiles. If a profile references an in-game action, the action must exist in the library of actions. If a profile sets an option, the option must exist in the library of options.

Definitions provided by the FingerTips Personalizer Framework development initiative are known as core definitions, while definitions provided by game developers are known as custom definitions.

Definitions for in-game actions, both core and custom, are stored in the actions library.

Definitions for options, either core or custom, are stored in the options library. Definitions for option types, either core or custom, are stored in the option types library.

4.2.1. On the Origins

To maintain and distinguish core and custom definition, Personalizer uses origins.

Every library definition has an origin. Origin identifies the source of the definition. One source is the FingerTips Personalizer Framework development initiative, it supplies core definitions. Our origin is 'Core FingerTips Personalizer Framework Library'. A game developer creating custom definitions for a game must use a unique origin to identify them. We suggest using a unique URI string such as 'http://softwarespecies.com/GameDev/ExtremeSuperTetris/V1.9".

FingerTips Personalizer Framework needs origins to function properly. In particular, it requires all origins to be distinct. The origin must be unique for every new game (game add-on, game release, and so on.) You can think of origins as of XML Namespaces if XML is familiar to you.

4.2.2. Names

Choice of names for options and in-game actions is an important matter. Names are about the only thing the player generally sees when dealing with a game setup. Some games thoughtfully include descriptions, which we think is a good practice.

Names are case sensitive. Names must also be unique, but creating names that differ only in case of characters (such as 'Invert Mouse' and 'Invert mouse') is forbidden.

Capitalization. Each distinct word in a name must be capitalized as in 'Invert Mouse'.

Definition versus Presentation. In library definitions, words in names are stringed together without intervening whitespace. So, 'Invert Mouse' in the core library of options looks, in fact, as 'InvertMouse'. The rule for presenting names to game players is exactly converse: names of actions and options must contain spaces between distinct words. Corollary: game developers must string together words in names of custom configuration items. Section 8.1, “'Unmangling' Names of Library Items” describes the algorithm for unmangling library names before presentation. FingerTips Personalizer Framework's Application Programming Interface has a ready-to-use method for unmangling names.

Word style. Atomic word combinations (such as Cut Scene, for example) are considered integral words and must be written using the above rules (i.e. Cutscene).

Contextual Omissions. Obvious words can be omitted from a name (consider, for example, 'Difficulty' against 'Game Difficulty').

Clarity and length. Choose transparent, unambiguous names, one to three component words long (one or two is better). Note, however, that the primary goal is to achieve clarity in names, in order to make life easier for users. Clarity is more important than length.

Stylish Captions. In some games, it may be desirable to decorate settings using game-related captions instead of standard names. Although Personalizer tries to standardize names of actions and options, it still recognizes the need for such styling. The developer can use any decorations as long as he maps them appropriately to Personalizer core library definitions. For example, a game can manifest an option such as 'Game Insanity Level', but internally still use Personalizer's core option 'Difficulty'.

4.2.3. Descriptions

Every library definition, either core or custom, includes a description, a clear and concise statement of the purpose, scope, and behavior of a library item. It is important for a description to be as unambiguous as possible. Descriptions of library items serve two purposes. First, the developers must have access to semantics of all core options. Second, these descriptions can be used as configuration hints and, consequently, presented to gamers on setup screens.

Again, the game developer has an option to override the standard description and provide a more suitable one.

4.2.4. Terms

FingerTips Personalizer Framework must be consistent in describing options and actions. The following terms and notions should give a fairly useful picture of how consistency is accomplished.

  • The term player character refers to all game objects that represent player (even a falling Tetris block is a player character). Player characters have also been known as playable characters.

  • The term view refers to scenes as seen through whatever serves as the "eyes" of a player character; the term camera refers to an external point from which the observation is conducted, while looking refers to moving player character's head briefly (glancing) or continuously (head turn).

  • Terms in Personalizer are largely multipurpose. The term inventory refers both to a magician's bag and a weapons menu; the word weapon itself may denote a magic potion as well as a missile. The inventory and grouping actions may be used on both RTS objects and quest objects.

  • Many actions have flexible semantics, and consequently can serve in different genres. Take Power, for example. In a serious simulator, this is the engine power control, which doesn't imply motion. In an arcade game, this action's role is accelerating or decelerating a vehicle.

4.2.5. Complexity Reduction

With many dozens of core library definitions available, it may be a daunting task for a game developer to locate the required definitions. To reduce the search complexity, Personalizer offers a metadata property that classifies library items. Classes divide actions and options into logical domains. For example, all actions related to moving player characters belong to class Motion, and all options related to tuning game controllers and controls belong to class Controls. This way, when preparing Personalizer-related metadata for a game, the developer always knows where to look for a particular configuration feature.

4.2.6. Relations

Relations are not a manifested feature of Personalizer; they are internal mechanisms that increase flexibility of the framework. Implementation of relations processing has been moved to the next release of Personalizer.

Relations establish certain dependencies between definitions within a library. There are currently three kinds of relations:

  • Simple;

  • Generalization/Specialization; and

  • Supercede/Superceded By

Simple relations link together definitions belonging to a logical group. For example, all mouse options are linked through simple relations. Every single mouse option references all other mouse options. Simple relations are a marginal feature, but they have their uses, such as automatic grouping of settings on setup screens.

Generalization and specialization go hand in hand and usually form a single relation for a pair of library definitions. We say that option A generalizes option B and option B, in turn, specializes option A when B represents a technical subset of A. For example, options 'Mouse Horizontal Sensitivity' and 'Mouse Vertical Sensitivity' are a technical specialization of 'Mouse Sensitivity'. 'Mouse Sensitivity', on the other hand, is a generalization of both 'Mouse Horizontal Sensitivity' and 'Mouse Vertical Sensitivity'.

Generalization/specialization relations are a valuable asset for Personalizer; more valuable than may appear. For example, the semantic difference between options in an arcade race simulator and options in a realistic race simulator may be huge, and it would be improper to use identical names for both complex techical concepts and simple arcade controls. However, from the standpoint of playing games the concepts often converge. Personalizer has two areas where generalization/specialization become important: profile matching and retrieval of options and bindings from profiles.

Profile matching calculates suitability of existing profiles for the game in question by analysing the contents of profiles: option settings and action bindings. The algorithm awards points when it runs across an option or an action that the game implements. If only exact matches were considered worthy, an attempt to pick up a suitable profile for an arcade race sim on a computer where only hardcore race sims have been played before would result in low-confidence selection. Relations that associate purely arcade (generalized) options with realistic (specialized) counterparts make it possible to select profiles with high confidence.

Generalization/specialization relations go further than simply fix confidence for profile matching, they also serve to retrieve options and bindings that may work as substitutes for options and bindings requested. For example, if a game requests option 'Mouse Horizontal Sensitivity' and at the time of request the profile in question only contains 'Mouse Sensitivity', but not 'Mouse Horizontal Sensitivity', FingerTips Personalizer Framework's Application Programming Interface detects the presence of a generalized option and returns its value.

The last kind of relations is supercede/superceded by. The purpose of this relation is to fight code rot. Personalizer-related code in every game will contain literal strings identifying options and actions the game is interested in. However, we presume that core libraries will evolve, and evolution can possible change names. Code rot refers to situation when a game requests a deprecated option or bindings for a deprecated action. Supercede/superceded by makes it possible to return meaningful results even for deprecated library definitions.

4.3. Action Definitions

In the library of actions, every action's definition includes the following information:

  • A unique action name. Custom actions' names include respective origins as prefixes.

  • A description that clarifies the semantics of the action.

  • An action class that specifies a logical domain for the action.

  • Optional relation records.

Because the overall number of action definitions is formidable and the game developer generally uses under 10% of all possible actions, Personalizer attaches mandatory class attribute to all definitions. The following action classes currently exist:

  • MaintenanceIncludes actions that allow players to maintain gaming sessions. Such actions are not directly relevant to controlling player characters or observing game events, but still occur within the game. Maintenance actions do not change in semantics even across different genres. 'Quick Save', 'Load', 'Connect', and 'Take Screenshot' are all Maintenance actions.

  • MotionIncludes actions related to moving the player characters and modifying motion parameters. Actions 'Turn Around', 'Backward', 'Descend', 'Run / Walk', and 'Slide' belong to class Motion.

  • ObservationIncludes various "looking" actions and actions related to switching views of game events, such as 'Zoom In' and 'Next Camera'.

  • InventoryIncludes actions for selecting various inventory items and operating on inventory. Selecting weapons and tools, dropping or taking an object, all such actions belong to class Inventory.

  • UsageSelecting an item does not imply using this item (especially true for weapons). Usage actions exist as a separate class. Some examples: 'Attack', 'Build', 'Drop', 'Pick', 'Reload', and 'Detonate'.

  • OrientationIncludes actions that "help" navigate the game. For example, 'Help', 'Target Lock', 'Objectives', 'Map'.

  • CommunicationIncludes actions related to communicating with other players and non-player characters, spelling orders and also communicating intentions to the game world environment. Examples: 'Team Broadcast', 'Defend', 'Escort', 'Radio', 'Talk'.

  • GeometryIncludes actions related to transformations of the player character. Examples: 'Crouch', 'Prone', 'Cloak'.

4.4. Option Definitions

In the library of options, every option's definition includes the following information:

  • A unique option name. Custom options' names include respective origins as prefixes.

  • A description that clarifies the semantics of the option.

  • An option class that specifies a logical domain for the option.

  • An option type that specifies the range of possible values for the option.

  • Optional relation records.

Because the overall number of option definitions is formidable and the game developer generally uses under 10% of all possible options, Personalizer attaches mandatory class attribute to all definitions. Option classes follow the traditional division found in many games:

  • Gameplay;

  • Graphics;

  • Controls;

  • Audio;

  • Network; and

  • Personality.

The developer will know to look into Graphics in order to locate the option controlling screen resolution.

Option class Personality is probably new for mainstream games. It is intended for options that identify (with user's consent) personal information that may be used for physical and psychological profiling of gameplay. Information such as sex, age, habits can make a game's content more appealing to player, while accessibility options describing possible gamer's impairments can make accessible games aware of the situation.

Every existing option must assume only those values that are mentioned in the option's definition. See Section 4.5, “Option Type Definition” for more information on how option types referred to from option definitions restrict the ranges of possible values.

4.5. Option Type Definition

In the library of options, every option definition references an option type that restricts the range of possible values for that option. The library of option types complements the library of options and stores definitions of option types. In particular, there are a number of built-in option types that model the most common option controls.

4.5.1. Built-in Types

Personalizer provides a number of built-in option types:

  • Truth. This models binary choices, such as boolean options that can be either enabled or disabled, or mutually exclusive alternatives. Positive values for such options are On, Yes, Enabled, and 1. Any positive value turns the boolean option on. Negative values for such options are Off, No, Disabled, and 0. Any negative value turns the boolean option off.

    Truth type corresponds to traditional on-off switches.

    Truth is generally used to create options limited to a pair of possible values.

  • Percentage. Used to define options with integer values ranging from 0 to 100. Percentage corresponds to traditional sliders and grades.

    A grade is a game option with a fixed number of possible values. Game developers often create specialized grades for options such as Difficulty. One such grade may include the values Normal, Hard, and Expert, another - the values Easy, Medium, Hard, Impossible, and Dead on Arrival. The exact wording is often important for the game style, but the idea doesn't change from the user's standpoint: option Difficulty sets the game difficulty; the higher its value, the more difficult the gameplay is.

    For this reason, type Percentage must be used for level settings. The in-game representation of the value may vary, while the framework representation remains consistent. A three mark grade corresponds to Percentage values 0, 50, and 100. A four mark grade corresponds to Percentage values 0, 33, 66, and 100. A five mark grade corresponds to Percentage values 0, 25, 50, 75, and 100.

    Rounding of values, if required, can be handled by the FingerTips Personalizer Framework's Application Programming Interface.

  • String. A catch-all type for free-form options, such as character names, filenames, network server names, and so on.

  • Precision. Used to define options with real number values. Sixteen digits and sixteen decimal places are allowed (16.16).

  • Natural. Used to define options with natural number values of up to 9 digits long. 0 is a valid value.

  • Other specific types such as Core.Resolution, Core.RefreshRate.

4.5.2. The Definition

Definitions for an option type includes the following information:

  • An origin the option type belongs to (custom option type definitions must use custom origins);

  • A unique option type name (custom options must have prefixes);

  • A regular expression (Perl 5 syntax);

  • An optional multivalue indicator (see below);

  • A description.

Regular Expressions. Regular expression is the heart of an option type definition. It creates a range of valid values for options that use the option type. Regular expressions use the syntax defined in the XML Schema specification (W3C Home). In fact, the W3C XML Schema syntax for regular expressions is largely compatible with Perl syntax for regular expressions. The FingerTips Personalizer Framework's Application Programming Interface currently uses a Perl-compatible regular expressions matcher to implement the relevant functionality.

Multivalue Indicators. The capability of options to list multiple values in the order of decreasing favor stems from multivalue indicators. Multivalue indicator is a property of option type definitions that instructs the framework to accept a space-separated list of values conforming to the option type regular expression as a valid value. One implication of using a list indicator on an option type definition is that the regular expression should not allow any embedded whitespace in individual values.

4.5.3. Considerations for creating an option type

Create an option type when

  • no existing option type suits the purposes of a custom option. Take type Core.Language, for example. It creates a number of distinct recognizable choices that have concrete meaning for any person. The option Language couldn't possibly use type Percentage, since there's no way for user to know that a certain integer value maps to a certain language choice.

  • you need to implement a custom option with complex value format that can only be specified through a regular expression.

Chapter 5. Inside Preferences Memory

Table of Contents

5.1. Options
5.2. Bindings
5.3. Sequences
5.4. Preferences Tagging

Personalizer implements a persistent preferences memory with life span exceeding life spans of individual games.

The Two Approaches

Figure 5.1. The Two Approaches

Preferences memory consists of profiles, which, in turn, consist of options, bindings, and sequences.

Profiles are familiar to most game developers and gaming addicst: a profile is what you get after configuring a game. In most games, you only have one profile, but there are also games that let you manage multiple profiles. In both cases, the game selects one profile to serve as the current source of configuration data.

Personalizer's preferences memory can store unlimited (for all practical purposes) number of profiles. A Personalizer-aware game is free to select any of these profiles as the source of configuration data; FingerTips Personalizer Framework's Application Programming Interface includes an intelligent selection tool (Profile Matcher) that ensures that every game selects the most suitable profile. Profile Matcher acts automatically during the API initialization.

The formal definition of profiles' data structure says that every profile must have a title (a human-readable line of text identifying the contents of the profile) and a unique profile identifier.

After a game has selected a profile, the profile is automatically tagged as selected for this specific game. Next time the game starts, it will skip profile matching procedures by selecting the tagged profile directly.

A profile can either be empty or contain any number of options, bindings, and sequences.

5.1. Options

Personalizer options are the well known name/value pairs, where a name serves as a reference to a library definition, and the corresponding value must be valid according to that definition. Every option mentioned in a profile must exist in the library of options as either a core option defition or a custom option definition.

Besides the multivalue quirk of Personalizer options (Chapter 2, Little Differences), there are several peculiarities related to retrieving values of options.

Default Values. The game has to have a value for an option, one way or another. If the value is not in the selected profile and not in any of the inherited profiles, and there are no alternatives, FingerTips Personalizer Framework's Application Programming Interface will return the default value specified by the game developer.

Valid Values. Certain option types list many possible option values. Take 'Core.Language', for instance. The option 'Language' can list all languages that 'Core.Languages' defines as a space-separated list. This is perfectly valid in Personalizer as a way to express value priorities. However, the game usually does not have an interface all that multilingual. In real life, three languages are common, five languages are rare. That's it. When a game encounters an option value it is not ready to encounter, unexpected things may happen. To avoid such situations, Personalizer lets the developer specify the values that are considered valid for an option. Seeing this restriction, FingerTips Personalizer Framework's Application Programming Interface will filter out unlisted values when retrieving the option.

Grades. A grade is a game option with a fixed number of possible values that represent different levels of something. Personalizer uses option type 'Percentage' (values 0 through 100) to model slider controls and grades.

In "Half-Life 2", the developers chose to describe difficulty variations with words like 'Easy', 'Normal', and 'Hard'. On the other hand, developers of "Max Payne" chose to describe difficulty variations with words like 'Fugitive', 'Hard-Boiled', and 'Dead On Arrival'. Personalizer only knows that Difficulty has type Percentage, so 'Easy', 'Normal', and 'Hard' map to 0, 50, and 100. 'Fugitive, 'Hard-Boiled', and 'Dead On Arrival' again map to 0, 50, and 100. No matter what wording the developers use, Personalizer always measures difficulty in per cent. It does not have to know that 'Normal' from "Half-Life 2" and 'Hard-Boiled' from "Max Payne" refer to the same difficulty level.

Now, consider what happens when two games use different number of variations for 'Difficulty'. There are 'Easy', 'Normal', and 'Hard' from "Half-Life 2". And, there are 'Very Easy', 'Easy', 'Medium', 'Hard', 'Very Hard' from "AquaNox 2: Revelation". Because game developers create grades to reflect such marks on a continuous axis, Personalizer knows that values must be preprocessed. If a game requests the value of 'Difficulty', Personalizer rounds this value to the lesser of the closest marks. For this example:

  • If "Half-Life 2" requests the value of 'Difficulty' set to 'Very Hard' in "AquaNox 2: Revelation", Personalizer returns a Percentage value corresponding to 'Normal'.

  • If "Half-Life 2" requests the value of 'Difficulty' set to 'Easy' in "AquaNox 2: Revelation", Personalizer rounds the Percentage value corresponding to AquaNox's 'Easy' (25) to the closest grade mark for Half-Life ('Easy', 0) and returns the result.

Another common use of grades is modeling of slider controls with steps larger than one per cent, such as 10-step or 20-step sliders.

To learn about the order in which Personalizer applies defaults, filters, and grades, refer to ???.

5.2. Bindings

A Personalizer binding is an association between an in-game action and one or more controls. A control is a sum of inputs provided by hardware controllers. Keyboards, mice, and joysticks can all contribute. An in-game action is simply any action initiated by the game player after the game launches.

Personalizer does not limit the number of bindings for any given action as well as the number of controls in a binding.

5.3. Sequences

A sequence is a set of option assignments and action calls executed successively. As with bindings, execution of a sequence starts when the gamer invokes an associated control. You can think of sequences as a simple scripting mechanism.

A sequence must have at least one associated control, an (optional) title, and must contain at lease one action call or option assignment.

Controls for sequences work exactly the same way as for individual bindings. In fact, you can also think of a sequence as a single higher order action bound to a control.

Action Calls. An action call executes a single in-game action. Action call has the same properties as action in a binding: action name and action argument. The sequence context adds a couple of extra attributes: action execution flow and duration.

There are two possible execution flows for an action call: Standard (the default) and Spawn. The Standard variant says: "Wait until this action fully executes, then proceed to execute subsequent sequence elements." The Spawn variant says: "Execute this action in parallel with subsequent sequence elements."

Spawned actions are similar to background processes working concurrently with foreground tasks. Game players routinely invoke many actions in parallel, so this concept must be already familiar to them, although implicitly.

The second attribute unique to action calls is duration. Duration tells the sequence interpreter for how long the action must be executed (if the action's semantics allows for prolonged execution.) Personalizer suggest to measure duration in milliseconds. Alternatively, the interpreting game can measure duration in game- or hardware-specific ticks.

Option Assignments. Option assignment in a sequence is no different from an option assignment in a profile. It is presumed that option assignments are executed in zero time.

5.4. Preferences Tagging

Personalizer allows game developers to attach arbitrary tags (name/value pairs) to most structures in preferences memory. Specifically, to profiles, options, bindings, controls, sequences, and sequence elements. Tags can serve as source of additional information. For example, when a game has found a suitable profile among the profiles from preferences memory, it can tag the profile as Selected="Yes". Next time the game starts, it can search for a profile tagged Selected="Yes" and initialize itself with information from that profile, if found. (This is done automatically by the API.)

When the developer sets tags programmatically, FingerTips Personalizer Framework's Application Programming Interface prefixes tag names with the game's unique origin string, so there is no possibility for misinterpreting tags (this also means that tags are not reusable in other games.)

Another natural application for tags are multi-player configurations where a single profile must contain preferences for two or more players who either take turns or play the game simultaneously. By tagging options and bindings with tags like Player="One", Player="Two", and so on, the game can store settings for many players in a single profile and be able to discriminate between the settings for different players.

Chapter 6. Configuration-Related Processes During Game Development

6.1. Personalizer-Related Metadata

While a Personalizer-aware game is still in development, certain preparations must be made. The developer creates Personalizer-related metadata that is loaded into FingerTips Personalizer Framework's Application Programming Interface memory space at run-time. This game-specific metadata includes the following information:

  • Game title;

  • Origin text;

  • Optional definitions for custom actions and custom options;

  • Lists of core and custom actions and options supported by the game (this information is vital for proper operation of Personalizer);

  • For every supported action the developer can provide the default control (used in generation of the default profile and in retrieving bindings), an optional alternative caption and an optional alternative description. An action combo group lists actions that must always share the same control or controls. Action combo groups are enforced through the FingerTips Personalizer Framework's Application Programming Interface.

  • For every supported option the developer can provide the default value (used in generation of the default profile and in retrieving bindings), an optional alternative caption, an optional alternative description, a list of valid values, and optionally a grade (only for options of type Percentage). Additionally, the developer can map values of type Percentage to specific text strings.

6.2. Setup Screens Recommendations

FingerTips Personalizer Framework was designed to keep the existing exteriors of the configuration process, so the setup screens for Personalizer-aware games will remain much the same. However, there are several important points that we must make.

Profile Management. For different reasons, many games do not include profile management. As a configuration component Personalizer already implements a full-featured system of profile management, so bringing operations such as creating, removing, modifying, and selecting profiles to the setup screens should be a breeze for game developers.

Configuration Stress Reduction. Personalizer makes possible automated discovery of preferences and tries to ensure that the discovered preferences are suitable for the game in question. To verify that the settings are right, the person intending to play the game still has to browse the setup screens, right? Simply because many games do not include tutorials, and awareness of the in-game actions available is key to playing.

The game developer can help by rearranging configurable items on the setup screens and/or marking the items visually using colors or icons. The idea is to partition items automatically derived from the persistent preferences memory and items for which the game had to use its own defaults. First, the gamer immediately sees configuration items that require immediate attention and, probably, reconfiguration. Second, the gamer can skim over the rest of the items with intent of understanding what actions and options are available. This approach is 50 to 80 per cent faster than verifying and tuning every available control separately.

Conflicting Controls. There are several ways for a game to react to conflicting controls for in-game actions. First, when the gamer assigns a control that is already in use, the game clears the control for the action that previously had it assign and remaps the control to the current action. Second, the game can inform the gamer that the control is in use and refuse to assign it. Third, the game assigns the control and marks both items using the control - either using color or icon. Personalizer suggests the third approach with possible additional quirk: the items participating in the conflict must not only be marked, they should also "bubble" to the top of the list and remain visible to the gamer.

Why keeping the conflict from automatic resolution is better? Because with high probability the binding that owned the control previously is one of the bindings automatically derived from preferences memory, and these, as far as Personalizer goes, are stable. Stable bindings are more likely to keep controls. However, there is margin for error, so it is up to the gamer to make the final decision.

Chapter 7. Configuration-Related Processes on a Gamer's Computer

Table of Contents

7.1. Game Installation
7.2. Game Launch
7.3. Game Uninstallation

7.1. Game Installation

During installation, a Personalizer-aware game must launch the redistributable core installer. This is a required action. The installer will install or update Personalizer on-disk files as necessary and provide base for further operations.

During uninstallation, the game must not launch the installer for any reason or explicitly uninstall Personalizer on-disk files. The preferences memory persists over life spans of individual games.

7.2. Game Launch

The initialization algorithm is as follows:

  • Bootstrap FingerTips Personalizer Framework. If automatic bootstrapping fails (Personalizer files are corrupt and snapshots are not available or Personalizer files cannot be found at the predefined location), briefly inform the gamer of the problem and fall back to Unaware Mode. Unaware Mode provides the game with necessary defaults, but turns off all other Personalizer functions.

  • When boostrapping has succeeded, search for a profile tagged as selected (see Section 5.4, “Preferences Tagging”). On success, load initialize game settings from preferences in that profile.

  • If no previously selected profile is found, perform Profile Matching. Profile Matching returns a list of profile identifiers ranked in order of decreasing suitability. Only profiles that exceeded the precomputed suitability threshold are included. Match results contain additional information for every profile, such as profile's content type (purely core configuration items or mixed), and so on.

    There are several ways to use the results of matching. Here are some of the most obvious. First, the game can inherit the contents of a suitable profile if that profile only references core actions and options. In this case, the game reuses game-independent definitions and adds its own (game-specific) definitions in the heir profile.

    Second, if a suitable profile has mixed content (refers both core and custom library items) the game can extract relevant definitions into a new profile and add its own (game-specific) definitions into the new profile. Irrelevant definitions that represent settings specific for other games are ignored.

  • If profile matching returns an empty list or the game does not consider any of the high-ranking matches suitable, the game should fall back to default profile (FingerTips Personalizer Framework's Application Programming Interface has a method that creates default profiles automatically).

7.3. Game Uninstallation

It is perfectly safe to uninstall Personalizer Redistributable Core when the game uninstalls because the Redistributable Core packages is structured in such fashion that it leaves behind the DLL and the persistent preferences memory.

Chapter 8. Algorithms

Algorithms described in this chapter are used in FingerTips Personalizer Framework's Application Programming Interface. This information is purely technical and isn't required for using Personalizer in your projects.

8.1. 'Unmangling' Names of Library Items

Internally, names of in-game actions and options are strings without embedded spaces. This was a conscious design choice. However, an option such as '{http://softwarespecies.com/GameDev/ExtremeSuperTetris/V1.9}MultifigureHints' is unacceptable for setup screens. The names of library options and actions must be unmangled before displaying. This involves removing the origin prefix and inserting spaces at certain points.

The Application Programming Interface inserts a space after a capital letter, if the letter does not preceed and does not follow another capital.

The hypothetical core option's name 'MouseHorizontalSpeed' is converted to 'Mouse Horizontal Speed'. The hypothetical custom option's name '{http://softwarespecies.com/GameDev/SuperMegaTetris/V1.19}MultifigureHints' is converted to 'Multifigure Hints', and so on.

Personalizer offers an alternative naming scheme where you can indicate need for spacing using dots. For example, a name such as 'MultifigureH.ints' will be converted into 'MultifigureH ints'.

8.2. Profile Matching

The purpose of profile matching is to rank profiles that may be suitable for the game in the order of decreasing weights. A profile's weight is the sum of points awarded to the profile for options and actions that match options and actions the game implements.

  • Profile matching disregards sequences.

  • Profile matching considers definitions inherited from other profiles.

  • Profile matching considers options and bindings orthogonal; that is, the matching code may return references to a pair of profiles so that one profile can serve as the source of options and the other as the source of bindings.

For every profile in preferences memory, Profile Matcher performs as follows.

  1. Paying attention to inherited definitions, collect options and actions mentioned in the profile into two sets. Every set only contains unique elements.

  2. For every item in the set of options, award the profile one point if the option is supported by the game.

  3. For every item in the set of actions, award the profile one point if the action is supported by the game.

  4. Calculate the profile's two Weights as sums of points awarded for options and points awarded for actions, respectively.

  5. If a profile's Weight does not exceed the suitability threshold set for the items of the corresponding type (options or bindings), discard the profile as the source of items of that type.

  6. Otherwise, add the profile to the set of profile descriptors to return. Personalizer actually returns only two top profiles in each category to the caller.

Appendix A. Reference Information

A.1. FingerTips Personalizer Framework On-Disk Files

FingerTips Personalizer Framework sets its own standard regarding pathnames for files and folders that relate to the framework. Personalizer-aware applications must respect this hierarchy.

Personalizer files, if present, must be located under a specific folder known as Personalizer Filesystem Root. The exact location of the root folder is important, since it is the base for all other Personalizer pathnames. The following table indicates Personalizer Filesystem Root locations for different operating systems.

Table A.1. Personalizer Filesystem Root Locations

Operating SystemPersonalizer Filesystem Root
Windows 98™, Windows Me™, Windows 2000™, Windows XP~/My Documents/My Games/Personalizer
Mac OS XHome folder/Personalizer
Unix and Linux systems~/.My Games/Personalizer

Replace the tilde character with an appropriate path (e.g., "C:" for a Windows 98 system, "/home/johnny" for a Linux system, "C:/Documents and Settings/johnny" for a Windows 2000 or Windows XP system).

A FingerTips Personalizer Framework's installation manifests the following filesystem hierarchy.

Table A.2. Personalizer Filesystem

+Personalizer Root Folder
 +libraryHosts files of Personalizer libraries.
 actions.xmlLibrary of actions.
 options.xmlLibrary of options     
 optypes.xmlLibrary of option types.     
 +preferencesHosts the persistent preferences memory.     
 preferences.xmlGaming preferences central storage.     
 +schemasHosts Personalizer XML Schemas.     
 actions.xsdSwarm of in-game actions. Autogenerated from library/actions.xml.     
 common.xsdCommon definitions for Personalizer XML Schemas.     
 controls.xsdIncluded XML Schema - controls available for use in bindings.     
 libactions.xsdLibrary of actions XML Schema.     
 liboptions.xsdLibrary of options XML Schema.     
 liboptypes.xsdLibrary of option types XML Schema.     
 options.xsdSwarm of options. Autogenerated from library/options.xml.     
 personalizer.xsdMain XML Schema driver for preferences memory.     
 primeII.xsdMetadata configuration document XML Schema.     
 types.xsdSwarm of option types. Autogenerated from library/optypes.xml.     
 +xslHosts various visualization scripts.     
 +stylersContains XSL visualization scripts for libraries and preferences memory.     

A.2. Relevant Links

The following links are of interest to a developer using FingerTips Personalizer Framework.

Appendix B. System Requirements

The following table summarizes general system requirements for developing and redistributing Personalizer-aware games.

Table B.1. FingerTips Personalizer Framework System Requirements

ParameterDevelopmentGamer's Box
Performance FootprintDoes not apply.None, Personalizer is not intended for use in real time.
Memory FootprintDoes not apply.Depends on the size of the preferences memory. FingerTips Personalizer Framework's Application Programming Interface allows unloading of irrelevant information during run-time and reloading the information again as needed.
Disk Space FootprintUp to 15 megabytes of disk space.Up to 15 megabytes of disk space.
Game Installer Size FootprintUnder 10 megabytes.Does not apply.
Operating SystemsMicrosoft Windows 2000 or Microsoft Windows XP recommended.Microsoft Windows 98, Microsoft Windows Me, Microsoft Windows NT 4.x, Microsoft Windows 2000, Microsoft Windows XP, Microsoft Windows Vista, Windows Server platforms. Ports for other target platforms are in consideration.

FingerTips Personalizer Framework Glossary

preferences memory

A persistent on-disk storage that keeps a gamer's personalized defaults for game controls and options. The location of preferences memory is fixed for all operating systems where Personalizer is available. The contents of preferences memory is accessible through our open source Application Programming Interface.

library

A set of definitions for configurable items. There are three libraries: library of in-game actions, library of options, and the supporting library of option types. Preferences memory can only contain preferences based on library items. Personalizer initially includes a rich library of options and actions; games and related applications can add to this library as need arises. The location of libraries is fixed for all operating systems where Personalizer is available.

core

Defines information inherent to FingerTips Personalizer Framework. For example, in "core option", "core" emphasizes that the option definition is initially included in FingerTips Personalizer Framework. Compare to custom.

custom

Defines information specific to concrete games. For example, in "custom action", "custom" emphasizes that the action definition is installed by a game. Compare to core.

snapshot

A backup copy of critical Personalizer information (preferences data, libraries, XML Schemas) with a timestamp. Snapshots allow for restoring a corrupt installation to one of the recent valid states.

extraction

Exporting a profile as an external file suitable for integration on other Personalizer-aware systems.

integration

Putting a profile extracted on another Personalizer-aware system into the line of active profiles.

origin

A unique string associated with certain library definitions (see action definition, option definition, option type definition) that identifies the source of these definitions. The source for core definitions is 'Core FingerTips Personalizer Framework Library'. Custom definitions must have their own unique origins.

profile

Container for preferences related to a single game, a certain game genre, or a game series. Contains any number of options, bindings, and sequences. A profile may inherit other profiles (see inheritance.)

binding

An association established between inputs of a peripheral hardware control device (such as keyboard, mouse, joystick, or gamepad), collectively known as control, and an in-game action.

action

Also known as in-game action. Any action initiated by the game player after the game launches.

in-game action

See action.

action name

A unique string identifier that follows the rules set for Personalizer library item names. Name of a core action becomes part of the FingerTips Personalizer nomenclature and should be used in the game setup screens. You must 'unmangle' action names before presenting them to gamers.

action definition

A fragment of a library of actions that defines facets of a single action, such as action name and action argument pattern. Every action definition belongs to an origin.

action class

A metadata property intended for structuring the library of actions. Classifies actions as belonging to various categories of activity in a game. For example, class Motion hosts all the actions related to moving the player character.

action argument

A free-form or regex-constrained string that serves as one of the action parameters. Action argument partially controls the behaviour of an action.

control

A sum of inputs from hardware peripherals such as keyboard, mouse, joystick, and gamepad.

option

An option is a certain game setting that can be enabled, disabled, or assigned a particular value. Certain options let the gamer specify a number of values in the order of decreasing preference. These are known as preference values.

option definition

A fragment of library of options that defines facets of a single option, such as option name and option class. Every option definition belongs to an origin.

option name

A unique string identifier that follows the rules set for Personalizer library item names. Name of a core option becomes part of the FingerTips Personalizer nomenclature and should be used in the game setup screens. You must 'unmangle' option names before presenting them to users.

option class

A metadata property intended for structuring the library of options. Classifies options as belonging to various categories. For example, class Graphics hosts all the options related to visuals.

option type

A set of values that are valid for an option of this type. To define such value sets, FingerTips Personalizer uses [Perl 5-compatible] regular expressions. There are several built-in option types, such as String, Truth, Percentage. Games and related applications can add new option types to the library of option types as need arises.

option type name

A unique string identifier that follows the rules set for Personalizer library item names. Name of a core option type becomes part of the FingerTips Personalizer nomenclature.

option type definition

A fragment of library of option types that defines facets of a single option type, such as option type name and regular expression. Every option type definition belongs to an origin.

sequence

A set of option assignments and action calls executed successively. See also sequence element.

sequence element

Collective term for option assignments and action calls within sequences. Sequences elements are instructions the sequences consist of.

action call

A sequence instruction that executes a single FingerTips Personalizer action.

action execution flow

Defines the execution flow of an action call. Available flows are Standard ("Wait until this action fully executes, then proceed to interpret subsequent sequence elements") and Spawn ("Execute this action in parallel with subsequent sequence elements".)

option assignment

A sequence instruction that changes the value of an option.

inheritance

A way to reuse content of a profile in other profiles. If profile A inherits (or uses) profile B, B's content becomes available in A. Inheritance works by references, no actual copying of data occurs. See also self-inheritance, inheritance loop, and override.

self-inheritance

A situation when a profile references its own contents for inclusion. Self-inheritance is prohibited and the offending reference will be removed or ignored by the system.

inheritance loop

A situation when a profile references its own contents for inclusion, although indirectly. For example, in a hierarchy of profiles where A uses B, B uses M, M uses A, an inheritance loop exists. The system will cut inheritance loops by removing offending references (in this case, profile M will no more reference profile A.

preference value

An option value that the profile's owner considers acceptable. An array of option values constituting an option defines the order of preference. The first value is the most preferred, the last value is the least preferred, but acceptable. The game must set the option to the earliest possible preference value.

override

Redefinition of an option or a binding as a result of inheritance.

grade

A game option with a fixed number of possible values. Grades are compatible with option type Percentage. FingerTips Personalizer rounds Percentage values to accomodate grades.

FingerTips Personalizer Framework (Personalizer Home)