Add get_card_stylesheet script function

This commit is contained in:
GenevensiS
2024-10-04 22:41:06 +02:00
parent 6b0d311dc9
commit ecb48aebf0
4 changed files with 32 additions and 1 deletions
+17
View File
@@ -0,0 +1,17 @@
Function: get_card_stylesheet
--Usage--
> get_card_stylesheet(card, set: set)
Get the stylesheet of a [[type:card]].
This is for use in exporter scripts. In card scripts, use the "stylesheet" predefined variable instead.
--Parameters--
! Parameter Type Description
| @input@ [[type:card]] The card you want to retrieve the stylesheet from.
| @set@ [[type:set]] The set the card belongs to. In an exporter script, this can be ommited since "set" is a predefined variable.
--Examples--
> # Retrieve the card regions from the card's stylesheet
> card_regions := get_card_stylesheet(card).card_regions
+1
View File
@@ -98,6 +98,7 @@ These functions are built into the program, other [[type:function]]s can be defi
! Cards <<<
| [[fun:new_card]] Construct a new [[type:card]] object.
| [[fun:get_card_styling]] Get the styling data of a [[type:card]].
| [[fun:get_card_styesheet]] Get the stylesheet of a [[type:card]].
! HTML export <<<
| [[fun:to_html]] Convert [[type:tagged text]] to html.