diff --git a/client/app/css/battle.styl b/client/app/css/battle.styl index e54f349..0efc54b 100644 --- a/client/app/css/battle.styl +++ b/client/app/css/battle.styl @@ -133,6 +133,7 @@ $side-width = ($battle-width - $screen-width) / 2 &.sand background linear-gradient(top, rgba(128, 64, 0, .3), rgba(64, 32, 48, .5)) &.sun + opacity 0.6!important background rgba(255, 196, 64, .3) .battle_pane diff --git a/client/app/js/models/battles/pokemon.coffee b/client/app/js/models/battles/pokemon.coffee index 5df7ee0..7f46b73 100644 --- a/client/app/js/models/battles/pokemon.coffee +++ b/client/app/js/models/battles/pokemon.coffee @@ -268,7 +268,7 @@ class @Pokemon extends Backbone.Model slugSpecies = slugify(@get('species')) slugForme = slugify(@get('forme')) - "//pokebattle.com/dex/pokemon/#{slugSpecies}/#{slugForme}" + "//wiki.p-insurgence.com/#{slugSpecies}" getIllu: -> @get('illu') diff --git a/public/Sprites/back-s/711-large.png b/public/Sprites/back-s/711-large.png new file mode 100644 index 0000000..d268c69 Binary files /dev/null and b/public/Sprites/back-s/711-large.png differ diff --git a/public/Sprites/back-s/711-small.png b/public/Sprites/back-s/711-small.png new file mode 100644 index 0000000..d268c69 Binary files /dev/null and b/public/Sprites/back-s/711-small.png differ diff --git a/public/Sprites/back-s/711-super.png b/public/Sprites/back-s/711-super.png new file mode 100644 index 0000000..d268c69 Binary files /dev/null and b/public/Sprites/back-s/711-super.png differ diff --git a/public/Sprites/back/711-large.png b/public/Sprites/back/711-large.png new file mode 100644 index 0000000..ccbb9f4 Binary files /dev/null and b/public/Sprites/back/711-large.png differ diff --git a/public/Sprites/back/711-small.png b/public/Sprites/back/711-small.png new file mode 100644 index 0000000..ccbb9f4 Binary files /dev/null and b/public/Sprites/back/711-small.png differ diff --git a/public/Sprites/back/711-super.png b/public/Sprites/back/711-super.png new file mode 100644 index 0000000..ccbb9f4 Binary files /dev/null and b/public/Sprites/back/711-super.png differ diff --git a/public/Sprites/front-s/711-large.png b/public/Sprites/front-s/711-large.png new file mode 100644 index 0000000..77cf5e2 Binary files /dev/null and b/public/Sprites/front-s/711-large.png differ diff --git a/public/Sprites/front-s/711-small.png b/public/Sprites/front-s/711-small.png new file mode 100644 index 0000000..77cf5e2 Binary files /dev/null and b/public/Sprites/front-s/711-small.png differ diff --git a/public/Sprites/front-s/711-super.png b/public/Sprites/front-s/711-super.png new file mode 100644 index 0000000..77cf5e2 Binary files /dev/null and b/public/Sprites/front-s/711-super.png differ diff --git a/public/Sprites/front/711-large.png b/public/Sprites/front/711-large.png new file mode 100644 index 0000000..bca6f42 Binary files /dev/null and b/public/Sprites/front/711-large.png differ diff --git a/public/Sprites/front/711-small.png b/public/Sprites/front/711-small.png new file mode 100644 index 0000000..bca6f42 Binary files /dev/null and b/public/Sprites/front/711-small.png differ diff --git a/public/Sprites/front/711-super.png b/public/Sprites/front/711-super.png new file mode 100644 index 0000000..bca6f42 Binary files /dev/null and b/public/Sprites/front/711-super.png differ diff --git a/public/css/main.css b/public/css/main.css index f2871d4..b34034c 100644 --- a/public/css/main.css +++ b/public/css/main.css @@ -327,7 +327,7 @@ h1{font-family:"PT Sans Narrow","Helvetica Neue",sans-serif;font-size:2em;font-w .battle .battle_overlays .battle_overlay.weather.rain{background:rgba(0,48,196,0.3)} .battle .battle_overlays .battle_overlay.weather.hail{background:rgba(128,255,255,0.3)} .battle .battle_overlays .battle_overlay.weather.sand{background:-webkit-gradient(linear, left top, left bottom, color-stop(0, rgba(128,64,0,0.3)), color-stop(1, rgba(64,32,48,0.5)));background:-webkit-linear-gradient(top, rgba(128,64,0,0.3) 0, rgba(64,32,48,0.5) 100%);background:-moz-linear-gradient(top, rgba(128,64,0,0.3) 0, rgba(64,32,48,0.5) 100%);background:-o-linear-gradient(top, rgba(128,64,0,0.3) 0, rgba(64,32,48,0.5) 100%);background:-ms-linear-gradient(top, rgba(128,64,0,0.3) 0, rgba(64,32,48,0.5) 100%);background:linear-gradient(top, rgba(128,64,0,0.3) 0, rgba(64,32,48,0.5) 100%)} -.battle .battle_overlays .battle_overlay.weather.sun{background:rgba(255,196,64,0.3)} +.battle .battle_overlays .battle_overlay.weather.sun{opacity:.6 !important;-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=60)" !important;filter:alpha(opacity=60) !important;background:rgba(255,196,64,0.3)} .battle .battle_pane{position:absolute;width:400px;height:300px;top:0;left:100px;} .battle .battle_pane .pokemon.bottom .pokemon-info{bottom:35%;left:200px} .battle .battle_pane .pokemon.bottom .sprite.fade{position:absolute;left:-20px;opacity:.3;-ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=30)";filter:alpha(opacity=30)} diff --git a/public/js/app.js b/public/js/app.js index 6596f6f..7a0510b 100644 --- a/public/js/app.js +++ b/public/js/app.js @@ -1863,7 +1863,7 @@ }; slugSpecies = slugify(this.get('species')); slugForme = slugify(this.get('forme')); - return "//pokebattle.com/dex/pokemon/" + slugSpecies + "/" + slugForme; + return "//wiki.p-insurgence.com/" + slugSpecies; }; Pokemon.prototype.getIllu = function() { diff --git a/public/js/replays.js b/public/js/replays.js index 28ee521..cb1e747 100644 --- a/public/js/replays.js +++ b/public/js/replays.js @@ -1863,7 +1863,7 @@ }; slugSpecies = slugify(this.get('species')); slugForme = slugify(this.get('forme')); - return "//pokebattle.com/dex/pokemon/" + slugSpecies + "/" + slugForme; + return "//wiki.p-insurgence.com/" + slugSpecies; }; Pokemon.prototype.getIllu = function() { diff --git a/server/index.coffee b/server/index.coffee index 349f06e..df97f09 100644 --- a/server/index.coffee +++ b/server/index.coffee @@ -21,7 +21,7 @@ replays = require('./replays') modify = require('./modify') MAX_MESSAGE_LENGTH = 250 -MAX_RANK_DISPLAYED = 100 +MAX_RANK_DISPLAYED = 25 # A MD5 hash of all the JavaScript files used by the client. This is passed to # each new connection via the .jade template, and when the client connects. If diff --git a/server/server.coffee b/server/server.coffee index 8ba3933..669507e 100644 --- a/server/server.coffee +++ b/server/server.coffee @@ -306,20 +306,21 @@ class @BattleServer # Add user to spectators # TODO: player.id should be using player.name, but alts present a problem. user = @users.get(player.id) - battle.add(spark) for spark in user.sparks + if typeof user != 'undefined' + battle.add(spark) for spark in user.sparks + + # Add/remove player ids to/from user battles + @userBattles[player.id] ?= {} + @userBattles[player.id][battleId] = true - # Add/remove player ids to/from user battles - @userBattles[player.id] ?= {} - @userBattles[player.id][battleId] = true + # Add the player to the list if its not an alt + if player.id == player.ratingKey # hacky - but no alternative right now + @visibleUserBattles[player.id] ?= {} + @visibleUserBattles[player.id][battleId] = true - # Add the player to the list if its not an alt - if player.id == player.ratingKey # hacky - but no alternative right now - @visibleUserBattles[player.id] ?= {} - @visibleUserBattles[player.id][battleId] = true + battle.once 'end', @removeUserBattle.bind(this, player.id, player.name, battleId) - battle.once 'end', @removeUserBattle.bind(this, player.id, player.name, battleId) - - battle.once 'expire', @removeBattle.bind(this, battleId) + battle.once 'expire', @removeBattle.bind(this, battleId) # Add the battle to the achievements system # Uneligible battles are ignored by this function