Which is more Flexible: Patch or Source Code Based Mods?

Anything related to Keen Modding.
Post Reply
Commander Luke
Posts: 1
Joined: Sat Aug 03, 2024 8:26 pm

Which is more Flexible: Patch or Source Code Based Mods?

Post by Commander Luke »

To Put Simply: I Think with the Source code you can do More Stuff.

Like, i wanted to make Multiple Weapons that Keen can Use, basically like in Wolf3D/Doom where you have Multiple Weapons that you can Choose.


Such Thing As:
  • New Weapons
    New Controls
    New Death Animations
    New Hud System
    etc.
Why?
I'm New to Keen Modding, and I Want to make a Mod for the Galaxy Engine. that's why
Benvolio
Posts: 229
Joined: Sun Aug 29, 2004 4:44 pm
Location: Ireland
Contact:

Re: Which is more Flexible: Patch or Source Code Based Mods?

Post by Benvolio »

My knowledge base is increasingly small compared with the knowledge and technology that has advanced in modding.

However just as you said a Source Code mod is likely to be significantly more flexible.

However it is also likely to be more difficult, depending on what your programming abilities are. With patching you could get enough patches to make a decent mod directly from the internet provided you develop at least some working knowledge of them.

There was a time when those in the community who were gifted in patching used to regularly respond to patch requests with highly effective patch solutions to the problem. I am not saying those people are gone or that this won't happen if you try, but it's probably going to be a bit of a slower or more challenging process now than it might once have been. Therefore this probably makes a patch-based mod a slightly more difficult thing to opt for than it once would have been.

For source modding, if you are not an accomplished programmer in the relevant languages, it's likely that you will need to team up with someone who is in order to get such a mod made. In doing so, you are likely committing to making it quite a big production project. Finished Galaxy mods tend to be large scale team efforts now. Take a look at the credit rolls for some of the recent releases to get more of an idea.

But by all means if your ambition and abilities are right for the job, then take your pick of the approaches and you're likely to get good support and an enthusiastic audience for your work!
User avatar
Quillax
Posts: 28
Joined: Sun Mar 27, 2016 5:48 pm
Contact:

Re: Which is more Flexible: Patch or Source Code Based Mods?

Post by Quillax »

I'm not sure if you'll ever read this, Commander Luke (given that according to your profile you haven't logged in almost two months), but if you are, then I'd like to welcome you to the Keen community! You might notice that the Keen: Modding forum is pretty quiet and almost dead; it's been like that for several years, maybe a decade. Nearly all of the modding discussion is on the Public Commander Keen Forum, where it's far more alive.

Anyway, to answer your question: You are correct that source code modding lets you do more, although I'd like to add that the barrier to entry may be higher. Patching is alright and gets the job done if you're just changing some text and values (e.g. Shockshund's health), but if you're looking to add new stuff, then working directly on the source code may be the way to go.

With patching, you're basically overwriting the game's code, where it's already compiled so thus it's all numbers and may seem nonsensical if you're not an expert on machine code and how the game's code is structured. The EXE must remain the same file size, otherwise it won't work, so if you want to add something, you'll usually have to sacrifice something, unless you do some crazy optimization.

With the source code, the code is far more readable, even at first glance, and C programming has a lower barrier to entry than intense machine coding. It's way easier to add onto the game, since you don't have to worry about fitting within the original EXE size. Keep in mind, however, that you still have to work under the memory limitations of DOS, so good programming is necessary. It's not like with, say, GameMaker or Unity where you can be a very sloppy programmer and yet get stuff running, no matter how much bloat and CPU-consuming there is. What you have in mind should be doable, but would be ambitious and possibly way out of your reach if you're just starting out (if that's the case, I'd recommended starting out small and working your way from there).

Just to provide a little disclaimer, I actually haven't done any source code modding, although I've inspected parts of the code of Keen Dreams, Atroxian Realm, and Foray in the Forest. In my latest mod, The Mortrix, I made some patches all by myself, but there was a ton of trial-and-error involved, and those patches are about as simple as you can get (just overwriting a byte or two)! I can't imagine what it's like for patching masters like Levellass or KeenRush, who are able to rewrite entire chunks of the game. K1n9_Duk3 is very talented in both patching and source code modding, and he wrote an excellent post a few years ago comparing the two types of Keen modding. He believes that source code modding is way faster and easier, and I can see why. If I took the time to learn source code modding, I imagine that it would be far more efficient than getting nitty-gritty with the machine code; I at least have some experience with programming in GameMaker Language, which is kind of like C (but not exactly).

I think the biggest roadblock for source code modding is the lack of documentation available. Nisaba and Ceilick were working on a tutorial, but it hasn't seen any progress for nearly two years now. There's also the fact that only Keen Dreams and 4-6 have their source codes either released or recreated, meaning that Keen 1-3 has no DOS-based source code available, and 4-6 modding is a much more daunting task than 1-3 modding (although the former seems more dominant these days).
Post Reply