mirror of
https://github.com/exane/not-gwent-online
synced 2024-10-31 10:36:53 +00:00
some minor stuff
This commit is contained in:
parent
b33606e943
commit
b5d28bcc08
@ -283,7 +283,6 @@ let BattleView = Backbone.View.extend({
|
||||
this.listenTo(user, "change:setHorn", this.render);
|
||||
this.listenTo(user, "change:isReDrawing", this.render);
|
||||
this.listenTo(user, "change:chooseSide", this.render);
|
||||
/*this.listenTo(user, "change:handCards", this.render);*/
|
||||
|
||||
this.$hand = this.$el.find(".field-hand");
|
||||
this.$preview = this.$el.find(".card-preview");
|
||||
|
@ -301,7 +301,7 @@ $game-height: 800px;
|
||||
}
|
||||
|
||||
.notifications {
|
||||
position: absolute;
|
||||
position: fixed;
|
||||
top: 0;
|
||||
z-index: 200;
|
||||
width: 500px;
|
||||
|
@ -61,6 +61,11 @@ var Battle = (function(){
|
||||
this.p1.draw(10);
|
||||
this.p2.draw(10);
|
||||
|
||||
/*this.p1.hand.add(this.p1.createCard("scorch"));
|
||||
this.p2.hand.add(this.p2.createCard("scorch"));
|
||||
this.p1.hand.add(this.p1.createCard("vernon_roche"));
|
||||
this.p2.hand.add(this.p2.createCard("vernon_roche"));*/
|
||||
|
||||
|
||||
/*this.p1.placeCard("ves");
|
||||
this.p2.placeCard("ves");
|
||||
|
@ -14,8 +14,12 @@ var Card = (function(){
|
||||
this.boost = 0;
|
||||
this._uidEvents = {};
|
||||
this.setDisabled(false);
|
||||
this._data = CardData[key] ? CardData[key] : CardData["none"];
|
||||
if(!(this._data = CardData[key])) {
|
||||
this._data = CardData["none"];
|
||||
key = "none";
|
||||
}
|
||||
this._key = key;
|
||||
this._data = CardData[key];
|
||||
this._data.key = key;
|
||||
this._boost = {};
|
||||
this._forcedPower = -1;
|
||||
|
@ -1,5 +1,6 @@
|
||||
var Card = require("./Card");
|
||||
/*var CardManager = require("./CardManager");*/
|
||||
var DeckData = require("../assets/data/deck");
|
||||
|
||||
var Deck = (function(){
|
||||
var Deck = function(deck, side){
|
||||
@ -40,6 +41,9 @@ var Deck = (function(){
|
||||
}
|
||||
|
||||
r.setDeck = function(deckData){
|
||||
if(!Array.isArray(deckData)) {
|
||||
deckData = DeckData["northern"];
|
||||
}
|
||||
this._originalDeck = deckData.slice();
|
||||
this._deck = deckData.slice();
|
||||
|
||||
|
@ -144,11 +144,12 @@ var Field = (function(){
|
||||
var highest = 0;
|
||||
|
||||
this.get().forEach(function(card) {
|
||||
if(noHeroes && card.getAbility("hero")) return;
|
||||
if(noHeroes && card.hasAbility("hero")) return;
|
||||
highest = card.getPower() > highest ? card.getPower() : highest;
|
||||
})
|
||||
|
||||
this.get().forEach(function(card) {
|
||||
if(noHeroes && card.hasAbility("hero")) return;
|
||||
if(card.getPower() === highest) res.push(card);
|
||||
});
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user