View Single Post
  #7  
Old 10-14-2011, 02:39 AM
Tolnaftate2004 Tolnaftate2004 is offline
penguin.
Join Date: Jul 2004
Location: Berkeley, CA
Posts: 534
Tolnaftate2004 is a jewel in the roughTolnaftate2004 is a jewel in the rough
Send a message via AIM to Tolnaftate2004
Quote:
Originally Posted by Stefan View Post
Well in that case it might a problem that your TStaticVar has no name... Would be good to check that. We are using tons of waitfors in other objects (database queries) and never had problems with that.
The TStaticVar has a name in the actual code.

e: This mimics exactly the problem I've been having:
PHP Code:
function onCreated() {
  
this.call = function () {
    echo(
"before" SPC getcallstack().size()); // before 3
    
waitfor(this.name,"ignoreme",1); // equivalently, sleep(1);
    
echo("after" SPC getcallstack().size()); // after 1
    
return "test";
  };
  
temp.= new TStaticVar("A");
  
temp.a.call = function (caller) {
    
temp.resp caller.call();
    echo(
temp.resp);
    return 
temp.resp;
  };
  echo(
temp.a.call(this));

However, I think this illustrates an even deeper problem:
PHP Code:
//#CLIENTSIDE

function onCreated() {
  
temp.= new TStaticVar("B");
  
temp.b.call = function () {
    echo(
"before" SPC getcallstack().size()); // before 2
    
sleep(1);
    echo(
"after" SPC getcallstack().size()); // never gets executed...
    
return "test";
  };
  echo(
temp.b.call());

__________________
◕‿‿◕ · pfa · check yer syntax! · src

Killa Be: when i got that locker in 6th grade the only thing in it was a picture of a midget useing a firehose :/

Last edited by Tolnaftate2004; 10-14-2011 at 05:40 AM..
Reply With Quote