Changeset 96 for veekun/branches

Show
Ignore:
Timestamp:
04/11/07 02:12:36 (3 years ago)
Author:
eevee
Message:

Styled type pages and added type effects to move pages.

Location:
veekun/branches/layout/templates
Files:
5 modified

Legend:

Unmodified
Added
Removed
  • veekun/branches/layout/templates/dex/page/move.tt

    r95 r96  
    3333    </dl> 
    3434</div> 
     35<!-- TODO: should this still show for typeless or fixed or zero-damage moves? --> 
    3536<div class="dex-long-box"> 
    36     <h2>Damage [% type_name(this.type) %] Does</h2> 
    37     <p>lol</p> 
     37    <h2>Damage [% type_name(this.type) %] Inflicts</h2> 
     38    <dl class="compact"> 
     39[% FOR modifier IN [ 'z', 'h', 'd' ] %] 
     40        <dt>[% tmp = ModEffect.$modifier * 10; ModLabels.$tmp %]&times; against</dt> 
     41        <dd> 
     42[%     FOR type IN TypeNames %] 
     43[%         NEXT UNLESS TypeData.${this.type}.new_effects.substr(TypeData.$type.id, 1) == modifier %] 
     44            [%+ type_name(type)  %] 
     45[%     END %] 
     46        </dd> 
     47[% END %] 
     48    </dl> 
    3849</div> 
    3950<div class="dex-basic-box"> 
  • veekun/branches/layout/templates/dex/page/pokemon.tt

    r95 r96  
    4343</div> 
    4444<div class="dex-long-box"> 
    45     <h2>Damage Done against [% type_name(this.type1) %][% IF this.type2; ' '; type_name(this.type2); END %]</h2> 
     45    <h2>Damage Taken By [% type_name(this.type1) %][% IF this.type2; ' '; type_name(this.type2); END %]</h2> 
    4646    <ul> 
    4747    [% FOREACH type IN TypeNames %] 
  • veekun/branches/layout/templates/dex/page/type.tt

    r39 r96  
    88[% END -%] 
    99 
    10 <p class="center"> 
    11   <a href="[% dex_uri('types', nexttype) %]" class="next"> <img src="/dex-images/typeicons/[% nexttype %].png" alt=""/> [%+ nexttype %] -&gt; </a> 
    12   <a href="[% dex_uri('types', prevtype) %]" class="prev"> &lt;- <img src="/dex-images/typeicons/[% prevtype %].png" alt=""/> [%+ prevtype %] </a> 
    13   <img src="/dex-images/typeicons/[% this.name %].png" alt=""/> [%+ this.name %] 
     10<p class="dex-navigation"> 
     11    <a href="[% dex_uri('types', nexttype) %]" class="next blocklink">     Next<br/><img src="/dex-images/gameui/[% nexttype %].png" alt="[% nexttype %]" title="[% nexttype %]"/> </a> 
     12    <a href="[% dex_uri('types', prevtype) %]" class="prev blocklink"> Previous<br/><img src="/dex-images/gameui/[% prevtype %].png" alt="[% prevtype %]" title="[% prevtype %]"/> </a> 
     13    [% this.internalid %]<br/><img src="/dex-images/gameui/[% this.name %].png" alt="[% this.name %]" title="[% this.name %]"/> 
    1414</p> 
    1515 
    1616<h1>Basic Data</h1> 
    17 <table class="dex-basic"> 
    18 <tr> 
    19  <td class="dex-basic-name">Name:</td>          <td class="dex-basic-value">[% this.name %]</td> 
    20  <td class="dex-basic-name">Class:</td>         <td class="dex-basic-value">[% this.internalid < 20 ? 'physical' : 'special' %]</td> 
    21  <td class="dex-basic-name">Abbreviation:</td>  <td class="dex-basic-value">[% this.abbr %]</td> 
    22 </tr> 
    23 <tr> 
    24  <td class="dex-basic-name">ID:</td>            <td class="dex-basic-value">[% this.internalid %]</td> 
    25  <td class="dex-basic-name">Generation:</td>    <td class="dex-basic-value">[% Icons.${Generations.${generation}.abbr} %] [%+ Generations.${generation}.games %]</td> 
    26  <td class="dex-basic-name">Styling:</td>    <td class="dex-basic-value" style="background: url('/dex-images/type/[% this.name %].png');"><img src="/dex-images/typeicons/[% this.name %].png" alt=""/></td> 
    27 </tr> 
    28 </table> 
    29  
    30 <!-- ####################################################################### --> 
    31  
    32 <h1>Modifiers</h1> 
    33 <table cellspacing="0" cellpadding="2" class="dex-types"> 
    34 <tr> 
    35  <th> <em>[% this.name %] is...</em> </th> 
    36 [% FOREACH type IN TypeNames %] 
    37  <th><a href="[% dex_uri('types', type) %]"><img src="/dex-images/typeicons/[% type %].png" alt="" title="[% type %]"/><br/>[%+ type %]</a></th> 
     17<div class="dex-summary"> 
     18    <div class="name">[% this.name %]</div> 
     19    <div class="type"><img src="/dex-images/gameui/[% this.name %].png" alt="[% this.name %]" title="[% this.name %]"/> [% class = this.internalid < 20 ? 'physical' : 'special'; type_name(class) %]</div> 
     20     
     21    <p><a href="[% c.uri_for('pokemon', { gen => generation }) %]">[% Icons.${Generations.$generation.abbr} %] [%+ Generations.$generation.abbr | upper %]</a></p> 
     22</div> 
     23<!-- TODO: refactor with similar move tables? --> 
     24<div class="dex-long-box"> 
     25    <h2>Offensive Modifers</h2> 
     26    <dl class="compact"> 
     27[% stats = {} %] 
     28[% FOR modifier IN [ 'z', 'h', 'd' ] %] 
     29        <dt>[% tmp = ModEffect.$modifier * 10; ModLabels.$tmp %]&times; against</dt> 
     30        <dd> 
     31[%     FOR type IN TypeNames %] 
     32[%         NEXT UNLESS TypeData.${this.name}.new_effects.substr(TypeData.$type.id, 1) == modifier %] 
     33[%         stats.$modifier = stats.$modifier + 1 %] 
     34            [%+ type_name(type)  %] 
     35[%     END %] 
     36        </dd> 
    3837[% END %] 
    39 </tr> 
    40 <tr> 
    41  <th>ATTACKING:</th> 
    42 [% FOREACH type IN TypeNames %] 
    43 [%     effect = type_effect(this.name, type) %] 
    44  <td class="center typemod-[% effect %]">[% ModLabels.$effect %]</td> 
     38<!-- 
     39        <dt>Average</dt> 
     40        <dd>Score of [% stats.d - stats.h %]; average type advantage of [% (stats.h * 0.5 + stats.d * 2 + (TypeNames.size - stats.h - stats.d)) / TypeNames.size * 100 - 100 | format('%.01f') %]%</dd> 
     41--> 
     42    </dl> 
     43</div> 
     44<div class="dex-long-box"> 
     45    <h2>Defensive Modifiers</h2> 
     46    <dl class="compact"> 
     47[% FOR modifier IN [ 'z', 'h', 'd' ] %] 
     48        <dt>[% tmp = ModEffect.$modifier * 10; ModLabels.$tmp %]&times; from</dt> 
     49        <dd> 
     50[%     FOR type IN TypeNames %] 
     51[%         NEXT UNLESS TypeData.$type.new_effects.substr(TypeData.${this.name}.id, 1) == modifier %] 
     52            [%+ type_name(type)  %] 
     53[%     END %] 
     54        </dd> 
    4555[% END %] 
    46 </tr> 
    47 <tr> 
    48  <th>DEFENDING:</th> 
    49 [% FOREACH type IN TypeNames %] 
    50 [%     effect = type_effect(type, this.name) %] 
    51  <td class="center typemod-[% effect %]">[% ModLabels.$effect %]</td> 
    52 [% END %] 
    53 </tr> 
    54 </table> 
     56<!-- 
     57        <dt>Average</dt> 
     58        <dd>Score of [% stats.h - stats.d %]; average type advantage of [% (stats.h * 2 + stats.d * 0.5 + (TypeNames.size - stats.h - stats.d)) / TypeNames.size * 100 - 100 | format('%.01f') %]%</dd> 
     59--> 
     60    </dl> 
     61</div> 
    5562 
    5663<!-- ####################################################################### --> 
     
    6370[% pokemon_ct = pokemon_ct + 1 %] 
    6471[% END %] 
    65 <div class="total">[% pokemon_ct %] Pok&eacute;mon total</div> 
     72<p class="total">[% pokemon_ct %] Pok&eacute;mon total</p> 
    6673 
    6774<!-- ####################################################################### --> 
     
    7178 
    7279[% color = 1 %] 
    73 <table class="dex" cellspacing="0"> 
    74 <tr> 
     80<table class="dex-table" cellspacing="0"> 
     81<tr class="heading"> 
    7582[% move_header %] 
    7683</tr> 
     
    8592[% END %] 
    8693</table> 
    87 <div class="total">[% moves_ct %] moves total</div> 
     94<p class="total">[% moves_ct %] moves total</p> 
    8895 
    8996<!-- ####################################################################### --> 
     
    9299<ul> 
    93100<li><a href="http://bulbapedia.bulbagarden.net/wiki/[% this.name | ucfirst %]_%28type%29">BulbaPedia</a></li> 
    94 <li><a href="http://www.smogon.com/advance/types/[% this.name | lower %]">Smogon</a></li> 
     101<li><a href="http://www.smogon.com/rs/types/[% this.name | lower %]">Smogon</a></li> 
    95102[% IF generation <= 1 %]<li>[% Icons.rby %] <a href="http://www.math.miami.edu/~jam/azure/pokedex/comp/[% this.name %].htm">Azure Heights</a></li>[% END %] 
    96103</ul> 
  • veekun/branches/layout/templates/style/dex.tt

    r95 r96  
    1818 
    1919.dex-alternates { text-align: center; } 
     20 
     21a.dex-pokelist img { border: 1px solid transparent; -moz-border-radius: 0.33em; } 
     22  a.dex-pokelist img:hover { border-color: #802020; background: #d89090; } 
    2023 
    2124/* main layout chunks */ 
  • veekun/branches/layout/templates/style/global.tt

    r95 r96  
    3737p { margin: 0.5em; line-height: 133%; } 
    3838#content h1, #content h2, #content h3 { background: url(/images/h1-ground.png) #e6d3b8 no-repeat left center; clear: both; margin: 1em 0 0.5em 0; padding-left: 80px; color: #806640; border: 1px solid #c0a680; border-left: none; border-right: none; } 
    39 #content h1 { margin: 0.5em -8px; padding: 0; padding-left: 80px; } 
     39#content h1 { margin: 0.5em -8px; padding: 0; padding-left: 80px; border-top: 2px solid #806640; } 
    4040#content h2 { background-image: url(/images/h2-ground.png); } 
    4141#content h3 { background-image: url(/images/h3-ground.png); }