paintSprite(layer,id, ...properties) , method of controller

Change the appearance of a sprite on the controller of a player.

Parameters:
name type description
layer int layer of the world (must be >= 0)
id int identifier of the sprite (must be >= 0)
properties …Object appearance parameter values, see Sprite properties
//  change the texture of a sprite

UB.controller(playerID).paintSprite(0,1,{texture:"images/rose.png"});

See all methods of the api.