{"id":405,"date":"2026-08-22T20:37:16","date_gmt":"2026-08-22T20:37:16","guid":{"rendered":"https:\/\/blogs.scummvm.org\/mohit\/?p=405"},"modified":"2026-08-22T20:40:29","modified_gmt":"2026-08-22T20:40:29","slug":"dm-dos","status":"publish","type":"post","link":"https:\/\/blogs.scummvm.org\/mohit\/2026\/08\/22\/dm-dos\/","title":{"rendered":"Dungeon Master: The DOS Version"},"content":{"rendered":"<p>Hi everyone, welcome back. This blog covers the code changes made to the DM engine to add support for the DOS version. The previous changes were covered up to this <a href=\"https:\/\/blogs.scummvm.org\/mohit\/2026\/07\/21\/week-8\/\">blog<\/a>. And, I apologize for the lack of screenshots this time \u2014 I was implementing and fixing so many things simultaneously that I forgot to capture before\/after comparisons, so there won&#8217;t be as many visuals as usual.<\/p>\n<h5><span style=\"color: #993366\"><strong>Right-Side Wall &amp; Door Frame Graphics<\/strong><\/span><\/h5>\n<p>In the dungeon view, door frames and side walls on the right side of the hallway rendered distorted or clipped, because horizontal pixel flipping routines were calculating sizes using Amiga graphic indices instead of DOS ones.<\/p>\n<p>Updated\u00a0<code class=\"whitespace-pre-wrap\">loadWallSet()<\/code>\u00a0to map platform-aware graphic database indices (<code class=\"whitespace-pre-wrap\">k86_FirstWallSetDOS<\/code>\u00a0starting at index 86 for DOS, compared to index 77 for Amiga). This ensures\u00a0<code class=\"whitespace-pre-wrap\">copyBitmapAndFlipHorizontal()<\/code>\u00a0fetches the exact pixel width and height of DOS left-side wall assets when creating their mirrored right-side counterparts.<\/p>\n<h5 id=\"user-content-item-1-fixing-garbled-item-names-in-status-log\"><span style=\"color: #993366\"><strong>Garbled Item Names in Status<\/strong><\/span><\/h5>\n<p>Examining or picking up weapons, potions, and dungeon items displayed garbled text in the status message area.<\/p>\n<p>On Amiga, item name strings in the data file were terminated using High-Bit encoding (where the last character had its 7th bit set, e.g.\u00a0<code class=\"whitespace-pre-wrap\">char | 0x80<\/code>). In the DOS version, string entries were updated to standard null-terminated strings (<code class=\"whitespace-pre-wrap\">'\\0'<\/code>). Updated\u00a0<code class=\"whitespace-pre-wrap\">loadObjectNames()<\/code>\u00a0to check for\u00a0<code class=\"whitespace-pre-wrap\">kPlatformDOS<\/code>\u00a0and read characters until encountering\u00a0<code class=\"whitespace-pre-wrap\">\\0<\/code>, restoring clean item names in the UI log.<\/p>\n<h5><span style=\"color: #993366\">Corrupted <\/span><span style=\"color: #993366\"><strong>Wall &amp; Door Frames<\/strong><\/span><\/h5>\n<p>Drawing dungeon wall panels and door frames resulted in torn graphics or crashes during rendering transitions.<\/p>\n<p>The pixel-copying routine\u00a0<code class=\"whitespace-pre-wrap\">blitToBitmap()<\/code>\u00a0calculated memory offsets using fixed Amiga buffer strides (<code class=\"whitespace-pre-wrap\">srcByteWidth * 2<\/code>). Because DOS standalone graphics have different widths and heights, calculating offsets using Amiga strides led to reading pixels from incorrect memory addresses. Added\u00a0<code class=\"whitespace-pre-wrap\">getBitmapDimensions()<\/code>\u00a0to dynamically look up the true pixel dimensions for each DOS wall and door buffer (<code class=\"whitespace-pre-wrap\">_bitmapWallSetD3LCR<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">_bitmapWallSetDoorFrameFront<\/code>, etc.), ensuring accurate pixel placement and preventing out-of-bounds reads.<\/p>\n<p>Loading into dungeon levels still caused heap memory corruption crashes. While the previous fixes ensured pixel coordinates were calculated correctly, the memory buffers holding those flipped wall images were still allocated using hardcoded Amiga dimensions.<\/p>\n<p>On Amiga, memory for flipped wall surfaces was allocated using fixed array sizes (like\u00a0<code class=\"whitespace-pre-wrap\">128 * 51<\/code>\u00a0for D3 walls or\u00a0<code class=\"whitespace-pre-wrap\">144 * 71<\/code>\u00a0for D2 walls). Because DOS standalone wall graphics are larger and have different pixel dimensions, flipping them into Amiga-sized buffers wrote pixels past the end of the allocated memory array.<\/p>\n<p>Updated <code class=\"whitespace-pre-wrap\">allocateFlippedWallBitmaps()<\/code>\u00a0to use\u00a0<code class=\"whitespace-pre-wrap\">getPixelWidth(index) * getPixelHeight(index)<\/code>\u00a0for all such buffer allocations, dynamically sizing the DOS wall buffers and preventing memory overflows.<\/p>\n<h5><span style=\"color: #993366\">Missing Fonts and Corrupted Graphics<\/span><\/h5>\n<p>Text in the UI (spell names, character stats, dialogs) was completely invisible or rendered as garbage pixels, and higher-level graphics assets failed to load.<\/p>\n<p>The original unpacking loop stopped at index 532 (the Amiga limit). Updated\u00a0<code class=\"whitespace-pre-wrap\">unpackGraphics()<\/code>\u00a0to dynamically unpack up to index\u00a0<strong>670<\/strong>\u00a0for DOS, ensuring all extended DOS graphics assets are decompressed into memory.<\/p>\n<h5><span style=\"color: #993366\"><strong>Mapping DOS Graphic Database Indices Across the Engine<\/strong><\/span><\/h5>\n<p>Monsters, spells, items, wall ornaments, doors, and explosions all rendered as wrong or glitched. \u00a0In the DOS version, graphic asset positions inside the graphic file were shifted significantly compared to Amiga.<\/p>\n<p>Upgraded the previous\u00a0<code class=\"whitespace-pre-wrap\">getFontIndex()<\/code>\u00a0helper into a universal\u00a0<code class=\"whitespace-pre-wrap\">getGraphicIndex(index)<\/code>\u00a0method in\u00a0<code class=\"whitespace-pre-wrap\">DisplayMan<\/code> to dynamically map all core game graphic offsets for DOS vs Amiga.<\/p>\n<h5><span style=\"color: #993366\">Adding Sound<\/span><\/h5>\n<p>Added\u00a0<code class=\"whitespace-pre-wrap\">soundsDOS<\/code>\u00a0table in\u00a0<code class=\"whitespace-pre-wrap\">SoundMan::initConstants()<\/code>. On DOS, raw sound samples start at graphic index\u00a0<strong>671<\/strong>\u00a0(<code class=\"whitespace-pre-wrap\">k671_MetallicThud<\/code>) up to\u00a0<strong>712<\/strong>\u00a0(<code class=\"whitespace-pre-wrap\">k712_MoveSkeleton<\/code>), compared to indices 533\u2013574 on Amiga.<\/p>\n<h4><span style=\"color: #993366\"><strong>Solving the Wall Atlas Problem<\/strong><\/span><\/h4>\n<p>On Amiga, left, center, and right walls for a given distance were stitched into a single wide atlas image (<code class=\"whitespace-pre-wrap\">D3LCR<\/code>). On DOS, however, left and right walls became standalone, tightly cropped images (<code class=\"whitespace-pre-wrap\">D3L<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">D3R<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">D2L<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">D2R<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">D1L<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">D1R<\/code>). Because the engine was trying to crop side walls out of the center-only DOS atlas, side walls appeared corrupted, torn, or completely blank.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-417\" src=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00000-1-1024x535.png\" alt=\"\" width=\"580\" height=\"303\" srcset=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00000-1-1024x535.png 1024w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00000-1-300x157.png 300w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00000-1-768x401.png 768w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00000-1-1200x627.png 1200w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00000-1.png 1413w\" sizes=\"auto, (max-width: 580px) 100vw, 580px\" \/> <img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-418\" src=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00001-1-1024x525.png\" alt=\"\" width=\"580\" height=\"297\" srcset=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00001-1-1024x525.png 1024w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00001-1-300x154.png 300w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00001-1-768x394.png 768w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00001-1-1200x616.png 1200w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00001-1.png 1415w\" sizes=\"auto, (max-width: 580px) 100vw, 580px\" \/><\/p>\n<p>Declared standalone bitmap buffers for DOS side walls: <code class=\"whitespace-pre-wrap\">_bitmapWallSetD1L<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">_bitmapWallSetD1R<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">_bitmapWallSetD2L<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">_bitmapWallSetD2R<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">_bitmapWallSetD3L<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">_bitmapWallSetD3R<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">_bitmapWallSetD2L2<\/code>, and\u00a0<code class=\"whitespace-pre-wrap\">_bitmapWallSetD2R2<\/code>.<\/p>\n<p>Updated <code class=\"whitespace-pre-wrap\">loadWallSet()<\/code>\u00a0for\u00a0<code class=\"whitespace-pre-wrap\">kPlatformDOS<\/code>\u00a0to load all 40 graphic items per wall set starting at index 86, populating every standalone left and right wall image buffer into memory.<\/p>\n<p>Updated individual wall drawing methods (like <code>drawSquareD3L<\/code>) to select the new standalone DOS wall bitmap.<\/p>\n<h4><span style=\"color: #993366\"><strong>Implementing the DOS Layout Tree Engine<\/strong><\/span><\/h4>\n<p>The DOS version abandoned fixed coordinate tables for drawing UI zones and dungeon elements, moving to a data-driven hierarchy tree where graphics dynamically calculate positions relative to parent containers.<\/p>\n<p>Implemented the core DOS layout engine (<code class=\"whitespace-pre-wrap\">getCoord<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">getLayoutRecord<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">getZoneBox<\/code>) to parse layout records from Graphic 696 and recursively compute dynamic X\/Y offsets, width, height, and clipping boundaries for all viewport and UI elements.<\/p>\n<h5><span style=\"color: #993366\"><strong>Integrating the DOS Layout Engine<\/strong><\/span><\/h5>\n<p>Even after loading the correct standalone wall graphics into memory, the dungeon walls on DOS were still completely misplaced, overlapping, or rendering at wrong depths on screen. This happened because the wall drawing routines were still using hardcoded Amiga screen coordinate tables (<code class=\"whitespace-pre-wrap\">Frame<\/code>) instead of calculating dynamic offsets for DOS.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-419\" src=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00002-1-1024x528.png\" alt=\"\" width=\"580\" height=\"299\" srcset=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00002-1-1024x528.png 1024w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00002-1-300x155.png 300w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00002-1-768x396.png 768w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00002-1-1200x619.png 1200w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00002-1.png 1385w\" sizes=\"auto, (max-width: 580px) 100vw, 580px\" \/> <img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-420\" src=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00003-1-1024x519.png\" alt=\"\" width=\"580\" height=\"294\" srcset=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00003-1-1024x519.png 1024w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00003-1-300x152.png 300w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00003-1-768x390.png 768w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00003-1-1200x609.png 1200w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00003-1.png 1396w\" sizes=\"auto, (max-width: 580px) 100vw, 580px\" \/><\/p>\n<p>Implemented\u00a0<code class=\"whitespace-pre-wrap\">drawWallSetBitmapDOS()<\/code>\u00a0to query the layout engine (<code class=\"whitespace-pre-wrap\">getCoord<\/code>) for each wall zone (<code class=\"whitespace-pre-wrap\">kDMZoneWallD3L2<\/code>\u00a0through\u00a0<code class=\"whitespace-pre-wrap\">kDMZoneWallD0R<\/code>). This dynamically calculates screen coordinates, width, height, and clipping boundaries for every wall.<\/p>\n<p>Integrated\u00a0<code class=\"whitespace-pre-wrap\">drawWallSetBitmapDOS()<\/code>\u00a0into all dungeon square drawing routines (<code class=\"whitespace-pre-wrap\">drawSquareD3L<\/code>\u00a0through\u00a0<code class=\"whitespace-pre-wrap\">drawSquareD0C<\/code>). This immediately aligned all dungeon walls across all distances (D0 to D4), bringing the DOS 3D dungeon view to life!<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-421\" src=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00004-1-1024x524.png\" alt=\"\" width=\"580\" height=\"297\" srcset=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00004-1-1024x524.png 1024w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00004-1-300x153.png 300w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00004-1-768x393.png 768w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00004-1-1200x614.png 1200w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00004-1.png 1394w\" sizes=\"auto, (max-width: 580px) 100vw, 580px\" \/><\/p>\n<h5><span style=\"color: #993366\"><strong>Fixing Spell Casting Panel Positioning &amp; Rune Rendering<\/strong><\/span><\/h5>\n<p>Selecting a champion to cast spells displayed the rune symbols and spell panel box misaligned or with black rectangle boxes drawn over the UI background.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-large wp-image-424\" src=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00005-1024x650.png\" alt=\"\" width=\"580\" height=\"368\" srcset=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00005-1024x650.png 1024w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00005-300x190.png 300w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00005-768x487.png 768w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00005-1200x761.png 1200w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00005.png 1392w\" sizes=\"auto, (max-width: 580px) 100vw, 580px\" \/><\/p>\n<p>Used the Layout Tree, placing the spell background box at its exact DOS coordinates.<\/p>\n<p>Updated rune symbol rendering in\u00a0<code class=\"whitespace-pre-wrap\">drawAvailableSymbols()<\/code>\u00a0and\u00a0<code class=\"whitespace-pre-wrap\">drawChampionSymbols()<\/code>\u00a0to pass\u00a0<code class=\"whitespace-pre-wrap\">kDMColorNoTransparency<\/code>\u00a0for DOS instead of\u00a0<code class=\"whitespace-pre-wrap\">kDMColorBlack<\/code>, preventing solid black boxes from obscuring the spell panel texture.<\/p>\n<h5><span style=\"color: #993366\"><strong>Corruption When Scaling Distant Ornaments (D2\/D3)<\/strong><\/span><\/h5>\n<p>Wall ornaments (alcoves, keyholes, lever slots, wall rings) and door buttons seen at a distance (Depth D2 and D3) appeared scrambled, stretched, or corrupted.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-425 alignnone\" src=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00006.png\" alt=\"\" width=\"577\" height=\"424\" srcset=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00006.png 969w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00006-300x220.png 300w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00006-768x564.png 768w\" sizes=\"auto, (max-width: 577px) 100vw, 577px\" \/> <img loading=\"lazy\" decoding=\"async\" class=\"size-large wp-image-426 alignnone\" src=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00007.png\" alt=\"\" width=\"580\" height=\"421\" srcset=\"https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00007.png 977w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00007-300x218.png 300w, https:\/\/blogs.scummvm.org\/mohit\/wp-content\/uploads\/sites\/82\/2026\/08\/scummvm-dm-00007-768x558.png 768w\" sizes=\"auto, (max-width: 580px) 100vw, 580px\" \/><\/p>\n<p>When downscaling distant ornaments and door buttons to fit smaller wall views at depths D2 and D3,\u00a0<code class=\"whitespace-pre-wrap\">blitToBitmapShrinkWithPalChange()<\/code>\u00a0was passing source dimensions hardcoded from Amiga coordinate tables (<code class=\"whitespace-pre-wrap\">coordSetBlueGoat[4] &lt;&lt; 1<\/code>).<\/p>\n<p>Updated\u00a0<code class=\"whitespace-pre-wrap\">drawDoorButton()<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">drawDoorOrnament()<\/code>, and\u00a0<code class=\"whitespace-pre-wrap\">isDrawnWallOrnAnAlcove()<\/code> to look up raw DOS asset dimensions.<\/p>\n<h5><span style=\"color: #993366\"><strong>Mapping DOS Item Names Resource Index<\/strong><\/span><\/h5>\n<p>Despite handling string decoding earlier, item names (like <code class=\"whitespace-pre-wrap\">\"Torch\"<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">\"Screamer Slice\"<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">\"Torch (out)\"<\/code>) were reading from the wrong asset offset in the graphics archive on DOS, displaying unrelated bytes instead of item names.<\/p>\n<p>Updated\u00a0<code class=\"whitespace-pre-wrap\">getGraphicIndex()<\/code>\u00a0to map\u00a0<code class=\"whitespace-pre-wrap\">kDMObjectNamesGraphicIndice<\/code>\u00a0(556) to\u00a0<strong>694<\/strong> for DOS.<\/p>\n<h5><span style=\"color: #993366\"><strong>Fixing Item &amp; Floor Ornament Corruption on D1 Tiles<\/strong><\/span><\/h5>\n<p>Items lying on the floor (swords, keys, chests) or floor ornaments (pressure plates, floor grates) on the square directly in front of the player (D1) rendered as torn graphics.<\/p>\n<p>Updated\u00a0<code class=\"whitespace-pre-wrap\">drawFloorOrnament<\/code>,\u00a0<code class=\"whitespace-pre-wrap\">drawFloorPitOrStairsBitmap<\/code>, and\u00a0<code class=\"whitespace-pre-wrap\">T0115015_DrawProjectileAsObject<\/code>\u00a0to look up raw DOS asset dimensions using\u00a0<code class=\"whitespace-pre-wrap\">getPixelWidth()<\/code>\u00a0and\u00a0<code class=\"whitespace-pre-wrap\">getPixelHeight()<\/code>\u00a0instead of Amiga aspect table offsets.<\/p>\n<h5><span style=\"color: #993366\">Alternate Endgame Sequence Not Triggering<\/span><\/h5>\n<p>Stepping on the floor sensor at Level 0 while holding the completed Firestaff failed to trigger the alternate endgame sequence.<\/p>\n<p>Updated\u00a0<code class=\"whitespace-pre-wrap\">processThingAdditionOrRemoval()<\/code>\u00a0sensor version check from\u00a0<code class=\"whitespace-pre-wrap\">&lt;= 20<\/code>\u00a0to\u00a0<code class=\"whitespace-pre-wrap\">&lt;= 21<\/code>\u00a0to match the DOS engine version, allowing entrance sensor triggers to fire correctly.<\/p>\n<p>Updated\u00a0<code class=\"whitespace-pre-wrap\">isObjectInPartyPossession()<\/code>\u00a0to treat both raw (<code class=\"whitespace-pre-wrap\">kDMIconIndiceWeaponTheFirestaff<\/code>) and completed (<code class=\"whitespace-pre-wrap\">kDMIconIndiceWeaponTheFirestaffComplete<\/code>) Firestaff states as valid matches, including when stored inside carried chests.<\/p>\n<p>&nbsp;<\/p>\n<p>Along with these, there were many other small changes that are self-explanatory in the commits. You can find all the changes made to support the DOS version in this single PR <a href=\"https:\/\/github.com\/scummvm\/scummvm\/pull\/7777\">7777<\/a>. Since the PR number is a lucky 7777, I hope the DOS version brings good fortune and fewer bug reports \ud83d\ude04<\/p>\n<p>So that was it for the DOS version of the DM engine. With that, ScummVM now supports both the Amiga and DOS versions of Dungeon Master.<\/p>\n<p>Thank you for reading. See you in the next one \u2014 the final GSoC blog!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Hi everyone, welcome back. This blog covers the code changes made to the DM engine to add support for the DOS version. The previous changes were covered up to this blog. And, I apologize for the lack of screenshots this time \u2014 I was implementing and fixing so many things simultaneously that I forgot to [&hellip;]<\/p>\n","protected":false},"author":30,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19],"tags":[],"class_list":["post-405","post","type-post","status-publish","format-standard","hentry","category-dm-engine"],"_links":{"self":[{"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/posts\/405","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/users\/30"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/comments?post=405"}],"version-history":[{"count":22,"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/posts\/405\/revisions"}],"predecessor-version":[{"id":437,"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/posts\/405\/revisions\/437"}],"wp:attachment":[{"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/media?parent=405"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/categories?post=405"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.scummvm.org\/mohit\/wp-json\/wp\/v2\/tags?post=405"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}