Changeset 394 for veekun/trunk
- Timestamp:
- 12/30/07 01:49:43 (11 months ago)
- Location:
- veekun/trunk
- Files:
-
- 1 removed
- 5 modified
-
lib/Vee/Controller/Dex.pm (modified) (2 diffs)
-
static/dex/dp/hacking/files.tt (modified) (3 diffs)
-
templates/dex/page/location.tt (modified) (1 diff)
-
templates/dex/page/pokemon.tt (modified) (1 diff)
-
templates/dex/page/pokemon/map.tt (deleted)
-
templates/style/dex.tt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
veekun/trunk/lib/Vee/Controller/Dex.pm
r393 r394 723 723 } 724 724 725 =head2 map726 727 =cut728 729 sub map : Chained('pokemon_chain') : Args(0) {730 my ($self, $c) = @_;731 my $s = $c->stash;732 733 my $poke = $c->req->captures->[0];734 my $gen = 'dp'; # TODO: CHEAP HACK PLZ MAKE THIS WORK RITE -- do by generation but split if versions disagree?735 736 my $row = get_row($c, 'Pokemon', $poke);737 $c->vee_abort('There is no such Pokémon ', $poke, '. If you are messing with my URLs, please stop. If you came here via a link, please inform its owner that it is invalid.') unless $row;738 739 $s->{encounters} = get_locations($row);740 $s->{location_coords} = {741 map { $_->name => $_->coordinates }742 $c->model('DBIC::Locations')->search(undef)743 };744 745 $s->{this} = $row;746 747 $s->{page_title} = $row->name . ' - Location Map';748 $s->{crumbs} = [749 '<a href="' . $c->uri('Dex') . '">Pokédex</a>',750 '<a href="' . $c->uri('Dex', 'pokemon_list') . '">Pokémon</a>',751 '<a href="' . $c->uri('Dex', 'pokemon', lc $row->name) . '">' . $row->name . '</a>',752 'Location Map',753 ];754 755 $s->{template} = 'dex/page/pokemon/map.tt';756 }757 758 725 ################################################################################ 759 726 … … 1420 1387 if ($node->{param}) { 1421 1388 $node->{blurb} .= ", or use $node->{param}"; 1422 $node->{item} = $1 eq 'day' ? 'gameui/day ' : 'gameui/night';1389 $node->{item} = $1 eq 'day' ? 'gameui/daytime' : 'gameui/night'; 1423 1390 } 1424 1391 -
veekun/trunk/static/dex/dp/hacking/files.tt
r315 r394 281 281 <dd>PLACEHOLDER: GBA 4bpp. Graphics used in the animations for the transitions from the overworld to battles.</dd> 282 282 <dt>graphic/fld_comact.narc</dt> 283 <dd>PLACEHOLDER: GBA 4bpp. Appears to only contain an up arrow and a down arrow?</dd> 283 284 <dt>graphic/font.narc</dt> 284 285 <dt>graphic/fontoam.narc</dt> … … 286 287 <dt>graphic/imageclip.narc</dt> 287 288 <dt>graphic/mail_gra.narc</dt> 289 <dd>PLACEHOLDER: GBA 4bpp. Background graphics for mail.</dd> 288 290 <dt>graphic/menu_gra.narc</dt> 289 291 <dt>graphic/mysign.narc</dt> … … 309 311 <dt>graphic/waza_oshie_gra.narc</dt> 310 312 <dt>graphic/winframe.narc</dt> 313 <dd>PLACEHOLDER: GBA 4bpp. Borders, down arrow, and rotating clock animation used for dialog.</dd> 311 314 <dt>graphic/worldtrade.narc</dt> 312 315 <dt>graphic/zukan.narc</dt> -
veekun/trunk/templates/dex/page/location.tt
r393 r394 9 9 [% FOREACH section IN encounters.keys %] 10 10 11 [% IF section %] 11 12 <h2>[% section %]</h2> 13 [% END %] 12 14 <table cellspacing="0" cellpadding="3" class="dex-table dex-locations"> 13 15 <tr class="heading"> -
veekun/trunk/templates/dex/page/pokemon.tt
r393 r394 276 276 277 277 <h1>Locations</h1> 278 [%# TODO fix ghastly links %] 279 <p><a href="[% dex_uri('pokemon', this.name) %]/map"><img src="/images/see-also.png" alt="See also:"/> Location map</a></p> 278 [% MAP_SCALE = 1 # DO NOT SET THIS TO ANYTHING BUT 1 UNTIL BACKGROUND PROBLEM IS SOLVED %] 279 <div class="dex-locations-map"> 280 <img src="/dex-images/maps/sinnoh-dim.png" style="width: [% 216 * MAP_SCALE %]px;" alt=""/> 281 [% FOR enc IN new_encounters %] 282 [% location = enc.location %] 283 [% NEXT IF done.${location.id} OR NOT location.coordinates%] 284 [% map_done.${location.id} = 1 %] 285 <a href="[% dex_uri('locations', location.name) %]" title="[% location.name %]" class="location"> 286 <div class="name">[% location.name %]</div> 287 [% FOREACH loc IN location.coordinates.split(';'); 288 coords = loc.split(' '); 289 left = coords.shift * MAP_SCALE; 290 top = coords.shift * MAP_SCALE; 291 width = coords.shift * MAP_SCALE; 292 height = coords.shift * MAP_SCALE; 293 %] 294 <div class="partition" style="top: [% top %]px; left: [% left %]px; width: [% width %]px; height: [% height %]px; background: url(/dex-images/maps/sinnoh.png) -[% left %]px -[% top %]px;" title="[% location_row.name %]"></div> 295 [% END %] 296 </a> 297 [% END %] 298 </div> 280 299 281 300 <p>Sorry, Pearl players! Only Diamond for the moment.</p> -
veekun/trunk/templates/style/dex.tt
r369 r394 120 120 .dex-natures td { text-align: center; padding-left: 1em; padding-right: 1em; } 121 121 122 .dex-locations-map { position: relative; }123 .dex-locations-map img.map { float: left;margin-right: 16px; }124 .dex-locations-map .location { position: absolute; top: 0; left: 0;}125 .dex-locations-map .location . marker { visibility: hidden; }126 .dex-locations-map .location:hover . marker{ visibility: visible; }127 .dex-locations-map . partition { position: absolute; z-index: 1; }128 .dex-locations-map . location:hover .partition { outline: 2px solid white; }122 .dex-locations-map { position: relative; float: right; } 123 .dex-locations-map img.map { margin-right: 16px; } 124 .dex-locations-map .location { } 125 .dex-locations-map .location .name { position: absolute; visibility: hidden; right: 0; bottom: 0; width: 75%; padding-right: 1em; text-align: right; color: white; font-weight: bold; font-family: monospace; } 126 .dex-locations-map .location:hover .name { visibility: visible; } 127 .dex-locations-map .location:hover .name:hover { visibility: hidden; } 128 .dex-locations-map .partition { position: absolute; z-index: 10; } 129 129 130 130 /* Pokemon comparifier */
