update
BTW, from my previous post (image of the fountain room) if you like a little piece of trivia, the little white cut in the channel on the left is actually a piece of the small mine, a room where you collect an Earth Crystal from a treasure chest. It's really crazy how compact the layouts are on the vertical plane. Luckily it's not generally a huge problem, but I suppose it could have been very worse. Usually the lower ceiling is only inches below the higher floor. In this case I will have to replace some flat tunnels with descending tunnels so that the small mine won't abut up into the fountain room. In the PlayStation version the separate levels are usually not loaded into memory simultaneously in order to meet the PlayStation's limited requirements. I don't think SOM will have any way to express this level of control, although I could add something in the form of an advanced extension to hide layers via events. (Which is how it would've been done most likely in the original.) Still I think that the overlap is undesirable, even in the level editor. I don't think it would be a good idea to do more than disable drawing on the other layer, so most likely sound effects would bleed in, which may or may not happen in KF2. Reproducing its sound landscape is something that concerns me, especially because it's largely an X factor that's opaque to my knowledge so far.
progress
As of a couple days ago I've begun to really hit my stride with much better development process at my disposal that allows me to work at a fast pace without any encumbrances. It's beginning to feel very exhilarating. I can set up tiles often in seconds. Everything is very streamlined and accurate. I will probably have to redo the first zone at some point.
SOM is at the beginning of feeling like an optimized development experience. It wasn't designed for building whole games from scratch with original art work, so it had not had facilities to integrate art development into its workflow... until now.
Since I've been using my own 3D modeling software to do this, I've been more inclined to work on improving its experience lately, since that pays dividends. I don't know how much I will spend time working on it now, it will depend on what feels like good tradeoffs. It certainly needs some work in areas. One thing I know I need to work on is nonlinear animation key frames. I think it's impossible to make high quality animations with linear interpolation, and if I'd had another option I think when I worked on adding animations for the shield and other things I probably wouldn't have struggled so much since I probably would've been happier with the results if they were more fluid. I'm surprised 3D graphics software often only deals with linear animation, since I think nonlinear is essential for good results, and allows for fewer key frames, less fuss.
I've had a very long journey to get this far. But it's starting to pay off. Finally.
simple machines forum
- December 03, 2024, 05:23:54 PM
- Welcome, Guest
News:
Remember to make your own backup of posts before submitting.
91
Sword of Moonlight / Projects, demos, and games Information / Re: STICKY: 2020 King's Field II port progress report
on: February 22, 2022, 10:20:39 AM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
92
Sword of Moonlight / Projects, demos, and games Information / Re: STICKY: 2020 King's Field II port progress report
on: February 05, 2022, 10:03:44 AM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
2022
I've got my work cut out for me |
93
on: February 01, 2022, 12:10:08 AM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
An important milestone has (finally) been reached by Sword of Moonlight by realizing the original King’s Field single environment experience of no “loading screens” after hopping into the game. This is something King’s Field fans always gloat about since it was pretty novel back in the day, and even to this day lately I’ve played a little bit of some PlayStation 4 games and am finding myself shocked how much of the time is really just spent on minutes long loading screens. In my opinion I would happily remove the high fidelity visuals in these games for practical seconds long loading screens. Of course, no load screens would be ideal. I wasn't sure whether to make this a release or a demo because I still need to battle test it by building out a full 2 map system using my KF2 project (it's long over due for another map to be added to its demo on itch.io and I've been postponing that until it could properly replicate KF2's no hiccups experience.) Both because I was thinking of making it a demo and I kept shooting myself in the foot with patches to the current release, all the way up to today, I've decided to just write this blog post and refer it to the current patch, which I hope is finally stable. Below are links to the patch files. I'm also going to be posting any future patches to this topic/thread to mark a point of departure. http://csv.swordofmoonlight.net/SomEx.dll/1.2.3.6.zip http://www.swordofmoonlight.net/text/日本語/最新.zip (Japanese) http://www.swordofmoonlight.net/text/English/Neutral.zip I've been working on this since the last weeks of December, last year. Although in that month I mainly did preliminary work (some studying/planning) by adding layer elements to events that take map coordinates. Technically I think it was possible to just refer to the base layer and set its elevation setting to coincide with a desired layer's elevation. I've tried to cover layers fully in the event system in this patch/quasi-release/project/task. This also includes new elevation limits and a rotation option for action based events and trip zone events. Note, I think in terms of activating things everything is now covered so that activation doesn't span "infinitely" above and below. IOW the default range is now limited to the object or character model bound to the event. (Also there's a "breaking-change" for the circle trip zone which had added its radius to said object's radius, which is no longer done. I've added an option to re-enable this, however I have a feeling the restriction to the object's base/height is more likely to break old games. I had a thought today to roll all of that together.) One new event "module" (I think I'm calling these modules now, even though I have another plan for literal C# modules for SOM, but that will offer a plugin system for events too, so they will technically be modules too) was added, filling out the last remaining slot in the list (before it requires a scroll-bar) as if fated to fill in this slot (why was a slot left unfilled?) much like the layer system filled in the spaces left by the layer system From Software ripped out prior to publishing. Anyway, this event module/command/operation/instruction (call it what you want) sets a secondary map to start loading in the background. This requires a multi-core CPU. They've been standard for many years now and current Windows systems require them to function, so unless there is demand it will just be a minimum requirement from now on to use this. I did some timing tests and I think that a single-core CPU just won't be practical given how slow Windows is to access files (I'm a little surprised it can stream the BGM file, and this may be a bottleneck) at 60+ frames per second, so if demand arises the only likely thing I can do is add a way to disable this so that loading screens come back. As a starting point this system functions just like the King's Field games would have functioned (I think all of them do so this way anyway) by connecting two maps at a time. Technically more than two "maps" (i.e. levels) will stay in memory for a few minutes, but two maps will remain in memory. Memory just means they're not on your disk drive. I'm pretty sure from what I've seen online that KF2 duplicates parts of its maps that intersect on the threshold. Currently this duplication is required with this existing system. I am interested in pushing it further down the road to actually display the other map against the current map. Logistically there is only one active map. Things like events only run on one map's events at a time. Under the current system the maps switch out instantaneously. If a more literal stitching system combined their images however, there would still just be one set of events. I do plan to try to carryover monsters, however presently, any monsters visible on map change will just blink out. This version isn't fully complete. To avoid that you can set up doorways (gates) like you will find in most KF games' inter-map corridors. Edited: To get this new style transition working the new "relative" setting has to be checked on the map change event module. Technically this makes it so the "event" can cover every tile inside its trip zone, but it's also doubling as a "new mode" switch, since the old mode is limited to a single tile, almost like a teleportation booth. (I've thought about upgrading the old mode but it's not clear-cut that the new semantics can work with it without losing something in the process.) One other small thing is you need to rebuild the MPX file (compile/prepare it) since MapComp needs to add some new information to it. (What tile/layer things belong too. This is information it used to emit but was disabled.) Note, it now defaults to "relative" mode. The fog and sky and BGM is smoothly transitioned, however there's a larger flaw in this version than monsters blinking out, that is there's no provision for transitioning lighting. I have a plan for this, but it's going to have to wait until later this year, and will be a big project. In the meantime there are some creative workarounds for this if someone is really keen on using this in the next few months. What can be done is map geometry can have its diffuse lighting component overpowered either by maximizing the "emissive" component or using the new per-tile ambient system my KF2 demo is using to overpower the ambient component. At that point you will be stuck with having to fake lights by baking any lighting into your textures. But this approach can create a liminal corridor which both maps (with different global lighting) can agree on. The solution I have planned involves more per-tile settings for most of SOM_MAP's settings. Even ones you wouldn't expect like the fog and names and music. This system should allow for little pocket regions within the maps themselves. (Edited: There will be an option to set the sky model on a per-tile basis, but it will most likely only apply to the current tile/layer and so anytime the sky is swapped out will have to be obscured from view somehow. The sky transition system blends two skies, and if it were possible to blend per-tile skies there would be a "combinatorial explosion" and tiles are square, so it would be tricky to smooth out jagged diagonals between tiles. That said I won't completely rule out tackling this one day.) Oh, one more small limitation is you should stick to WAV files for music. The transcoding system I set up a while back isn't super efficient, but it will no doubt incur a hiccup if you try to mix it with a new nonstop map transfer. I need to roll that into the new art system cache x2mdl.dll is using so that the conversion to WAV is done one time and saved until the cache is emptied. I will do that when I add sound effects to the art system. Another little something worth mentioning is I've tweaked the opening movies to load the first map in the background so that the game will load faster, even if players just try to cancel it ASAP... it only needs a second or two, which it can take to do the fade out effect. I'm also going to add this to the Continue screen, but I haven't yet. It will need to start loading while its Yes/No menu is shown. Also if you use do_start/start_mode=1 ("KF1" style) it will load the first map as soon as the title screens begin. Ideally SOM can be a no loading experience like the old 16-bit consoles which used ROM cartridges Edited: For the record, I want to take some time off to work on art for my KF2 project. So I'm not going to be working on SOM features for a while, and when I return to it I plan to focus on a few things that will make a new KF2 demo shine. One other odd thing that made it into this patch is a new way to turn off the menu system on the item pickup screen. This is how most of From Software's games actually work. SOM works differently IOW. But this new system still feels a little bit unfinished. Obviously it needs animation, but I wonder if it needs something else. (A sound perhaps?) Anyway, you can try it by setting it to Off in the Options menu, or pressing one of the auxiliary face buttons on the pickup screen. Even in an unfinished state it's actually good to get rid of the old Options setting, since it was totally nonsensical (and implemented completely wrong I found out) and so would otherwise be interpreted as the mark of unprofessional product. https://www.youtube.com/watch?v=TgQUZcwd-JQ |
94
on: January 31, 2022, 07:04:41 PM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
Last patch? Demo patch
http://csv.swordofmoonlight.net/SomEx.dll/1.2.3.6.zip http://www.swordofmoonlight.net/text/日本語/最新.zip (Japanese) http://www.swordofmoonlight.net/text/English/Neutral.zip Aye yai yai, I don't know how it happened but the fog got messed up by the last patch. This was because it thought it was to be applying the blending effect. What I don't understand is why my test project wasn't exhibiting that behavior. I thought about putting it under the microscope but decided it wasn't worth the time and effort. I'm really sick of all the patches in this release. I mean I'm disgusted with myself to a large extent. I'm hoping it's just a cursed release. This patch is actually the final patch of what I thought might be the next release, but actually I've recalled I'd considered just releasing a patch as a demo since I've still not built out a full scale scenario with two real maps of significant scale. Since this patch is identical to what would be a demo I'm not going to make an odd numbered demo patch for it. I'm just going to write a blog post up and start a new discussion thread. Also even though there's enough here to do what KFII requires, I feel that lighting being missing from this feature set makes it a little bit incomplete. I also kept getting stuck in Moratheia's opening titles. I thought I covered them in terms of multi-thread locks but I went back and looked and it seemed like not. So I hope they're covered now. I'm not sure what happened in that case. After a little more testing to see if the code has stabilized I'm going to see about updating the TOOL folder. The language packs have new UI things for SOM_MAP's events. For English it may just be new trip zone and action based activation features compared to that quick/dirty demo I shared a while back. For Japanese it's all new to be up-to-speed with the English version. When I write a blog I will share some potential ways to workaround the missing lighting feature in case anyone wants to do early tests before I can work on it. Anyway, this is technically a patch to fix things I broke. I will reshare this patch in the new topic/thread I should make sometime later today. I did work on some last minute things before posting this fix, even after I noticed the problem. |
95
on: January 27, 2022, 11:10:34 PM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
Oh man, not another PATCH
http://csv.swordofmoonlight.net/SomEx.dll/1.2.3.6.zip I felt sick at my stomach when I found out I messed up the do_fix_circle_trip_zone_radius code from the other day's patch. I knocked out the event's radius instead of the unwanted one! I guess that was wishful thinking since it turned out the other one was too difficult to get at. I honestly don't understand how I miss these things. (Edited: I just rewrote the subroutine instead.) I also found a bug in the sky routine I use to resituate the sky in front of the transparent scene elements. It kicks in when the sky has more transparent elements than the scene itself, and there aren't 0 such elements. I guess I never saw it before because SOM's skies only have one transparent element, so that means it could never be more unless there are 0. So maybe this isn't interesting. (Edited: When blending skies all elements are transparent and there are two skies for the moment.) There's also code in place to blend the fog and sky across maps in this patch. I expected blending the sky to look kind of funky, but it's actually perfectly smooth and even. That's a relief. I was afraid it would be a weak point. I haven't quite figured out how to drive the blending parameter. In this patch it just blends it over the course of two seconds. That's actually what Dark Souls does. But it's not what I have planned. The one problem with my plan is it needs a notion of what is moving towards the new map and away from the old map, and that's not an obvious metric. I have some ideas but I have a feeling there won't be a perfect solution. But it should work fine most of the time if you don't do anything funny. I have to work on fading out the BGM. I'm surprised SOM doesn't have a system for that. I think it's mute function just cuts out. But I could be wrong. It's worded that way. Anyway, after that and some work on the Japanese language pack the next release cycle will be wrapping up. It's always annoying when the previous release gets patched to the degree it's the same as the new release. Sometimes it's easy to isolate features to a release and sometimes it would be more work than is worth it for "alpha" software. |
96
on: January 25, 2022, 11:42:18 PM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
REPOST: I had to pull this post after more problems started to arise. It sucks to be a programmer sometimes. So, some time has passed since I originally posted this. (The new problem was because some new code I'd written in haste failed to make some important thread synchronizing objects because C++ has this annoying thing where if you don't write the name of an object it just pops in and out of existence as if it never really existed. In this case the threads were stepping on each others toes.)
------------------------------------------------------------ Patch Patch (Important) http://csv.swordofmoonlight.net/SomEx.dll/1.2.3.6.zip The patch I put up the other day with map streaming capability has a critical problem where the textures will be lost when an old map is unloaded from memory (kicks in a few minutes after switching maps without using the standby map system.) Off-topic: While working on blending skies I found out that some extension code I think I thought was doing a "Z-test" optimization on the sky was being defeated by some code I might not have understood, although it's possible I did but couldn't solve it at that point, but I don't see notes to that effect. So I rewrote the sky subroutine and it wasn't working with the Z-test, and that's because opaque MDO elements force on z-buffer writes. To get around that this has to be momentarily overruled just for the sky. Anyway, what this amounts to is a pretty good optimization when portions of the sky are hidden. I.e. this should improve frame rates significantly where applicable. Oh yeah, another weird thing I noticed yesterday is the circular trip zone event system actually adds the radius it's given to the object/character that's bound to the event's own radius. I've disabled this behavior. I added a do_fix_circle_trip_zone_radius extension to the Ex.ini file in case this breaks a game that can't be fixed. The square trip zone doesn't do this. I guess someone didn't get the memo. [EDITED: I also patched x2mdl (http://csv.swordofmoonlight.net/x2mdl.dll/1.0.0.2.zip) earlier today. It wasn't working with when the model has no (0) polygons/vertices (i.e. a dummy) because of some error checks I wrote for reasons I'm not sure why.] |
97
on: January 20, 2022, 02:12:40 PM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
Here (attached) is a copy of SOM_MAP that can be copied into the TEXT/English/Neutral.zip (or if unpacked dropped into the Neutral folder) to add an event "module" to SOM_MAP to be able to direct an event to load a map in the background. It's just something to play around with in the meantime if anyone wants to try this out. (I've been talking some lately with "Verdite" who's responsible for the Moratheia project.)
A word of warning is if you remove (rollback) this patch or this language pack feature then SOM_MAP will quietly remove the event "module" from your events. I've also updated yesterday's patch just now just to add a little readout to the F6 display that will show the second map in memory under the "map" heading. You can confirm it's working that way. I'm thinking about how to display the percentage of the maps' loading progress, but didn't add that yet. Generally they will load in a second or so, but there's no precise way to say given that PCs all have different capabilities. If loading is that fast then a loading percentage readout might only be a blip. In the present state you need to check the new "Relative" option in the map transfer event module to get the maps to change without any visual indication. I don't know if there's any other route to doing this than this way. I have to study it some more if so. (Edited: The problem is that the preexisting behavior likely has to change to let the other modes be used this way, and I'm not sure it's worth it given limitations.) Of course the sky and fog settings will be a tell unless they're identical. I'm still working on this. I think that lights system I spoke of will also entail settings for overriding the fog and sky and map title and BGM. This will let you designate organic subsections of maps as having different conceptual localities. Plus KFII has tiles with custom fog that have to be implemented for my project to faithfully reproduce them. It's still possible to blend in the fog on map changes, as it would be possible to do with the ambient light if it wasn't burnt into the maps' vertex colors. (I don't know what it will mean to have a variable sky, most likely it will just be a way to switch between interior and exterior sections.) |
98
on: January 19, 2022, 07:59:24 PM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
Emergency Patch
http://csv.swordofmoonlight.net/SomEx.dll/1.2.3.6.zip I learned 2 days ago that I messed up again and had broken sound effects on "objects" and the magic equipment (and a few other things too) but I was too deep into debugging the new background loading system to be able to publish a patch... and a little embarrassed to be making so many patching posts. I hoped I could iron out some troubles yesterday, but it took me 2 days of keep running into things. (Plus I figure probably next to no one is downloading these patches. I make them out of principle.) I don't like how the work on the next release is being consumed into this release. It's about tantamount to just roll it into this release as an early demo. I will announce it since it's an interesting juncture. Technically it can be used with this patch but just requires a language pack with the extra event module for SOM_MAP. I may upload that tomorrow as a sneak preview. I still have to work on blending the fog and sky to call it good enough to officially publish it. I won't be surprised if something breaks, but this patch/version will start loading the first map either when the New Game option is chosen, in which case an intro sequence can hide the loading, or if do_start and start_mode=1 is used it will start loading as soon as the first title screen. I also intend to work on starting the load when a save file is chosen, since it takes some time to move the button up to Yes (it defaults to No) which can be enough to load a game. Currently it can take time to process textures, which this patch doesn't do all immediately. I've been able to improve the start of maps, especially when they fade in. The first frame will process everything that's in its scene, but after that it starts processing in the background and goes ahead and starts playing the map. This would benefit from implementing the prioritization system I've in mind even now. But I also intend to move that processing into x2mdl ASAP. Technically even x2mdl runs in the background now, so it might not even be noticed if lucky. I've had to switch Direct3D 9 over to a "multi-threaded" mode, which is supposedly pretty flaky and naive. It might not be necessary if these textures were processed by x2mdl but it can take several milliseconds to process them at runtime, which is too much to do on the same thread as Direct3D. It seems to work, but it can't upload textures without jamming, so I've set it to upload one processed texture per frame. Of course if a model actually requires a texture it will be uploaded in addition to this, and too many can result in a hiccup. It might be nice to be able to fade things in a little late in that case to avoid frame drops. I think only NPCs and items fade in normally. Support for NPC reskins is limited too. The model preloading system isn't fully aware of skins now, so it will apply the first skin to a model, so that model will never have a different skin if there's more than one. I will work on this. I don't know if the Moratheia 2.1 demo doubles up models with skins. Now with MDL+MDO skins aren't required but can be an optimization for "palette swapped" NPCs. There's also the start of an alternative "item" pickup experience, but it feels a bit flat. I will have to study KFII to see if it has any sound effects involved. It can be jarring to not have the visual spin around and rise up. I have to work on that. Luckily this can be turned on and off in the Options menu. I will probably update the TOOL folder again after some sleep and more testing and confidence this time. |
99
on: January 16, 2022, 04:45:52 PM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
follow-up
I found myself doing a small project at the end of the day from the previous reply in this topic/thread about converting a useless option into a way to get classic KF style experience when examining items. I just laid down the basics. I still have to work on animating the item transition and manipulating it with the controller to call it finished. But something really weird I discovered is the third toggle option that hides items in menus doesn't actually prevent the model files from being loaded up. That's really weird because I assumed its purpose was to speed up the menus. And I was surprised it even hides items from the pick up screen... which is doubly bizarre since they completely disappear from the scene before appearing in the menu display, so that with this option enabled (or technically off) it looks as if the object (item) has disappeared entirely from the game. I hope I can find time to mess around with this more before long but it's good either way to be rid of that funky option in the meantime. I have set up a button toggle to turn the menu on and off with the triangle button or J key, but it only works when examining items outside of menus. I'm thinking about having the other button show text, but the menu shows the name too, so it can be used to reveal the name briefly before taking the item. Edited: Oh yeah, for the default English I called it "Examine Display" and I'm thinking of leaving the Japanese alone since it calls it Item Display (in Japanese) which seems close enough to the meaning. |
100
on: January 15, 2022, 01:28:15 AM
|
||
Started by Holey Moley - Last post by Holey Moley | ||
Patch Patch
http://csv.swordofmoonlight.net/SomEx.dll/1.2.3.6.zip Yesterday's patch had a bad number in it (offset to the PARAM/OBJ. I had to update the TOOL folder (again) and I'd like to consolidate the last three posts, but I feel like there's information in them that would be collateral damage if so. Daily patches never get old. It feels like once a release is published its patching draws on until the next release. Probably a good reason to hang back one release cycle. |