It is currently Sun Oct 12, 2008 4:06 pm

All times are UTC - 8 hours




Post new topic This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: attributes.cfg
PostPosted: Thu Jul 06, 2006 10:46 am 
Offline
Packet Maintainer

Joined: Thu Feb 02, 2006 8:33 am
Posts: 300
core-changes wrote:
06-16 Austin
Removed: Skills.cfg is no longer used.
Instead skill IDs will be read from uoskills.cfg and redirected to
attributes.cfg. The attributes.cfg file now has support for the old entries.
skills.cfg entries supported now in attributes.cfg are:
DELAY, UNHIDES and SCRIPT


First a question, not a suggestion.
Must DELAY, UNHIDES and SCRIPT be written in capital letters? :wink:

Code:
checkpoint: load_attributes_cfg


From LogLevel i get this checkpoint in the log file, so i assume that the attributes.cfg is permanently loaded to memory. This leads to my suggestion, if that is right.
I put in some other members, e.g.

Code:
Attribute DetectingHidden
{
   Alias      DetectHidden
                Test                          944949
   Delay      10
   Script      :detecthidden:detect_hidden
}


Is this "Test" also loaded on startup or only the "known" things like Alias ...?
If the "Test" is also loaded we could save some performance perhaps by a constant leading to this config in memory.

Something like:
const ATTRIBUTE_CFG := value; in uo.em

In combat related code you don't need to load a cfg at each hit with
ReadConfigFile();. If its already in memory for pol you could do something like that:

Code:
FindConfigElem(ATTRIBUTE_CFG, whatever);


I don't know if this works or if i make a mistake in thinking :wink:
But if that works one could think about more constants like that,
e.g.
const NPCDESC_CFG := value; in uo.em

It is called a lot of times at least in our scripting and every script that wants something has to read it first again.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 06, 2006 11:06 am 
Offline
POL Developer
User avatar

Joined: Wed Jan 25, 2006 2:30 am
Posts: 422
Location: San Diego, California
No, I just wrote them in all caps so they stood out.

_________________
-Austin


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 8 hours


Who is online

Users browsing this forum: No registered users and 0 guests


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 post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Style based on FI Subice by phpBBservice.nl