Template:Infobox Smasher: Difference between revisions

From SmashWiki, the Super Smash Bros. wiki
Jump to navigationJump to search
mNo edit summary
m (zomg teh code)
Line 30: Line 30:
! align="left" {{!}} {{if|{{{location|}}}|Location|}}
! align="left" {{!}} {{if|{{{location|}}}|Location|}}
{{!}} <div align="right">{{{location|}}}{{if|{{{country|}}}|&nbsp;[[Image:{{{country|Unknown}}}flag.gif|18px]]|}}</div>
{{!}} <div align="right">{{{location|}}}{{if|{{{country|}}}|&nbsp;[[Image:{{{country|Unknown}}}flag.gif|18px]]|}}</div>
|}{{if|{{NAMESPACE}}||[[Category:Smashers]]}}</includeonly><noinclude>This is a variation on the original [[Template:Smasher]] with additional features and some stylistic changes. It is consistently under construction, as all wiki-related things are, but feel free to make use of it in its current form if "alpha" code doesn't scare you too much.  
|}{{if|{{NAMESPACE}}||[[Category:Smashers|{{UCFIRST:{{LC:{{{category|{{PAGENAME}}}}}}}}}]]}}</includeonly><noinclude>This is a variation on the original [[Template:Smasher]] with additional features and some stylistic changes. It is consistently under construction, as all wiki-related things are, but feel free to make use of it in its current form if "alpha" code doesn't scare you too much.  


==Code==
==Code==

Revision as of 12:23, April 26, 2007

This is a variation on the original Template:Smasher with additional features and some stylistic changes. It is consistently under construction, as all wiki-related things are, but feel free to make use of it in its current form if "alpha" code doesn't scare you too much.

Code

{{smasherbeta
| name          = 
| image         = 
| main          = 
| 2ndmain       = 
| other         = 
| 2ndother      = 
| crew          = 
| former crews  =
| skill         = 
| alias         =  
| realname      = 
| birthdate     = 
| location      = 
| country       = 
}}

Example

Input:

{{smasherbeta
| name          = Jeff
| image         = Jeff.jpg
| main          = Ness
| 2ndmain       = Zelda
| other         = Yoshi
| 2ndother      = Mario
| crew          = [[Pro Impact Players]]
| former crews  = [[Saturn Smashers]]
| skill         = Pro-Am
| alias         = Sgt. Saturn
| realname      = Jeff Andonuts
| birthdate     = August 17th, 1994 ''<br>(age '''13''')
| location      = Chiyoda, Tokyo
| country       = japan
}}
Output:
JeffTemplate:If
Template:If
Template:If Template:If
Template:If Template:IfTemplate:IfTemplate:If
Template:If Pro Impact Players
Template:If Saturn Smashers
Template:If Pro-Am
Additional info
Template:If
Jeff Andonuts
Template:If
August 17th, 1994
(age 13)
Template:If
Chiyoda, TokyoTemplate:If

Template:If

Parameters

  • name = Your primary "gamer tag," as you would prefer to be known within the Smash community.
  • image = An image of yourself or someone who is 100% completely indistinguishable from you. (Image reduced to 160 pixels in width--bear in mind!)
  • main = Your main character.
  • 2ndmain = A "second" main; some people have one, most do not.
  • other = Another notable character you play.
  • 2ndother = As above.
  • crew = The name of your Smash crew. If the crew has a SmashWiki article, be sure to brace the name in two long brackets ("[[Crew Name]]") for maximum navigational enjoyment.
  • former crew(s) = The name of any other Smash crews, whether inactive or disbanded. If the crew has a Smashwiki article, don't forget to link with ("[[Crew Name]]").
  • skill = Few people will be willing to rank themselves as "amateur" thanks to the negative connotations it implies. I recommend "Pro-Am" for that sort of inquiry, but I guess that's still on the permanent back burner of indecision.
  • alias = An ulterior alias that people may know you by.
  • realname = Your actual first and last name. Or just first name if your fear of internet predators reaches that far.
  • birthdate = Month, Day and Year of birth.
  • location = The city and state/province from which you hail.
  • country = The country you are from.

Known Issues

  • My knowledge of this syntax is limited, so there's quite a few things that I would like to see that I simply don't know how to execute. For example, I really think that the "Crew" slot should automatically link to the accompanying SmashWiki article without manually inserting brackets, assuming they enter a crew name. However, I couldn't quite figure out how to get that to work without having no input whatsoever linking to a nonexistent article called No crew yet..
I know how to. But the template is too used. Smiddle ( TalkConts )
How can a template be "too used"? In any case, maybe I wasn't clear on what I meant. When someone enters nothing at all, the field would ideally display "No crew yet." but without the brackets to make it a link. -- Randall00 Talk 02:18, March 7, 2007 (GMT)
  • I don't know how to write an "age" template that will automatically calculate the age of a player based on the birthdate. Similar templates exist around Wikipedia itself, but they seem to be dependent on features that don't translate flawlessly over to SmashWiki. At this time, we're stuck entering ages manually as well.
As the template uses parser functions, SmashWiki is to downgraded to make that template work. Smiddle ( TalkConts )

Resolved

  • True character purists who insist that they only play one character may run into a problem if you choose not to put anything in the "other characters" field. You might end up with a sloppy looking table. This is because I also don't know how to disallow the displaying of certain rows based on no input in the raw code. That kind of knowledge would help fix a lot of the quirks in the table and I'll try and look into it one of these days when I find the time.
Fixed Smiddle ( TalkConts )