View Single Post
  #22  
Old 06-22-2007, 07:01 PM
Inverness Inverness is offline
Incubator
Inverness's Avatar
Join Date: Aug 2004
Location: Houston, Texas
Posts: 3,613
Inverness is a jewel in the roughInverness is a jewel in the rough
Quote:
Originally Posted by killerogue View Post
TStaticVar's by nature are made global objects when you name them I believe.
Graal is just automatically making a global variable that points to the object. Its not different than making a global variable to point to level npcs or to players. On Aeon when the player logs in I have makevar("Player" @ player.account) = player;This was originally added so I could access any player using makevar() with an old script.

The only problem I'm seeing with my method is that onCreated() is not called until after the function that is creating the object.
PHP Code:
function onCreated() {
  
temp.= new TVector();
  
v.5;

In this, onCreated will be called in the new vector object after that function has finished.
PHP Code:
function onCreated() {
  
temp.= new TVector();
  
sleep(0.1);
  
v.5;

If you add in the sleep, onCreated is called in the object while the current function is sleeping, this is something I would like without the use of sleep.

Basically I'm requesting an event onJoinedClass or something that is called as soon as Graal joins the class script and before the next class is joined so I can execute functions that need to be done before continuing. If something like this already exists by all means point it out please
__________________
Reply With Quote