Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting
FAQ Members List Calendar Today's Posts

Closed Thread
 
Thread Tools Search this Thread Display Modes
  #1  
Old 03-01-2002, 04:32 AM
Andor_RC14 Andor_RC14 is offline
Registered User
Join Date: Jan 2002
Location: U.S.A - Ohio
Posts: 101
Andor_RC14 is on a distinguished road
Send a message via ICQ to Andor_RC14 Send a message via AIM to Andor_RC14 Send a message via Yahoo to Andor_RC14
Angry Drowning script (i need help)

were it says onwater is wrong what do i put thier to work it i tried
if (playerswimming) --nothing seems to work

// Made by Mystical Dragon
//#CLIENTSIDE
if (onwater( x, y )){
showimg 1000,@@c@Water Count 0/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,0,0,3,0;}
if (onwater( x, y )){
showimg 1000,@@c@Water Count 1.5/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 2/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 4/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 6/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 8/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 10/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 12/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 13/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 13.5/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 14/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 15/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,2,0,0,0;
sleep 2;
playerhearts=>0}

P.S

Script thiefs are lame
__________________


Statistics show that 60% of all statistics are made-up
Manager of Norin.
EX Co-Manager of Bravo Online.
  #2  
Old 03-01-2002, 04:38 AM
TDK_RC6 TDK_RC6 is offline
Registered User
TDK_RC6's Avatar
Join Date: Jan 2002
Location: Earth
Posts: 0
TDK_RC6 is on a distinguished road
well, i noticed that in the onwater flags, there were spaces, i dont know if that is what is messing it up or not though
__________________
Staff on Renegade


email: [email protected]
aim: papivicente
  #3  
Old 03-01-2002, 04:47 AM
Lomgren Lomgren is offline
Senior Member, Anti-Spam
Join Date: Mar 2001
Location: Missouri
Posts: 196
Lomgren will become famous soon enough
try playerx and playery, your just checking the x,y of the npc, unless it is in a weapon or something where its
position = playerspos...
__________________
Lomgren - devoted to classic, even though I may be gone for months on end
  #4  
Old 03-01-2002, 04:59 AM
nyghtGT nyghtGT is offline
Banned
nyghtGT's Avatar
Join Date: Jun 2001
Posts: 3,993
nyghtGT is on a distinguished road
Send a message via AIM to nyghtGT
Re: Drowning script (i need help)

Quote:
Originally posted by Andor_RC14
were it says onwater is wrong what do i put thier to work it i tried
if (playerswimming) --nothing seems to work

// Made by Mystical Dragon
//#CLIENTSIDE
if (onwater( x, y )){
showimg 1000,@@c@Water Count 0/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,0,0,3,0;}
if (onwater( x, y )){
showimg 1000,@@c@Water Count 1.5/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 2/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 4/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 6/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 8/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 10/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 12/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 13/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 13.5/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 14/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 15/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,2,0,0,0;
sleep 2;
playerhearts=>0}

P.S

Script thiefs are lame
i dont know who would want to steal that script, lol ....
try this:
NPC Code:

NPC Code:

if (onwater(vecx,vecy)) {
for (i=15;i>0;i--) {
sleep 2;
showimg 1000,@@c@Water Count i/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
if (i=15) {
changeimgcolors 1000,2,0,0,0;
}
if (i<=14&&i>=1) {
changeimgcolors 1000,1,1,0,1;
}
if (i=0) {
changeimgcolors 1000,0,0,3,0;
}
}
}





edit:
I added 'vecx,vecy' I am totally unsure about using that ...
  #5  
Old 03-01-2002, 05:05 AM
nyghtGT nyghtGT is offline
Banned
nyghtGT's Avatar
Join Date: Jun 2001
Posts: 3,993
nyghtGT is on a distinguished road
Send a message via AIM to nyghtGT
Quote:
Originally posted by TDK_RC6
well, i noticed that in the onwater flags, there were spaces, i dont know if that is what is messing it up or not though
was that a charity script ?
  #6  
Old 03-01-2002, 06:24 AM
Saga2001 Saga2001 is offline
Wishing he had 3 feet
Join Date: Aug 2001
Location: Basement
Posts: 1,565
Saga2001 is on a distinguished road
Send a message via ICQ to Saga2001 Send a message via AIM to Saga2001 Send a message via Yahoo to Saga2001
ummmmm use a for loop or while....please?
__________________

!Wan ( 11:27:55 AM):
can i c ur scripts please?
Zorg (RC): If I hear NPC Server call Ne0, Past Austin or Brent sexy one more time im disconnecting it
  #7  
Old 03-01-2002, 08:44 AM
Faheria_GP2 Faheria_GP2 is offline
Banned
Faheria_GP2's Avatar
Join Date: Oct 2001
Posts: 1,177
Faheria_GP2 is on a distinguished road
Quote:
(i need help)
you need more "help" than anyone here can give you

I am referring you to a psychiatrist right now
  #8  
Old 03-01-2002, 09:04 AM
nyghtGT nyghtGT is offline
Banned
nyghtGT's Avatar
Join Date: Jun 2001
Posts: 3,993
nyghtGT is on a distinguished road
Send a message via AIM to nyghtGT
Quote:
Originally posted by Faheria_GP2


you need more "help" than anyone here can give you

I am referring you to a psychiatrist right now
hey i sorta knew him, he is nice, just sucks at scripting ...
  #9  
Old 03-01-2002, 09:10 AM
Lomgren Lomgren is offline
Senior Member, Anti-Spam
Join Date: Mar 2001
Location: Missouri
Posts: 196
Lomgren will become famous soon enough
NyghtGT, just so you know, vecx and vecy are basically hardcoded arrays that are used for the x,y movement for directions,

x += vecx(dir);
y += vecy(dir);

you would use something like that for moving the npc according to it's direction.
__________________
Lomgren - devoted to classic, even though I may be gone for months on end
  #10  
Old 03-01-2002, 02:21 PM
nyghtGT nyghtGT is offline
Banned
nyghtGT's Avatar
Join Date: Jun 2001
Posts: 3,993
nyghtGT is on a distinguished road
Send a message via AIM to nyghtGT
Quote:
Originally posted by Lomgren
NyghtGT, just so you know, vecx and vecy are basically hardcoded arrays that are used for the x,y movement for directions,

x += vecx(dir);
y += vecy(dir);

you would use something like that for moving the npc according to it's direction.
uhh, ok ...
i said i wasn't sure and thanx for correcting me ...
  #11  
Old 03-01-2002, 08:19 PM
Andor_RC14 Andor_RC14 is offline
Registered User
Join Date: Jan 2002
Location: U.S.A - Ohio
Posts: 101
Andor_RC14 is on a distinguished road
Send a message via ICQ to Andor_RC14 Send a message via AIM to Andor_RC14 Send a message via Yahoo to Andor_RC14
Talking Nyght GT

You no me can you speack english please i dont no what vex is ROLF
what would thscript be if i added that
__________________


Statistics show that 60% of all statistics are made-up
Manager of Norin.
EX Co-Manager of Bravo Online.
  #12  
Old 03-01-2002, 08:26 PM
Andor_RC14 Andor_RC14 is offline
Registered User
Join Date: Jan 2002
Location: U.S.A - Ohio
Posts: 101
Andor_RC14 is on a distinguished road
Send a message via ICQ to Andor_RC14 Send a message via AIM to Andor_RC14 Send a message via Yahoo to Andor_RC14
Angry this still wont work wtf

//#CLIENTSIDE
if (!onwater(playerx+1.5+vecx(playerdir)*2,playery+2+ vecy(playerdir)*2)) {
showimg 1000,@@c@Water Count 0/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,0,0,3,0;}
if (onwater(playerx+1.5+vecx(playerdir)*2,playery+2+v ecy(playerdir)*2)) {
showimg 1000,@@c@Water Count 1.5/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 2/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 4/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 6/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 8/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 10/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 12/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 13/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 13.5/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 14/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,1,1,0,1;
sleep 1.5;
showimg 1000,@@c@Water Count 15/15,screenwidth-75,screenheight-25;
changeimgvis 1000,5;
changeimgcolors 1000,2,0,0,0;
sleep 2;
playerhearts=>0}
__________________


Statistics show that 60% of all statistics are made-up
Manager of Norin.
EX Co-Manager of Bravo Online.
  #13  
Old 03-01-2002, 08:45 PM
Loriel Loriel is offline
Somewhat rusty
Loriel's Avatar
Join Date: Mar 2001
Posts: 5,059
Loriel is a name known to allLoriel is a name known to allLoriel is a name known to allLoriel is a name known to all
You need to put the checking thing in a permanent timeout loop.

Try this, not sure.
NPC Code:

//#CLIENTSIDE
if (playerenters || timeout) {
if (onwater(playerx+1.5,playery+2)) this.wcount += 0.05;
else this.wcount = 0;
showimg 1000,@@c@Water Count #v(this.wcount)/15,screenwidth-75,screenheight-25;
if (this.wcount>15) playerhearts = 0;
timeout = 0.05;
}

  #14  
Old 03-01-2002, 08:49 PM
Andor_RC14 Andor_RC14 is offline
Registered User
Join Date: Jan 2002
Location: U.S.A - Ohio
Posts: 101
Andor_RC14 is on a distinguished road
Send a message via ICQ to Andor_RC14 Send a message via AIM to Andor_RC14 Send a message via Yahoo to Andor_RC14
Loriel

i tryed that it says
Error: No if-clause specified
__________________


Statistics show that 60% of all statistics are made-up
Manager of Norin.
EX Co-Manager of Bravo Online.
  #15  
Old 03-01-2002, 10:23 PM
Saga2001 Saga2001 is offline
Wishing he had 3 feet
Join Date: Aug 2001
Location: Basement
Posts: 1,565
Saga2001 is on a distinguished road
Send a message via ICQ to Saga2001 Send a message via AIM to Saga2001 Send a message via Yahoo to Saga2001
NPC Code:

//#CLIENTSIDE
if (playerenters || timeout) {
if (onwater(playerx+1.5,playery+2)) {this.wcount += 0.05;}
else {this.wcount = 0;}
showimg 1000,@@c@Water Count #v(this.wcount)/15,screenwidth-75,screenheight-25;
if (this.wcount>15) {playerhearts = 0;}
timeout = 0.05;
}



I ono...lol...what no if clause specified means is that you have an else somewhere, but no original if. To fix that make sure if you don't have curly brackets ({}) around an if phrase than make sure that there is only one command, if you have this:
NPC Code:

// this works:
if (playerenters) message hi;
else message;
//this doesn't, it will give you a no if clause specified error:
if (playerenters) message hi;
setplayerprop #c,hi;
else message;
setplayerprop #c,;



Understand?
__________________

!Wan ( 11:27:55 AM):
can i c ur scripts please?
Zorg (RC): If I hear NPC Server call Ne0, Past Austin or Brent sexy one more time im disconnecting it
Closed Thread


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 07:54 AM.


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