Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

sketchpad background

New Here ,
May 11, 2008 May 11, 2008
Ok im very new to this. I used a tutorial to create a sketchpad from http://www.lukamaras.com/tutorials/cool-design/flash-drawing-pad.html

I would like to draw on a background image but dunno how to add this. i read somewhere about using empty movie clip but got stuck. anyone can help me!!!

TOPICS
ActionScript
3.5K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
May 11, 2008 May 11, 2008
if you mean you just want to replace the stage with an image, place an image on the stage and follow the rest of the tutorial steps.
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
May 11, 2008 May 11, 2008
that doesnt work. the drawing appears under the image and not on it
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 11, 2008 May 11, 2008
>>that doesnt work. the drawing appears under the image and not on it

Place the drawing on stage, and then place an empty movie clip on a layer
above the drawing. Give the clip an instance name of ink.

Change the two functions:

function startDrawing() {
if (_xmouse<455) {
ink.lineStyle(lineThickness, selectedColor);
ink.moveTo(_root._xmouse, _root._ymouse);
_root.onMouseMove = drawLine;
}
}
function drawLine() {
ink.lineTo(this._xmouse, this._ymouse);
}


--
Dave -
www.offroadfire.com
Head Developer
http://www.blurredistinction.com
Adobe Community Expert
http://www.adobe.com/communities/experts/


Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
May 11, 2008 May 11, 2008
ok managed to put a background on to draw over but the width<455 part is not working on the new movieclip.

Is there a way to stop the drawing when it goes past this coordinate
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
May 12, 2008 May 12, 2008
LATEST
The condition works, it's just that you test it only one time - in
startDrawing(). Notice you can't start drawing at x > 455. I think what you
want to do is then also put the test in drawLine(). Try:

function drawLine() {
if (_xmouse < 455) {
mcDrawing.lineTo(this._xmouse, this._ymouse);
}
}


--
Dave -
www.offroadfire.com
Head Developer
http://www.blurredistinction.com
Adobe Community Expert
http://www.adobe.com/communities/experts/


Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines