Files
cajun 9a7b7949e8 [wip] updating exporters for 2.5 (#75)
* Add Card Regions to DFCs
* Add Hashes
* Add crop_multi_image to help crop with card regions
* bugfix exporters and organize the list
* add dfc splitter support for Cockatrice and Lackey exporters
* fix sizing bugs on Planesculptors exporter
* update icons on exporters missing them
* update namecheck exporter and improve near checking

---------

Co-authored-by: cajun <12363371+CajunAvenger@users.noreply.github.com>
2024-09-24 09:52:17 -05:00

59 lines
1.9 KiB
Plaintext
Raw Permalink Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
mse version: 0.3.8
short name: XML
full name: Formatted data
position hint: 430
icon: icon.png
version: 2009-06-29
installer group: magic/Export/xml
depends on: magic.mse-game 2008-08-08
game: magic
create directory: false
file type: *.xml|*.xml|*.*|*.*
# By Seeonee
# Based on code by Idle Muse
# Enhanced by Pichoro
#
# Changes Made:
# New and Correct Version Number
# MSE Version 0.3.8
# New Installer Group
# Spaces to Tabs
# New Icon
# Redid tabbing for clarity
# Changed "<" to "" (that's not a space)
option field:
type: choice
name: output
description: What data should be output?
choice: all card attributes
choice: card names
script:
MSEcard := {" card>\n"
+" name>"+to_text(card.name)+"/name>\n"
+" cost>"+to_text(card.casting_cost)+"/cost>\n"
+" type>\n"
+" supertype>"+to_text(card.super_type)+"/supertype>\n"
+" subtype>"+to_text(card.sub_type)+"/subtype>\n"
+" /type>\n"
+" rarity>"+substring(to_upper(to_text(card.rarity)),end:1)+"/rarity>\n"
+" rules>"+to_text(card.rule_text)+"/rules>\n"
+" flavor>"+to_text(card.flavor_text)+"/flavor>\n"
+" stats>\n"
+" power>"+to_text(card.power)+"/power>\n"
+" toughness>"+to_text(card.toughness)+"/toughness>\n"
+" /stats>\n"
+" illustrator>"+to_text(card.illustrator)+"/illustrator>\n"
+" number>"+to_text(card.card_number)+"/number>\n"
+" /card>\n"
}
write_card := { if options.output == "card names" then to_text( "card>\nname>" + card.name + "/name>\n/card>\n" )
else MSEcard()
}
write_cards := "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<spoiler set=\"" + to_text(set.title) + "\">\n" + to_text( for each card in sort_list( cards, order_by: {input.card_number} ) do write_card() ) + "</spoiler>\n"
to_string(write_cards)