Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   Soccer script! (https://forums.graalonline.com/forums/showthread.php?t=11520)

mhermher 09-09-2001 10:49 PM

Soccer script!
 
Does the offline soccer ball work online? The one in "level1.graal" if not can someone post a script thaat works online?

Enigma_GP6 09-09-2001 11:04 PM

I dunno, try this, it usually works as far as I know, I made this 3 months ago, someone else copied it, and will probably try to take credit for it.:
// NPC made by Rebel95
if (playerenters){timereverywhere;timeout=.05;
drawunderplayer;canbepushed}
if(playertouchsme){
if(playerdir=1){this.x-=1.5;this.y+=(y-playery-1)}
if(playerdir=3){this.x+=1.5;this.y+=(y-playery-1)}
if(playerdir=2){this.y+=1.5;this.x+=(x-playerx-1)}
if(playerdir=0){this.y-=1.5;this.x+=(x-playerx-1)}
this.subx=abs((this.x)/10);
this.suby=abs((this.y)/10);
}
if(timeout){timeout=.05;
if(this.x<>0)}{x+=this.x;
if(this.x>0)this.x-=this.subx;
if(this.x<0)this.x+=this.subx;
if(abs(this.x)<.1)this.x=0;
}
if(this.y<>0){y+=this.y;
if(this.y>0)this.y-=this.suby;
if(this.y<0)this.y+=this.suby;
if(abs(this.y)<.1)this.y=0;
}
if(onwall(x+.5,y-.5)&&this.y<0)this.y=(-this.y);
if(onwall(x+.5,y+1.5)&&this.y>0)this.y=(-this.y);
if(onwall(x+1.5,y+.5)&&this.x>0)this.x=(-this.x);
if(onwall(x-.5,y+.5)&&this.x<0)this.x=(-this.x);


-Rebel95

mhermher 09-09-2001 11:10 PM

Thanx alot =) u think i can use a gani to it? i mean to make it look like kicking

Slaktmaster 09-09-2001 11:19 PM

I made a football script that I sent to Sage Chazou so he is improving it to allow kicking and such, quite like that ball in level1.graal.

mhermher 09-09-2001 11:33 PM

coolt


va det du som gjorde den?


All times are GMT +2. The time now is 07:44 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.