Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   pmswaiting() (https://forums.graalonline.com/forums/showthread.php?t=69965)

xAndrewx 11-09-2006 03:36 PM

pmswaiting()
 
HTML Code:

player.chat = (pmswaiting()? "Yes, I need to reply to them!": "No PM's waiting!");
Doesn't seem to be working =[

Chompy 11-09-2006 04:18 PM

Have you tried to echo pmswaiting()?
like
HTML Code:

temp.foo = pmswaiting();
echo(temp.foo);

and see if it returns 0/false or 1/true?

also pmswaiting() is TServerPlayer

Admins 11-09-2006 05:19 PM

Like
PHP Code:

for (plallplayers) {
  if (
pl.pmswaiting())
    echo(
"there is a pm from " pl.account);



xAndrewx 11-09-2006 10:41 PM

Quote:

Originally Posted by Stefan (Post 1241170)
Like
PHP Code:

for (plallplayers) {
  if (
pl.pmswaiting())
    echo(
"there is a pm from " pl.account);



Doesn't seem to work :[

xAndrewx 11-12-2006 08:19 PM

Weapon/GUI-script Andrew/PlayerCheck added/updated by xAndrewx
GraalScript: Function pmswaiting not found at line 3 in script of Andrew/PlayerCheck

[On Era]

Skyld 11-12-2006 08:34 PM

Quote:

Originally Posted by xAndrewx (Post 1242468)
Weapon/GUI-script Andrew/PlayerCheck added/updated by xAndrewx
GraalScript: Function pmswaiting not found at line 3 in script of Andrew/PlayerCheck

[On Era]

I hope you are not using it serverside :(

xAndrewx 11-12-2006 08:35 PM

Quote:

Originally Posted by Skyld (Post 1242477)
I hope you are not using it serverside :(

Oh....hahahaha :s
I get it now =D

Skyld 11-12-2006 09:07 PM

Quote:

Originally Posted by xAndrewx (Post 1242480)
Oh....hahahaha :s
I get it now =D

Yeah, you use it clientside because the PM is queued until the player deals with it.

On the serverside, all PMs are immediately handled by the onPM() event.

xAndrewx 11-13-2006 09:04 AM

Quote:

Originally Posted by Skyld (Post 1242513)
Yeah, you use it clientside because the PM is queued until the player deals with it.

On the serverside, all PMs are immediately handled by the onPM() event.

Totally get it now, basically you need to check if a certain player has sent you a PM. Would be alot less laggy if there were a function that just returned who the people are that have sent you a PM though.
Thanks alot :D


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

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