Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Server (https://forums.graalonline.com/forums/forumdisplay.php?f=14)
-   -   Few questions (https://forums.graalonline.com/forums/showthread.php?t=33584)

Max-imus 07-16-2002 04:20 AM

Few questions
 
I don't have that much knowledge about scripting with the npc server, so hopefully you guys can help me out and explain these things to me.

Why doesn't this script work for me online?

if(compusdied){
//#CLIENTSIDE
hide;
}

and also

//#CLIENTSIDE
if(playertouchsme)
{toinventory keyname;hidelocal;}

if you could help me with getting these to work and explaining them, I'd greatly appreciate it.

Poogle 07-16-2002 05:53 AM

i didnt think Delteria had a npc server.

Python523 07-16-2002 06:36 AM

I know toweapons doesnt work clientside but I'm not sure about toinventory, I have never found a use for it and I try to not use it, if something doesnt work for you, try it both clientside and serverside and see what happens

Max-imus 07-16-2002 08:53 AM

Quote:

Originally posted by Python523
I know toweapons doesnt work clientside but I'm not sure about toinventory, I have never found a use for it and I try to not use it, if something doesnt work for you, try it both clientside and serverside and see what happens
Yeah I've been doing that :-/ . Well thanks for the suggestion, I will keep playing around with it.

doubleZ 07-23-2002 06:16 AM

toinventory ish old =P. Liek, no one uses it no more. I just use a weapon item, and flags as a substitute for it, liek for quests and stuff =)

Spark910 08-25-2002 01:18 AM

Re: Few questions
 
Quote:

Originally posted by Max-imus
.........

//#CLIENTSIDE
if(playertouchsme)
{toinventory keyname;hidelocal;}

..........

Im an Amature, Im sure someone can confirm if Im right or wrong. I think this is serverside script so.........

This at top

if(playertouchsme)
{toinventory keyname;hidelocal;}

then:

//#CLIENTSIDE

then the other bit Which i forgot!

*It work?*

TIP:You dont need to keep putting ''//#CLIENTSIDE''

The script is server side with NPC servers until you tell it other wise (by using ''//#CLIENTSIDE'') and once you put ''//#CLIENTSIDE'' anything below it becomes Clientside, So you dont need to keep telling it that its Clientside:

[serverside script]
//#CLIENTSIDE
[Client side (ANYTHING) Below it]

-----------

If what I said didnt work..... try only putting ONE ''//#CLIENTSIDE'' and put it above the ''IF'' the first one.

I dont know if that made sence or will help, But have a go and see if it works. Tell me if it does work and if it doesn't

emortylone 08-27-2002 11:06 PM

I don't know if you CAN put //#CLIENTSIDE in the middle of a script... I see no point behind it =P! Some scripts can be both, but others are just one or the other. If need-be, triggeraction is there for a reason, he he.
---Shifter

Com013 08-28-2002 04:03 PM

I don't like toinventory, because it destroys the NPC and the image won't be saved when disconnecting.
You could try this, although I haven't tested it. (I don't have access to a script-server).

NPC Code:

// this part will be executed server-side:
if (created) {
setshape 1,32,32; // whatever...I just think you need it serverside
// for playertouchsme
}
if (playertouchsme) {
set gotwhatever;
toweapons whatever;
}
//#CLIENTSIDE
if (playertouchsme) {
hidelocal;
play extra.wav;
}



All times are GMT +2. The time now is 04:28 PM.

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