![]() |
How would I edit this so that it can go everywhere and not hit invisible objects as if it were in the tygcpolo area which I dun like :P (playerenters) {
timeout=0.05; } if(timeout){ ballx=x; bally=y; for(this.i=0;this.i<playerscount;this.i++){ if(abs(x-players[this.i].x)<=2&&abs(y-players[this.i].y)<=2&&!strequals(#n(this.i),)&&abs(this.xspeed)< =0.25&&abs(this.yspeed)<=0.75){ this.xspeed=x-players[this.i].x; this.yspeed=y-players[this.i].y; } } if(abs(this.xspeed)>0.01){ this.xspeed*=0.9; if((x+this.xspeed)<44.5&&(x+this.xspeed)>20.5) x+=this.xspeed; else this.xspeed*=-1; this.xspeed+=random(-0.001,0.001); }//else this.xspeed=0; if(abs(this.yspeed)>0.01){ this.yspeed*=0.9; if((y+this.yspeed)<49&&(y+this.yspeed)>12) y+=this.yspeed; else this.yspeed*=-1; this.yspeed+=random(-0.001,0.001); }//else this.yspeed=0; if(x>30.5&&x<32.5){ if(y<13){ x=30.5; y=29.5; this.xspeed=0; this.yspeed=0; npcs[1].timeout=0.05; redscore++; }else if(y>48){ x=30.5; y=29.5; this.xspeed=0; this.yspeed=0; npcs[2].timeout=0.05; bluescore++; } } if(abs(this.xspeed)>0.5||abs(this.yspeed)>0.5){ showimg 0,charshadow.gif,x+0.5,y+1.5; hide; }else{ hideimg 0; show; } showimg 1,ball.png,x+0.6,(y+1)-((abs(this.xspeed)+abs(this.yspeed))*0.5); timeout=0.05; } |
Mou, where'd you get that?
|
pants
PANTS!
|
| All times are GMT +2. The time now is 11:17 PM. |
Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.