Alias Module (#162)
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 12 KiB |
@@ -1,95 +1,17 @@
|
||||
# Scripts for blending images
|
||||
# Included by a style file in its init script
|
||||
|
||||
|
||||
########################################################################
|
||||
# Filenames and other defaults
|
||||
########################################################################
|
||||
|
||||
mask_hybrid_with_land := { false }
|
||||
mask_hybrid_with_gold := { false }
|
||||
mask_multi_land_with_color := { false }
|
||||
template := { input + "{type}.jpg" }
|
||||
land_template := { (if input == "a" then "c" else input) + "l{type}.jpg" }
|
||||
# For what value should thumbnails of hybrids be made?
|
||||
hybrid_previews := "hybrid"
|
||||
# Are there templates for colored lands, land_template(...)?
|
||||
colored_lands := true
|
||||
trim_colors :=
|
||||
replace@(match:"(, )?(multicolor|hybrid|artifact|land|horizontal|vertical|radial)", replace:"")
|
||||
watermark_colors := {
|
||||
if face == false then face := card.card_color
|
||||
trimmed := trim_colors(face)
|
||||
if trimmed == "white" then "ww"
|
||||
else if trimmed == "blue" then "uu"
|
||||
else if trimmed == "black" then "bb"
|
||||
else if trimmed == "red" then "rr"
|
||||
else if trimmed == "green" then "gg"
|
||||
else if contains(face, match:"multi") or contains(face, match:"hybrid") or contains(face, match:", land") then hybrid_color(face:face)
|
||||
else if contains(face, match:"artifact") then "aa"
|
||||
else "cc"
|
||||
}@(face:false)
|
||||
hybrid_color := {
|
||||
if face == false then face := card.card_color
|
||||
trimmed := trim_colors(face)
|
||||
if trimmed == "white, blue" then "wu"
|
||||
else if trimmed == "white, black" then "wb"
|
||||
else if trimmed == "white, red" then "rw"
|
||||
else if trimmed == "white, green" then "gw"
|
||||
else if trimmed == "blue, black" then "ub"
|
||||
else if trimmed == "blue, red" then "ur"
|
||||
else if trimmed == "blue, green" then "gu"
|
||||
else if trimmed == "black, red" then "br"
|
||||
else if trimmed == "black, green" then "bg"
|
||||
else if trimmed == "red, green" then "rg"
|
||||
else if trimmed == "white, blue, reversed" then "uw"
|
||||
else if trimmed == "white, black, reversed" then "bw"
|
||||
else if trimmed == "white, red, reversed" then "wr"
|
||||
else if trimmed == "white, green, reversed" then "wg"
|
||||
else if trimmed == "blue, black, reversed" then "bu"
|
||||
else if trimmed == "blue, red, reversed" then "ru"
|
||||
else if trimmed == "blue, green, reversed" then "ug"
|
||||
else if trimmed == "black, red, reversed" then "rb"
|
||||
else if trimmed == "black, green, reversed" then "bg"
|
||||
else if trimmed == "red, green, reversed" then "gr"
|
||||
else "mm"
|
||||
}@(face:false)
|
||||
########################################################################
|
||||
# Combining multiple colors (hybrids)
|
||||
########################################################################
|
||||
|
||||
card_hybrid_blend := {
|
||||
linear_blend(
|
||||
card_hybrid_2 := {
|
||||
if mode != "mask" then linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: 0.4, y1: 0
|
||||
x2: 0.6, y2: 0
|
||||
)
|
||||
}
|
||||
card_hybrid_2 := {
|
||||
masked_blend(
|
||||
else masked_blend(
|
||||
light: template(colors[1])
|
||||
dark: template(colors[0])
|
||||
mask: "hybrid_blend_{type}.png"
|
||||
mask: "special_blend_{type}.png"
|
||||
)
|
||||
}
|
||||
|
||||
overlay_hybrid := [
|
||||
1: { template(colors[0]) }
|
||||
2: { combine_blend(
|
||||
image1: template(colors[0]),
|
||||
image2: template(colors[1]),
|
||||
combine: "symmetric overlay"
|
||||
)}
|
||||
]
|
||||
|
||||
# vertical version of a horizontal hybrid
|
||||
vertical_card_hybrid := {
|
||||
do_linear_blend := linear_blend
|
||||
linear_blend := { do_linear_blend(x1: 0, x2: 0, y1: x1, y2: x2) }
|
||||
card_hybrid.horizontal[color_count]()
|
||||
}
|
||||
|
||||
horizontal_card_hybrid := [
|
||||
1: { template(colors[0]) }
|
||||
2: card_hybrid_2
|
||||
@@ -260,318 +182,6 @@ card_hybrid := [
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
|
||||
########################################################################
|
||||
# P/T box
|
||||
########################################################################
|
||||
# These are easier
|
||||
|
||||
horizontal_pt_hybrid := [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { linear_blend(
|
||||
image1: template(colors[1])
|
||||
image2: template(colors[2])
|
||||
x1: -0.51, y1: 0
|
||||
x2: 0.26, y2: 0
|
||||
)}
|
||||
4: { linear_blend(
|
||||
image1: template(colors[2])
|
||||
image2: template(colors[3])
|
||||
x1: -0.1, y1: 0
|
||||
x2: 0.6, y2: 0
|
||||
)}
|
||||
5: { linear_blend(
|
||||
image1: template(colors[3])
|
||||
image2: template(colors[4])
|
||||
x1: 0.08, y1: 0
|
||||
x2: 0.65, y2: 0
|
||||
)}
|
||||
6: { linear_blend(
|
||||
image1: template(colors[4])
|
||||
image2: template(colors[5])
|
||||
x1: 0.07, y1: 0
|
||||
x2: 0.7, y2: 0
|
||||
)}
|
||||
7: {linear_blend(
|
||||
image1: linear_blend(
|
||||
image1: template(colors[4]),
|
||||
image2: template(colors[5]),
|
||||
x1: -0.2, y1: 0
|
||||
x2: 0.2, y2: 0
|
||||
),
|
||||
image2: template(colors[6]),
|
||||
x1: 0.5, y1: 0
|
||||
x2: 0.7, y2: 0
|
||||
)}
|
||||
]
|
||||
|
||||
pt_hybrid := [
|
||||
radial: [
|
||||
0: { template("c") }
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { template(colors[2]) }
|
||||
4: { template(colors[2]) }
|
||||
5: { linear_blend(
|
||||
image1: template(colors[2])
|
||||
image2: template(colors[3])
|
||||
x1: 0, y1: -1.5
|
||||
x2: 0, y2: 0.7
|
||||
)}
|
||||
6: { linear_blend(
|
||||
image1: template(colors[2])
|
||||
image2: template(colors[3])
|
||||
x1: 0, y1: -1.5
|
||||
x2: 0, y2: 0.7
|
||||
)}
|
||||
7: { template(colors[4]) }
|
||||
]
|
||||
horizontal: horizontal_pt_hybrid
|
||||
vertical: [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { template(colors[2]) }
|
||||
4: { template(colors[3]) }
|
||||
5: { template(colors[4]) }
|
||||
6: { template(colors[5]) }
|
||||
7: { template(colors[6]) }
|
||||
]
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
########################################################################
|
||||
# P/T boxes of flip cards
|
||||
########################################################################
|
||||
|
||||
flip_pt_hybrid := [
|
||||
radial: [
|
||||
0: { template("c") }
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { template(colors[1]) }
|
||||
4: { template(colors[1]) }
|
||||
5: { linear_blend(
|
||||
image1: template(colors[1])
|
||||
image2: template(colors[2])
|
||||
x1: 0, y1: -1
|
||||
x2: 0, y2: 1.8
|
||||
)}
|
||||
6: { linear_blend(
|
||||
image1: template(colors[1])
|
||||
image2: template(colors[2])
|
||||
x1: 0, y1: -1
|
||||
x2: 0, y2: 1.8
|
||||
)}
|
||||
7: { template(colors[4]) }
|
||||
]
|
||||
horizontal: horizontal_pt_hybrid
|
||||
vertical: [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[0]) }
|
||||
3: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 2
|
||||
)}
|
||||
4: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: 0, y1: -1.5
|
||||
x2: 0, y2: 1
|
||||
)}
|
||||
5: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: 0, y1: -1.1
|
||||
x2: 0, y2: 0.2
|
||||
)}
|
||||
6: { template(colors[1]) } # Probably not right
|
||||
7: { template(colors[2]) }
|
||||
]
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
flip_pt_hybrid2 := [
|
||||
radial: [
|
||||
0: { template("c") }
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[0]) }
|
||||
3: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[2])
|
||||
x1: 0, y1: -1
|
||||
x2: 0, y2: 1.1
|
||||
)}
|
||||
4: { template(colors[3]) }
|
||||
5: { template(colors[4]) }
|
||||
6: { template(colors[5]) }
|
||||
7: { template(colors[5]) }
|
||||
]
|
||||
horizontal: [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[0]) }
|
||||
3: { template(colors[0]) }
|
||||
4: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: 0.4, y1: 0
|
||||
x2: 1.5, y2: 0
|
||||
)}
|
||||
5: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: 0.08, y1: 0
|
||||
x2: 0.65, y2: 0
|
||||
)}
|
||||
6: { template(colors[5]) } #TODO
|
||||
7: { template(colors[6]) } #TODO
|
||||
]
|
||||
vertical: [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { linear_blend(
|
||||
image1: template(colors[1])
|
||||
image2: template(colors[2])
|
||||
x1: 0, y1: -1
|
||||
x2: 0, y2: 1.5
|
||||
)}
|
||||
4: { linear_blend(
|
||||
image1: template(colors[2])
|
||||
image2: template(colors[3])
|
||||
x1: 0, y1: 0.5
|
||||
x2: 0, y2: 3
|
||||
)}
|
||||
5: { template(colors[3]) }
|
||||
6: { template(colors[5]) } # Probably not right
|
||||
7: { template(colors[6]) }
|
||||
]
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
|
||||
########################################################################
|
||||
# P/T boxes for leveler cards
|
||||
########################################################################
|
||||
|
||||
leveler_pt_hybrid := [
|
||||
radial: [
|
||||
0: { template("c") }
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { linear_blend(
|
||||
image1: template(colors[1])
|
||||
image2: template(colors[2])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 1
|
||||
)}
|
||||
4: { template(colors[2]) }
|
||||
5: { template(colors[2]) }
|
||||
6: { template(colors[2]) }
|
||||
7: { template(colors[4]) }
|
||||
]
|
||||
horizontal: horizontal_pt_hybrid
|
||||
vertical: [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { linear_blend(
|
||||
image1: template(colors[1])
|
||||
image2: template(colors[2])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 1
|
||||
)}
|
||||
4: { template(colors[2]) }
|
||||
5: { template(colors[3]) }
|
||||
6: { linear_blend(
|
||||
image1: template(colors[3])
|
||||
image2: template(colors[4])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 0.25
|
||||
)}
|
||||
7: { template(colors[5]) }
|
||||
]
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
leveler_pt_hybrid2 := [
|
||||
radial: [
|
||||
0: { template("c") }
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { template(colors[2]) }
|
||||
4: { template(colors[2]) }
|
||||
5: { template(colors[2]) }
|
||||
6: { template(colors[2]) }
|
||||
7: { template(colors[4]) }
|
||||
]
|
||||
horizontal: horizontal_pt_hybrid
|
||||
vertical: [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { template(colors[2]) }
|
||||
4: { linear_blend(
|
||||
image1: template(colors[2])
|
||||
image2: template(colors[3])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 1
|
||||
)}
|
||||
5: { linear_blend(
|
||||
image1: template(colors[3])
|
||||
image2: template(colors[4])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 0.75
|
||||
)}
|
||||
6: { template(colors[4]) }
|
||||
7: { template(colors[5]) }
|
||||
]
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
leveler_pt_hybrid3 := [
|
||||
radial: [
|
||||
0: { template("c") }
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { template(colors[2]) }
|
||||
4: { template(colors[2]) }
|
||||
5: { linear_blend(
|
||||
image1: template(colors[2])
|
||||
image2: template(colors[3])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 1
|
||||
)}
|
||||
6: { linear_blend(
|
||||
image1: template(colors[2])
|
||||
image2: template(colors[3])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 1
|
||||
)}
|
||||
7: { template(colors[4]) }
|
||||
]
|
||||
horizontal: horizontal_pt_hybrid
|
||||
vertical: [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { template(colors[2]) }
|
||||
4: { template(colors[3]) }
|
||||
5: { linear_blend(
|
||||
image1: template(colors[3])
|
||||
image2: template(colors[4])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 0.5
|
||||
)}
|
||||
6: { linear_blend(
|
||||
image1: template(colors[4])
|
||||
image2: template(colors[5])
|
||||
x1: 0, y1: 0
|
||||
x2: 0, y2: 0.5
|
||||
)}
|
||||
7: { template(colors[5]) }
|
||||
]
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
########################################################################
|
||||
# Textbox and typeline for FPM templates and Futureshifts
|
||||
########################################################################
|
||||
@@ -600,403 +210,3 @@ textbox_hybrid := [
|
||||
]
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
typeline_hybrid := textbox_hybrid
|
||||
|
||||
########################################################################
|
||||
# Color Identity Marking
|
||||
########################################################################
|
||||
|
||||
identity_horizontal_hybrid := [
|
||||
0: { template("c") }
|
||||
1: { template(colors[0]) }
|
||||
2: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: 0.49, y1: 0.49
|
||||
x2: 0.5, y2: 0.5
|
||||
)}
|
||||
3: {masked_blend(light: masked_blend(light: template(colors[0]), dark: template(colors[2]), mask: "/magic-modules.mse-include/indicators/imask_32.png"), dark: template(colors[1]), mask: "/magic-modules.mse-include/indicators/imask_33.png")}
|
||||
4: {masked_blend(
|
||||
light: masked_blend(
|
||||
light: masked_blend(light: template(colors[1]), dark: template(colors[0]), mask: "/magic-modules.mse-include/indicators/imask_42.png"),
|
||||
dark: template(colors[2]),
|
||||
mask: "/magic-modules.mse-include/indicators/imask_43.png")
|
||||
dark: template(colors[3]),
|
||||
mask: "/magic-modules.mse-include/indicators/imask_44.png"
|
||||
)}
|
||||
5: {masked_blend(
|
||||
light: masked_blend(
|
||||
light: masked_blend(
|
||||
light: masked_blend(
|
||||
light: template(colors[0]),
|
||||
dark: template(colors[4]),
|
||||
mask: "/magic-modules.mse-include/indicators/imask_52.png"),
|
||||
dark: template(colors[1]),
|
||||
mask: "/magic-modules.mse-include/indicators/imask_53.png"),
|
||||
dark: template(colors[2]),
|
||||
mask: "/magic-modules.mse-include/indicators/imask_54.png"),
|
||||
dark: template(colors[3]),
|
||||
mask: "/magic-modules.mse-include/indicators/imask_55.png")
|
||||
}
|
||||
6: { template("m") }
|
||||
]
|
||||
|
||||
identity_hybrid := [
|
||||
radial: identity_horizontal_hybrid
|
||||
vertical: identity_horizontal_hybrid
|
||||
horizontal: identity_horizontal_hybrid
|
||||
overlay: identity_horizontal_hybrid
|
||||
]
|
||||
|
||||
########################################################################
|
||||
# Promo Stamp
|
||||
########################################################################
|
||||
# These are easier
|
||||
|
||||
horizontal_stamp_hybrid := [
|
||||
1: { template(colors[0]) }
|
||||
2: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: -0.3, y1: 0
|
||||
x2: 1.3, y2: 0
|
||||
)}
|
||||
3: { template(colors[1]) }
|
||||
4: { linear_blend(
|
||||
image1: template(colors[1])
|
||||
image2: template(colors[2])
|
||||
x1: -0.3, y1: 0
|
||||
x2: 1.3, y2: 0
|
||||
)}
|
||||
5: {linear_blend(
|
||||
image1: template(colors[1])
|
||||
x1: -0.55, y1: 0
|
||||
x2: 0.2, y2: 0
|
||||
image2: linear_blend(
|
||||
image1: template(colors[2])
|
||||
x1: 0.8, y1: 0
|
||||
x2: 1.55, y2: 0
|
||||
image2: template(colors[3])
|
||||
))}
|
||||
6: { linear_blend(
|
||||
image1: template(colors[2])
|
||||
image2: template(colors[3])
|
||||
x1: 0.1, y1: 0
|
||||
x2: 0.9, y2: 0
|
||||
)}
|
||||
7: {linear_blend(
|
||||
image1: template(colors[2])
|
||||
x1: -0.55, y1: 0
|
||||
x2: 0.2, y2: 0
|
||||
image2: linear_blend(
|
||||
image1: template(colors[3])
|
||||
x1: 0.8, y1: 0
|
||||
x2: 1.55, y2: 0
|
||||
image2: template(colors[4])
|
||||
))}
|
||||
]
|
||||
|
||||
stamp_hybrid := [
|
||||
radial: [
|
||||
0: { template("c") }
|
||||
1: { template(colors[0]) }
|
||||
2: { linear_blend(
|
||||
image1: template(colors[0])
|
||||
image2: template(colors[1])
|
||||
x1: -0.3, y1: 0
|
||||
x2: 1.3, y2: 0
|
||||
)}
|
||||
3: { template(colors[2]) }
|
||||
4: { linear_blend(
|
||||
image1: template(colors[3])
|
||||
image2: template(colors[2])
|
||||
x1: -0.3, y1: 0
|
||||
x2: 1.3, y2: 0
|
||||
)}
|
||||
5: { template(colors[3]) }
|
||||
6: { linear_blend(
|
||||
image1: template(colors[4])
|
||||
image2: template(colors[3])
|
||||
x1: -0.3, y1: 0
|
||||
x2: 1.3, y2: 0
|
||||
)}
|
||||
7: { template(colors[4]) }
|
||||
]
|
||||
horizontal: horizontal_stamp_hybrid
|
||||
vertical: [
|
||||
1: { template(colors[0]) }
|
||||
2: { template(colors[1]) }
|
||||
3: { template(colors[2]) }
|
||||
4: { template(colors[3]) }
|
||||
5: { template(colors[4]) }
|
||||
6: { template(colors[5]) }
|
||||
7: { template(colors[6]) }
|
||||
]
|
||||
overlay: overlay_hybrid
|
||||
]
|
||||
|
||||
########################################################################
|
||||
# Putting it all together.
|
||||
########################################################################
|
||||
|
||||
# Determine the card background based on the card_color multiple choice options
|
||||
color_background := {
|
||||
|
||||
# for thumbnails
|
||||
if input == "hybrid" then
|
||||
input := "white,blue,red,{hybrid_previews},horizontal"
|
||||
else if input == "overlay" then
|
||||
input := "blue,red,{hybrid_previews},overlay"
|
||||
else if input == "radial" or input == "horizontal" or input == "vertical" then
|
||||
input := "white,blue,red,{hybrid_previews}," + input
|
||||
else if input == "reversed" then
|
||||
input := "white,blue,red,{hybrid_previews},horizontal,reversed"
|
||||
|
||||
# What type of 'hybrid'?
|
||||
land := chosen(choice:"land")
|
||||
multi := chosen(choice:"multicolor")
|
||||
hybrid := chosen(choice:"hybrid")
|
||||
artifact := chosen(choice:"artifact")
|
||||
if land and colored_lands then template := land_template # use land template instead?
|
||||
|
||||
# The selected colors
|
||||
colors := sort_text( order: if card_is_wedge(input) then "(wbgur)" else "(wubrg)"
|
||||
, (if chosen(choice:"white") then "w")
|
||||
+ (if chosen(choice:"blue") then "u")
|
||||
+ (if chosen(choice:"black") then "b")
|
||||
+ (if chosen(choice:"red") then "r")
|
||||
+ (if chosen(choice:"green") then "g"))
|
||||
if multi and (hybrid or colors == "") then (
|
||||
colors := colors + "m"
|
||||
multi := false
|
||||
)
|
||||
if artifact and (hybrid or colors == "") then (
|
||||
colors := colors + "a"
|
||||
artifact := false
|
||||
)
|
||||
if chosen(choice:"reversed") then colors := reverse(colors)
|
||||
color_count := number_of_items(in: colors)
|
||||
if colors == "" then colors == "c"
|
||||
|
||||
# 'shape' / type of hybrid
|
||||
shape := if chosen(choice:"horizontal") then "horizontal"
|
||||
else if chosen(choice:"vertical") then "vertical"
|
||||
else if chosen(choice:"overlay") then "overlay"
|
||||
else "radial"
|
||||
|
||||
# Determine background (allows styles to hook something else here)
|
||||
color_combination()
|
||||
}
|
||||
|
||||
color_combination := {
|
||||
# The base hybrid, without the outer frame blended over it
|
||||
base := base_hybrid[shape][color_count]()
|
||||
# Put a frame around it?
|
||||
if land and not colored_lands then
|
||||
masked_blend(
|
||||
mask: "multicolor_blend_{type}.png",
|
||||
dark: land_template("c"),
|
||||
light: base,
|
||||
)
|
||||
else if land and multi and mask_multi_land_with_color() then
|
||||
masked_blend(
|
||||
mask: "hybrid_blend_{type}.png",
|
||||
dark: base,
|
||||
light: land_template("m"),
|
||||
)
|
||||
else if multi and artifact then
|
||||
masked_blend(
|
||||
mask: "artifact_blend_{type}.png",
|
||||
dark: template("a"),
|
||||
light: masked_blend(
|
||||
mask: "multicolor_blend_{type}.png",
|
||||
dark: template("m"),
|
||||
light: base
|
||||
)
|
||||
)
|
||||
else if multi then
|
||||
masked_blend(
|
||||
mask: "multicolor_blend_{type}.png",
|
||||
dark: template("m"),
|
||||
light: base,
|
||||
)
|
||||
else if artifact and color_count > 1 and mask_hybrid_with_land() then
|
||||
masked_blend(
|
||||
mask: "artifact_blend_{type}.png",
|
||||
dark: template("a"),
|
||||
light: masked_blend(
|
||||
mask: "multicolor_blend_{type}.png",
|
||||
dark: template("c"),
|
||||
light: base
|
||||
)
|
||||
)
|
||||
else if artifact and color_count > 1 and mask_hybrid_with_gold() then
|
||||
masked_blend(
|
||||
mask: "artifact_blend_{type}.png",
|
||||
dark: template("a"),
|
||||
light: masked_blend(
|
||||
mask: "multicolor_blend_{type}.png",
|
||||
dark: template("m"),
|
||||
light: base
|
||||
)
|
||||
)
|
||||
else if artifact then
|
||||
masked_blend(
|
||||
mask: "artifact_blend_{type}.png",
|
||||
dark: template("a"),
|
||||
light: base,
|
||||
)
|
||||
else if color_count > 1 and mask_hybrid_with_land() then
|
||||
masked_blend(
|
||||
mask: "hybrid_blend_{type}.png",
|
||||
dark: land_template("c"),
|
||||
light: base,
|
||||
)
|
||||
else if color_count > 1 and mask_hybrid_with_gold() then
|
||||
masked_blend(
|
||||
mask: "hybrid_blend_{type}.png",
|
||||
dark: land_template("m"),
|
||||
light: base,
|
||||
)
|
||||
else base
|
||||
}
|
||||
|
||||
########################################################################
|
||||
# Specific types
|
||||
########################################################################
|
||||
|
||||
card_background := { color_background(type:"card", base_hybrid:card_hybrid) }
|
||||
card_ptbox := { color_background(type:"pt", base_hybrid:pt_hybrid) }
|
||||
flip_ptbox := { color_background(type:"pt", base_hybrid:flip_pt_hybrid) }
|
||||
flip_ptbox2 := { color_background(type:"pt2", base_hybrid:flip_pt_hybrid2) }
|
||||
leveler_ptbox := { color_background(type:"pt", base_hybrid:leveler_pt_hybrid) }
|
||||
leveler_ptbox2 := { color_background(type:"pt", base_hybrid:leveler_pt_hybrid2) }
|
||||
leveler_ptbox3 := { color_background(type:"pt", base_hybrid:leveler_pt_hybrid3) }
|
||||
card_textbox := { color_background(type:"textbox", base_hybrid:textbox_hybrid) }
|
||||
card_typeline := { color_background(type:"typeline", base_hybrid:typeline_hybrid) }
|
||||
card_identity := { color_background(type:"identity", base_hybrid:identity_hybrid) }
|
||||
card_identity_2 := { color_background(type:"identity2", base_hybrid:identity_hybrid) }
|
||||
card_stamp := { color_background(type:"stamp", base_hybrid:stamp_hybrid) }
|
||||
card_stamp2 := { color_background(type:"stamp2", base_hybrid:stamp_hybrid) }
|
||||
|
||||
flip_background := {
|
||||
linear_blend(
|
||||
image1: card_background(top)
|
||||
image2: card_background(bottom)
|
||||
x1: 0, y1: 0.4
|
||||
x2: 0, y2: 0.6
|
||||
)
|
||||
}
|
||||
|
||||
########################################################################
|
||||
# Font colors
|
||||
########################################################################
|
||||
|
||||
# For which colors is the font white?
|
||||
font_colors_white := { input == "b" or input == "l" }
|
||||
|
||||
font_color_positions := [
|
||||
radial: [0,0,0,2,3,3,4,4]
|
||||
horizontal: [0,0,0,0,0,0,0,0]
|
||||
vertical: [0,0,1,2,3,4,5,6]
|
||||
overlay: [0,0,0,0,0,0,0,0]
|
||||
]
|
||||
|
||||
# Determine whether light or dark fonts should be used
|
||||
font_white := {
|
||||
hybrid := chosen(choice:"hybrid")
|
||||
artifact := chosen(choice:"artifact")
|
||||
colors := sort_text( order: "(wubrg)"
|
||||
, (if chosen(choice:"white") then "w")
|
||||
+ (if chosen(choice:"blue") then "u")
|
||||
+ (if chosen(choice:"black") then "b")
|
||||
+ (if chosen(choice:"red") then "r")
|
||||
+ (if chosen(choice:"green") then "g"))
|
||||
+ (if artifact then "a")
|
||||
font_colors_white(
|
||||
if chosen(choice:"land") then "l"
|
||||
else if input == "artifact, multicolor" then "a"
|
||||
else if chosen(choice:"multicolor") then "m"
|
||||
else if artifact and not hybrid then "a"
|
||||
else if colors == "" then "c"
|
||||
else colors[
|
||||
font_color_positions[
|
||||
if chosen(choice:"horizontal") then "horizontal"
|
||||
else if chosen(choice:"vertical") then "vertical"
|
||||
else if chosen(choice:"overlay") then "overlay"
|
||||
else "radial"
|
||||
][number_of_items(in: colors)]
|
||||
]
|
||||
)
|
||||
}
|
||||
|
||||
font_color := { if font_white() then rgb(255,255,255) else rgb(0,0,0) }
|
||||
|
||||
#####Watermark Blending
|
||||
watermark_hybrid:= {
|
||||
linear_blend(
|
||||
image1: colors[0] + input + ".png"
|
||||
image2: colors[1] + input + ".png"
|
||||
x1: 0.4, y1: 0
|
||||
x2: 0.6, y2: 0
|
||||
)
|
||||
}
|
||||
set_watermark_blend := {
|
||||
set_alpha(
|
||||
alpha: 0.75
|
||||
input:
|
||||
linear_blend(
|
||||
image1:
|
||||
masked_blend(
|
||||
light: "/magic-watermarks.mse-include/sets/" + input + ".png"
|
||||
dark: "/magic-watermarks.mse-include/sets/" + watermark_colors().0 + "mark.png"
|
||||
mask: "/magic-watermarks.mse-include/sets/" + input + ".png"
|
||||
)
|
||||
image2:
|
||||
masked_blend(
|
||||
light: "/magic-watermarks.mse-include/sets/" + input + ".png"
|
||||
dark: "/magic-watermarks.mse-include/sets/" + watermark_colors().1 + "mark.png"
|
||||
mask: "/magic-watermarks.mse-include/sets/" + input + ".png"
|
||||
)
|
||||
x1: 0.4, y1: 0
|
||||
x2: 0.6, y2: 0
|
||||
)
|
||||
)
|
||||
}
|
||||
spotlight_watermark_blend := {
|
||||
if face == false then face := card.card_color
|
||||
wmc := watermark_colors(face:face)
|
||||
c1 := "/magic-watermarks.mse-include/spotlight/" + wmc.0 + (if contains(face, match:"land") then "l") + "spotlight.png"
|
||||
c2 := "/magic-watermarks.mse-include/spotlight/" + wmc.1 + (if contains(face, match:"land") then "l") + "spotlight.png"
|
||||
if contains(input, match:".png,") then (
|
||||
array := split_text(input+",,", match:",")
|
||||
input := array.0
|
||||
l := min(to_number(array.1),500)
|
||||
h := min(to_number(array.2),500)
|
||||
)
|
||||
if (h != 500 or l != 500) then (
|
||||
c1 := crop(c1, height:h, width:l, offset_x:0, offset_y:0)
|
||||
c2 := crop(c2, height:h, width:l, offset_x:0, offset_y:0)
|
||||
)
|
||||
set_alpha(
|
||||
alpha: 0.75
|
||||
input:
|
||||
linear_blend(
|
||||
image1:
|
||||
masked_blend(
|
||||
light: input
|
||||
dark: c1
|
||||
mask: input
|
||||
)
|
||||
image2:
|
||||
masked_blend(
|
||||
light: input
|
||||
dark: c2
|
||||
mask: input
|
||||
)
|
||||
x1: 0.4, y1: 0
|
||||
x2: 0.6, y2: 0
|
||||
)
|
||||
)
|
||||
}@(h:500,l:500,face:false)
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 119 B |
Binary file not shown.
|
After Width: | Height: | Size: 6.5 KiB |
@@ -1,4 +1,4 @@
|
||||
mse version: 2.0.0
|
||||
mse version: 2.1.2
|
||||
game: magic
|
||||
short name: Showcase
|
||||
full name: Strixhaven Showcase
|
||||
@@ -105,6 +105,31 @@ init script:
|
||||
then styling.default_partition
|
||||
else "A"
|
||||
}
|
||||
module_alias := {
|
||||
template := alias_custom_template
|
||||
land_template := alias_custom_land_template
|
||||
color_background(
|
||||
type: "alias",
|
||||
base_hybrid: card_hybrid,
|
||||
artifact_blend: "black",
|
||||
hybrid_blend: "white",
|
||||
multicolor_blend: "black"
|
||||
)
|
||||
}
|
||||
alias_offset_top_1 := {5}
|
||||
alias_colors := {
|
||||
[
|
||||
w: rgb(243, 241, 229),
|
||||
u: rgb(0, 108, 169),
|
||||
b: rgb(55, 54, 48),
|
||||
r: rgb(217, 62, 39),
|
||||
g: rgb(0, 111, 64),
|
||||
a: rgb(193, 193, 193),
|
||||
m: rgb(234, 208, 106),
|
||||
c: rgb(165, 149, 133)
|
||||
][input]
|
||||
}
|
||||
|
||||
############################################################## Set info fields
|
||||
set info style:
|
||||
symbol:
|
||||
@@ -253,6 +278,7 @@ include file: /magic-modules.mse-include/watermarks/card_fields
|
||||
include file: /magic-modules.mse-include/information/card_fields
|
||||
include file: /magic-modules.mse-include/stamps/card_fields
|
||||
include file: /magic-modules.mse-include/separators/card_fields
|
||||
include file: /magic-modules.mse-include/alias/card_fields_under
|
||||
card style:
|
||||
############################# Background stuff
|
||||
card color:
|
||||
|
||||
Reference in New Issue
Block a user