s

부드러운 움직임 2

· 17년 전 · 2090

//관성력
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,569
17년 전 조회 1,659
17년 전 조회 1,457
17년 전 조회 1,496
17년 전 조회 1,531
17년 전 조회 1,616
17년 전 조회 1,615
17년 전 조회 1,664
17년 전 조회 1,592
17년 전 조회 1,941
17년 전 조회 3,256
17년 전 조회 3,660
17년 전 조회 1,755
17년 전 조회 1,847
17년 전 조회 1,640
17년 전 조회 2,407
17년 전 조회 3,340
17년 전 조회 1,673
17년 전 조회 1,652
17년 전 조회 1,688
17년 전 조회 1,542
17년 전 조회 1,728
17년 전 조회 1,787
17년 전 조회 1,605
17년 전 조회 2,869
17년 전 조회 1,624
17년 전 조회 1,883
17년 전 조회 1,770
17년 전 조회 2,092
17년 전 조회 2,094
17년 전 조회 2,102
17년 전 조회 2,170
17년 전 조회 1,850
17년 전 조회 1,897
17년 전 조회 1,816
17년 전 조회 2,155
17년 전 조회 2,086
17년 전 조회 1,866
17년 전 조회 2,064
17년 전 조회 1,712
17년 전 조회 1,947
17년 전 조회 2,273
17년 전 조회 3,089
17년 전 조회 2,314
17년 전 조회 1,701
17년 전 조회 2,283
17년 전 조회 2,719
17년 전 조회 1,863
17년 전 조회 2,625
17년 전 조회 2,091
17년 전 조회 1,791
17년 전 조회 1,617
17년 전 조회 2,291
17년 전 조회 3,229
17년 전 조회 2,817
17년 전 조회 1,833
17년 전 조회 3,226
17년 전 조회 2,737
17년 전 조회 3,085
17년 전 조회 3,083
17년 전 조회 2,874
17년 전 조회 2,690
17년 전 조회 2,050
17년 전 조회 2,779
17년 전 조회 4,303
17년 전 조회 2,141
18년 전 조회 4,244
18년 전 조회 2,150
18년 전 조회 2,044
18년 전 조회 2,407
18년 전 조회 2,808
18년 전 조회 1,762
18년 전 조회 2,113
18년 전 조회 2,668
18년 전 조회 2,158
18년 전 조회 2,096
18년 전 조회 1,891
18년 전 조회 1,716
18년 전 조회 1,695
18년 전 조회 1,483
18년 전 조회 1,502
18년 전 조회 1,503
18년 전 조회 1,508
18년 전 조회 1,914
18년 전 조회 2,029
18년 전 조회 2,151
18년 전 조회 3,298
18년 전 조회 2,448
18년 전 조회 2,094
18년 전 조회 2,449
18년 전 조회 2,174
18년 전 조회 3,704
18년 전 조회 1,857
18년 전 조회 1,989
18년 전 조회 1,694
18년 전 조회 2,543
18년 전 조회 3,465
18년 전 조회 2,589
18년 전 조회 2,062
18년 전 조회 3,321