View Single Post
  #1  
Old 03-30-2007, 11:19 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
Heres a sample of my coding, I'm extremely picky about the formatting.
PHP Code:
public function loadRefs(obj) {
  
temp.i;
  
temp.e;
  
temp.vars;
  
temp.count;
  
temp.ref;
  
  
vars obj.getVarNames();
  
count 0;
  for (
0vars.size(); ++) {
    if (
obj.(@ vars[i]).type() == 1) {
      if (
MudControl.isRefStr(obj.(@ vars[i]))) {
        
ref obj.(@ vars[i]);
        
obj.(@ vars[i]) = MudControl.parseRef(ref);
        
obj.(@ vars[i]).addRef(obj);
        
count ++;
      }
    }
    else if (
obj.(@ vars[i]).type() == 3) {
      for (
0obj.(@ vars[i]).size(); ++) {
        if (
obj.(@ vars[i])[e].type() == 1) {
          if (
MudControl.isRefStr(obj.(@ vars[i])[e])) {
            
ref obj.(@ vars[i])[e];
            
obj.(@ vars[i])[e] = MudControl.parseRef(ref);
            
obj.(@ vars[i])[e].addRef(obj);
            
count ++;
          }
        }
      }
    }
  }
  echo(
format("References Loaded (%s): %s %s"countobj.mudtypeobj.mudid));

__________________
Reply With Quote