Guest DILDOMASTER666 Posted February 15, 2018 (edited) WindowCaster is, to my knowledge, the first attempt to create a Windows-native port of Shadowcaster. It is built with Game Maker: Studio and the objective is, upon 1.0 release, to read all game data from their associated archives and externalize as much of the game code as possible to human-readable files. If this is insufficient for the user to create their mod of choice, then a project source file containing the entire engine will be made available at a later date, allowing for complete and fundamental modification of the game in every way. Release Timeline: Currently: map editor. a few gameplay elements, but there is still a long way to go. Next release: more gameplay elements and expanding the editor. Screenshots: Spoiler Current features: Functions as a Shadowcaster level viewer Renders the game at up to 2560x1080 From-scratch Direct3D renderer Functional player morphing (use the number keys) Mouse- or keyboard-based navigation controls Easily portable to other platforms (courtesy of Game Maker) OGG music support Externally scripted PK3 mod loading support map editor Planned features: in-engine level and resource editor externalized scripts for most of the game and engine code the ability to statically link a mod to the executable at compile-time (create your own games using the engine) full support for Shadowcaster 1.12F (floppy version) and Shadowcaster 1.01F (CD version) Downloads: version 0.25-PRE-7 (current) Source Code OPL Music Pack WindowCaster Example Mod Historical versions: version 0.25-PRE-5 version 0.25-PRE-3 version 0.25-PRE-2 version 0.20.5132 version 0.10.2b0e version 0.10.0459 version 0.10.8636 version 5a85bbad version 5a856963 version 5a85151f Changelog: Spoiler ver. 0.25-PRE-7 to ver.0.25-PRE-4: * these were mostly debugging releases released over Discord and to certain specific people to test the map editor functionality. * various small backend improvements to support the editor. + added map editor. ver. 0.25-PRE-3: * modified the way internal .dat textures are handled to support transparent pixels (for doors, cobwebs, etc) + *.dor files are loaded. this is preliminary, the format is not completely known at this time. the doors themselves can be used, but have no lock information, so you can just open every door in the game for now... including ones you aren't supposed to, like cobwebs. + added positional audio playback. you can test this by opening doors. + added support for GZDoom-style dynamic lights. this feature is disabled by default(the macro "R_ENABLE_LIGHTING" toggles this). + added support for global directional lighting, which simulates Doom's "fake contrast" on walls of different angles. the resulting effect is like ZDoom's "smoothlighting" option. this is also disabled by default, togglable with R_ENABLE_LIGHTING. ver. 0.25-PRE-2: * first open-source release. + added back music playback support and exposed the appropriate key for mapinfo to define which song to play on each map. + added support for reading two types of graphic lumps from RAVDATA.DAT (for walls and flats). ver. 0.25-PRE-1: * internal debug release. - due to the extreme changes to the way textures are handled, animated textures and flats have been temporarily disabled. ver. 0.20.5132: * completely rewrote the entire map loading code so that it can be more easily modded. this constitutes a refactor of something like 30% of the entire codebase. + added tile definition support. + added mapinfo support. - temporarily removed music playback in maps (involves a mapinfo bug). ver. 0.10.2b0e: * physics were finally fixed. it was technically "working" in pre-0.10 but had to be rewritten from scratch once the internal map "format" changed for the 100th time and became more or less final. + added mouselook. + finally finished the audio support mentioned in 5a85151f's log. + added preliminary mod support. Currently, the only things exported are the music and the floor tileid script. more will be exported from the engine in future versions. ver. 0.10.0459: * fixed a pretty major surface cache issue with 0.10.8636 that could cause considerable memory leaks if you changed the screen size more than once. * fixed a related but different, less critical issue with the surface cache: in 8636, the game would only render at 640x400 and upscale. now the game should accurately determine the internal resolution to render at. ver. 0.10.8636: proof of concept release. * most of the work in this version has gone into renderer backend improvements and the expansion of CA_ConstructMapDebug. as of now there is only one level in the floppy version that decodes into memory incorrectly. investigating a fix for that. in the mean time, while all levels from the floppy version are now accessible, most tile definitions do not exist yet so they will be broken. * the rendersurface is now managed in a much cleaner way, so i enabled screen resizing. the game will not run in fullscreen yet, but you can resize the game window to any size. it will try to keep the game aspect ratio consistent for you, letterboxing where appropriate. ver. 5a85bbad: * vastly expanded upon CA_ConstructMapDebug. it's still a long way from done, but you can visit all levels from the floppy version now. please do not try the cd version yet, as ConstructMapDebug still relies on raw offsets into the lib file. * preliminary mapping of cellcontent objects to tileids. ruinsa, ruinsb, and ruinbwat are just about done, and vestetst has some limited mappings so you can at least look at it, sort of. + cell ceiling rendering. there are no mapped objects that use it yet. + in ver. 5a856963, i forgot to mention that for now, all graphics are statically linked to the executable. - removed some unused data from the executable.ver. 5a856963: * upturned the renderer and did a lot of back-end work. it should now more closely resemble the original game's rendering. + you can now, in theory, load any level from Shadowcaster. however, since lots of tile definitions are still missing, only ruinsa and ruinsb are accessible. - made ruinbwat inaccessible. for now. ver. 5a85151f: * completely rewrote the collision detection from scratch. it is now objectively 200,000 times better than the old code. + preliminary audio support. not finished and not accessible now. + maps can be loaded via CA_ConstructMapDebug(), if you know the offset to the map file in the lib. + morphing works, but not all forms are accessible right now. you can currently change to human, Maorin, Caun, Opsis, and Kahpa. - got rid of the old map data that was statically-linked in the exe. as above, the game now reads maps directly from the libs and creates cell content instances as necessary. Known bugs: the in-game pause menu is bugged badly. sometimes doors are loaded from user maps in such a way that they may crash the game when viewed. by morphing at specific times, the player can clip through the ceiling in some levels. Edited June 27, 2018 by DILDOMASTER666 new version available, source code update 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted February 15, 2018 Version 5a856963 is now available. Download is in the first post, where you can check the text file for a detailed changelog and all the controls you'll need to play around. 0 Quote Share this post Link to post
KVELLER Posted February 15, 2018 I've never played Shadowcaster, but this might end up being my first experience with the game, at least when a full release comes out. 2 Quote Share this post Link to post
Arno Posted February 15, 2018 Thanks for offering an eary peek at your source port. I just gave it a try and walked around the two maps for a while. Without sprites and sounds, there is obviously hardly any gameplay going on. Nevertheless, I think it is still quite an accomplishment to be able to render these maps natively under Windows without having any access to the original source code. I didn't find an option to resize the window or to go full screen. Is such a feature in the plans? 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted February 16, 2018 It would be very easy to add such a feature, yes. I just didn't worry about it very much since it's in such an otherwise early state. I'll add window resizing for next release. 0 Quote Share this post Link to post
Arno Posted February 16, 2018 13 hours ago, DILDOMASTER666 said: I'll add window resizing for next release. Great, thanks! I fully understand that in this early stage window resizing is not a must-have among the dozens and dozens of other functionality/features that could be added. It's just that on my laptop screen the game window has roughly the size of a postcard, which triggered the question. I'm looking forward to seeing more of this source port in the future. Good luck! 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted February 17, 2018 8 hours ago, Arno said: I fully understand that in this early stage window resizing is not a must-have among the dozens and dozens of other functionality/features that could be added Seems pretty useful to me. ;) New version added with view resizing support. You can now visit every level from the floppy version, though most tilemap ids are not yet mapped to GM objects, so while every level (except one) loads correctly, they aren't very interesting to look at just yet. A few have all their walls and flats mapped correctly. The proof of concept is there; I just need to do the hard work of poking around with the "X" command and figuring out all the tileids. 0 Quote Share this post Link to post
Arno Posted February 17, 2018 (edited) Nice to see the world of Shadowcaster coming alive bit by bit. With a crispier image than ever before, due to the higher screen resolution. Edited February 17, 2018 by Arno 2 Quote Share this post Link to post
Guest DILDOMASTER666 Posted February 18, 2018 There were some serious issues with the surface management of the previous version, which manifested two bugs: the game would eat up unreasonable amounts of memory (2+ GB in the worst instances) in certain instances, and the game always defaulted to 640x400 internal resolution. This is no longer the case with 0.10.0459. Since this is a critical issue, I uploaded a new version ahead of schedule (I wanted the next release to be able to view all levels correctly). As a slight bonus, a lot more cell ids are known, so more levels -- but not all of them -- will load and render mostly properly. 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted February 19, 2018 (edited) The first post has been updated with a new version. The engine is now scriptable with external files, which may be stored in pk3s like ZDoom. Additionally, OGG music support is back and as an added bonus, it can be included in a mod pk3 too. To this end, I have uploaded an example mod to show how this is done, and an OGG music pack which you should either rename to "mod.pk3" or place the raw folder in your WindowCaster appdata directory to enable. EDIT: Regarding the next release, I am looking into exporting the wall and ceiling databases to the pk3s as well as the WindowCaster equivalent of "mapinfo". The script interpreter is very slow though, so don't expect the entire game to eventually be exported - what I export to scripts will depend on how much of a performance impact doing so would incur. Edited February 19, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
MrFlibble Posted February 21, 2018 Robert W. Morgan III, one of the developers of In Pursuit of Greed, suggested that ShadowCaster runs on a modified Wolfenstein 3-D engine called the Raven engine, and released the version of Raven engine (for educational purposes) that Channel 7/Mind Shear Software received for the development of Greed. This version is available, along with the Greed source, from his website. Maybe this could somehow help you with your project. On another note, all screenshots shown above are without aspect ratio correction, does the recreation have this option? 4 Quote Share this post Link to post
Quasar Posted February 21, 2018 The Raven engine is pretty well-known in these parts (see https://doomwiki.org/wiki/Raven_engine ). Unfortunately one of its features is that the core engine is mostly just the renderer and resource management stuff, and nearly 100% of the game code for the games that utilize it is not shared. This means that outside the basics, the IPoG source isn't that much help with figuring out the specifics of Shadowcaster. 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted February 21, 2018 (edited) 8 hours ago, MrFlibble said: On another note, all screenshots shown above are without aspect ratio correction, does the recreation have this option? Not yet. That is a planned feature in a future release, after the "extended menu" is finished. Probably not next release. While the source code to the Raven engine is not absolutely 100% going to solve the problems WindowCaster faces (the renderer is completely Direct3D anyway), it is certainly an interesting peek into the engine. Thanks for sharing. edit: this source code contains a level editor and resource editor??? that was unexpected Edited February 21, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
taufan99 Posted February 22, 2018 Kick ass! Definitely putting my eyes on this. 0 Quote Share this post Link to post
Lila Feuer Posted February 22, 2018 This looks very promising, I never got to play this, so I'm looking forward to a full release. 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 11, 2018 Apologies for the the thread necromancy. This is still actively being developed. As most of the work over the past few months has been back-end and cleaning up the awful codebase, I have only one major new feature to add. Textures and sprites can now be loaded from pk3s and can be assigned to arbitrary cell values using external scripts. This feature is very broken at the moment, but I hope that it will be ready for actual use next release. This new script format will also be adopted by the "mapinfo" equivalent system. It is very simple and uses section-key-value format, exactly like ini files: [walls] 0 = "-1" 1 = "badflat.png" 2 = "stone1.png" //etc... [flats] 0 = "-1" 1 = "bigrock.png" 2 = "sewer3.png" //etc... [mapinfo] thismap = 5 nextmap = 7 watermap = 6 music = "g_ruins1.ogg" //etc... I will post an actual release when these features are complete. 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 11, 2018 https://www.dropbox.com/s/wh1eq3rqj4ec373/WindowCaster_0_20_5132.zip?dl=0 New version. From changelog: ver. 0.20.5132: * completely rewrote the entire map loading code so that it can be more easily modded. this constitutes a refactor of something like 30% of the entire codebase. + added tile definition support. (all vanilla sc maps should fully render correctly.) + added mapinfo support. - temporarily removed music playback in maps (involves a mapinfo bug). This will hopefully be the last version that contains no real gameplay. 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 14, 2018 (edited) Version 0.25-PRE-2 Version 0.25-PRE-2 source code Interim release. This should not be considered a "real" update - this release is as-is for convenience purposes so you do not have to build the source in GM to see what has changed so far. Now that 99% of the Shadowcaster graphics and data that were statically linked to the executable have been removed, I feel much more comfortable releasing the source project behind it. It is designed with Game Maker: Studio 1.4.1804. Be warned: this does not mean my code is at all good or pleasant to look at. It will compile and run as-is without modification, but keep in mind that I am the only person I expect to be able to follow what's happening at this point in time. From changelog: ver. 0.25-PRE-2: * first open-source release. + added back music playback support and exposed the appropriate key for mapinfo to define which song to play on each map. + added support for reading two types of graphic lumps from RAVDATA.DAT (for walls and flats). Texture definition files (tile_floors.ini/tile_walls.ini) and external PNG graphic replacements are still allowed using the same method from 0.20.5132. Edited June 14, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 17, 2018 (edited) A new feature I've been working on for the "real" 0.25 release. GZDoom-style dynamic lighting in a scene can be toggled on or off at any time. There is a hard limit of 8 lights which can be visible at a time (with no prospect of expanding on this limit), which are managed automatically with excess lights simply not being drawn until previous lights are dropped from the list. By default, this feature will be disabled in vanilla maps. Edited June 17, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 19, 2018 (edited) New pre-0.25 release. As before, it is not important that you update immediately. The new test version contains positional audio playback, doors, and some patches to the way G_LoadWall/G_LoadAllWalls work. Dynamic lighting is included in this release, but disabled by default. In order to test this feature, you must manually place light objects in the room "levelarena" and set R_ENABLE_LIGHTING = true in the GM Macros editor. Edited June 19, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 24, 2018 (edited) New pre-0.25 release. This version contains a map editor. Check the readme for details. This release was not planned, but I figured since I had basically finished the backbone of the editor it would be smart to test it out publicly. Please inform me of any bugs you find, show me your creations, or just give me your opinions on how the interface should expand or change. I would also like to ask the community for your opinions regarding a text-based map format for WindowCaster, similar in concept to UDMF. Binary maps will continue to be supported and I will do my best to enable writing your own .lib files, with the objective of being compatible with the original DOS executable. If there is interest, I would also like to consider creating a Discord server to discuss future developments of this "source port" since I am sure one Discord server in particular is tired of hearing about it. ver. 0.25-PRE-5 ver. 0.25-PRE-5 source code Edited June 24, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
Gez Posted June 24, 2018 Have you looked at ECWolf's UWMF? It's basically UDMF for Wolfenstein 3D. It seems it'd be a good starting point since both are tile-based. Do you use an online repository like GitHub, GitLab, or BitBucket? 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 24, 2018 I use GitHub, but not for WindowCaster - I doubted anyone was that interested in the source code. 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 25, 2018 (edited) Possibly buggy update that allows you to save/load custom maps. No pk3 update needed. Press F5 to save to filename or F6 to load from filename while the editor is running (M key). Maps are saved to %appdata%/WindowCaster/Maps. The files it generates are text files, with a format loosely similar to UWMF/UDMF. Edited June 25, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 25, 2018 (edited) Patched version of 0.25-PRE-6. The version I posted above has some nasty flaws. Please use this version instead, and please feel free to post any maps you make with the editor here. I would love to see them, especially if they expose any bugs in the editor. Example map. Edited June 25, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted June 27, 2018 (edited) New version. This version includes some fixes for various bugs in the map editor and adds door editing mode, but be aware that while maps will save properly, doors do not always get saved or loaded properly. This will require several changes in the way doors are handled by the engine and those changes should be ready for the next pre-release, whenever that is. Go here if you want to talk about WindowCaster or give me bug reports or whatever. EDIT: Source code updated. Edited June 27, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
Guest DILDOMASTER666 Posted October 16, 2018 (edited) Version 0.25 released. This version correctly loads most static map objects and loads some of the .arc/.crt and .itm data, but due to my lack of a clear understanding of how these three formats work, only placeholder sprites are loaded. In addition, 3D collision detection with non-wall objects works. Mostly. Next up: - A rewrite to the texture manager, again. The current implementation has proven problematic when dealing with animated textures and this is also one of the big reasons doors do not save correctly in the text map format (all textures need a textureID linking them back to the TextureManager.TextureReference map, but no such mechanism exists in the engine at the moment to determine what textureID a door has - they only keep a "pointer" to the pixel data. walls and floors do this via the global.mapbuf_tile_* arrays, but no array of this type exists for doors). - I think at some point while developing this version, I introduced a bug in the music playback system. There was always a hidden bug in music playback where the engine would attempt to destroy a nonexistent stream (in other words, stop .ogg playback for a .ogg that was not being played), but something I did seems to have broken it for real. Investigating a fix. - A partial renderer rewrite. The way things work right now is naive - every polygonal surface has its own draw step which involves a texture and height lookup per object. I am not satisfied with this. The plan is a system that dynamically groups visible surfaces based on their texture and iterates through them, minimizing the amount of time spent looking for a texture resource and determining its dimensions. - Over the long term, I will be rewriting the way cellcontent works so that more varied features are allowed, such as variable height floors and ceilings and sloped cells. Source code. Edited October 16, 2018 by DILDOMASTER666 0 Quote Share this post Link to post
UnknDoomer Posted July 7, 2020 (edited) Is this project still alive? What about CD version support? Edited July 7, 2020 by UnknDoomer 0 Quote Share this post Link to post
Arno Posted July 8, 2020 Earlier this year I had a brief chat with the author of WindowCaster. He told me the project is on hold, due to difficulties with figuring out the mapscripts. He did plan to continue working on it at some point. In any case, the source code is published on Github. All the reverse engineering done so far in this project might be of value to others. 4 Quote Share this post Link to post
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.