Page 1 of 1

self:set("backmaterial")

Posted: 2006-10-07, 04:40
by desirefx
I'm trying to understand the syntax for this method.

What file types can be loaded as background images for windows?
What is the path specification to the file? is it relative to where the cgui files are located?

Posted: 2006-10-07, 09:42
by Carsten
Hi,

well the "backMaterial" variable (note the capital M, the variables names are case sensitive) takes as a value the name of a MatSys material. This MatSys material will be used for the background of the window.

Please see the MatSys documentation for more details, i.e.
http://www.ca3d-engine.de/wiki/doku.php ... troduction and
http://www.ca3d-engine.de/wiki/doku.php ... mat_manual

Short summary:
You have to create a new .cmat file in the Games/DeathMatch/Materials folder or a subfolder. In this file, define your (GUI background-)materials, then use their names with the set:self("backMaterial", "my/GUI/Material") statement.

By the way:
The Ca3DE GuiSys is pretty new to the engine, and it seems you're its first serious user. ;) So if you experience any problems etc, please let me know - I'd be happy about any feed-back!

Posted: 2006-10-09, 21:27
by desirefx
Question,

The names I use:

Is it the name of the .cmat file? or is it the name of the texture within the .cmat file?

What file types can be used within the cmat file?

Posted: 2006-10-10, 14:59
by Carsten
desirefx wrote:Is it the name of the .cmat file?
Nope, name of the material. That is, in the example at http://www.ca3d-engine.de/wiki/doku.php ... mat_manual the name would be Textures/Kai/3r_metpan01
or is it the name of the texture within the .cmat file?
Name of the material, to be precise. ;)
What file types can be used within the cmat file?
png, tga, jpg and bmp, as detailed at http://www.ca3d-engine.de/wiki/matsys:c ... ifications subsection "Map Compositions", point "filename".
;)