s

부드러운 움직임 2

· 17년 전 · 1756

//관성력
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,381
17년 전 조회 1,155
17년 전 조회 1,203
17년 전 조회 1,240
17년 전 조회 1,311
17년 전 조회 1,336
17년 전 조회 1,354
17년 전 조회 1,311
17년 전 조회 1,632
17년 전 조회 2,959
17년 전 조회 3,357
17년 전 조회 1,448
17년 전 조회 1,547
17년 전 조회 1,353
17년 전 조회 2,112
17년 전 조회 3,030
17년 전 조회 1,376
17년 전 조회 1,365
17년 전 조회 1,368
17년 전 조회 1,229
17년 전 조회 1,421
17년 전 조회 1,479
17년 전 조회 1,287
17년 전 조회 2,574
17년 전 조회 1,317
17년 전 조회 1,583
17년 전 조회 1,461
17년 전 조회 1,770
17년 전 조회 1,785
17년 전 조회 1,805
17년 전 조회 1,860
17년 전 조회 1,520
17년 전 조회 1,606
17년 전 조회 1,516
17년 전 조회 1,856
17년 전 조회 1,760
17년 전 조회 1,559
17년 전 조회 1,740
17년 전 조회 1,406
17년 전 조회 1,636
17년 전 조회 1,955
17년 전 조회 2,785
17년 전 조회 1,993
17년 전 조회 1,399
17년 전 조회 1,956
17년 전 조회 2,410
17년 전 조회 1,569
17년 전 조회 2,325
17년 전 조회 1,757
17년 전 조회 1,462
17년 전 조회 1,319
17년 전 조회 1,993
17년 전 조회 2,888
17년 전 조회 2,503
17년 전 조회 1,532
17년 전 조회 2,877
17년 전 조회 2,410
17년 전 조회 2,760
17년 전 조회 2,771
17년 전 조회 2,550
17년 전 조회 2,370
17년 전 조회 1,722
17년 전 조회 2,458
17년 전 조회 3,953
17년 전 조회 1,830
17년 전 조회 3,915
17년 전 조회 1,846
17년 전 조회 1,735
17년 전 조회 2,072
17년 전 조회 2,476
17년 전 조회 1,431
17년 전 조회 1,777
17년 전 조회 2,338
17년 전 조회 1,810
17년 전 조회 1,759
17년 전 조회 1,545
17년 전 조회 1,394
17년 전 조회 1,346
17년 전 조회 1,158
17년 전 조회 1,152
17년 전 조회 1,178
17년 전 조회 1,183
17년 전 조회 1,603
17년 전 조회 1,681
17년 전 조회 1,818
17년 전 조회 2,954
17년 전 조회 2,095
17년 전 조회 1,770
17년 전 조회 2,106
17년 전 조회 1,819
17년 전 조회 3,354
17년 전 조회 1,533
17년 전 조회 1,659
17년 전 조회 1,374
17년 전 조회 2,188
17년 전 조회 3,132
17년 전 조회 2,275
17년 전 조회 1,731
17년 전 조회 2,985
🐛 버그신고