Difference between revisions of "SCI Specifications"

From SCI Wiki
Jump to navigationJump to search
m (1 revision)
m (Collector moved page Sierra Creative Interpreter Specifications to SCI Specifications over redirect)
 
(13 intermediate revisions by the same user not shown)
Line 1: Line 1:
by<br />
+
<div align="center"><span style="font-size: 22pt">Sierra Creative Interpreter Specifications</span><br />
 +
''Authors:''<br />
 
'''Lars Skovlund'''<br />
 
'''Lars Skovlund'''<br />
 
'''Christoph Reichenbach'''<br />
 
'''Christoph Reichenbach'''<br />
Line 8: Line 9:
 
'''Dark Minister'''<br />
 
'''Dark Minister'''<br />
 
'''Francois Boyer'''<br />
 
'''Francois Boyer'''<br />
 +
</div>
  
====Preface====
+
&nbsp;
 +
 
 +
====<br /> Preface====
 
This book describes the '''Sc'''ript '''I'''nterpreter or as it later became known as, '''S'''ierra '''C'''reative '''I'''nterpreter, versions 0.xxx and 1.xxx to the extent known to the general public, as well as the FreeSCI interpreter for those games. Please contact the author if you find that anything is being described incorrectly or missing.
 
This book describes the '''Sc'''ript '''I'''nterpreter or as it later became known as, '''S'''ierra '''C'''reative '''I'''nterpreter, versions 0.xxx and 1.xxx to the extent known to the general public, as well as the FreeSCI interpreter for those games. Please contact the author if you find that anything is being described incorrectly or missing.
  
Line 23: Line 27:
 
: [[SCI Specifications: Chapter_1_-_Introduction#The basics|1.1 &nbsp;The basics]]
 
: [[SCI Specifications: Chapter_1_-_Introduction#The basics|1.1 &nbsp;The basics]]
 
: [[SCI Specifications: Chapter_1_-_Introduction#Resource_Storage|1.2 &nbsp;Resource storage]]
 
: [[SCI Specifications: Chapter_1_-_Introduction#Resource_Storage|1.2 &nbsp;Resource storage]]
: [[SCI Specifications: Chapter_1_-_Introduction#The_individual_resources:_A_summary|1.3 &nbsp;The individual resources: A summary]]
+
: [[SCI_Specifications: Chapter 1 - Introduction#SCI Resources|1.3 &nbsp;SCI Resources]]
:: [[SCI Specifications: Chapter_1_-_Introduction#Graphical_resources_summarized|1.3.1 &nbsp;Graphical resources summarized]]
+
:: [[SCI_Specifications: Chapter 1 - Introduction#|1.3.1 &nbsp;SCI0 Resources]]
:: [[SCI Specifications: Chapter_1_-_Introduction#Sound_resources_summarized|1.3.2 &nbsp;Sound resources summarized]]
+
:: [[SCI_Specifications: Chapter 1 - Introduction#|1.3.2 &nbsp;SCI01 extensions]]
:: [[SCI Specifications: Chapter_1_-_Introduction#Logic_resources_summarized|1.3.3 &nbsp;Logic resources summarized]]
+
:: [[SCI_Specifications: Chapter 1 - Introduction#|1.3.3 &nbsp;SCI1 extensions]]
: [[SCI Specifications: Chapter_1_-_Introduction#SCI01_extensions|1.4 &nbsp;SCI01 extensions]]
+
: [[SCI Specifications: Chapter_1_-_Introduction#The_individual_resources:_A_summary|1.4 &nbsp;The individual resources: A summary]]
: [[SCI Specifications: Chapter_1_-_Introduction#SCI1_extensions|1.5 &nbsp;SCI1 extensions]]
+
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI0_Graphical_resources_summarized|1.4.1 &nbsp;Graphical resources summarized]]
: [[SCI Specifications: Chapter_1_-_Introduction#Sierra_SCI_games|1.6 &nbsp;Sierra SCI games]]
+
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI0_Sound_resources_summarized|1.4.2 &nbsp;Sound resources summarized]]
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI0|1.6.1 &nbsp;SCI0]]
+
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI0_Logic_resources_summarized|1.4.3 &nbsp;Logic resources summarized]]
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI01|1.6.2 &nbsp;SCI01]]
+
: [[SCI Specifications: Chapter_1_-_Introduction#Sierra_SCI_games|1.5 &nbsp;Sierra SCI games]]
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI1|1.6.3 &nbsp;SCI1]]
+
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI0|1.5.1 &nbsp;SCI0]]
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI1-T.A series|1.6.4 &nbsp;SCI1-T.A series]]
+
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI01|1.5.2 &nbsp;SCI01]]
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI1 suspected forks|1.6.5 &nbsp;SCI1 suspected forks]]
+
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI1|1.5.3 &nbsp;SCI1]]
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI1.1|1.6.6 &nbsp;SCI1.1]]
+
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI1-T.A series|1.5.4 &nbsp;SCI1-T.A series]]
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI32|1.6.7 &nbsp;SCI32]]
+
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI1 suspected forks|2.5 &nbsp;SCI1 suspected forks]]
 +
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI1.1|1.5.6 &nbsp;SCI1.1]]
 +
:: [[SCI Specifications: Chapter_1_-_Introduction#SCI32|1.5.7 &nbsp;SCI32]]
  
 
==[[SCI Specifications: Chapter 2 - Resource files]]==
 
==[[SCI Specifications: Chapter 2 - Resource files]]==
Line 134: Line 140:
 
&nbsp;
 
&nbsp;
  
: ''Note: This is a Wiki conversion of the [http://freesci.linuxgames.com/scihtml/book1.html original SCI documentation] found on the FreeSCI site. The following is the copyright from that documentation''
+
: ''Note: This is a Wiki conversion of the [http://web.archive.org/web/20090221173250/http://freesci.linuxgames.com/scihtml/book1.html SCI documentation] found on the FreeSCI site. The following is the copyright from that documentation''
  
  
Line 149: Line 155:
 
The Sierra Creative Interpreter was originally developed by Sierra On-Line, Inc. "Sierra On-Line Inc. (TM)" is a registered trademark of Sierra On-Line, Inc. ''Quest for Glory: So You Want To Be A Hero'', ''Quest For Glory 2: Trial By Fire'' and ''Space Quest 3: The Pirates of Pestulon'' are trademarks of Sierra On-Line, Inc.
 
The Sierra Creative Interpreter was originally developed by Sierra On-Line, Inc. "Sierra On-Line Inc. (TM)" is a registered trademark of Sierra On-Line, Inc. ''Quest for Glory: So You Want To Be A Hero'', ''Quest For Glory 2: Trial By Fire'' and ''Space Quest 3: The Pirates of Pestulon'' are trademarks of Sierra On-Line, Inc.
  
 +
&nbsp;
 +
 +
[[Category:SCI Documentation]]
 
[[Category:Sierra Creative Interpreter Specifications]]
 
[[Category:Sierra Creative Interpreter Specifications]]

Latest revision as of 19:42, 2 December 2015

Sierra Creative Interpreter Specifications

Authors:
Lars Skovlund
Christoph Reichenbach
Ravi Iyengar
Rickard Lind
Vladimir Gneushev
Petr Vyhnak
Dark Minister
Francois Boyer

 


Preface

This book describes the Script Interpreter or as it later became known as, Sierra Creative Interpreter, versions 0.xxx and 1.xxx to the extent known to the general public, as well as the FreeSCI interpreter for those games. Please contact the author if you find that anything is being described incorrectly or missing.

Warning.png This version of the documentation is incomplete and covers only some parts of SCI0.

Throughout the documentation, the term SCI will be used to describe the original Sierra Creative Interpreter, in any version. SCI0 will refer to all games using the SCI version 0.xxx, except for those games who use the 'in-between' game engine referred to as SCI01 (such as Quest for Glory 2). SCI1 will refer to the interpreter version 1.xxx. FreeSCI will refer specifically to either implementation details of the FreeSCI engine or to extensions of the original SCI engine specific to FreeSCI.

I would like to take this opportunity to thank the members of the FreeSCI and SCI Decoding Projects and their supporters, as well as Carl Muckenhoupt, who took the first steps of SCI decoding, for their valuable help and support.

Please note that some of the text contributions have been cut, reformatted or slightly modified in an attempt to improve the general quality of this document.

SCI Specifications: Chapter 1 - Introduction

1.1  The basics
1.2  Resource storage
1.3  SCI Resources
1.3.1  SCI0 Resources
1.3.2  SCI01 extensions
1.3.3  SCI1 extensions
1.4  The individual resources: A summary
1.4.1  Graphical resources summarized
1.4.2  Sound resources summarized
1.4.3  Logic resources summarized
1.5  Sierra SCI games
1.5.1  SCI0
1.5.2  SCI01
1.5.3  SCI1
1.5.4  SCI1-T.A series
2.5  SCI1 suspected forks
1.5.6  SCI1.1
1.5.7  SCI32

SCI Specifications: Chapter 2 - Resource files

2.1  SCI0 resources
2.1.1  resource.map
2.1.2  resource.<nr>
2.2  SCI1 resources
2.2.1  resource.map
2.2.2  resource.<nr>
2.3  Decompression algorithms
2.3.1  Decompression algorithm LZW
2.3.2  Decompression algorithm HUFFMAN
2.3.3  Decompression algorithm COMP3
2.3.4  Decompression algorithm DCL-EXPLODE
2.3.5  Decompression algorithm UNKNOWN

SCI Specifications: Chapter 3 - The Graphics subsystem

3.1  General stuff
3.2  SCI Ports
3.3  The Cursor resource
3.3.1  Color mapping for the SCI0 mouse pointer
3.3.2  Color mapping for the SCI1 mouse pointer
3.4  The SCI0 View Resource
3.4.1  The View Resource
3.4.2  Cell List
3.4.3  Image Cell
3.5  The SCI font resource
3.6  The SCI0 and SCI01 pic resource
3.7  Windows, Dialogs and Controls
3.8  Pictures and movement control

SCI Specifications: Chapter 4 - The Sound subsystem

4.1  The SCI0 Sound Resource Format
4.1.1  Preface
4.1.2  Sound Devices
4.1.3  File Format
4.1.4  Digial Samples
4.1.5  Revision history
4.2  Mapping instruments in FreeSCI
4.2.1  The Patch.002 resource
4.2.2  Percussion instruments

SCI Specifications: Chapter 5 - The SCI Virtual Machine

5.1  SCI Virtual Machine Introduction
5.1.1  Script resources
5.1.2  Selectors
5.1.3  Function invocation
5.1.4  Variable types
5.2  Interpreter initialization and the main execution loop
5.3  The SCI Heap
5.3.  Heap structure
5.3.  Memory handles
5.3.  Initialization
5.3.  Memory allocation
5.4  The Sierra PMachine
5.4.1  Local variables (LocalVar)
5.4.2  Global variables
5.4.3  Temporary variables
5.4.4  Parameter variables
5.4.5  Objects
5.4.6  The PMachine "registers"
5.4.7  The instruction set
5.5  Kernel functions
5.5.1  Parameter types
5.5.2  SCI0 Kernel functions

SCI Specifications: Chapter 6 - SCI in action

6.1  Event handling in SCI
6.1.1  Event types and modifiers
6.2  The Parser
6.2.1  Vocabulary file formats
6.2.2  The black box: The magic behind Sierra's text parser
6.2.3  The Parse tree
6.2.4  Said specs
6.2.5  Matching the trees
6.3  Views and animation in SCI

List of Tables

2-1  SCI0 compression algorithms
2-2  SCI01 compression algorithms
2-3  SCI1.0 compression algorithms
2-4  SCI1.1 compression algorithms
3-1  The SCI font resource data structure
3-2  The SCI font resource character data structure
6-1  SCI and FreeSCI signal bits

List of Examples

6-1  Parse grammar example
6-2  Parser example
6-3  Semantic tree example

 
 

Copyright Info
 

Note: This is a Wiki conversion of the SCI documentation found on the FreeSCI site. The following is the copyright from that documentation


Copyright (C) 1999, 2000, 2001, 2002 by the authors - Lars Skovlund, Christoph Reichenbach, Ravi Iyengar, Rickard Lind, Vladimir Gneushev, Petr Vyhnak, Dark Minister and Francois Boyer

Permission is hereby granted, free of charge, to any person obtaining a copy of this documentation to deal in the Documentation without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Documentation, and to permit persons to whom the Documentation is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Documentation.


THE DOCUMENTATION IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE DOCUMENTATION OR THE USE OR OTHER DEALINGS IN THE DOCUMENTATION.


The Sierra Creative Interpreter was originally developed by Sierra On-Line, Inc. "Sierra On-Line Inc. (TM)" is a registered trademark of Sierra On-Line, Inc. Quest for Glory: So You Want To Be A Hero, Quest For Glory 2: Trial By Fire and Space Quest 3: The Pirates of Pestulon are trademarks of Sierra On-Line, Inc.