Page Index Toggle Pages: 1 Send TopicPrint
Sticky Topic Pre-Release Developer info > Y2.1 (Read 2236 times)
Spikecity
God Member
*****
Offline


Beer anyone ?

Posts: 2630
Location: New York
Joined: Apr 16th, 2002
Gender: Male
Pre-Release Developer info > Y2.1
Mar 1st, 2006 at 10:06pm
Print Post  
Pre release info on version > Y2.1

New fatal error structure implemented:

Quote:
&fatal_error("<log_flag>","<descriptive_tag>","<error_info>",<verbose_flag>);

<log_flag> = 0|1 -> Add to logfile or not
<descriptive_tag> = see Error.lng
<error_info> = additional text generated from the script
<verbose_flag> = 0|1 -> Adds the output from $! to the error message.

If the board is set in debug mode addition to the error message the following is added:

Script
Linenumber
Subroutine
  

Nothing to add here Smiley
Back to top
 
IP Logged
 
Spikecity
God Member
*****
Offline


Beer anyone ?

Posts: 2630
Location: New York
Joined: Apr 16th, 2002
Gender: Male
Re: Pre-Release Developer info > Y2.1
Reply #1 - Sep 22nd, 2006 at 10:13pm
Print Post  
IMPORTANT MOD CODE INFORMATION

We decided to make the thread control file (CTB) consistent in format to all other hash based files.

Actually if you are running a current 2.x version the new format change will be painless as the new code will convert the old ctb on the fly once a thread is opened.
To force a complete conversion all you need to do is a Rebuild Message Index.

The new format looks like :


Quote:
### ThreadID: 1128620481, LastModified: Fri, 22 Sep 2006 23:48:07 +0100 ###

'board',"chatter"
'replies',"13"
'views',"465"
'lastposter',"admin"
'lastpostdate',"1129916623"
'threadstatus',"0s"
'repliers',""


The good thing is that through better code reused the MessageTotals Subroutine became about 60 lines shorter  

This new format also gives mod writers a solid and comfortable place to add their thread related variables, by adding them to the hash @tag) in MessageTotals (); in Load.pl, thus avoiding separate new files per thread to emerge.
Reading and setting the vars should be ${$threadid...}{'tag'}, where $threadid could be any thread id variable in the code
  

Nothing to add here Smiley
Back to top
 
IP Logged
 
..:X.T.C:..
Forum Administrator
*****
Offline


I love YaBB Forum!

Posts: 656
Location: Spittal
Joined: Dec 22nd, 2002
Gender: Male
Re: Pre-Release Developer info > Y2.1
Reply #2 - Jan 21st, 2007 at 8:42am
Print Post  
Hi Ron

Quote:
<log_flag> = 0|1 -> Add to logfile or not
<descriptive_tag> = see Error.lng
<error_info> = additional text generated from the script
<verbose_flag> = 0|1 -> Adds the output from $! to the error message.

Where should be the Mod Error "descriptive_tag" are placed? In the Error.lng or in the Mod_Name.lng?

lg XTC
  

Back to top
WWW  
IP Logged
 
Spikecity
God Member
*****
Offline


Beer anyone ?

Posts: 2630
Location: New York
Joined: Apr 16th, 2002
Gender: Male
Re: Pre-Release Developer info > Y2.1
Reply #3 - Jan 21st, 2007 at 11:36am
Print Post  
..:X.T.C:.. wrote on Jan 21st, 2007 at 8:42am:
Hi Ron

Where should be the Mod Error "descriptive_tag" are placed? In the Error.lng or in the Mod_Name.lng?

lg XTC


As you can see in Error.lng most sections of language have been sort of marked.
I think both are OK, meaning if the mod language file is loaded the best place is there (so you do not alter original files) but there is no harm done if you add it to the Error.lng.
  

Nothing to add here Smiley
Back to top
 
IP Logged
 
MF-B
Senior Member
****
Offline



Posts: 410
Location: Moscow
Joined: Apr 11th, 2006
Gender: Male
Re: Pre-Release Developer info > Y2.1
Reply #4 - Jan 21st, 2007 at 11:51am
Print Post  
I love placed lang string in files where it used... Function for MessageIndex - placed string in MessageIndex.lng... Etc...

Or... I install more then 30 mod's, need load 30 mod lang files? It's a hell... Lips Sealed
  
Back to top
WWW  
IP Logged
 
Spikecity
God Member
*****
Offline


Beer anyone ?

Posts: 2630
Location: New York
Joined: Apr 16th, 2002
Gender: Male
Re: Pre-Release Developer info > Y2.1
Reply #5 - Jan 21st, 2007 at 4:10pm
Print Post  
MF-B wrote on Jan 21st, 2007 at 11:51am:
I love placed lang string in files where it used... Function for MessageIndex - placed string in MessageIndex.lng... Etc...

Or... I install more then 30 mod's, need load 30 mod lang files? It's a hell... Lips Sealed

Agreed, Error.lng is loaded anyway so error message go best in there Wink
  

Nothing to add here Smiley
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint