Tootsville.FurnitureBuilder.setMaterialTexture

Function

Tootsville.FurnitureBuilder.setMaterialTexture is a function with lambda list: (material, texture, scene)

Items may have a material texture applied on a per-item basis. The material must be named (case-insensitive) map and the texture filename is given by the item's specialTexture field.

Kinds of Special Textures

Ordinarily, this will be a PNG or JPEG file located at https://jumbo.tootsville.org/Assets/Textures/5/ whose name is given in specialTexture ending in .png or .jpg or .jpeg.

However, the special texture may also be an SVG image which will be drawn onto a texture (probably at 1024×1024 px), if its name ends in .svg.

The special texture may also be a video stream, which will be played on a silent loop, when its name ends in .mp4, .webm, or .ogv. Note that we will attempt to load all of the MPEG 4, WebM, and OGG Vorbis forms of the video simultaneously in different browsers, so it is not defined which of the two will be loaded by any particular user (due to CODEC issues in browsers). A third file, in JPEG format and named ending in .jpg will be used as the “poster” image texture until the video has loaded.

Very Special Special Textures

Other special cases can be specified with names that begin with the character #, since that is forbidden in URLs (and used in the operator command language in Tootsville as well). Currently, only one such extension is defined, which is #theater-west.

#theater-west

The special code #theater-west is used only for the movie screen in the theater located in Toot Square West, which has some special behaviors.

First, the theater's current film is selected by a server-side setting from the Assets/Movies/5/ path.

Second, the film plays at the same time offset for all users, modulo the running length of the film.

Third, the film plays with sound enabled.