{"id":43,"date":"2019-10-25T07:50:00","date_gmt":"2019-10-25T06:50:00","guid":{"rendered":"https:\/\/techblog.dansbo.dk\/?p=43"},"modified":"2025-05-17T13:49:36","modified_gmt":"2025-05-17T12:49:36","slug":"my-1st-assembler-game-for-cx16-part-2","status":"publish","type":"post","link":"https:\/\/techblog.dansbo.dk\/?p=43","title":{"rendered":"My 1st assembler game for CX16 \u2013 part 2"},"content":{"rendered":"\n<p>Continuing from&nbsp;<a href=\"https:\/\/techblog.dansbo.dk\/?p=41\" target=\"_blank\" rel=\"noreferrer noopener\">part 1<\/a>&nbsp;where I created 3 small functions: GotoXY, HLine and VLine. I am going to create a couple more \u201chelper\u201d functions as well as the function that will initialize the screen and make it ready to start the game.<\/p>\n\n\n\n<p>First I will look at the function to print a string on the screen. It is actually fairly simple. We start by finding the address in memory where the string is stored. When that is found, we print the character that is stored there, increment the address and start over until we reach a 0-byte. As the function being used (CHROUT) automatically move the cursor we do not have to think about anything other than incrementing the address and checking for 0-byte.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>; **************************************************************\n; PrintStr\n; **************************************************************\n; Description:\tWrite a zero-terminated PETSCII string to scr\n; **************************************************************\n; Inputs:\tRegister X = Low byte of string start address\n;\t\tRegister Y = High byte of string start address\n; **************************************************************\nPrintStr:\n\t<font color=\"orange\">stx<\/font>\tTMP0\t\t; Store string start address in\n\t<font color=\"orange\">sty<\/font>\tTMP1\t\t; Zero-page memory in order to\n\t\t\t\t; do indirect addressing\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#0<\/font>\t\t; Y used as offset, start at 0\n.doprint\n\t<font color=\"orange\">lda<\/font>\t(TMP0), Y\t; Load character into reg A\n\t<font color=\"orange\">beq<\/font>\t.printdone\t; If char=0, we are done\n\t<font color=\"orange\">jsr<\/font>\tCHROUT\t\t; Print the character\n\t<font color=\"orange\">iny<\/font>\t\t\t; Increment offset (Y)\n\t<font color=\"orange\">jmp<\/font>\t.doprint\t; Loop back, get next character\n.printdone:\n\t<font color=\"orange\">rts<\/font><\/code><\/pre>\n\n\n\n<p>Now that we have the PrintStr function, let me show how it is called. I will create a small snippet of code to show how to use the PrintStr function. This snippet will not function correctly on its own, but if it is combined with the information found in part 1, it should be possible to assemble a .prg file that will actually run on the Commander X16.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>; Load X with low-byte of .title address\n\t<font color=\"orange\">ldx<\/font>\t#&lt;.title\n\t; Load Y with high-byte of .title address\n\t<font color=\"orange\">ldy<\/font>\t#&gt;.title\n\t<font color=\"orange\">jsr<\/font>\tPrintStr\n\n; Variable containing our string\n.title\t!pet\t<font color=\"red\">\"x16-maze\"<\/font>,<font color=\"blue\">0<\/font><\/code><\/pre>\n\n\n\n<p>The next function converts a !byte value into a 3 digit PETSCII string. As we all know, a byte can hold any value from 0 to 255 so we need 3 digits to represent any number that can be held in a byte. The function works directly on 2 global variables. A !byte called .lvl and a !pet called .lvltxt<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>.lvl\t!byte\t<font color=\"blue\">0<\/font>\n.lvltxt\t!pet\t<font color=\"red\">\"000\"<\/font>,<font color=\"blue\">0<\/font><\/code><\/pre>\n\n\n\n<p>Since the .lvltxt variable is initialized with \u201c000\u201d, we only need to change the digits that are not 0. So if the value in .lvl is 53, we only change the 2nd and 3rd digit and leave the first 0 in place. The .lvltxt will then contain \u201c053\u201d. The function works, roughly this way:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>if value &gt;= 200 then\n\twrite '2' in the first digit\n\tsubtract 200 from the value\nelse if value &gt;= 100 then\n\twrite '1' in the first digit\n\tsubtract 100 from the value\nendif\nfor digit=9 downto 1\n\tnum = digit * 10\n\tif value &gt;= num then\n\t\tconvert digit to petscii char\n\t\twrite petscii-char in 2nd digit\n\t\tsubtract num from value\n\t\tbreak out of for-loop\n\tendif\nendfor\nconvert value to petscii char\nwrite petscii-char in 3rd digit<\/code><\/pre>\n\n\n\n<p>In the hundred\u2019s we check for either 200 or 100 to see if we need to change the first zero to 2 or 1. For the ten\u2019s a loop is created that counts from 90 down to 10 and checks if we need to change the middle digit. Finally for the one\u2019s, we simply convert the remaining value to a writable char (i.e. add $30 to the value).<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>; **************************************************************\n; LVLtoPET\n; **************************************************************\n; Description:\tConvert value in byte to 3-digit decimal string\n; **************************************************************\n; Inputs:\t.lvl = Global variable containing a byte value\n;\t\t.lvltxt = Global variable containing string\n; **************************************************************\nLVLtoPET:\n\t; Local names to zero-page constant to make the code\n\t; a little more readable\n\t.value=<font color=\"blue\">$00<\/font>\n\t.digit=<font color=\"blue\">$01<\/font>\n\t.num=<font color=\"blue\">$02<\/font>\n\n\t<font color=\"orange\">lda<\/font>\t.lvl\t; Load Reg A with current level\n\n\t; Check if .lvl is &gt;= 200\n\t<font color=\"orange\">cmp<\/font>\t<font color=\"blue\">#200<\/font>\n\t<font color=\"orange\">bcc<\/font>\t.is100\t; branch to .is100 if .lvl &lt;200\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"red\">#'2'<\/font>\t; Write '2' to first digit of .lvltxt\n\t<font color=\"orange\">sty<\/font>\t.lvltxt\n\t<font color=\"orange\">sbc<\/font>\t<font color=\"blue\">#200<\/font>\t; Subtract 200 from .lvl\n\t<font color=\"orange\">beq<\/font>\t.allDone; If result = 0, we are done\n\t<font color=\"orange\">jmp<\/font>\t.Tens\t\n\t; Check if .lvl is &gt;= 100\n.is100:\n\t<font color=\"orange\">cmp<\/font>\t<font color=\"blue\">#100<\/font>\n\t<font color=\"orange\">bcc<\/font>\t.Tens\t; branch to .Tens if .lvl &lt; 100\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"red\">#'1'<\/font>\t; Write '1' to first digit of .lvltxt\n\t<font color=\"orange\">sty<\/font>\t.lvltxt\n\t<font color=\"orange\">sbc<\/font>\t<font color=\"blue\">#100<\/font>\t; Subtract 100 from .lvl\n\t<font color=\"orange\">beq<\/font>\t.allDone; If result = 0, we are done\n\t; Check if .lvl contains any tens (10-90)\n.Tens:\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#9<\/font>\n\t<font color=\"orange\">sty<\/font>\t.digit\t; Store digit in zero-page memory\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#90<\/font>\n\t<font color=\"orange\">sty<\/font>\t.num\t; Store digit*10 in zero-page memory\n.DoTens\n\t<font color=\"orange\">cmp<\/font>\t.num\n\t<font color=\"orange\">bcc<\/font>\t.Any10\t; branch to .Any10 if .lvl &lt; .num\n\n\t<font color=\"orange\">sta<\/font>\t.value\t; Save current value, we need the a reg\n\t<font color=\"orange\">lda<\/font>\t.digit\n\t<font color=\"orange\">clc<\/font>\t\t; Clear carry to ensure correct add\n\t<font color=\"orange\">adc<\/font>\t<font color=\"blue\">#$30<\/font>\t; Add $30 to digit to get petscii char\n\t<font color=\"orange\">sta<\/font>\t.lvltxt+<font color=\"blue\">1<\/font>;Write digit to 2nd space of .lvltxt\n\n\t<font color=\"orange\">lda<\/font>\t.value\t; Restore value into A register\n\t<font color=\"orange\">sec<\/font>\t\t; Set carry to ensure correct subtraction\n\t<font color=\"orange\">sbc<\/font>\t.num\t; Subtract .num from current .value\n\t<font color=\"orange\">jmp<\/font>\t.Ones\n\n.Any10\t<font color=\"orange\">cmp<\/font>\t<font color=\"blue\">#10<\/font>\n\t<font color=\"orange\">bcc<\/font>\t.Ones\t; branch to .Ones if A &lt; 10\n\t; subtract 10 from .value\n\t<font color=\"orange\">sta<\/font>\t.value\t; Save current value\n\t<font color=\"orange\">lda<\/font>\t.num\t; Subtract 10 from .number\n\t<font color=\"orange\">sec<\/font>\n\t<font color=\"orange\">sbc<\/font>\t<font color=\"blue\">#10<\/font>\n\t<font color=\"orange\">sta<\/font>\t.num\n\t<font color=\"orange\">lda<\/font>\t.value\t; Restore value into A register\n\t<font color=\"orange\">dec<\/font>\t.digit\n\t<font color=\"orange\">jmp<\/font>\t.DoTens\n.Ones:\n\t<font color=\"orange\">clc<\/font>\t\t; Clear carry to ensure correct add\n\t<font color=\"orange\">adc<\/font>\t<font color=\"blue\">#$30<\/font>\t; Add $30 to get petscii char\n\t<font color=\"orange\">sta<\/font>\t.lvltxt+<font color=\"blue\">2<\/font>;Write digit to 3rd space of .lvltxt\n.allDone:\n\t<font color=\"orange\">rts<\/font><\/code><\/pre>\n\n\n\n<p>This is, by far, the largest and most complicated helper-function yet. There might be a simpler way of doing it (I hope so) but I have not searched for it.<\/p>\n\n\n\n<p>Finally we have reached a point where we can actually start to get something written to the screen. Now it is just a question of deciding how the screen should look. At the time I was designing the screen layout for the game, I was unaware that it is possible to write to the bottom right without scrolling the entire screen <s>(See my note on&nbsp;<strong>Line to scroll on<\/strong>&nbsp;on the&nbsp;<a href=\"https:\/\/web.archive.org\/web\/20230320193441\/https:\/\/techblog.dansbo.dk\/?page_id=38\" target=\"_blank\" rel=\"noreferrer noopener\">Programming Ramblings<\/a>&nbsp;page)<\/s>. For this reason I am clearing the screen with a black background and creating a frame that sits 1 char in from the border all the way around. This reduces the area for the actual mazes, but there is still plenty of space for some fairly complex mazes.<\/p>\n\n\n\n<p>The InitSCR function initializes the screen to 40\u00d730 mode. It creates the area that will contain the mazes, level information and a bit of helpful information on how to play the game. The function depends on the following global constants.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>CHROUT=<font color=\"blue\">$FFD2<\/font>\t; CHROUT outputs a character (C64 KERNAL API)\nSWAPPER=<font color=\"blue\">$FF5F<\/font>\t; Switches between 80x60 and 40x30 modes\nCOLPORT=<font color=\"blue\">$0286<\/font>\t; This address contains foreground and\n\t\t; background colors\nWall=<font color=\"blue\">113<\/font>\t; PETSCII circle\nWallCol=<font color=\"blue\">$0B<\/font>\t; Black\/Darkgray\nSpace=<font color=\"red\">' '<\/font>\t; Char used for spaces<\/code><\/pre>\n\n\n\n<p>NOTE: SWAPPER is now called SCRMOD and is a new KERNAL function for the CX16 instead of an old function from C128. This means that these examples are no longer working. See the&nbsp;<a href=\"https:\/\/github.com\/x16Community\/x16-docs\/\" target=\"_blank\" rel=\"noreferrer noopener\">CX16 Programmers reference<\/a>&nbsp;for using SCRMOD<\/p>\n\n\n\n<p>The following global variables are used by the function.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>.lvl\t\t!byte\t<font color=\"blue\">1<\/font>\n.title\t\t!pet\t<font color=\"red\">\"cx16-maze\"<\/font>,<font color=\"blue\">0<\/font>\n.helptxt\t!pet\t<font color=\"red\">\"w,a,s,d=move spc=next r=reset q=quit\"<\/font>,<font color=\"blue\">0<\/font>\n.lvlstr\t\t!pet\t<font color=\"red\">\"lvl:\"<\/font>,<font color=\"blue\">0<\/font>\n.lvltxt\t\t!pet\t<font color=\"red\">\"000\"<\/font>,<font color=\"blue\">0<\/font><\/code><\/pre>\n\n\n\n<p>And finally for the function it self. It makes use of the helper functions that have been explained previously so this function in it self is not very complex.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>; **************************************************************\n; Initializes the screen\n; **************************************************************\n; INPUTS:\tGloabl variables\n;\t\t\t.lvl\n;\t\t\t.title\n;\t\t\t.helptxt\n;\t\t\t.lvlstr\n;\t\t\t.lvltxt\n; **************************************************************\nInitSCR:\n\t<font color=\"orange\">lda<\/font>\t<font color=\"blue\">$D9<\/font>\t; $D9 contains the number of\n\t\t\t; columns being shown\n\t<font color=\"orange\">cmp<\/font>\t<font color=\"blue\">#80<\/font>\t; if this is 80, we will switch to 40x30\n\t<font color=\"orange\">beq<\/font>\t.SetIt\t; Set 40 column mode\n\t<font color=\"orange\">jmp<\/font>\t.NoSet\n.SetIt:\n\t<font color=\"orange\">jsr<\/font>\tSWAPPER\t; Switch screenmode\n.NoSet:\n\t<font color=\"orange\">lda<\/font>\t<font color=\"blue\">#$01<\/font>\t; Black background, white text\n\t<font color=\"orange\">sta<\/font>\tCOLPORT\t; Set Color\n\t\n\t<font color=\"orange\">lda<\/font>\t<font color=\"blue\">#147<\/font>\t; ClrHome\n\t<font color=\"orange\">jsr<\/font>\tCHROUT\t; Clear Screen\n\t<font color=\"orange\">lda<\/font>\t<font color=\"blue\">#$10<\/font>\t; White background, black text\n\t<font color=\"orange\">sta<\/font>\tCOLPORT\t; Set color\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#1<\/font>\t; Setup to create top horizontal line\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#1<\/font>\n\t<font color=\"orange\">jsr<\/font>\tGotoXY\n\t<font color=\"orange\">lda<\/font>\t#Space\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#38<\/font>\n\t<font color=\"orange\">jsr<\/font>\tHLine\t; Draw horizontal line\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#28<\/font>\t; Setup to create bottom horizontal line\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#1<\/font>\n\t<font color=\"orange\">jsr<\/font>\tGotoXY\n\t<font color=\"orange\">lda<\/font>\t#Space\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#38<\/font>\n\t<font color=\"orange\">jsr<\/font>\tHLine\t; Draw horizontal line\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#2<\/font>\t; Setup to create left most vertical line\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#1<\/font>\n\t<font color=\"orange\">jsr<\/font>\tGotoXY\n\t<font color=\"orange\">lda<\/font>\t#Space\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#26<\/font>\n\t<font color=\"orange\">jsr<\/font>\tVLine\t; Draw left most vertical line\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#2<\/font>\t; Setup to create right most vertical line\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#38<\/font>\n\t<font color=\"orange\">jsr<\/font>\tGotoXY\n\t<font color=\"orange\">lda<\/font>\t#Space\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#26<\/font>\n\t<font color=\"orange\">jsr<\/font>\tVLine\t; Draw right most vertical line\n\t<font color=\"orange\">lda<\/font>\t<font color=\"blue\">#$12<\/font>\t; Set color, white background, red text\n\t<font color=\"orange\">sta<\/font>\tCOLPORT\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#1<\/font>\t; Set up for title text\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#15<\/font>\n\t<font color=\"orange\">jsr<\/font>\tGotoXY\n\t<font color=\"orange\">ldx<\/font>\t#&lt;.title; Write the title text\n\t<font color=\"orange\">ldy<\/font>\t#&gt;.title\n\t<font color=\"orange\">jsr<\/font>\tPrintStr\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#1<\/font>\t; Set up for level text (top right corner)\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#31<\/font>\n\t<font color=\"orange\">jsr<\/font>\tGotoXY\n\t<font color=\"orange\">ldx<\/font>\t#&lt;.lvlstr; Write the level text\n\t<font color=\"orange\">ldy<\/font>\t#&gt;.lvlstr\n\t<font color=\"orange\">jsr<\/font>\tPrintStr\n\t<font color=\"orange\">jsr<\/font>\tLVLtoPET ; Create level as a petscii string\n\t<font color=\"orange\">ldx<\/font>\t#&lt;.lvltxt\n\t<font color=\"orange\">ldy<\/font>\t#&gt;.lvltxt\n\t<font color=\"orange\">jsr<\/font>\tPrintStr\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#2<\/font>\t; Set up for help text (bottom line)\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#28<\/font>\n\t<font color=\"orange\">jsr<\/font>\tGotoXY\n\t<font color=\"orange\">ldx<\/font>\t#&lt;.helptxt; Write help text\n\t<font color=\"orange\">ldy<\/font>\t#&gt;.helptxt\n\t<font color=\"orange\">jsr<\/font>\tPrintStr\n\t<font color=\"orange\">jsr<\/font>\tFillGA\n\t<font color=\"orange\">rts<\/font><\/font><\/font><\/code><\/pre>\n\n\n\n<p>NOTE: First line of above function is not correct. $D9 no longer contains the number of columns, instead it can be found on address $02AE. As mentioned in previous note. SWAPPER no longer exists and is now SCRMOD.<\/p>\n\n\n\n<p>As you might have noticed, the last line before the rts is actually a call to another helper function that I have not yet described.<\/p>\n\n\n\n<p>FillGA is a function, who\u2019s only function is to fill the center of the screen, the area within the white border, with \u201cwall\u201d characters. It does this by creating horizontal lines of the \u201cwall\u201d character.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>; **************************************************************\n; Fill the \"gamearea\" with \"wall tiles\"\n; **************************************************************\n; INPUTS:\tGlobal constant WallCol is used.\n; **************************************************************\nFillGA:\n\t<font color=\"orange\">lda<\/font>\t#WallCol\t; Set background and foreground\n\t<font color=\"orange\">sta<\/font>\tCOLPORT\t\t; color\n\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#1<\/font>\t\t; X register holds Y coordinate\n\n.StartOfFill:\n\t<font color=\"orange\">inx<\/font>\t\t\t; Increment Y coordinate\n\t<font color=\"orange\">stx<\/font>\tTMP0\t\t; Save the Y coordinate in ZP\n\t<font color=\"orange\">cpx<\/font>\t<font color=\"blue\">#28<\/font>\t\t; If we have reached line 28,\n\t<font color=\"orange\">beq<\/font>\t.EndOfFill\t; We are done, so branch to end\n\t<font color=\"orange\">ldy<\/font>\t<font color=\"blue\">#2<\/font>\t\t; Y register holds X coordinate\n\t<font color=\"orange\">jsr<\/font>\tGotoXY\t\t; Place cursor at X, Y coordinates\n\t<font color=\"orange\">lda<\/font>\t#Wall\t\t; Load A with 'wall' character\n\t<font color=\"orange\">ldx<\/font>\t<font color=\"blue\">#36<\/font>\t\t; Create a horizontal line that is\n\t<font color=\"orange\">jsr<\/font>\tHLine\t\t; 36 characters wide\n\t<font color=\"orange\">ldx<\/font>\tTMP0\t\t; Restore Y coordinate from ZP\n\t<font color=\"orange\">jmp<\/font>\t.StartOfFill\n.EndOfFill\n\t<font color=\"orange\">rts<\/font><\/code><\/pre>\n\n\n\n<p>Now with the last helper function in place, the initial screen should look something like this:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"788\" src=\"https:\/\/techblog.dansbo.dk\/wp-content\/uploads\/2024\/01\/cx16-initial-screen-1024x788.jpg\" alt=\"\" class=\"wp-image-44\" srcset=\"https:\/\/techblog.dansbo.dk\/wp-content\/uploads\/2024\/01\/cx16-initial-screen-1024x788.jpg 1024w, https:\/\/techblog.dansbo.dk\/wp-content\/uploads\/2024\/01\/cx16-initial-screen-300x231.jpg 300w, https:\/\/techblog.dansbo.dk\/wp-content\/uploads\/2024\/01\/cx16-initial-screen-768x591.jpg 768w, https:\/\/techblog.dansbo.dk\/wp-content\/uploads\/2024\/01\/cx16-initial-screen.jpg 1280w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Next up: Defining the mazes and getting them drawn on the screen and possibly getting started with some \u201canimation\u201d. Stay tuned for\u00a0<a href=\"https:\/\/techblog.dansbo.dk\/?p=47\">part 3<\/a>.<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Continuing from&nbsp;part 1&nbsp;where I created 3 small functions: GotoXY, HLine and VLine. I am going to create a couple more \u201chelper\u201d functions as well as the function that will initialize&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-43","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=\/wp\/v2\/posts\/43","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=43"}],"version-history":[{"count":3,"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=\/wp\/v2\/posts\/43\/revisions"}],"predecessor-version":[{"id":108,"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=\/wp\/v2\/posts\/43\/revisions\/108"}],"wp:attachment":[{"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=43"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=43"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/techblog.dansbo.dk\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=43"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}