SetLineTexture

void SetLineTexture(int lineid, int line_side, int sidedef_texture, str texturename);

Usage

SetLineTexture will change the specified texture on all lines with the line id number specified (assigned by Line_SetIdentification or directly in UDMF). For readability, line_side and sidedef_texture have some definitions in zdef.acs:

  • SIDE_FRONT  front of the linedef (front sidedef)
  • SIDE_BACK  back of the linedef (back sidedef)
  • TEXTURE_TOP  upper texture of sidedef
  • TEXTURE_MIDDLE  middle texture of sidedef
  • TEXTURE_BOTTOM  lower texture of sidedef

Parameters

  • lineid: the line id of the lines to change.
  • line_side: the side of the line to change.
  • sidedef_texture: which texture to change.
  • texturename: the texture that will be set on the line. Using "-" means to remove a texture.

Examples

script 1 (int line1, int line2, int line3)
{
    SetLineTexture(line1, SIDE_FRONT, TEXTURE_MIDDLE, "-"); //remove middle 
    SetLineTexture(line1, SIDE_BACK, TEXTURE_MIDDLE, "-"); //floating texture

    SetLineTexture(line2, SIDE_BACK, TEXTURE_TOP, "BFALL1");
    SetLineTexture(line3, SIDE_BACK, TEXTURE_BOTTOM, "FOOTEX01");
}

This article is issued from Zdoom. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.