Graal Forums  

Go Back   Graal Forums > Private forums > Graal4 Forums > Graal V4 Main Forum
FAQ Members List Calendar Today's Posts

 
 
Thread Tools Search this Thread Rate Thread Display Modes
  #1  
Old 11-26-2006, 06:24 AM
Twinny Twinny is offline
My empire of dirt
Twinny's Avatar
Join Date: Mar 2006
Location: Australia
Posts: 2,422
Twinny is just really niceTwinny is just really nice
Send a message via AIM to Twinny
onPlayerLogout()

Would it be possible to allow scripts to modify the object created by this function? I would like to erase a load of clientr. flags when the player logs off.
  #2  
Old 11-26-2006, 06:36 AM
Gambet Gambet is offline
Registered User
Join Date: Oct 2003
Posts: 2,712
Gambet is on a distinguished road
You can create a similar effect by doing so when the moment they log on. Though, I agree, that would be nice.
  #3  
Old 11-26-2006, 08:00 AM
Ducati_Link Ducati_Link is offline
Banned
Ducati_Link's Avatar
Join Date: Oct 2001
Location: Perth, Australia
Posts: 415
Ducati_Link is on a distinguished road
Send a message via MSN to Ducati_Link
Great idea! I would like that.
  #4  
Old 11-26-2006, 02:18 PM
contiga contiga is offline
Graal2001 Administration
contiga's Avatar
Join Date: Jul 2004
Location: Netherlands
Posts: 419
contiga is an unknown quantity at this point
Send a message via ICQ to contiga Send a message via AIM to contiga Send a message via MSN to contiga Send a message via Yahoo to contiga
That'd be awesome.
__________________
AIM: Contiga122
MSN: [email protected]
Status:
Quote:
Originally Posted by unixmad View Post
I am also awake 3AM to help correct problems.
Quote:
Originally Posted by Bomy Island RC people
Daniel: HoudiniMan is a bad guy =p
*Bell: rofl. I first read that as houdini is a bad man. like the little kid that wants his mommy to keep her away from that boogie man
Daniel: xD
*Rufus: I wouldn't want my kids around him.
  #5  
Old 11-26-2006, 02:29 PM
xAndrewx xAndrewx is offline
Registered User
xAndrewx's Avatar
Join Date: Sep 2004
Posts: 5,260
xAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud ofxAndrewx has much to be proud of
I'm guessing you'd use something like that clientrc command to view offline player's details.
__________________
  #6  
Old 11-26-2006, 03:41 PM
Skyld Skyld is offline
Script-fu
Skyld's Avatar
Join Date: Jan 2002
Location: United Kingdom
Posts: 3,914
Skyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud ofSkyld has much to be proud of
Send a message via AIM to Skyld
Quote:
Originally Posted by xAndrewx View Post
I'm guessing you'd use something like that clientrc command to view offline player's details.
Client-RC only works clientside and if you have RC rights.
__________________
Skyld
  #7  
Old 11-26-2006, 03:43 PM
Twinny Twinny is offline
My empire of dirt
Twinny's Avatar
Join Date: Mar 2006
Location: Australia
Posts: 2,422
Twinny is just really niceTwinny is just really nice
Send a message via AIM to Twinny
Not sure what they are.. all I want to have is the ability for any to script to write to an offline player.

For example,
PHP Code:
function onPlayerLogout(pl)
{
  
pl.clientr.logout getTime();
  
pl._mudClear(); //Removes all clientr. beginning with 'mud'

  #8  
Old 11-27-2006, 10:51 PM
Gambet Gambet is offline
Registered User
Join Date: Oct 2003
Posts: 2,712
Gambet is on a distinguished road
Quote:
Originally Posted by Twinny View Post
Not sure what they are.. all I want to have is the ability for any to script to write to an offline player.

For example,
PHP Code:
function onPlayerLogout(pl)
{
  
pl.clientr.logout getTime();
  
pl._mudClear(); //Removes all clientr. beginning with 'mud'


It would be the same thing to clear them the moment they logged back on. Clearing their strings while they're offline does you no good, since no changes will be effected until the next time they log on anyways.

I don't really see why you would need to write to offline players, when you can do the same thing the moment they log on.

Have an NPC check to see if the player is online, and if they log off, then have it save to a DB or something and then have the DB be read when a player logs on and if their account is in the DB, then the strings would clear.


There are several ways you can do such a thing, or rather, create the same effect.
  #9  
Old 11-27-2006, 11:17 PM
Twinny Twinny is offline
My empire of dirt
Twinny's Avatar
Join Date: Mar 2006
Location: Australia
Posts: 2,422
Twinny is just really niceTwinny is just really nice
Send a message via AIM to Twinny
Apparently having alot of clientr. 's leads to a slower login.
  #10  
Old 11-28-2006, 12:16 AM
Gambet Gambet is offline
Registered User
Join Date: Oct 2003
Posts: 2,712
Gambet is on a distinguished road
Quote:
Originally Posted by Twinny View Post
Apparently having alot of clientr. 's leads to a slower login.


That shouldn't happen. I believe Graal truncates a player's flags after it exceeds a certain amount.
  #11  
Old 11-28-2006, 03:49 AM
Twinny Twinny is offline
My empire of dirt
Twinny's Avatar
Join Date: Mar 2006
Location: Australia
Posts: 2,422
Twinny is just really niceTwinny is just really nice
Send a message via AIM to Twinny
Well...it's still an idea
  #12  
Old 12-01-2006, 08:47 AM
Andy0687 Andy0687 is offline
Enigma
Join Date: Feb 2002
Posts: 1,072
Andy0687 is on a distinguished road
Quote:
Originally Posted by Gambet View Post
That shouldn't happen. I believe Graal truncates a player's flags after it exceeds a certain amount.
I think he is talking about how many flags are in the players attribs, not how long the string is.

So far to my knowledge there is no end to the flags you can store on a player, in 4+ years at babylon i never found one.
  #13  
Old 12-01-2006, 09:34 AM
KuJi KuJi is offline
Banned
Join Date: Apr 2004
Location: Staten Island, New York
Posts: 2,202
KuJi will become famous soon enough
Send a message via ICQ to KuJi Send a message via AIM to KuJi Send a message via MSN to KuJi Send a message via Yahoo to KuJi
Hehe, I had a problem thinking the length was too long, I later found out I had a function that caused lag on clientside that was no longer used.. lol =(
  #14  
Old 12-07-2006, 06:09 AM
jake13jake jake13jake is offline
Former Classic Staff
jake13jake's Avatar
Join Date: Dec 2002
Location: Northwest Vermont
Posts: 1,452
jake13jake will become famous soon enough
Quote:
Originally Posted by Twinny View Post
Would it be possible to allow scripts to modify the object created by this function? I would like to erase a load of clientr. flags when the player logs off.
I imagine this would actually save a lot of load-up time.

When the player logs in, they need to download all of their weapons, client.flags, clientr.flags, saved attributes, and all of the surrounding players/NPCs.

Would it be better to locally store client/r.flags and other data and let there be a single packet that the server would have to send in order for those to be used? Wouldn't know if it does that.

Even better, the server could specify to the client which flags it can't pre-load from local storage before using them. I wonder if the login event in the control-NPC is executed before the player loads anything else, otherwise it would be kindof strange to delete client/r.flags when that happens.
  #15  
Old 12-09-2006, 02:31 AM
Admins Admins is offline
Graal Administration
Join Date: Jan 2000
Location: Admins
Posts: 11,693
Admins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud of
Normally you can write the game so that it doesn't use any client/clientr flags that are not necessary. Most flags don't require a lot of network bandwidth though since e.g. items use similar names and can be easily compressed when sent to the client.
The reason why you currently cannot modify the player data (except on kingdoms) is that the gserver is managing the player data and when the npcserver is handling the logout the gserver has already saved and deleted the player object. This will be changed sometime in the future though, there will be special npcservers managing the player login and rights, and the playerworld npcserver will manage the game data itself.
 


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 09:13 PM.


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