Roster Addon developer credits on the credits page.

Download, Present, and receive support for third party WoWRoster AddOns and modifications
WoWRoster AddOns and Mods are supported by the author only
Please understand that some AddOns and Mods may require advanced skills to employ

Roster Addon developer credits on the credits page.

Postby nightfighter » Mon Jul 24, 2006 12:14 am

I have been working on one of the addons and uploading it here, and I feel that the specs for the addons are slightly deficient in that they don't give a standard way for the author to get proper credits (Put on the credits page).

Here are the changes needed to get a box added to the credits page for the addon developers.

1. Modify lib/menu.php
Code: Select all
function makeAddonList()
{
   global $roster_conf, $wordings;

to
Code: Select all
function makeAddonList()
{
   global $roster_conf, $wordings, $creditspage;


2. Modify credits.php
Add this code at the bottom of the file:
Code: Select all
/**
 * Gets the list of currently installed roster addons
 *
 * @return string formatted list of addons
 */
function makeAddonCredits()
{
   global $roster_conf, $wordings, $creditspage;

   $output = '';

   if(isset($creditspage[$roster_conf['roster_lang']]['addons'])) {
      foreach( array_keys($creditspage[$roster_conf['roster_lang']]['addons']) as $addonName )
      {
         $AddOnArray = $creditspage[$roster_conf['roster_lang']]['addons'][$addonName];
         foreach( $AddOnArray as $addonDev )
         {
            $stripe_class = 'membersRow' . ( ( ++$strip_count % 2 ) + 1 );
            $stripe_class_right = 'membersRowRight' . ( ( $strip_count % 2 ) + 1 );
            $output .= "\t<tr>\n";
            $output .= "\t\t<td class=\"$stripe_class\">" . $addonName . "</td>\n";
            $output .= "\t\t<td class=\"$stripe_class\">" . $addonDev['name']."</td>\n";
            $output .= "\t\t<td class=\"$stripe_class_right\">" . nl2br($addonDev['info']) . "</td>\n";
            $output .= "\t</tr>\n";
            $lCount += 1;
         }
      }
   }

   if ($lCount < 1)
   {
      return '';
   }

   return $output;
}


Next change:
Code: Select all
echo "</table>\n".border('syellow','end');


// format table locations
echo "\n</td></tr></table>\n";

to
Code: Select all
echo "</table>\n".border('syellow','end');

$AddonCredits = makeAddonCredits();
if($AddonCredits != '') {
   // Print the Addon developer credits
   echo "<br />\n" . border('sblue','start','WoWRoster Addon Developers') . "<table cellspacing=\"0\">\n";
   echo $AddonCredits;
   echo "</table>\n".border('sblue','end');
}

// format table locations
echo "\n</td></tr></table>\n";


3. Go to your addon localization file and add something like this:
Code: Select all
$creditspage['enUS']['addons']['guildstats'] = array(
         array(   "name"=>   "Nightfighter",
            "info"=>   "Original Addon developer"),
         array(   "name"=>   "Aibon",
            "info"=>   "German Translator"),
);


change the addon name and the developers and their information and it will automatically get added into the credits when a user installs your addon.

Here is how it looks on my website: Credits Page

I believe that I got all of the places that I changed documented here, but if you have trouble, let me know and I will try to help correct the problems.
Last edited by nightfighter on Mon Jul 24, 2006 12:17 am, edited 1 time in total.
User avatar
nightfighter
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 169
Joined: Wed Jul 05, 2006 11:25 pm
Location: Boise, Idaho, USA

Roster Addon developer credits on the credits page.

Postby zanix » Mon Jul 24, 2006 1:27 am

Nice idea

When we made the addon framework for roster, it was ment to be as simple as possible, given the unstability of roster at the time

So amy things were not taken into acount for addons, like credits, an installer, and many other things
Good news though, PleegWat is working on redesigning the addon framework for roster 1.8, and we'll be able to include all this functionality

Anyway, good work. :thumright:
May have to add this to roster 1.7.1
Last edited by zanix on Mon Jul 24, 2006 1:30 am, edited 1 time in total.
Read the Forum Rules, the WiKi, and Search before posting!
WoWRoster v2.1 - SigGen v0.3.3.523 - WoWRosterDF
User avatar
zanix
Admin
Admin
WoWRoster.net Dev Team
WoWRoster.net Dev Team
UA/UU Developer
UA/UU Developer
 
Posts: 5546
Joined: Mon Jul 03, 2006 8:29 am
Location: Idaho Falls, Idaho
Realm: Doomhammer (PvE) - US

Roster Addon developer credits on the credits page.

Postby nightfighter » Mon Jul 24, 2006 4:10 am

Sounds great. I would love to see this included in 1.7.1. I am sure the other addon developers would use it as well. Especially if all they have to do is put a couple of lines in their localization files.

Please let us know if the format changes or something. There might be something someone else thinks of as regards this that would be a great help with it too.
User avatar
nightfighter
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 169
Joined: Wed Jul 05, 2006 11:25 pm
Location: Boise, Idaho, USA

Roster Addon developer credits on the credits page.

Postby PleegWat » Mon Jul 24, 2006 2:57 pm

I've already considered this functionality. Stuff like full mod name, version, author name, etc. I've been thinking of storing the info in localization, but since you were suggesting overhauling the structure of that the time I didn't come out with it.
I <3 /bin/bash
User avatar
PleegWat
WoWRoster.net Dev Team
WoWRoster.net Dev Team
 
Posts: 1636
Joined: Tue Jul 04, 2006 1:43 pm

Roster Addon developer credits on the credits page.

Postby nightfighter » Mon Jul 24, 2006 10:05 pm

Another thing that you might be able to add is in the roster diag page where it checks the version number of the current installed addon with the one uploaded to the website. Not sure how to do this, but at least it is food for thought.
User avatar
nightfighter
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 169
Joined: Wed Jul 05, 2006 11:25 pm
Location: Boise, Idaho, USA

Roster Addon developer credits on the credits page.

Postby PleegWat » Tue Jul 25, 2006 12:06 am

I'm not completely sure of how rosterdiag works. It's mathos' project. Addon versions will be centrally registered, and will be monitorable.
I <3 /bin/bash
User avatar
PleegWat
WoWRoster.net Dev Team
WoWRoster.net Dev Team
 
Posts: 1636
Joined: Tue Jul 04, 2006 1:43 pm

Roster Addon developer credits on the credits page.

Postby zanix » Sun Jul 30, 2006 1:32 pm

Alright, this is added for roster 1.7.1
Athough the format of the array in the addons localization.php file will be different
Code: Select all
$wordings['addoncredits']['AddonName'] = array(
    array(    
"name"=>    "Author Name",
        
"info"=>    "Extra Info"),
);
 
Read the Forum Rules, the WiKi, and Search before posting!
WoWRoster v2.1 - SigGen v0.3.3.523 - WoWRosterDF
User avatar
zanix
Admin
Admin
WoWRoster.net Dev Team
WoWRoster.net Dev Team
UA/UU Developer
UA/UU Developer
 
Posts: 5546
Joined: Mon Jul 03, 2006 8:29 am
Location: Idaho Falls, Idaho
Realm: Doomhammer (PvE) - US


Return to AddOns and Mods

Who is online

Users browsing this forum: No registered users and 0 guests

cron