More Research and Testing

Today I have done some research on another piece of software that we are going to use in our project. Previously I had said that we were certain that we were going to use the programming software called Processing, but after much consideration and group meetings we have decided that we are going to use Flash. Why are we going to use Flash? Well, we have been studying it for the last 3-4 years and in my case I think I feel much more comfortable using it. We also had a massive project to make in Interactive Programming using Adobe Flash and after completing it I have learned a lot of important parts to the Flash system and also to the actionscript code. So today I wanted to do some testing with Flash using Actionscript code. As we have explained our project is going to based around drawing. We want the user to have a selection of colours that the can use so I did some coding and I came up with the colour pallete below. I think it is much more up to date than anything we could do in processing and I also think it looks more professional. I also inserted a “Erase” button on the stage just to give the user that option if the wanted to undo what the have drawing but we as a group have to decided whether we are going to keep that in the program or not. I also created a tool which lets the user select the line thinkness that they want. I thought that this would be a handy tool because if the were drawing something like a tree trunk it would save them colouring the whole tree trunk, instead they would just get the thickest line, which is 7, and select the colour brown and just draw the tree trunk. These are all just little ideas that could be incorporated into our project but are not definitive. I also have to do some research to see if reacTIVision will work with Flash because that is something else we are thinking of incorporating into our game in relation to using the cubes to select you background.


var spBoard:Sprite=new Sprite();




var shDrawing:Shape=new Shape();


var doDraw:Boolean=false;

var lineSize:Number=7;

var currentColor:Number;


spBoard.filters = [ new DropShadowFilter() ];





function boardOut(e:MouseEvent):void {



function boardDown(e:MouseEvent):void {




function boardUp(e:MouseEvent):void {



function boardMove(e:MouseEvent):void {

var curX:Number=shDrawing.mouseX;

var curY:Number=shDrawing.mouseY;

if(doDraw && checkCoords(curX,curY)){,curY);




function checkCoords(a:Number,b:Number):Boolean {

if(a>=250-lineSize/2 || a<=lineSize/2 || b>=250-lineSize/2 || b<=lineSize/2){

return false;

else {

return true;


btnErase.addEventListener(MouseEvent.CLICK, eraseClicked);
function eraseClicked(e:MouseEvent):void {;


btnUp.addEventListener(MouseEvent.CLICK, upClicked);

function upClicked(e:MouseEvent):void {



} else {





btnDown.addEventListener(MouseEvent.CLICK, downClicked);

function downClicked(e:MouseEvent):void {



} else {






Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s