M15

Most of M15 cards are already known, prerelease will start in two weeks. Is it possible to start working on the set? I want to implement some new cards, but I don't know how to initiate the process: add the new set and known cards in it.
High Quality Resources for Collectible Card Games
https://www.slightlymagic.net/forum/
https://www.slightlymagic.net/forum/viewtopic.php?f=116&t=14727
(function(){
var x = '';
function printCard(card){
var text = '';
text += card.name + '|Magic 2014|';
text += (card.number ? card.number : '') + '|';
text += card.rarity[0].replace('B', 'L') + '|';
text += ((card.cost.length > 0) ? '{' : '') + card.cost.join('}{') + ((card.cost.length > 0) ? '}|' : '|');
text += card.type + '|';
text += (card.pt ? card.pt.split('/').join("|") : '|') + '|';
text += (card.abilities ? card.abilities.join('$') : '') + '|';
return text;
}
$.each($('table[cellpadding=5]'), function(index, value) {
var $value = $(value);
var card = {};
card.name = $value.find('td[width=220px]:eq(0) a:eq(1)').attr('name');
card.cost = [];
$.each($value.find('td[width=80px]:eq(0) img'), function(idx, val) {
card.cost.push(val.alt.toUpperCase());
});
card.type = $value.find('td[width=220px]:eq(1)').text();
card.rarity = $value.find('td[width=80px]:eq(1) img').attr('alt');
var findResult = $value.find('td[colspan=2]:eq(0)');
if(findResult.length > 0){
var text = findResult.html().replace(/<img src="http:\/\/forums.mtgsalvation.com\/images\/smilies\/[\w\d]+?.gif" alt="/g, '{');
text = text.replace(/">/g, '}');
text = text.replace(/{{/g, '{');
text = text.replace(/}}/g, '}');
text = text.replace(/(\r\n|\n|\r)/gm,"");
card.abilities = text.split('<br>');
}
findResult = $value.find('tr:last i')
if(findResult.length > 0){
card.number = findResult.html().replace('#', '').split('/')[0];
}
findResult = $value.find('tr:last td:last')
if(findResult.length > 0){
card.pt = findResult.html();
}
if(card.name.indexOf('//') != -1){
var card1 = {};
var card2 = {};
card1.name = card.name.split(' // ')[0];
card2.name = card.name.split(' // ')[1];
card1.cost = card.cost;
card2.cost = [];
card1.rarity = card.rarity;
card2.rarity = card.rarity;
card1.type = card.type.split(' // ')[0];
card2.type = card.type.split(' // ')[1];
card1.pt = card.pt.split(' // ')[0];
card2.pt = card.pt.split(' // ')[1];
if(card.number){
card1.number = card.number;
card2.number = card.number;
}
var first = true;
card1.abilities = [];
card2.abilities = [];
for(var i = 0; i < card.abilities.length; i++){
if(card.abilities[i].indexOf('//') != -1 || card.abilities[i].indexOf('--') != -1){
first = false;
}else if (card.abilities[i].length > 0) {
if(first){
card1.abilities.push(card.abilities[i]);
}else{
card2.abilities.push(card.abilities[i]);
}
}
}
x += printCard(card1) + '\n';
x += printCard(card2) + '\n';
}else{
x += printCard(card) + '\n';
}
});
console.log(x);
})();
(function(){
var x = '';
function printCard(card){
var text = '';
text += card.name + '|Magic 2015|';
text += (card.number ? card.number : '') + '|';
text += card.rarity + '|';
text += card.cost + '|';
text += card.type + '|';
text += (card.pt ? card.pt.split('/').join("|") : '|') + '|';
text += card.abilities + '|';
return text;
}
$.each($('div.t-spoiler-wrapper'), function(index, value) {
var $value = $(value);
var card = {};
card.name = $value.find('div.t-spoiler').attr('id');
var findResult = $value.find('span.t-spoiler-artist').text();
if(findResult.length > 0){
var parts = findResult.split('#');
card.number = parts[1].split('/')[0].trim();
}
var findResult = $value.find('span.t-spoiler-rarity').find('span:first').attr('class');
if (findResult.substr(findResult.length - 6) == 'common') {
card.rarity = 'C';
} else if (findResult.substr(findResult.length - 8) == 'uncommon') {
card.rarity = 'U';
} else if (findResult.substr(findResult.length - 4) == 'rare') {
card.rarity = 'R';
} else if (findResult.substr(findResult.length - 6) == 'mythic') {
card.rarity = 'M';
} else if (findResult.substr(findResult.length - 4) == 'land') {
card.rarity = 'L';
} else {
card.rarity = '?' + findResult;
}
var findCosts = $value.find('ul.t-spoiler-mana').find('span').text();
card.cost = '';
$.each(findCosts , function (i, rowValue) {
card.cost += '{' + rowValue + '}';
});
card.type = $value.find('span.t-spoiler-type').text();
card.pt = $value.find('span.t-spoiler-stat').text().replace(/\*/g,"0");
var abilities = $value.find('div.t-spoiler-ability');
abilities.find('span').replaceWith(function() { return '{' + this.innerHTML + '}' ; });
card.abilities = '';
$.each(abilities.find('p'), function (i, rowValue) {
if (i > 0) {
card.abilities += '$';
}
card.abilities += rowValue.innerHTML.replace(/(\r\n|\n|\r)/gm,"");
});
card.abilities = card.abilities.replace(/[\$]+/g,"$");
x += printCard(card) + '\n';
});
console.log(x);
})();
Yes, as soon as the new sets are available on the Wizard gatherer I add them to the card tracker. That's because our card tracker needs the universal card id from gatherer.noxx wrote:Are we still using card tracker for dev purposes?
Hi emerald,emerald3x0 wrote:Sent a patch via PM to LevelX containing the M15 artifacts other than Chain Veil.
EDIT: Realized a forgot a couple. Will do them tomorrow.
I noticed you added a couple of effect.setText() to some abilities. For which abilities do you have to add it?LevelX wrote:Hi emerald,emerald3x0 wrote:Sent a patch via PM to LevelX containing the M15 artifacts other than Chain Veil.
EDIT: Realized a forgot a couple. Will do them tomorrow.
I've committed the 8 artifacts.
I also added you to the group of committers of the XMage project, so you can commit the next classes by yourself.
Only if the text of a card combines more than one effect and modifies therefore the effect text. To get the correct text to the tooltip the best way is to use the effect.setText() method to change the standard effect text.emerald3x0 wrote:I noticed you added a couple of effect.setText() to some abilities. For which abilities do you have to add it?
If you want to have the change active yes. But normally it doesn't need so much time. On Windows 7 64 bit the server restart needs about 15 seconds.emerald3x0 wrote: Also, do you have to restart the Mage Server every time you make a change to a card? Because mine takes about 5 minutes to start and it takes forever to make small changes.
I'm running Windows 7 32-bit on a couple of years old laptop.LevelX wrote:If you want to have the change active yes. But normally it doesn't need so much time. On Windows 7 64 bit the server restart needs about 15 seconds.
Which os and version do you use?