# Help With Snow Tut. AS

**URL:** <https://forum.kirupa.com/t/help-with-snow-tut-as/94167>\
**Category:** Uncategorized\
**Created:** [November 9, 2003, 5:53pm UTC](https://forum.kirupa.com/t/help-with-snow-tut-as/94167 "2003-11-09T17:53:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![macmar](https://avatars.discourse-cdn.com/v4/letter/m/7c8e57/32.png) [@macmar](https://forum.kirupa.com/u/macmar)\
**Post date:** [November 9, 2003, 5:53pm UTC](https://forum.kirupa.com/t/help-with-snow-tut-as/94167/1 "2003-11-09T17:53:17Z")

</div>

Could someone PLEASE help me script the snow to my dimensions:  
Stage 600 wide x 400 High  
I only want the snow in an area 432 Wide x 296 High at the X=80 y=52 position  
I’ve tried scripting it and totally messed it up…again & again & again. I’ll never learn this stuff :\<(  
Here’s the original script:  
onClipEvent (load) {  
onClipEvent (load) {  
//specifies the size of the movie stage  
movieWidth = 300;  
movieHeight = 200;

```
//variables that will modify the falling snow
i = 1+Math.random()*2;
k = -Math.PI+Math.random()*Math.PI;

//giving each snowflake unique characteristics
this._xscale = this._yscale=50+Math.random()*100;
this._alpha = 75+Math.random()*100;
this._x = -10+Math.random()*movieWidth;
this._y = -10+Math.random()*movieHeight;

```

}  
onClipEvent (enterFrame) {  
//putting it all together  
rad += (k/180)\*Math.PI;  
this.\_x -= Math.cos(rad);  
this.\_y += i;  
if (this.\_y\>=movieHeight) {  
this.\_y = -5;  
}  
if ((this.\_x\>=movieWidth) || (this.\_x\<=0)) {  
this.\_x = -10+Math.random()\*movieWidth;  
this.\_y = -5;  
}  
}
