Intranet Catprocess
  1. news...
  2. about Blackvoxel
  3. download
  4. manual
  5. videos
  6. about us
  1. Programmable Robot

    Programmable Robot BlackVoxel


    The Programmable Robot is a special active voxel whose behavior is controlled by an user defined program written using the Squirrel programming language.
    By the mean of a language extension, the robot can interract with the game environnment and make it's own use of the Voxel Dynamic Reaction Engine. The robot can move, grab and place voxels, scan environnment and use interfaces of other automation voxels to store/transmit/get voxels through them.
    The Robot have a storage space and support the voxel_input and voxel_output interfaces, so you can use voxels such as pumps or Voxel Dematerializer directly on it to fill it's storage space.

    We decided to use Squirrel, a programming language made by Alberto Demichelis because it's a modern and performant language. But one of the main reasons of the choice was it's use of a "near C style" syntax. Most of the main languages actualy used daily in the programming world are C syntax oriented (Ex : Javascript, C/C++, Java, PHP, Objective C, C#). So, learning a language with this syntax style is a good and long term investment.

    How to use it

    If you are familar with programming, first, you may look at the general language documentation at the official squirrel's website :
    Then, look at the robot programming manual for the specific functions added to the Squirrel language for driving the robot. Some examples are given in this manual for each functions.

    The squirrel programs used by the robot must be stored in a special directory which is tied to the world you are in. This directory is located in the blackvoxel storage directory into the subdirectories Universes/world_num/Scripts/Squirrel.The script must be named with the script number and the .nut extension. Ex : 0.nut , 1.nut, 2.nut....
    You can use whatever text editor or programming environment you like.

    There are 3 main functions your program can include.

    • Voxel_Load() : Called at the voxel creation or the loading of the voxel from the hard disk.
    • Voxel_Unload(): Called at the voxel destruction or before the unloading of the world/zone to the disk.
    • Voxel_Step() : Called at each voxel animation engine step.

    You must take care to don't take excessive execution time to avoid blocking or slowing down the Voxel Dynamic Reaction Engine (for Voxel_Step() ) or the Voxel Loader (for Voxel_Load() and Voxel_Unload() ).

    Not yet findable in the environment nor can be made by the player. Use provisory "cheat" key "L" to get some in your inventory.

    How to make it

    Use the following manufacturing instructions to make the item. If you do not know how to use them, follow how to understand manufacturing instructions

    How to collect it

    Can be collected like regular voxels with any type of constructor/destructor.

    Technical data

    Active Voxel : Yes
    Physical Form : Solid.
    Interface(s) : voxel_input, voxel_output
    VoxelType : 108

  2. Google+