s

부드러운 움직임 2

· 17년 전 · 1766

//관성력
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,275
17년 전 조회 1,389
17년 전 조회 1,164
17년 전 조회 1,211
17년 전 조회 1,250
17년 전 조회 1,320
17년 전 조회 1,340
17년 전 조회 1,363
17년 전 조회 1,320
17년 전 조회 1,641
17년 전 조회 2,969
17년 전 조회 3,368
17년 전 조회 1,458
17년 전 조회 1,554
17년 전 조회 1,365
17년 전 조회 2,120
17년 전 조회 3,038
17년 전 조회 1,383
17년 전 조회 1,377
17년 전 조회 1,375
17년 전 조회 1,238
17년 전 조회 1,427
17년 전 조회 1,489
17년 전 조회 1,298
17년 전 조회 2,582
17년 전 조회 1,328
17년 전 조회 1,593
17년 전 조회 1,471
17년 전 조회 1,778
17년 전 조회 1,796
17년 전 조회 1,814
17년 전 조회 1,869
17년 전 조회 1,530
17년 전 조회 1,612
17년 전 조회 1,524
17년 전 조회 1,864
17년 전 조회 1,770
17년 전 조회 1,567
17년 전 조회 1,749
17년 전 조회 1,413
17년 전 조회 1,647
17년 전 조회 1,961
17년 전 조회 2,795
17년 전 조회 2,002
17년 전 조회 1,409
17년 전 조회 1,965
17년 전 조회 2,420
17년 전 조회 1,582
17년 전 조회 2,336
17년 전 조회 1,767
17년 전 조회 1,470
17년 전 조회 1,329
17년 전 조회 2,002
17년 전 조회 2,896
17년 전 조회 2,513
17년 전 조회 1,534
17년 전 조회 2,883
17년 전 조회 2,419
17년 전 조회 2,769
17년 전 조회 2,782
17년 전 조회 2,559
17년 전 조회 2,377
17년 전 조회 1,731
17년 전 조회 2,469
17년 전 조회 3,961
17년 전 조회 1,839
17년 전 조회 3,923
17년 전 조회 1,853
17년 전 조회 1,745
17년 전 조회 2,082
17년 전 조회 2,483
17년 전 조회 1,440
17년 전 조회 1,783
17년 전 조회 2,346
17년 전 조회 1,819
17년 전 조회 1,766
17년 전 조회 1,553
17년 전 조회 1,401
17년 전 조회 1,354
17년 전 조회 1,162
17년 전 조회 1,159
17년 전 조회 1,185
17년 전 조회 1,192
17년 전 조회 1,613
17년 전 조회 1,689
17년 전 조회 1,829
17년 전 조회 2,963
17년 전 조회 2,105
17년 전 조회 1,777
17년 전 조회 2,112
17년 전 조회 1,826
17년 전 조회 3,362
17년 전 조회 1,540
17년 전 조회 1,669
17년 전 조회 1,382
17년 전 조회 2,197
17년 전 조회 3,142
17년 전 조회 2,281
17년 전 조회 1,740
17년 전 조회 2,995
🐛 버그신고