Thank you very much! You have solved the doubts that have plagued me for a long time.
Tomoaky TMCard (English Translated)
JS Plugin Releases (RMMV)I already forgot about the upgrades I've been doing on this plugin, but let me show you guys this mode.
When you enter this mode, you get to open a booster pack and use those cards immediately in battle. When you WIN, you get to keep them, when you LOSE, you won't get to keep them.
When you enter this mode, you get to open a booster pack and use those cards immediately in battle. When you WIN, you get to keep them, when you LOSE, you won't get to keep them.
here's some update you can add. add these to easily export card images!
use the plugin command:
this will export card ID 1 from the data base
this will export card ID from 20 to 25
the cards will be saved in the img/cards/ folder. also you need to wait for it to load in game. the first time it runs it will be blank and black images. but after a few seconds it will then be outputted correctly 192 x 288 pixels as png file with filenames 000 to 999. you can edit the finalname format. i run it twice, and for sure on the second try it not black anymore. it takes less than 5 seconds on my end for all my 140 cards to be generated.
this very useful for devs as the current setup of the card sprites are layered.
use the plugin command:
this will export card ID 1 from the data base
Code:
exportCardImage 1
this will export card ID from 20 to 25
Code:
exportCardImage 20 25
the cards will be saved in the img/cards/ folder. also you need to wait for it to load in game. the first time it runs it will be blank and black images. but after a few seconds it will then be outputted correctly 192 x 288 pixels as png file with filenames 000 to 999. you can edit the finalname format. i run it twice, and for sure on the second try it not black anymore. it takes less than 5 seconds on my end for all my 140 cards to be generated.
this very useful for devs as the current setup of the card sprites are layered.
JavaScript:
else if (command === 'exportCardImage') { // x24
// Check if a range is provided (args[1] will be the end of the range if given)
var startId = Number(args[0]); // Starting card ID
var endId = Number(args[1]) || startId; // Ending card ID, defaults to startId if not provided
var fs = require('fs');
var path = require('path');
// Create the folder path if it doesn't exist
var folderPath = path.join(process.cwd(), 'img/cards');
if (!fs.existsSync(folderPath)) {
fs.mkdirSync(folderPath, { recursive: true });
}
// Function to export a single card image
var exportCardImage = function(cardId) {
if (!cardId || !$dataItems[cardId]) {
console.error("Invalid card ID or card not found: " + cardId);
return;
}
// Set up the card image size (192x288)
var cardBitmap = new Bitmap(192, 288);
// Use the actual card sprite rendering
var card = new Game_Card(cardId);
var sprite = new Sprite_Card(card);
sprite.bitmap = cardBitmap;
// Update sprite logic to render onto the bitmap
sprite.setFrame(0, 0, 192, 288);
sprite.update();
// Save the card image as a PNG
var fileName = String(cardId).padStart(3, '0') + '.png'; // Pad the filename with zeroes
var filePath = path.join(folderPath, fileName);
cardBitmap.addLoadListener(function() {
try {
var base64Data = cardBitmap._canvas.toDataURL().replace(/^data:image\/png;base64,/, "");
fs.writeFileSync(filePath, base64Data, 'base64');
console.log("Card image saved at:", filePath);
} catch (error) {
console.error("Error saving card image:", error);
}
});
};
// Loop through the range and export each card image
for (var cardId = startId; cardId <= endId; cardId++) {
exportCardImage(cardId);
}
}
So it occurred to me, if we can make in-game generated cards. ive got the image export. just need a scene to create one. This idea is from digimon card battle where they have partner cards. they level up increase stats and equip skill effects. i think this will be a complex add-on, as item instances aren't normal in rpg maker mv itself.
EDIT:
Oh my, i just realized you can make the card stats depend on a variable!
<cardHp=\v[10]>
This just made it more insane.
replace this in the Game_Card
EDIT:
Oh my, i just realized you can make the card stats depend on a variable!
<cardHp=\v[10]>
This just made it more insane.
replace this in the Game_Card
JavaScript:
Game_Card.prototype.cost = function() {
return this.getDynamicNotetagValue('cardCost');
};
Game_Card.prototype.hp = function() {
return this.getDynamicNotetagValue('cardHp');
};
Game_Card.prototype.atk = function() {
return this.getDynamicNotetagValue('cardAtk');
};
Game_Card.prototype.type = function() {
return this.getDynamicNotetagValue('cardType');
};
Game_Card.prototype.element = function() {
return this.getDynamicNotetagValue('cardElement');
};
Game_Card.prototype.rare = function() {
return this.getDynamicNotetagValue('cardRare');
};
Game_Card.prototype.unitSkill = function() {
return this.getDynamicNotetagValue('unitSkill');
};
Game_Card.prototype.partySkill = function() {
return this.getDynamicNotetagValue('partySkill');
};
Game_Card.prototype.getDynamicNotetagValue = function(tagName) {
if (this._item && this._item.meta[tagName]) {
const interpreter = new Game_Interpreter();
let textValue = interpreter.convertEscapeCharactersTM(this._item.meta[tagName]);
return parseInt(textValue, 10) || 0;
}
return 0;
};
You can actually turn this plugin into an original battle system just by turning ON two params
fixCardNum = 0 --> allows deck to be valid even if it only has 1 card
sameCard = 0 --> turns on same cards in the deck, all cards must be unique
you can even set upto X number of cards, as long as you define their position inside the plugin
Now that i've made an updated on the dynamic card values as with plugin usage. this battle system will even be more unique!
So, imagine this card battle system. You have a main card, that can be upgraded - HP , AP, Type, Element, Cost, Skill1, Skill 2. It can be reflected in the Card Album and Deck Edit and Deck Select. You can modify the params via plugin command or script call, for that randomization!
fixCardNum = 0 --> allows deck to be valid even if it only has 1 card
sameCard = 0 --> turns on same cards in the deck, all cards must be unique
you can even set upto X number of cards, as long as you define their position inside the plugin
Now that i've made an updated on the dynamic card values as with plugin usage. this battle system will even be more unique!
So, imagine this card battle system. You have a main card, that can be upgraded - HP , AP, Type, Element, Cost, Skill1, Skill 2. It can be reflected in the Card Album and Deck Edit and Deck Select. You can modify the params via plugin command or script call, for that randomization!
First of all, thank you for all the amazing work you've done! I love that you're keeping this alive!
Is there a way to make it auto battle without needing to hold the button down?
Is there a way to make it auto battle without needing to hold the button down?
hello thank you for your interest! i think it has to do with the wait flag of the window card battle message
Code:
//-----------------------------------------------------------------------------
// Window_CardBattleMessage
//
function Window_CardBattleMessage() {
this.initialize.apply(this, arguments);
}
Window_CardBattleMessage.prototype = Object.create(Window_Base.prototype);
Window_CardBattleMessage.prototype.constructor = Window_CardBattleMessage;
Window_CardBattleMessage.prototype.initialize = function(x, y) {
var width = this.windowWidth();
var height = this.fittingHeight(1);
Window_Base.prototype.initialize.call(this, x, y, width, height);
this.setBackgroundType(1);
this._waitFlag = false;
};
Window_CardBattleMessage.prototype.windowWidth = function() {
return Graphics.boxWidth;
};
Window_CardBattleMessage.prototype.refresh = function() {
this.contents.clear();
this.drawTextEx(this._message, 0, 0, this.contents.width); // option colored text
};
Window_CardBattleMessage.prototype.update = function() {
Window_Base.prototype.update.call(this);
if (this._waitFlag) {
if (Input.isRepeated('ok') || TouchInput.isRepeated()) {
this._waitFlag = false;
}
} else {
this._message = $gameCardBattle.getMessage();
if (this._message) {
this.refresh();
this._waitFlag = true;
}
}
};
see the touch input, change that. set the waitflag to false after the message, like if this switch is ON. it will definitely be nonstop
That works! Thanks so much!!! Currently working on my little booster pack system, but I've been wanting the battles to just be full auto once you start, helps add some much needed speed progression for the game since we can't control them 😀
yes, i use an evented system for the booster pack and card shop as well and card fusion.
i have already finished the card album with the dynamic card values.
i am still busy at the moment so i cannot upload a new bugfree demo project, but feel free to ask here.
my suggested plugins are. these are for better movement
MPP_ScrollBar
MPP_SimpleTouch
MPP_WindowInsideClear
these are for image effects.
NGT_Shatter
Picturecallcommon
MOG_PictureEffects
DTextPicture
You need TMTextEscape and RS_MessageAlign for better message system
I also did a shuffle prize reward picking here . the plugin version i made still in testing.
I checked my log, i was developing a plugin for replay system. i already have it evented as practice mode. the flow is just save the enemy cards to a variable and have a scene where the player gets to input them.
another inline was the in game stats for making achievements, like max damage, max heal, but this would be a lot so its far from the main.
sadly, im not successful in adding another image layer for animated holographic effect for cards. it would be nice if legend cards were animated right?
you can have different animations for each skill when activating, there is only 1 animation for receiving damage.
my deckselect now looks like this too. im going to replace the item name from icon + name to image.
i have already finished the card album with the dynamic card values.
i am still busy at the moment so i cannot upload a new bugfree demo project, but feel free to ask here.
my suggested plugins are. these are for better movement
MPP_ScrollBar
MPP_SimpleTouch
MPP_WindowInsideClear
these are for image effects.
NGT_Shatter
Picturecallcommon
MOG_PictureEffects
DTextPicture
You need TMTextEscape and RS_MessageAlign for better message system
I also did a shuffle prize reward picking here . the plugin version i made still in testing.
I checked my log, i was developing a plugin for replay system. i already have it evented as practice mode. the flow is just save the enemy cards to a variable and have a scene where the player gets to input them.
another inline was the in game stats for making achievements, like max damage, max heal, but this would be a lot so its far from the main.
sadly, im not successful in adding another image layer for animated holographic effect for cards. it would be nice if legend cards were animated right?
you can have different animations for each skill when activating, there is only 1 animation for receiving damage.
my deckselect now looks like this too. im going to replace the item name from icon + name to image.
My booster pack system is also event based 😀 I even recently just added to where it shows you the cards you get from the booster pack.
A card album would be sooo cool! It looks like you've made some amazing progress! As for my game I'm going more of the old school pokemon tcg route.
An animated legendary card would be soooo cool! Not sure if you can make the frames loop? rather than just one.
Here's a little snapshot.
oh, pokemon! that would be nice, so support skills and active skills sounds nice. you can always make your own skills, just create them inside the plugin. lots of item cards to include too!
Well pokemon style, but it won't include pokemon 😀 By that I just mean that it'll be an adventure similar to what pokemon is, lead duelist and masters to face against. Things like that. Also a lot of inspiration from their maps, basically direct rips XD, but the game will be its own thing. But I'll be using all the additions you added to make some very unique cards. Seeing what you've done has given me a lot of inspiration as I've had this thing on the backburner for years XD. But I'll be trying to push through this project this time. I'll be sure to post some updates.
i see. i guess these new tweaks might ne useful for your adventure type - the dynamic values, where the card stats can grow. enemies having random params too.
i think the fixCardNum = 0 sameCard = 0 will be useful for your game type. i'll try to release a demo for you.
i think the fixCardNum = 0 sameCard = 0 will be useful for your game type. i'll try to release a demo for you.
I think those are already in place, I got your ver 1.7.e
My first battle that takes place, the guy has 3 of the same card 😀
I have important questions:
1) how would i make the enemy deck use one of the players created decks (Deck 2 for example)
2) i dont see any guide on how to use the card album and was hoping i get help on that
3) is there any in depth documentation anywhere (i couldn't find any)
please help me if you can
Sorry for bad english
hello @Tesla-Ootachi
1. use plugin command startdeckselect, this is explained in the plugin
2. the card album posted here is evented, the plugin extension i am developing is not yet posted here (still being tested with the dynamic stats, dynamic stats are where the card stats can be variable based and change value as game progresses)
3. the in-depth documentation available is the one inside the plugin
still busy, unless there is urgent upgrade or update, i can add new demo. feel free to ask more questions
1. use plugin command startdeckselect, this is explained in the plugin
2. the card album posted here is evented, the plugin extension i am developing is not yet posted here (still being tested with the dynamic stats, dynamic stats are where the card stats can be variable based and change value as game progresses)
3. the in-depth documentation available is the one inside the plugin
still busy, unless there is urgent upgrade or update, i can add new demo. feel free to ask more questions
1. no i have mean the enemy use one of the player's equipped decks
2. If you would be able to show me how you evented that, that would be awesome. (or release a new demo if possible please)
Thanks in advance
to have a mirror match, each card has item ID, set it with same ID in the plugin command.
when i have time, i can upload a bug free demo. its hard to release a buggy one, cause will get more questions.
when i have time, i can upload a bug free demo. its hard to release a buggy one, cause will get more questions.
oh yeah i'm aware of that, thanks
much like you i have card 1,2,3 of an opponents deck set by variables
my question is how would i set a variable to (player deck 0, card 1) for example?
EDIT: i found out how to achieve what i need to do
basically you set each corresponding variable to "$gameParty.deck(deck id)[card number]" (with 0 being the first one for each) For items its "$dataItems[$gameParty._itemCards[deck id]].id"
then you setup your duel to use the corresponding variables (in my case i use 6 cards and an item)
Yes. That is very same to the change equip plugin command i shared here.
But you need to set it to that of the active deck. So that it will be a mirror match.
The active deck is the last editted deck by default. Or maybe deck 1 is the default active deck
But you need to set it to that of the active deck. So that it will be a mirror match.
The active deck is the last editted deck by default. Or maybe deck 1 is the default active deck
Original thread: https://forums.rpgmakerweb.com/threads/tomoaky-tmcard-english-translated.140259/