View Single Post
  #22  
Old 01-06-2011, 03:20 AM
scriptless scriptless is offline
Banned
Join Date: Dec 2008
Location: N-Pulse
Posts: 1,412
scriptless is a splendid one to beholdscriptless is a splendid one to beholdscriptless is a splendid one to beholdscriptless is a splendid one to behold
New problem, move() only works first time then stops.. any particular reason behind this?

PHP Code:
function onMouseDown() {
  
this.nx x;
  
this.ny y;
  for ( 
i=0i<3i++ ) {
    
this.angle random(this.angle-0.522,this.angle+0.522); // angle
    
this.distance random(2,5); // distance
    
this.nx2 this.nx sin(this.angle) * this.distance;
    
this.ny2 this.ny cos(this.angle) * this.distance;
    
move(xyx+5y+5);
    
DrawLine(2000+ithis.nxthis.nythis.nx2this.ny2);
    
this.nx += sin(this.angle) * this.distance;
    
this.ny += cos(this.angle) * this.distance;
  }

Reply With Quote