s

부드러운 움직임 2

· 17년 전 · 1773

//관성력
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,288
17년 전 조회 1,399
17년 전 조회 1,174
17년 전 조회 1,219
17년 전 조회 1,260
17년 전 조회 1,328
17년 전 조회 1,349
17년 전 조회 1,374
17년 전 조회 1,333
17년 전 조회 1,652
17년 전 조회 2,977
17년 전 조회 3,378
17년 전 조회 1,470
17년 전 조회 1,568
17년 전 조회 1,378
17년 전 조회 2,131
17년 전 조회 3,052
17년 전 조회 1,396
17년 전 조회 1,385
17년 전 조회 1,385
17년 전 조회 1,251
17년 전 조회 1,441
17년 전 조회 1,500
17년 전 조회 1,312
17년 전 조회 2,589
17년 전 조회 1,340
17년 전 조회 1,602
17년 전 조회 1,482
17년 전 조회 1,789
17년 전 조회 1,806
17년 전 조회 1,822
17년 전 조회 1,879
17년 전 조회 1,538
17년 전 조회 1,617
17년 전 조회 1,533
17년 전 조회 1,871
17년 전 조회 1,779
17년 전 조회 1,579
17년 전 조회 1,757
17년 전 조회 1,421
17년 전 조회 1,655
17년 전 조회 1,972
17년 전 조회 2,806
17년 전 조회 2,015
17년 전 조회 1,417
17년 전 조회 1,974
17년 전 조회 2,432
17년 전 조회 1,590
17년 전 조회 2,341
17년 전 조회 1,774
17년 전 조회 1,483
17년 전 조회 1,336
17년 전 조회 2,007
17년 전 조회 2,909
17년 전 조회 2,527
17년 전 조회 1,541
17년 전 조회 2,896
17년 전 조회 2,428
17년 전 조회 2,780
17년 전 조회 2,792
17년 전 조회 2,564
17년 전 조회 2,386
17년 전 조회 1,736
17년 전 조회 2,475
17년 전 조회 3,970
17년 전 조회 1,845
17년 전 조회 3,933
17년 전 조회 1,859
17년 전 조회 1,754
17년 전 조회 2,092
17년 전 조회 2,492
17년 전 조회 1,444
17년 전 조회 1,793
17년 전 조회 2,358
17년 전 조회 1,835
17년 전 조회 1,771
17년 전 조회 1,562
17년 전 조회 1,411
17년 전 조회 1,363
17년 전 조회 1,170
17년 전 조회 1,166
17년 전 조회 1,192
17년 전 조회 1,199
17년 전 조회 1,617
17년 전 조회 1,696
17년 전 조회 1,835
17년 전 조회 2,973
17년 전 조회 2,112
17년 전 조회 1,784
17년 전 조회 2,117
17년 전 조회 1,836
17년 전 조회 3,367
17년 전 조회 1,551
17년 전 조회 1,673
17년 전 조회 1,387
17년 전 조회 2,199
17년 전 조회 3,146
17년 전 조회 2,287
17년 전 조회 1,745
17년 전 조회 2,998