home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2003 January
/
Chip_2003-01_cd1.bin
/
oddech
/
bechpack
/
bechpack.exe
/
scripts
/
frame_1064
/
DoAction.as
< prev
Wrap
Text File
|
2002-10-29
|
722b
|
37 lines
function createMosquitos(count)
{
var i;
i = 1;
while(count >= i)
{
_root.attachMovie("mosquito","mosquito" + i,i);
i++;
}
}
function changeCursor(movieclip)
{
Mouse.hide();
_root.attachMovie(movieclip,"customCursor",9999);
_root.customCursor.startDrag(true);
}
function calculateRandom(min, max)
{
return Math.floor(Math.random() * (max + 1 - min)) + min;
}
function playSound(max, x, soundID)
{
var soundobject;
soundobject = new Sound();
soundobject.attachSound(soundID);
if(x < 0)
{
x = 0;
}
else if(max < x)
{
x = max;
}
soundobject.setPan((x - max / 2) * 100 / (max / 2));
soundobject.start();
}