s

부드러운 움직임 2

· 17년 전 · 2078

//관성력
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,565
17년 전 조회 1,654
17년 전 조회 1,442
17년 전 조회 1,487
17년 전 조회 1,519
17년 전 조회 1,605
17년 전 조회 1,601
17년 전 조회 1,649
17년 전 조회 1,581
17년 전 조회 1,929
17년 전 조회 3,245
17년 전 조회 3,647
17년 전 조회 1,742
17년 전 조회 1,838
17년 전 조회 1,628
17년 전 조회 2,397
17년 전 조회 3,328
17년 전 조회 1,662
17년 전 조회 1,640
17년 전 조회 1,673
17년 전 조회 1,535
17년 전 조회 1,714
17년 전 조회 1,777
17년 전 조회 1,592
17년 전 조회 2,859
17년 전 조회 1,616
17년 전 조회 1,872
17년 전 조회 1,756
17년 전 조회 2,082
17년 전 조회 2,083
17년 전 조회 2,082
17년 전 조회 2,154
17년 전 조회 1,835
17년 전 조회 1,887
17년 전 조회 1,806
17년 전 조회 2,142
17년 전 조회 2,075
17년 전 조회 1,852
17년 전 조회 2,054
17년 전 조회 1,703
17년 전 조회 1,933
17년 전 조회 2,259
17년 전 조회 3,085
17년 전 조회 2,300
17년 전 조회 1,693
17년 전 조회 2,267
17년 전 조회 2,710
17년 전 조회 1,850
17년 전 조회 2,616
17년 전 조회 2,079
17년 전 조회 1,779
17년 전 조회 1,607
17년 전 조회 2,277
17년 전 조회 3,215
17년 전 조회 2,808
17년 전 조회 1,825
17년 전 조회 3,217
17년 전 조회 2,722
17년 전 조회 3,075
17년 전 조회 3,071
17년 전 조회 2,862
17년 전 조회 2,679
17년 전 조회 2,037
17년 전 조회 2,768
17년 전 조회 4,289
17년 전 조회 2,131
17년 전 조회 4,231
18년 전 조회 2,139
18년 전 조회 2,034
18년 전 조회 2,393
18년 전 조회 2,798
18년 전 조회 1,754
18년 전 조회 2,097
18년 전 조회 2,658
18년 전 조회 2,143
18년 전 조회 2,084
18년 전 조회 1,884
18년 전 조회 1,703
18년 전 조회 1,681
18년 전 조회 1,473
18년 전 조회 1,480
18년 전 조회 1,490
18년 전 조회 1,499
18년 전 조회 1,905
18년 전 조회 2,015
18년 전 조회 2,143
18년 전 조회 3,288
18년 전 조회 2,432
18년 전 조회 2,084
18년 전 조회 2,442
18년 전 조회 2,163
18년 전 조회 3,692
18년 전 조회 1,852
18년 전 조회 1,981
18년 전 조회 1,682
18년 전 조회 2,534
18년 전 조회 3,452
18년 전 조회 2,581
18년 전 조회 2,052
18년 전 조회 3,315