Home - Forums - Documentation - Gallery - Bugs
m
Current revision (20:03, 25 March 2009) (edit) (undo)
 
(14 intermediate revisions not shown.)
Line 6: Line 6:
Additionally there exists a module called <b>pycscegui</b> in standard cs distribution that wraps the cegui-cs connector, plus the <b>pycsextra</b> module in CSExtra repository wrapping some additional plugins there, notably the cs-qt connector.
Additionally there exists a module called <b>pycscegui</b> in standard cs distribution that wraps the cegui-cs connector, plus the <b>pycsextra</b> module in CSExtra repository wrapping some additional plugins there, notably the cs-qt connector.
 +
 +
== Documents ==
 +
 +
=== Usage ===
[[Python Prerequesites]] Getting python to work with cs
[[Python Prerequesites]] Getting python to work with cs
Line 11: Line 15:
[[Introduction to the Python Bindings]] General remarks
[[Introduction to the Python Bindings]] General remarks
-
== cspace Tutorial apps ==
+
[[Python Mini Howtos]] Little howtos about doing things.
-
You can find them at scripts/python/tutorial* with cs standard distribution.
+
[[Using callback interfaces from python]] Document on using callbacks
 +
 
 +
=== Cel Specific ===
 +
 
 +
[[Python Property Classes]] Creating property classes from python.
 +
 
 +
=== Technical ===
 +
 
 +
[[Generating wrappers for your own cs plugins/apps]] How to guide on generating wrappers for external projects that will work with the cs ones.
 +
 
 +
[[Compiling Python binding MSVC]] How to guide on compiling python bindings on MSVC
 +
 
 +
== Pure Python CrystalSpace tutorial apps ==
 +
 
 +
You can find them at [https://crystal.svn.sourceforge.net/svnroot/crystal/CS/trunk/scripts/python/ scripts/python/] with cs sdk.
 +
 
 +
* <b>tutorial0.py</b>: minimal pure-Python script to setup Crystal Space from Python.
 +
* <b>tutorial1.py</b>: Creates a room and allows moving around.
 +
* <b>tutorial2.py</b>: Creates a room and some object.
 +
* <b>tutorial3.py</b>: Loads a whole world.
 +
* <b>tutorial4.py</b>: Nicer way of doing an app (on cs 1.3 onwards).
 +
* <b>pyceguitest.py</b>: An example loading a cegui interface.
 +
* <b>csutils.py</b>: Helper module with a base python app you can inherit from, used by tutorial4 (on cs 1.3 onwards).
== Celstart Tutorial apps ==
== Celstart Tutorial apps ==
Line 20: Line 46:
http://b2cs.delcorp.org/celstart/
http://b2cs.delcorp.org/celstart/
 +
 +
* <b>playertest.zip</b>: A player moving around.
 +
* <b>lookat.zip</b>: A player and several cubic entities looking at him.
 +
* <b>odetest.zip</b>: A player and some physics enabled objects.
 +
* <b>particles.zip</b>: A player and several particle systems.
 +
* <b>quests.zip</b>: A player, and some quest controlled objects (a door and some pickables).
Note all of these examples are generated from [http://b2cs.delcorp.org/examples/ .blend sources] using blender2crystal.
Note all of these examples are generated from [http://b2cs.delcorp.org/examples/ .blend sources] using blender2crystal.
 +
 +
There are also many example behaviours at the cel library ([https://cel.svn.sourceforge.net/svnroot/cel/cel/trunk/data/library/blpython/ data/library/blpython] in cel sdk)
== Links ==
== Links ==

Current revision

Contents

Python Bindings for Cel and CrystalSpace

CrystalSpace and Cel both have their own scripting bindings. The modules are pretty extensive and should give you access to most of the c++ api.

The CrystalSpace python module is called cspace, and the cel counterpart is blcelc. Also, a slightly higher level module is available in cel for entity behaviours, called pycel.

Additionally there exists a module called pycscegui in standard cs distribution that wraps the cegui-cs connector, plus the pycsextra module in CSExtra repository wrapping some additional plugins there, notably the cs-qt connector.

Documents

Usage

Python Prerequesites Getting python to work with cs

Introduction to the Python Bindings General remarks

Python Mini Howtos Little howtos about doing things.

Using callback interfaces from python Document on using callbacks

Cel Specific

Python Property Classes Creating property classes from python.

Technical

Generating wrappers for your own cs plugins/apps How to guide on generating wrappers for external projects that will work with the cs ones.

Compiling Python binding MSVC How to guide on compiling python bindings on MSVC

Pure Python CrystalSpace tutorial apps

You can find them at scripts/python/ with cs sdk.

  • tutorial0.py: minimal pure-Python script to setup Crystal Space from Python.
  • tutorial1.py: Creates a room and allows moving around.
  • tutorial2.py: Creates a room and some object.
  • tutorial3.py: Loads a whole world.
  • tutorial4.py: Nicer way of doing an app (on cs 1.3 onwards).
  • pyceguitest.py: An example loading a cegui interface.
  • csutils.py: Helper module with a base python app you can inherit from, used by tutorial4 (on cs 1.3 onwards).

Celstart Tutorial apps

Some simple celstart applications to get you started.

http://b2cs.delcorp.org/celstart/

  • playertest.zip: A player moving around.
  • lookat.zip: A player and several cubic entities looking at him.
  • odetest.zip: A player and some physics enabled objects.
  • particles.zip: A player and several particle systems.
  • quests.zip: A player, and some quest controlled objects (a door and some pickables).

Note all of these examples are generated from .blend sources using blender2crystal.

There are also many example behaviours at the cel library (data/library/blpython in cel sdk)

Links

Python section at the cel manual

Python section at the cs manual

Creating celstart-python games using blender2crystal

Cs python api

Cel python api

Projects using CrystalSpace and Python

Interstate Outlaws

Ecksdee

CsPop

Do Let Us Know at the mailing list or irc channel if you want your project listed here.

Crystal Space machinamation demo
Crystal Space machinamation demo
Ecksdee, a futuristic Race & Destroy game
Ecksdee, a futuristic Race & Destroy game
Coche Garaje, a small celstart racing game.
Coche Garaje, a small celstart racing game.
| Article | Discussion | View source | History |