Update Alternate Rarity Color script (#24)

Added Alt Rarity to:
- Adventures
- Aftermath
- Mainframe
- M15 Future
- Mainframe Planeswalkers
- Mainframe DFCs
- Paradox
- Sagas
- Mainframe Splits

Added custom fonts to
- Adventures
- Mainframe
- Mainframe Tokens

Added Print Fix to
- Adventures
- Mainframe DFC
- Mainframe Planeswalkers
- Mainframe Tokens
- Paradox
- Sagas

Close #19
This commit is contained in:
cajun
2024-01-05 08:31:38 -06:00
committed by GitHub
parent 1adaf70609
commit 5023d2a85c
11 changed files with 887 additions and 174 deletions

View File

@@ -6,7 +6,7 @@ icon: card-sample.png
installer group: magic/m15 style/split cards
position hint: 011
version: 2023-02-13
version: 2024-01-05
depends on:
package: magic.mse-game
version: 2014-06-25
@@ -116,6 +116,186 @@ init script:
is_skinned := {contains(styling.other_options, match:"godzilla style alias")}
card_shape := {"adventure"}
# alternate rarity color
alt_rarity := {styling.alt_rarity_color}
### Customize fonts
swap_font := {styling.apply_custom_fonts}
name_font := {
swap_font_name(
src:styling.custom_name_font,
font_name: "Beleren Bold"
)
}
name_font_size := {
swap_font_size(
src:styling.custom_name_font,
font_size: 16
) - shrink_name()
}
name_font_color := {
swap_font_color(
src: styling.custom_name_font,
font_color: "black"
)
}
name_font_vertical := {
swap_font_vertical(
src: styling.custom_name_font
)
}
name_font_italic := {
swap_font_italic(
src: styling.custom_name_font
)
}
name2_font := {
swap_font_name(
src:styling.custom_name_2_font,
font_name: "Beleren Bold"
)
}
name2_font_size := {
swap_font_size(
src:styling.custom_name_2_font,
font_size: 12
) - shrink_name2()
}
name2_font_color := {
swap_font_color(
src: styling.custom_name_2_font,
font_color: "white"
)
}
name2_font_vertical := {
swap_font_vertical(
src: styling.custom_name_2_font
)
}
name2_font_italic := {
swap_font_italic(
src: styling.custom_name_2_font
)
}
type_font := {
swap_font_name(
src:styling.custom_type_font,
font_name: "Beleren Bold"
)
}
type_font_size := {
swap_font_size(
src:styling.custom_type_font,
font_size: 13
) - shrink_type()
}
type_font_color := {
swap_font_color(
src: styling.custom_type_font,
font_color: "black"
)
}
type_font_vertical := {
swap_font_vertical(
src: styling.custom_type_font
)
}
type_font_italic := {
swap_font_italic(
src: styling.custom_type_font
)
}
type2_font := {
swap_font_name(
src:styling.custom_type_2_font,
font_name: "Beleren Bold"
)
}
type2_font_size := {
swap_font_size(
src:styling.custom_type_2_font,
font_size: 11
) - shrink_type2()
}
type2_font_color := {
swap_font_color(
src: styling.custom_type_2_font,
font_color: "white"
)
}
type2_font_vertical := {
swap_font_vertical(
src: styling.custom_type_2_font
)
}
type2_font_italic := {
swap_font_italic(
src: styling.custom_type_2_font
)
}
body_font := {
swap_font_name(
src:styling.custom_body_font,
font_name: "MPlantin"
)
}
body_font_size := {
swap_font_size(
src:styling.custom_body_font,
font_size: 13
)
}
body_font_color := {
swap_font_color(
src: styling.custom_body_font,
font_color: "black"
)
}
body_font_vertical := {
swap_font_vertical(
src: styling.custom_body_font
)
}
body_font_italic := {
swap_font_italic(
src: styling.custom_body_font
)
}
pt_font := {
swap_font_name(
src:styling.custom_pt_font,
font_name: "Beleren Bold"
)
}
pt_font_size := {
swap_font_size(
src:styling.custom_pt_font,
font_size: 16
)
}
pt_font_color := {
swap_font_color(
src: styling.custom_pt_font,
font_color: if is_vehicle() then "white" else "black"
)
}
pt_font_vertical := {
swap_font_vertical(
src: styling.custom_pt_font
)
}
pt_font_italic := {
swap_font_italic(
src: styling.custom_pt_font
)
}
############################################################## Set info fields
set info style:
symbol:
@@ -185,6 +365,39 @@ styling field:
type: boolean
name: use holofoil stamps
description: Use holofoil stamps on rares and mythics
styling field:
type: text
name: alt rarity color
description: Use a custom color for the rarity symbol. Formatted as "R1,G1,B1:R2,G2,B2:...:X:" 1 and 2 are fill color, 3 and 4 border color, X is border thickness. For example, rare is 214,196,94:95,84,40:0,0,0:0,0,0:0.07
styling field:
type: boolean
name: apply custom fonts
description: Enable to attempt to use custom fonts given below
initial: no
styling field:
type: text
name: custom name font
description: Formatted as "font name;font size;font color;vertical offset;italic font name" last 4 are optional. color can be a name or R,G,B,A numbers.
styling field:
type: text
name: custom type font
description: Formatted as "font name;font size;font color;vertical offset;italic font name" last 4 are optional. color can be a name or R,G,B,A numbers.
styling field:
type: text
name: custom body font
description: Formatted as "font name;font size;font color;vertical offset;italic font name" last 4 are optional. color can be a name or R,G,B,A numbers.
styling field:
type: text
name: custom pt font
description: Formatted as "font name;font size;font color;vertical offset;italic font name" last 4 are optional. color can be a name or R,G,B,A numbers.
styling field:
type: text
name: custom name 2 font
description: Formatted as "font name;font size;font color;vertical offset;italic font name" last 4 are optional. color can be a name or R,G,B,A numbers.
styling field:
type: text
name: custom type 2 font
description: Formatted as "font name;font size;font color;vertical offset;italic font name" last 4 are optional. color can be a name or R,G,B,A numbers.
styling field:
type: boolean
name: grey hybrid name
@@ -301,27 +514,29 @@ card style:
############################# Name line
name:
left: { (if is_spot() then 22 else 0) + (if card.card_symbol=="none" then 32 else 50) }
top: 30
top: {30 + name_font_vertical()}
right: { 341 - card_style.casting_cost.content_width }
height: { 23 - 0.5*shrink_name() }
alignment: bottom shrink-overflow
padding bottom: 0
z index: 1
font:
name: Beleren Bold
size: {16 - shrink_name() }
color: black
name: { name_font() }
italic name: { name_font_italic() }
size: { name_font_size() }
color: { name_font_color() }
name 2:
left: { if is_reversed() then 197 else 32}
top: { 328 + (if is_spot() then 2 else 0)}
top: { 328 + (if is_spot() then 2 else 0)+ name2_font_vertical()}
right: { (if is_reversed() then 28 else 178) - card_style.casting_cost_2.content_width }
height: { 20 - shrink_name2() }
alignment: bottom shrink-overflow
z index: 2
font:
name: Beleren Bold
size: {12 - shrink_name2() }
color: white
name: { name2_font() }
italic name: { name2_font_italic() }
size: { name2_font_size() }
color: { name2_font_color() }
alias:
left: {if is_skinned() then 45 else 33}
top: 53
@@ -396,15 +611,16 @@ card style:
type:
left: { (if is_spot() then 50 else 0) + (if has_identity() then (if is_spot() then 50 else 52) else 32) }
top: { shrink_type() + if is_spot() then 298 else 296}
width: { (if has_identity() then "290" else "310") - max(22,card_style.rarity.content_width) - (if is_spot() then 73 else 0) }
width: { (if has_identity() then "290" else "310") - rare_width() - (if is_spot() then 73 else 0) }
height: { 20 - shrink_type() }
alignment: { if is_spot() then "top center shrink-overflow" else "top shrink-overflow"}
z index: 1
padding top: 2
font:
name: Beleren Bold
size: { 13 - shrink_type() }
color: black
name: { type_font() }
italic name: { type_font_italic() }
size: { type_font_size() }
color: { type_font_color() }
separator color: red
indicator 2:
left: {(if is_reversed() then 165 else 0) + (if has_identity2() then 30 else 0)}
@@ -424,9 +640,10 @@ card style:
z index: 1
padding top: 2
font:
name: Beleren Bold
size: { 11 - shrink_type2() }
color: white
name: { type2_font() }
italic name: { type2_font_italic() }
size: { type2_font_size() }
color: { type2_font_color() }
separator color: red
rarity:
right: { if is_spot() then 342 else 344}
@@ -441,28 +658,34 @@ card style:
basic land:
script:
if use_main_rarity() then "/magic-mainframe-extras.mse-include/" + un_png(set.mainframe_rarity_name) + "c.png"
else if use_alt_rarity() then alt_symbol()
else if styling.inverted_common_symbol then symbol_variation(symbol: set.symbol, variation: "invertedcommon")
else symbol_variation(symbol: set.symbol, variation: "common")
common:
script:
if use_main_rarity() then "/magic-mainframe-extras.mse-include/" + un_png(set.mainframe_rarity_name) + "c.png"
else if use_alt_rarity() then alt_symbol()
else if styling.inverted_common_symbol then symbol_variation(symbol: set.symbol, variation: "invertedcommon")
else symbol_variation(symbol: set.symbol, variation: "common")
uncommon:
script:
if use_main_rarity() then "/magic-mainframe-extras.mse-include/" + un_png(set.mainframe_rarity_name) + "u.png"
else if use_alt_rarity() then alt_symbol()
else symbol_variation(symbol: set.symbol, variation: "uncommon")
rare:
script:
if use_main_rarity() then "/magic-mainframe-extras.mse-include/" + un_png(set.mainframe_rarity_name) + "r.png"
else if use_alt_rarity() then alt_symbol()
else symbol_variation(symbol: set.symbol, variation: "rare")
mythic rare:
script:
if use_main_rarity() then "/magic-mainframe-extras.mse-include/" + un_png(set.mainframe_rarity_name) + "m.png"
else if use_alt_rarity() then alt_symbol()
else symbol_variation(symbol: set.symbol, variation: "mythic rare")
special:
script:
if use_main_rarity() then "/magic-mainframe-extras.mse-include/" + un_png(set.mainframe_rarity_name) + "s.png"
else if use_alt_rarity() then alt_symbol()
else symbol_variation(symbol: set.symbol, variation: "special")
masterpiece:
script:
@@ -471,15 +694,15 @@ card style:
############################# Text box
text:
left: {if is_reversed() then 27 else 200}
top: { 328 + to_int(chop_top()) }
top: { 328 + to_int(chop_top()) + body_font_vertical() }
width: {if is_reversed() then 157 else 143}
bottom: { (if is_spot() then 464 else 481) - to_int(chop_bot()) }
font:
name: MPlantin
italic name: MPlantin-Italic
size: 13
name: { body_font() }
italic name: { body_font_italic() }
size: { body_font_size() }
scale down to: 6
color: black
color: { body_font_color() }
symbol font:
name: { styling.text_box_mana_symbols }
size: 13
@@ -502,15 +725,15 @@ card style:
line height line max: 1.6
text 2:
left: {if is_reversed() then 190 else 29}
top: { 375 + to_int(back_chop_top()) }
top: { 375 + to_int(back_chop_top()) + body_font_vertical()}
width: 157
bottom: { (if is_spot() then 464 else 481) - to_int(back_chop_bot()) }
font:
name: MPlantin
italic name: MPlantin-Italic
size: 14
name: { body_font() }
italic name: { body_font_italic() }
size: { body_font_size() }
scale down to: 6
color: black
color: { body_font_color() }
symbol font:
name: { styling.text_box_mana_symbols }
size: 14
@@ -555,14 +778,15 @@ card style:
pt:
z index: 2
left: { if is_spot() then 293 else 286}
top: {if is_spot() then 466 else 469}
top: {(if is_spot() then 466 else 469)+(pt_font_vertical())}
width: 60
height: 28
alignment: center middle shrink-overflow
font:
name: Beleren Bold
size: 16
color: {if is_vehicle() then "white" else "black"}
name: {pt_font()}
italic name: {pt_font_italic()}
size: {pt_font_size()}
color: {pt_font_color()}
separator color: red
############################# Card sorting / numbering
set code: