664901738ef73

664901738f574
1 Guest is here.
 

Topic: My NewDark Compatibility Wishlist Read 539 times  

6649017390031sarge945

66490173900cc
This is mostly a "what if" thread, I doubt the developer of NewDark reads this forum, but if they do, here's what I believe would be some very important/critical features for mod compatibility, since mods are getting more complicated and more compatibility issues are cropping up between various mods as more and more are developed.

To anyone reading this thread, these are not actually usable features, don't use them in your mods. This is just a wishlist of sorts and an attempt to (hopefully) describe what I believe are some limitations of newdark modding.

When (if) the SS2/Dark Engine source becomes available, I would be very glad to help implement all of these.

1. A DML Concatenation operator
This would mainly be used for the DesignNoteSS property. Currently, AFAIK, there's no way for 2 mods to edit the DesignNoteSS property (or any other property) on the same object without conflicts. This is a serious problem because this is the main way for scripts to be setup with parameters, so it's used frequently.

The syntax would look something like this

My Mod:
Code: [Select]
//Some data
+++ObjProp 1234 "DesignNoteSS"
{
"" "myModData1=0;myModData2=0;"
}

+ObjProp 1234 "Scripts"
{
"Script 1" "myScript"
}

Your Mod:
Code: [Select]
//Some data
+++ObjProp 1234 "DesignNoteSS"
{
"" "yourModData1=0;yourModData2=0;"
}

+ObjProp 1234 "Scripts"
{
"Script 2" "yourScript"
}

This would essentially be the equivalent of:

Code: [Select]
+ObjProp 1234 "DesignNoteSS"
{
"" "myModData1=0;myModData2=0;yourModData1=0;yourModData2=0;"
}

+ObjProp 1234 "Scripts"
{
        "Script 1" "myScript"
"Script 2" "yourScript"
}

These mods would still have to manually ensure compatibility, though, because as you can see, I am using script slot 1 and you are using Script Slot 2. Normally this isn't an issue because we can use metaproperties to attach scripts instead, however sometimes objects have the Don't Inherit flag set, in these cases, I would love to have...


2. Automatic Script Slot Assignment

Instead of doing this

Code: [Select]
+ObjProp 1234 "Scripts"
{
"Script 1" "myScript"
}

I should be able to do this

Code: [Select]
+AddScript 1234 "myScript"
{
}

which would automatically add that script to the first available slot, or log a DML error if no slots are available.

3. Partial Strings Support

Currently, if I want to modify a string in my mod, I have to ship an entire strings file. This causes issues, because if we both want to make changes to, say, chargen.str, our mods are inherently incompatible.

Instead, I should be able to ship strings/mymod.chargen.str, containing only my modified strings:

Code: [Select]
Mission4:"Feb. 23, 2113
    Time to get off the UNN Antigua and back to Wake Island Station, and not a month too soon.  Five months into your posting, the Gunnery Sergeant snapped during a training exercise, and killed half a troop with live plasma fire before you tackled her.  After that, you were in charge of the exercises, and in the months after, got pretty good with the low-energy beam weapons.
    You've gained +1 Energy Weapons and +1 Cybernetic Affinity. This mod is really cool"

Meanwhile, you should be able to ship strings/yourmod.chargen.str, containing only your modified strings:

Code: [Select]
Mission5:"Feb. 23, 2113
    Time to get out of the Asteroid Belt and back to Wake Island Station.  You'll probably have nightmares about cramped little tunnels for years, but you and the team got the jobs done.  A combination of EMP grenades and high explosives will stop most hostile machinery, and in your year in the Belt, you got a lot of practice at knocking the 'borgs and 'bots right back to the assembly line.
    You've gained +1 Heavy Weapons and +1 Cybernetic Affinity. This mod is also really cool"

When the game loads, it will read the default strings file, then it will read every partial string file provided in alphabetical order, overwriting any strings it finds. If 2 partial strings files overwrite the same string, the latest one is used.

4. Support for arbitrary/custom properties

Currently, the only way to save data on an object that persists between level transitions is to store the data in an unused property. This has potential for conflicts as mods may use the same properties, and overwriting some properties may have unintended side effects.

If I could instead use Property.Set(myObject,"Some cool custom Property","My Value"), and have it persist like any other property, then I could save all my needed data in my own properties, without having to potentially clash with anything else.

Custom properties would also make feature request #1 less necessary, as script arguments could be stored in custom properties rather than always using DesignNoteSS. Obviously NVScript would still need it, but for custom squirrel it would not be as necessary anymore.
« Last Edit: 22. June 2023, 03:32:44 by sarge945 »
Acknowledged by: RoSoDude

Your name:
This box must be left blank:

Look at you, hacker: a pathetic creature of ____ and bone!  (Fill in the missing word):
1 Guest is here.
Funny, how I blind myself, I never knew
Contact SMF 2.0.19 | SMF © 2016, Simple Machines | Terms and Policies
FEEP
6649017390250