C3Fire

Object Configuration

From C3LearningLabs


Object Types

The xml element ObjectTypes defines all the geographical object types in a session.

<ObjectTypes>
  <ObjectType> 
  <ObjectType> 
  ...
  <ObjectType> 
</ObjectTypes>

The xml element ObjectType defines a geographical object type and contain a set of basic properties. Beside the basic properties the activated modules can add properties for the ObjectTypes. See documentation for each module.

A geographical object type is defined with the following properties:

Property

Module

Value

IDName

The identification name for a object type.

Value example = "Pine", "Birch", "House", "Water"

Description

Object description.

Value example= "Water post"/>

DestroyEffect

Forest Fire

What happens when the object are in fire.
See DestroyEffect

Value example= "Fuel station"/>

FireSpeed

Forest Fire

The fire spread factor for this object. The ignite time is multiplied with this value.

Value example= "1"
Value example = "0.5"

For more information see the fire simulation documentation.

FuelRefillSpeed

Logistic Fuel

The amount of fuel this object can to deliver every second to a unit that is refilling fuel from this object. Apply on object type "fuel". Value example = "15"

Module : Fuel Logistic

Should only be defined if the module FuelLogistic is active.

Image

The Image

UnitMovementSpeed

Units movement delay factor.

ValueEmotional

Emotional value.

ValueMaterial

Material Value.

WaterRefillSpeed

Logistic Water

The amount of water this object can to deliver every second to a unit that is refilling water from this object.
Apply on object type "water". Value example = "15"

Module : Water Logistic

Should only be defined if the module WaterLogistic is active.

    <ObjectType
      IDName = "Normal"
      Description = ""
      DestroyEffect = ""
      FireSpeed = "1"
      FuelRefillSpeed = "5"
      Image = "Object/Normal.gif"
      UnitMovementSpeed = "1"
      ValueEmotional = "1"
      ValueMaterial = "1"
      WaterRefillSpeed = "5" />


Objects

The xml element Objects contains all map objects that should exist in the simulation.

Object

Defines where a map object should exist.

Configuration example:

<source>
<Objects>
  <Object> ... </Object>
  <Object> ... </Object>
  ...
  <Object> ... </Object>
 <Object Type = "Pine" Pos = "12,12" />
    <Object Type = "Pine" Pos = "12,11" />
    <Object Type = "Pine" Pos = "11,2" />
    <Object Type = "Birch" Pos = "38,23" />
    <Object Type = "Birch" Pos = "23,40" />
    <Object Type = "Birch" Pos = "2,32" />
    <Object Type = "House" Pos = "40,40" />
    <Object Type = "Water" Pos = "17,22" />
    <Object Type = "Fuel"  Pos = "11,12" />
    <Object Type = "Water"  Pos = "10,10" />
</Objects>
</source>


A object is defined with the following properties:

Property

Value

Type

The object type identification number.

Value example = "House"
Value example= "Pine"

Pos

Pos on the map

Value example = "2, 20"
Value example= "12,12"

<Source>
    <Object
        Type = "Pine" 
         Pos = "12,12" 
    />
</Source>


Object Image

The image representing this object on the map should have the file name IDName with '12.gif' as a
extension ( <IDName>12.gif).

Example : Pine12.gif

The image file should be stored in the map image catalog <C3FIRE-MAP-IMAGES> , located at <C3FIRE-WWW-ROOT>/pic/

Example : C:\c3fire\www\pic\Pine12.gif


The standard experiment setting defines four object types. They are Normal, Pine, Birch and House.
The module extended setting defines an additional object type, Water. The type must be represented
of an image, named and saved according to examples above.


Standard experiment setting

Normal : C3system-config-session-unit-window-image-normal12.gif

Pine : C3system-config-session-unit-window-image-pine12.gif

Birch : C3system-config-session-unit-window-image-birch12.gif

House : C3system-config-session-unit-window-image-house12.gif


Module extended setting
Water : C3system-config-session-unit-window-image-water12.gif


C3system-config-session-unit-window-image-geographical-objects.gif
The different
geographical objects


Display Objects

The xml element Objects contains all map objects that should be visible on the users map at start.

DisplayObject

Defines where a map object should exist on the map.

Configuration example

<source>
<DisplayObjects>
  <DisplayObject> ... </DisplayObject>
  <DisplayObject> ... </DisplayObject>
  ...
  <DisplayObject> ... </DisplayObject>
    <DisplayObject Type = "Pine"  Pos = "5,10" />
    <DisplayObject Type = "Pine"  Pos = "38,22" />
    <DisplayObject Type = "Birch" Pos = "37,23" />
    <DisplayObject Type = "Birch" Pos = "1,2" />
    <DisplayObject Type = "Birch" Pos = "23,34" />
    <DisplayObject Type = "House" Pos = "1,38" />
    <DisplayObject Type = "Water" Pos = "17,22" />
    <DisplayObject Type = "Fuel"  Pos = "11,12" />
    <DisplayObject Type = "Water"  Pos = "10,10" />    
</DisplayObjects>
</source>

A DisplayObject is defined with the following properties:

Property

Value

Type

The object type identification number.

Value example = "House"
Value example= "Pine"

PosX

Pos on the map

Value example = "5, 10"
Value example= "12,12"


 
<Source>
    <DisplayObject
        Type = "Pine" 
         Pos = "12,12" 
    />
</Source>

DestroyEffect

 
  <DestroyEffects>

    <DestroyEffect
      IDName = "FuelStation"
      Description = "When the fuel station is in fire it will explode, All unit in the area 3x3 will be destroyed."
      DestroyTime = "0.0"
      FireRadie = "2"
      FireType = "Fire"
      ObjectRadie = "0"
      ObjectType = ""
      UnitRadie = "2"
      UnitType = "Destroy"
      WhenFireBurnedOut = "False"
      WhenInFire = "True"
      WhenInFireAndOutOfWater = "False" />

  </DestroyEffects>

Edit Objects on Map

Examples

Change House to School

If you have a map with houses and want to change some house to a school follow these steps.


  1. Make sure that the a school object is defined in ObjectTypes definition file, Example name ...-ObjectsTypes.coni
    <ObjectTypes>
      <ObjectType
        ...
        <ObjectType
            IDName = "School"
            AidRefillSpeed = "0"
            Description = ""
            DestroyEffect = ""
            FireSpeed = "1"
            Image = "/Object/School.gif"
            PeopleTransportAlwaysSendNrOfPeople = "False"
            PeopleTransportEnterLeaveSpeed = "0"
            PeopleTransportUnload = "False"
            PowerRefillSpeed = "0"
            SandbagRefillSpeed = "0"
            UnitMovementSpeed = "1"
            ValueEmotional = "1"
            ValueMaterial = "1" />
    

Map Editor

Undocumented feature

Description below make it possible to manipulate the map (objects and units) and save it to disk.

Activation
  1. In Players UI configuration in file <config_name>-UIMain-Mac.coni set ObjectPalette config to
  1.       <Object
            Name = "ObjectPalette"
            BorderVisible = "True"
            Enabeled = "true"      Should be true
            Pos = "1222,290"   
            Size = "120,180"
            Visible = "true"       Should be true
            VisibleObjects = "" /> Should be empty
    
  1. Start the session and let the session run


Map maipulation
While the session is running you can do this, (Save before session end).
The mouse pointer needs to be on the map to make the key commands to work.
Copy the saved object and unit positions to you configuration
  • Use the object palette to insert and delete objects in the map.



  • Alt-S : Save, saves the map to, ...\C3LearningLabs\C3Fire\Client\Files\Root\saved-map.txt
  • Alt-R : Rotate the map clockwise
  • Alt-L : Rotate the map counter clockwise
  • Alt-H : Mirror horizontally
  • Alt-V : Mirror vertically
  • Alt-T : Mirror top right bottom left
  • Alt-U : Mirror top left bottom right