task06

Joshua Piersanti

Please install the Flash Player from Adobe to view this content.
Get Adobe Flash player

For this assignment, I decided to apply what I've learned to my MFA thesis work: creating a digital tool to improve the experience of design instructors and students. I focused on creating something that can be used for critiquing student work, a very common activity in design courses. My goal is to create something that can be used outside (and inside) of class to bring a level of organization, archiving, and participation not found in current in-class critiques.

I used materials from the introductory drawing course Design 201 (taught by our classmate Joelle).

There were lots of problems and challenges as I tried to implement the tool in Flash. I didn't know how to create a zoom/pan function allowing the user to interact more with the drawing. I eventually figured out how to do this when we talked about 'tweens' in class:

import fl.transitions.Tween;
import fl.transitions.easing.*;

function zoomIn(e:MouseEvent):void {
	this.startDrag ();
	MovieClip(parent).cursor.gotoAndPlay("HAND");
	var tween:Tween;
tween = new Tween(this, "scaleX", Regular.easeIn, 1, 1.5, 0.2, true);
tween = new Tween(this, "scaleY", Regular.easeIn, 1, 1.5, 0.2, true);
tween = new Tween(this, "x", Regular.easeIn, 174.9, x-(mouseX/2), 0.2, true);
tween = new Tween(this, "y", Regular.easeIn, 101.8, y-(mouseY/2), 0.2, true);

}
function zoomOut(e:MouseEvent):void {
	this.stopDrag ();
	MovieClip(parent).cursor.gotoAndPlay("INIT");
	var tween:Tween;
tween = new Tween(this, "scaleX", Regular.easeOut, 1.5, 1, 0.2, true);
tween = new Tween(this, "scaleY", Regular.easeOut, 1.5, 1, 0.2, true);
tween = new Tween(this, "x", Regular.easeOut, x, 174.9, 0.2, true);
tween = new Tween(this, "y", Regular.easeOut, y, 101.8, 0.2, true);
}

addEventListener(MouseEvent.MOUSE_DOWN,zoomIn);
addEventListener(MouseEvent.MOUSE_UP,zoomOut);

function onMove(e:MouseEvent):void {
	MovieClip(parent).cursor.x = stage.mouseX;
	MovieClip(parent).cursor.y = stage.mouseY;
	Mouse.hide();
	MovieClip(parent).cursor.alpha=100;
	MovieClip(parent).cursor.mouseEnabled = false;
	MovieClip(parent).cursor.mouseChildren = false;
}

function rollOut2(e:MouseEvent):void {
	Mouse.show();
	MovieClip(parent).cursor.alpha=0;
}

addEventListener(MouseEvent.MOUSE_MOVE, onMove);
addEventListener(MouseEvent.ROLL_OUT, rollOut2);

Another difficult area was trying to get SharedObject to remember mouse paths. I intended for the user to be able to draw a mouse path (a "doodle") on a drawing and have it stored along with the user's comment. It wasn't difficult to have SharedObject store the comment, but despite many, many attempts, I didn't figure out how to get a mouse path stored.

It was also challenging to make sure that, when the user clicked on the comment button to create a second comment, the button did not simply direct the user back to the first comment. Instead, a second comment had to be created, but only if there was already a first comment, and likewise with the creation of the third comment. To do this I needed to understand how "if" and "else if" work, and eventually this worked fine:

function makeAComment(e:MouseEvent):void {
	
	if (MovieClip(parent.parent).commenter1.currentFrame == 1) {
    MovieClip(parent.parent).commenter1.gotoAndPlay("TYPECOMMENT");
	}
	else if ((MovieClip(parent.parent).commenter1.currentFrame == 6||7) &&
		MovieClip(parent.parent).commenter2.currentFrame == 1)	{
	MovieClip(parent.parent).commenter2.gotoAndPlay("TYPECOMMENT");
	}
	else if (MovieClip(parent.parent).commenter2.currentFrame == 6||7) {
	MovieClip(parent.parent).commenter3.gotoAndPlay("TYPECOMMENT");
	}
	
}

typeText.addEventListener(MouseEvent.MOUSE_DOWN, makeAComment);