Clean, reset or delete dynamically loaded texture (SOLVED)

just add more params to function from gui api ))

gui.new_texture(name, 1, 1, "rgb", string.rep(string.char(0x00) .. string.char(0x00) .. string.char(0x00), 1 * 1))

Probably the error was in the texture size being 0