Hello, let me introduce myself.
I’m craqueleure and am new to programming.
However, I’ve tried some basic algorithms to make a typing program in Flash 8.
The alphabet has a size of 50*50px.
The problem with this is that it doesn’t have a backspace function. Then, I added
I have been figuring out how to do this since months ago.
Because I don’t know the syntax and anything in Flash 8, I searched for it on the Internet. I’ve got some time because I’m in a holiday.
Actually just a few hours ago I managed to complete the actions in the first image, but I’ve got some problems in doing the second image (backspace function).
The backspace function will delete the last-created character.
The code looks like this
var xposisi:Number = 0; //the x of the movie clip created
var yposisi:Number = 0; //the y of the movie clip created
var nomor:Number = 0; //the number of the movie clip
var namo:String = "cacaca";
var namonyo:String = namo.concat(nomor); //the name of the instance of the last movie clip
var mvc:MovieClip; //I want to utilise this
stop;
function myHello () {
if (xposisi > 501) {
{yposisi = yposisi + 50;
xposisi = 0;
}
}
}
setInterval(myHello, 20);
keyListener = new Object();
keyListener.onKeyDown = function() {
if (Key.getCode() == 65){
_root.attachMovie("hua", namonyo, _root.getNextHighestDepth(), {_x:xposisi, _y:yposisi});
xposisi = xposisi + 50;
nomor = nomor + 1;
}
}
else if... until Z
Key.addListener(keyListener);
** keyListener2 = new Object();**
** keyListener2.onKeyDown = function() {**
** if (Key.getCode() == 8)**
** {**
** if (xposisi = 0)**
** {**
** _root.removeMovieClip(namonyo);**
** yposisi = yposisi - 50;**
** xposisi = 500;**
** }**
** else**
** {**
** _root.removeMovieClip(namonyo);**
** xposisi = xposisi - 50;**
** }**
** }**
** }**
** Key.addListener(keyListener2);**
If any people here could provide me with some help I will be very pleased.
Thank you