Template:CustomAvatarTr

From A KoL Wiki


|- id="{{{aname|player-id-{{{id|{{{1|0}}}}}}}}}" | {{{name|{{{2|<Player's Name Unknown>}}}}}} || {{{id|{{{1}}}}}} || {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 0 | {{{avatar1|{{{4|[[File:{{{id|{{{1|0}}}}}}.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s Avatar]]}}}}}}}} {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 1 | {{{avatar2|{{{5|[[File:{{{id|{{{1|0}}}}}}_2.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s 2nd Avatar]]}}}}}}}} {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 2 | {{{avatar3|{{{6|[[File:{{{id|{{{1|0}}}}}}_3.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s 3rd Avatar]]}}}}}}}} {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 3 | {{{avatar4|{{{7|[[File:{{{id|{{{1|0}}}}}}_4.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s 4th Avatar]]}}}}}}}} {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 4 | {{{avatar5|{{{8|[[File:{{{id|{{{1|0}}}}}}_5.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s 5th Avatar]]}}}}}}}} {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 5 | {{{avatar6|{{{9|[[File:{{{id|{{{1|0}}}}}}_6.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s 6th Avatar]]}}}}}}}} {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 6 | {{{avatar7|{{{10|[[File:{{{id|{{{1|0}}}}}}_7.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s 7th Avatar]]}}}}}}}} {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 7 | {{{avatar8|{{{11|[[File:{{{id|{{{1|0}}}}}}_8.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s 8th Avatar]]}}}}}}}} {{#ifexpr: {{{avatarcount|{{{3|1}}}}}} > 8 | {{{avatar9|{{{12|[[File:{{{id|{{{1|0}}}}}}_9.gif|{{{name|{{{2|<Player's Name Unknown>}}}}}}'s 9th Avatar]]}}}}}}}}

Options

All arguments (expect for aname) are both positional and keyword selectable with the keywords have precedes over poitional. Meaning {{Template:CustomAvatarTr|1|[[Jick]]|7|[[File:jick_avatar.gif]]}} is the same as {{Template:CustomAvatarTr|id=1|avatar1=[[File:jick_avatar.gif]]|avatarcount=7|name=[[Jick]]}}

  • id The player's ID number. Defaults to '<Player's Name Unknown>'.
  • name The player's in-game name. Defaults to '0'.
  • avatarcount The number of avatars the player has. Defaults to '1'. If no avatarN argument is supplied then the template will use '{{{id}}}_N.gif' instead. ( '{{{id}}}.gif' will be used for avatarcount=1 )
  • avatarN A keyword assignment of a particular avatar. Defaults to '[[File:{{{id}}}.gif]]'. avatarN will only show if avatarcount >= N. The image should be a mediawiki File include not just the file name. Note: N is valid for numbers from 0-9. 0 will cause no images to be used.
  • aname Anchor name (use when the monster name has special characters that cannot be used in a CSS id specifier). Defaults to 'player-id-{{{id}}}'.

Examples

{| border="1px" cellpadding="4px" cellspacing="0" style="margin:1em; text-align:center; width: 100%"
|- style="background-color:#EFEFEF;"
! Player Name !! Player ID !! Custom Avatar(s)
{{Template:CustomAvatarTr|1|[[Jick]]|7|[[File:jick_avatar.gif]]|[[File:jick_avatar2.gif]]|avatar4=[[File:jick_avatar4.gif]]|[[File:jick_avatar3.gif]]}}
{{Template:CustomAvatarTr|6|[[Multi Czar]]|1|aname="bob"|[[File:Avatar_6.gif]]}}
{{Template:CustomAvatarTr|1061|Janice is Uber Cool|2}}
{{Template:CustomAvatarTr|4576|[[BoozerBear]]}}
{{Template:CustomAvatarTr|4576|[[BoozerBear]]|4}}
|}

Player Name Player ID Custom Avatar(s)
Jick 1 Jick's 5th Avatar Jick's 6th Avatar Jick's 7th Avatar
Multi Czar 6
Janice is Uber Cool 1061 Janice is Uber Cool's Avatar Janice is Uber Cool's 2nd Avatar
BoozerBear 4576 BoozerBear's Avatar
BoozerBear 4576 BoozerBear's Avatar BoozerBear's 2nd Avatar BoozerBear's 3rd Avatar BoozerBear's 4th Avatar