s

부드러운 움직임 2

· 17년 전 · 1758

//관성력
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,267
17년 전 조회 1,383
17년 전 조회 1,159
17년 전 조회 1,204
17년 전 조회 1,243
17년 전 조회 1,315
17년 전 조회 1,336
17년 전 조회 1,354
17년 전 조회 1,312
17년 전 조회 1,633
17년 전 조회 2,959
17년 전 조회 3,359
17년 전 조회 1,450
17년 전 조회 1,548
17년 전 조회 1,357
17년 전 조회 2,115
17년 전 조회 3,030
17년 전 조회 1,377
17년 전 조회 1,368
17년 전 조회 1,370
17년 전 조회 1,230
17년 전 조회 1,423
17년 전 조회 1,483
17년 전 조회 1,289
17년 전 조회 2,577
17년 전 조회 1,321
17년 전 조회 1,585
17년 전 조회 1,466
17년 전 조회 1,774
17년 전 조회 1,788
17년 전 조회 1,808
17년 전 조회 1,863
17년 전 조회 1,522
17년 전 조회 1,607
17년 전 조회 1,519
17년 전 조회 1,858
17년 전 조회 1,764
17년 전 조회 1,561
17년 전 조회 1,741
17년 전 조회 1,406
17년 전 조회 1,639
17년 전 조회 1,958
17년 전 조회 2,788
17년 전 조회 1,997
17년 전 조회 1,404
17년 전 조회 1,958
17년 전 조회 2,412
17년 전 조회 1,570
17년 전 조회 2,326
17년 전 조회 1,759
17년 전 조회 1,464
17년 전 조회 1,320
17년 전 조회 1,997
17년 전 조회 2,889
17년 전 조회 2,507
17년 전 조회 1,533
17년 전 조회 2,880
17년 전 조회 2,414
17년 전 조회 2,762
17년 전 조회 2,776
17년 전 조회 2,552
17년 전 조회 2,372
17년 전 조회 1,723
17년 전 조회 2,461
17년 전 조회 3,956
17년 전 조회 1,830
17년 전 조회 3,916
17년 전 조회 1,847
17년 전 조회 1,736
17년 전 조회 2,076
17년 전 조회 2,478
17년 전 조회 1,433
17년 전 조회 1,779
17년 전 조회 2,341
17년 전 조회 1,812
17년 전 조회 1,760
17년 전 조회 1,546
17년 전 조회 1,394
17년 전 조회 1,349
17년 전 조회 1,159
17년 전 조회 1,153
17년 전 조회 1,179
17년 전 조회 1,185
17년 전 조회 1,606
17년 전 조회 1,682
17년 전 조회 1,821
17년 전 조회 2,957
17년 전 조회 2,099
17년 전 조회 1,771
17년 전 조회 2,108
17년 전 조회 1,821
17년 전 조회 3,358
17년 전 조회 1,536
17년 전 조회 1,661
17년 전 조회 1,376
17년 전 조회 2,191
17년 전 조회 3,135
17년 전 조회 2,278
17년 전 조회 1,734
17년 전 조회 2,988
🐛 버그신고