Template:Userbox Server: Difference between revisions

From Homecoming Wiki
Jump to navigation Jump to search
imported>Konoko (historical)
m (testing)
imported>Konoko (historical)
m (attempt to explain if/then statements)
Line 9: Line 9:
* first is the game, either '''Heroes''' or '''Villains'''
* first is the game, either '''Heroes''' or '''Villains'''
* second is the server.
* second is the server.
* the third parameter is optional. if specified, will replace the image with the one specified. If the first paramter does not match Heroes or Villians, a 'default' image will be displayed
* the third parameter is optional. if specified, will replace the image with the one specified.
: If the first paramter does not match Heroes or Villians, a 'default' image will be displayed, unless replaced by this third parameter.
:* '''<nowiki>{{#if: {{{3|}}} | {{{3}}}</nowiki>'''
:*: ''If third parameter exists, then display the third paratmeter''
:** '''<nowiki> | {{#ifeq: {{{1}}} | Heroes | [[Image:Flight CombatFlight.png]] </nowiki>'''
:**: ''if third parameter does not exist, attempt to replace with a default 'hero' icon, based on first parameter''
:*** '''<nowiki> | {{#ifeq: {{{1}}} | Villains | [[Image:Ninjitsu NinjaReflexes.png]]</nowiki>'''
:***: ''if not heroes, try villains''
:**** '''<nowiki> | [[Image:Power_Missing.png]]</nowiki>'''
:****: ''if all else fails, display the missing icon (replace with paragon wiki icon?!?)''
:***** '''<nowiki> }} }} }}</nowiki>'''
:*****: ''close all three if statements''
----
{|
{|
|-
|-

Revision as of 01:20, 10 March 2007

Power Missing.png This user plays City of {{{1}}} on the {{{2}}} server.


Usage

Three parameters

  • first is the game, either Heroes or Villains
  • second is the server.
  • the third parameter is optional. if specified, will replace the image with the one specified.
If the first paramter does not match Heroes or Villians, a 'default' image will be displayed, unless replaced by this third parameter.
  • {{#if: {{{3|}}} | {{{3}}}
    If third parameter exists, then display the third paratmeter
    • | {{#ifeq: {{{1}}} | Heroes | [[Image:Flight CombatFlight.png]]
      if third parameter does not exist, attempt to replace with a default 'hero' icon, based on first parameter
      • | {{#ifeq: {{{1}}} | Villains | [[Image:Ninjitsu NinjaReflexes.png]]
        if not heroes, try villains
        • | [[Image:Power_Missing.png]]
          if all else fails, display the missing icon (replace with paragon wiki icon?!?)
          • }} }} }}
            close all three if statements

{{Userbox Server|Heroes|Champion}}
Flight CombatFlight.png This user plays City of Heroes on the Champion server.
{{Userbox Server|Villains|Virtue}}
Ninjitsu NinjaReflexes.png This user plays City of Villains on the Virtue server.
{{Userbox Server|Villains|Freedom|[[Image:Skill power invent.png]]}}
Skill power invent.png This user plays City of Villains on the Freedom server.
{{Userbox Server|Moonmen|Pinnacle}}
Power Missing.png This user plays City of Moonmen on the Pinnacle server.
{{Userbox Server|Zeroes|Elysium|[[Image:ArcticMastery BlockOfIce.png]]}}
ArcticMastery BlockOfIce.png This user plays City of Zeroes on the Elysium server.