s

부드러운 움직임 2

· 17년 전 · 1764

//관성력
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,274
17년 전 조회 1,388
17년 전 조회 1,164
17년 전 조회 1,210
17년 전 조회 1,249
17년 전 조회 1,319
17년 전 조회 1,340
17년 전 조회 1,362
17년 전 조회 1,320
17년 전 조회 1,641
17년 전 조회 2,969
17년 전 조회 3,366
17년 전 조회 1,456
17년 전 조회 1,552
17년 전 조회 1,364
17년 전 조회 2,118
17년 전 조회 3,037
17년 전 조회 1,383
17년 전 조회 1,377
17년 전 조회 1,375
17년 전 조회 1,235
17년 전 조회 1,426
17년 전 조회 1,488
17년 전 조회 1,298
17년 전 조회 2,582
17년 전 조회 1,328
17년 전 조회 1,592
17년 전 조회 1,469
17년 전 조회 1,777
17년 전 조회 1,794
17년 전 조회 1,814
17년 전 조회 1,867
17년 전 조회 1,529
17년 전 조회 1,611
17년 전 조회 1,523
17년 전 조회 1,863
17년 전 조회 1,770
17년 전 조회 1,565
17년 전 조회 1,748
17년 전 조회 1,412
17년 전 조회 1,644
17년 전 조회 1,960
17년 전 조회 2,795
17년 전 조회 2,002
17년 전 조회 1,407
17년 전 조회 1,965
17년 전 조회 2,420
17년 전 조회 1,581
17년 전 조회 2,334
17년 전 조회 1,765
17년 전 조회 1,470
17년 전 조회 1,326
17년 전 조회 2,001
17년 전 조회 2,895
17년 전 조회 2,512
17년 전 조회 1,533
17년 전 조회 2,882
17년 전 조회 2,419
17년 전 조회 2,766
17년 전 조회 2,781
17년 전 조회 2,557
17년 전 조회 2,375
17년 전 조회 1,729
17년 전 조회 2,467
17년 전 조회 3,961
17년 전 조회 1,836
17년 전 조회 3,922
17년 전 조회 1,852
17년 전 조회 1,744
17년 전 조회 2,081
17년 전 조회 2,479
17년 전 조회 1,437
17년 전 조회 1,783
17년 전 조회 2,346
17년 전 조회 1,818
17년 전 조회 1,765
17년 전 조회 1,549
17년 전 조회 1,399
17년 전 조회 1,353
17년 전 조회 1,162
17년 전 조회 1,159
17년 전 조회 1,185
17년 전 조회 1,191
17년 전 조회 1,612
17년 전 조회 1,688
17년 전 조회 1,827
17년 전 조회 2,961
17년 전 조회 2,105
17년 전 조회 1,775
17년 전 조회 2,111
17년 전 조회 1,825
17년 전 조회 3,360
17년 전 조회 1,539
17년 전 조회 1,668
17년 전 조회 1,381
17년 전 조회 2,194
17년 전 조회 3,141
17년 전 조회 2,280
17년 전 조회 1,739
17년 전 조회 2,993
🐛 버그신고