MovieClip.prototype.vibration = function(staerke) {
this.onEnterFrame = function() {
this._x = Math.sin(a)*staerke+100;
this._y = Math.cos(a)*staerke+100;
a++>=10 ? a=0 : null();
};
};
//usage;
mc3.vibration(1);
MovieClip.prototype.ZoomDiv = function (pDim, pTempo)
{
this.onEnterFrame = function ()
{
if (this._xscale < pDim - 1 / pTempo)
{
this._xscale = this._xscale + (pDim [...]
Otomatil zoom için prototype
MovieClip.prototype.ZoomAdd = function (pOption, pDim, pTempo)
{
if (pOption)
{
this.onEnterFrame = function ()
{
if (this._xscale < pDim)
[...]
Actionscript ile style verme ve text olusturma Creating TextField by AS
_root.createTextField("newField",1,100,100,300,300);
with (newField){
background = true;
backgroundColor=0×8888FF;
border = true;
borderColor = 0×000000;
autoSize = "left";
wordWrap = true;
[...]
Flash’ın Kendi tween classının kolaylastırılmıs ve optimize edilmiş halı oldukca basit kulanıslı kb olarak yer kaplamıyor. Kulanım ornekleri ve link devamında..
Genelde problem olan ve sık ıhtıyac duyulan bir kod .Sahnenin tam ortasını hesaplayıp bu movie clipleri dizmek Basit bir function ile kolay hale gelıor
MovieClip.prototype.centerClip = function (){
this._y = this._parent._height / 2 - (this._height / 2);
this._x = this._parent._width / 2 - (this._width / 2);
};
// USAGE:
// Center MovieClip
// by: Gustavo Perez
// aka pcMan [...]