Register to post in forums, or Log in to your existing account
 

Play RetroMUD
Post new topic  Reply to topic     Home » Forums » zMUD General Discussion
ariesroyaal
Newbie


Joined: 16 Oct 2004
Posts: 5

PostPosted: Sat Dec 24, 2005 5:47 pm   

#ADDKEY limitations
 
Is there a way to get addkey to work with a class correctly? I have noticed it doesn't work normally with classes. The syntax I am using is as follows:


Code:

#ADDKEY aclass/avar {this=that|here=there}


It creates the actual variable in the correct class if that variable doesn't exist, however it will leave the variable blank. If I use the EXACT same syntax and drop the class....

Code:

#ADDKEY avar {this=that|here=there}


It will create the variable just fine. However I need the variable in a class. Any ideas?
Reply with quote
shalimar
GURU


Joined: 04 Aug 2002
Posts: 4691
Location: Pensacola, FL, USA

PostPosted: Sat Dec 24, 2005 5:55 pm   
 
#VAR avar {} _nodef {classname}
#ADDKEY avar {this=that|here=there}

Addkey is made to update your database variable, seeing as it has no class option in and of it self it was never made to create the variable.
_________________
Discord: Shalimarwildcat
Reply with quote
ariesroyaal
Newbie


Joined: 16 Oct 2004
Posts: 5

PostPosted: Sat Dec 24, 2005 6:52 pm   
 
So what happens if I have another avar in a different class?
Reply with quote
TonDiening
GURU


Joined: 26 Jul 2001
Posts: 1958
Location: Canada

PostPosted: Sat Dec 24, 2005 7:27 pm   
 
Maybe try setting the #CLASS to the avar location then #CLASS 0É

Quote:

CLASS

Syntax: #CLA [classname] [state|options]

Sets the state of a class. The specified class name is enabled if the state expression is true (1) or disabled if it is false (0). If you just specify #CLASS with no parameters, a list of classes is displayed with the status of each class indicated.
The #CLASS command can also be used to set the "default class". The default class is used whenever a setting is defined without specifying a class name. Normally the default class is <None>. To set the default class, use #CLASS with a single argument, which is the name of the class you want to set as the default. To return to the <None> default, use a classname of "0" (zero).
Reply with quote
Display posts from previous:   
Post new topic   Reply to topic     Home » Forums » zMUD General Discussion All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

© 2009 Zugg Software. Hosted by Wolfpaw.net