ReplaceObjectTexture( object, string, string )

From NWN Lexicon
Revision as of 19:47, 8 August 2020 by Shadguy (talk | contribs) (Version: version corrected)
Jump to: navigation, search
Nwnee logo.jpg Note: This article documents Neverwinter Nights: Enhanced Edition new content or changes/updates/fixes to 1.69 functions. These are all listed under the category and patches pages.
Replace individual textures on objects at runtime.
void ReplaceObjectTexture(
    object oObject,
    string sOld,
    string sNew = ""
);


Parameters

oObject
An object to update a texture.
sOld
The old texture to replace.
sNew
The new texture. Specifying sNew = "" will restore the original texture.


Description

Replace's oObject's texture sOld with sNew. Specifying sNew = "" will restore the original texture. If sNew cannot be found, the original texture will be restored. sNew must refer to a simple texture, not PLT.

Remarks

Information icon.png This section of the article is a stub. You can help the NWN Lexicon by expanding it.


Version

1.80.8193.14

Example

Information icon.png This article is in need of examples. You can help the NWN Lexicon by showing how to use this code effectively.


See Also

functions: SetTextureOverride()



 author: Shadguy