RailClone Reference
RailClone / Library / Customizing

Customizing


Overview

In RailClone we include some nice libraries, but often you will need to create your own styles or modify the included ones. Creating a new tree library is an easy and quick way to reuse and share RailClone models in your proyects. In this section you will learn the possible options to create your own libraries in RailClone.

All libraries are stored in disk as XML files, you can also edit them with a text editor or with an xml editor.


Folder and Library edition

The RailClone libraries are divided into two types, the standard libraries included with the plugin and third-party packages. Libraries you create are stored by default in "My Documents\RailClone."

Note: the libraries included with RailClone cannot be modified. If you want to edit them, make a copy of the files to your own user folder. See below for a reference of the libraries' file structure.

You can edit the folder tree at the left panel. Use the right mouse button to access to the context menu. Use the context menu to create new libraries, or empty folders to organize them. You can also use the mouse to drag and drop folders and libraries between branches.

Tree Context Menu

Commands available in the tree context menu:

NameDescription
Create LibraryCreates a folder and a new "index.xml" file.
Create FolderCreates an empty folder on the disk, to organize folders or libraries.
RenameRenames a Folder or Library, this commands changes the name of the folder on the disk.
DeleteDeletes a Folder or Library with all its contents. Use with caution!

Item Editing

To edit or create items, right-click over the grid at left to show the context menu. On this menu you will find commands to create new items, delete, open the properties and import tools. Please note that item changes are stored only in system memory until you save the changes.

Style Properties

Commands available in the item context menu:

NameDescription
Create ItemCreates a new empty item in the current library.
PropertiesShows the Item Settings dialog box.
DeleteDeletes the selected item.

To commit your changes to disk, click the Save Changes button in the toolbar.


Style Properties

This window is used to set the properties for a library style. The RailClone plugin uses these settings to construct an object based on the properties of a reference object in a .max file.

RailCone Item Properties

Settings available for Styles:

NameDescription
NameStyle name.
FamilyFamily or catrgory.
DescriptionTextual description of the style.
Max File3DSMax scene where the reference object is stored.
ObjectName of the reference object. Choose one of the scene contents in the reference scene.
Override MaterialOverride the reference object material, and apply a supplied one.
Material Lib.3DSMax material library containing the material.
MaterialName of the override material, choose one from the selected library.
ThumbnailPreview image of object.
Thumbnail Selector buttonPress this button to change the thumbnail image.

File Structure

Library Structure

A library is a special folder on the disk which contains an index.xml file, where the items are listed. This file points to the files necesary to define a library style. The browser stops to scan directories when an index.xml file is found, so a library folder can't contain other libraries and all subfolders are hidden in the interface, this permits to you to organize the data in several subfolders.

Each library item points to a single template object in a .max file. Each time you select a library style, all settings in the template object are loaded and applied to the current RailClone object. You can group several objects in a single file, or have separate files for each one. You can also use macro substituion (see section below) to use conditions or complex structures.

Each library item also has an associated image file, typically stored in the thumbnails folder. This image is used to show the image preview in the library and you shuld have one image for each library item. If you name the files using the same name of the object, the image is automatically selected in the editor.

Additionally, you can have materials libraries to override the object's default material. This way you can have several library items with the same geometric base, but with different materials and textures.


Macros

In some fields, such as filenames and object or material names, you can use macro sustituions to add more flexibility to your library structures. These macros represent the library root location, current folder, or 3dsmax state values. The macros are instanced using the $(NAME) format.

To open the Insert Macro window, press the Macros... button in the properties window, select a macro and click OK, the selected macro will be inserted in the current field of the propierties.

Macro substitution