AS Class

Hi

I have managed to create a method which changes the colour of a line

I now…need a seperate method which changes the thickness of the line, however whatever I try messes up

thanks for any ideas.


class SimpleDraw {
 private var drawing_mc:MovieClip;
 private var penDown:Boolean;
 public function SimpleDraw(timeline:MovieClip, depth:Number) {
  drawing_mc = timeline.createEmptyMovieClip("drawingClip"+depth, depth);
  penDown = false;
  Mouse.addListener(this);
  drawing_mc.lineStyle(1, 0x000000, 100);
 }
** public function setColour(col:Number):Void {
  // thickness, colour, alpha
  drawing_mc.lineStyle(1, col, 100);
 }**
** [COLOR=red]public function setThick(l:Number):Void {
  // thickness, colour, alpha
  drawing_mc.lineStyle(l, c, 100);
 }[/COLOR]**
 public function onMouseDown():Void {
  drawing_mc.moveTo(_xmouse, _ymouse);
  penDown = true;
 }
 public function onMouseUp():Void {
  //drawing_mc.moveTo(_xmouse, _ymouse);
  penDown = false;
 }
 public function onMouseMove():Void {
  // place stuff inside class function
  if (penDown == true) {
   drawing_mc.lineTo(_xmouse, _ymouse);
  }
 }
}