s

부드러운 움직임 2

· 17년 전 · 2117

//관성력
MovieClip.prototype.inertiaMove = function(widthX,heightY,g,fric){
        if(this._x + this.speedX > widthX - this._width/2){
                this.speedX = -1*this.speedX;
                this._x = widthX - this._width/2;
        }else if(this._x + speedX <0 + this._width/2){
                this.speedX = -1*this.speedX;
                this._x = 0 + this._width/2;
        }else{
                this._x += this.speedX ;
        }
        if(this._y + this.speedY > heightY - this._height/2){
                this.speedY = -1*this.speedY;
                this._y = heightY - this._height/2;
        }else if(this._y + this.speedY <0 + this._height/2){
                this.speedY = -1*this.speedY;
                this._y = 0 + this._height/2;
        }else{
                this._y += this.speedY;
        }
       
        this.speedY = this.speedY + g;
        this.speedX = fric*this.speedX;
        this.speedY = fric*this.speedY;
};

//포물선운동
MovieClip.prototype.parabolaMove = function(){
        this.vy = this.vy + this.g;
        this._x = this._x + this.vx;
        this._y = this._y + this.vy;
};

[이 게시물은 관리자님에 의해 2011-10-31 16:50:06 Flash에서 이동 됨]
|
댓글을 작성하시려면 로그인이 필요합니다.

프로그램

+
제목 글쓴이 날짜 조회
17년 전 조회 1,602
17년 전 조회 1,698
17년 전 조회 1,495
17년 전 조회 1,532
17년 전 조회 1,568
17년 전 조회 1,656
17년 전 조회 1,656
17년 전 조회 1,697
17년 전 조회 1,631
17년 전 조회 1,980
17년 전 조회 3,287
17년 전 조회 3,699
17년 전 조회 1,779
17년 전 조회 1,889
17년 전 조회 1,675
17년 전 조회 2,440
17년 전 조회 3,363
17년 전 조회 1,696
17년 전 조회 1,674
17년 전 조회 1,708
17년 전 조회 1,572
17년 전 조회 1,750
17년 전 조회 1,812
17년 전 조회 1,632
17년 전 조회 2,893
17년 전 조회 1,661
17년 전 조회 1,913
17년 전 조회 1,797
17년 전 조회 2,126
17년 전 조회 2,120
17년 전 조회 2,131
17년 전 조회 2,201
17년 전 조회 1,879
17년 전 조회 1,931
17년 전 조회 1,844
17년 전 조회 2,184
17년 전 조회 2,110
17년 전 조회 1,890
17년 전 조회 2,089
17년 전 조회 1,745
17년 전 조회 1,974
17년 전 조회 2,297
17년 전 조회 3,128
17년 전 조회 2,340
17년 전 조회 1,733
17년 전 조회 2,307
17년 전 조회 2,756
17년 전 조회 1,888
17년 전 조회 2,653
17년 전 조회 2,118
17년 전 조회 1,822
17년 전 조회 1,646
17년 전 조회 2,324
17년 전 조회 3,259
17년 전 조회 2,846
17년 전 조회 1,859
17년 전 조회 3,246
17년 전 조회 2,764
17년 전 조회 3,120
17년 전 조회 3,126
17년 전 조회 2,904
17년 전 조회 2,720
17년 전 조회 2,068
17년 전 조회 2,803
17년 전 조회 4,336
18년 전 조회 2,172
18년 전 조회 4,268
18년 전 조회 2,181
18년 전 조회 2,072
18년 전 조회 2,437
18년 전 조회 2,838
18년 전 조회 1,789
18년 전 조회 2,136
18년 전 조회 2,705
18년 전 조회 2,186
18년 전 조회 2,121
18년 전 조회 1,921
18년 전 조회 1,748
18년 전 조회 1,729
18년 전 조회 1,511
18년 전 조회 1,532
18년 전 조회 1,532
18년 전 조회 1,541
18년 전 조회 1,939
18년 전 조회 2,053
18년 전 조회 2,176
18년 전 조회 3,317
18년 전 조회 2,473
18년 전 조회 2,117
18년 전 조회 2,474
18년 전 조회 2,203
18년 전 조회 3,728
18년 전 조회 1,879
18년 전 조회 2,013
18년 전 조회 1,711
18년 전 조회 2,567
18년 전 조회 3,494
18년 전 조회 2,610
18년 전 조회 2,086
18년 전 조회 3,345