technically, all you have to do is take the mission and export the lantern setup to dml. I'm guessing someone familiar with that process could put it together in a couple of hours.
EDIT: Solution:
A working toggleable lantern for any mission: download
Thanks to Jax64!
My original message:
I like to play with low gamma. It makes things look more realistic and it makes Garrett's "night vision" less super human. The problem is that many missions or Dark Engine in general aren't designed to be played like that as the darkness becomes just too dark to see in. My current workaround is to adjust gamma with hotkeys so I can see when I need to. But what I'd love to have is a portable lantern, like in The Dark Mod.
I have seen some missions do it; at least Rowena's Curse and Break from Cragscleft Prison in the HD mod have a lantern. So it is possible.
But is it possible to make a mod that adds a lantern to the inventory/shop for every mission, OM and FM? I have zero modding or Dromed experience for Thief, but I'm a programmer so I can imagine the best case scenario be just a couple of lines (probably not though, as the games are from 1998/2000).
If it is possible and feasible, I think that could be a nice little project for me for the holidays. Could some one give me a little help to get started? What files would I need to edit/add? What documentation should I look into?
Last edited by DiMarzio; 13th Dec 2020 at 21:09.
technically, all you have to do is take the mission and export the lantern setup to dml. I'm guessing someone familiar with that process could put it together in a couple of hours.
This is certainly possible to implement and I would argue that doing so is relatively easy as well. As already said, adding something like this would likely require a reasonable understanding of the dbmod system and probably DromEd as well, as using a DML makes implementing this fairly trivial. Fortunately, DromEd is really not especially difficult to pick up and use and there is some official documentation along with plenty of fan-made tutorials out there should it seem at all daunting. Most relevant documentation should be located in the "doc" subdirectory of your Thief install, notably "dbmod-sample.dml" and "modders_notes.txt", though there are quite a variety of other useful documents located there as well.
This having been said, I have coincidentally already played around with implementing something like this in the past. If you just want a toggleable lantern in each mission, extracting the contents of this archive to any mod directory, such as "usermods", should be sufficient. Feel free to modify the implementation as you please; the DMLs and new scripts should be reasonably well-documented.
would be nice to have the lantern inventory object light up when it's on, but yeah, working ok.
will link the mod in the Thief mod topic, if I can find it. //there it is, all forgotten again.
Last edited by voodoo47; 13th Dec 2020 at 11:00.
As an author, is there a way to prevent this? I’m working on missions which rely on pitch black as an important gameplay mechanic, and such a dml would be game-breaking.
Obvs I can put a note in the readme, but not everyone reads that.
yes, dml fingerprinting. both the fm author and the mod author would have to agree on a fingerprint and modify their respective work accordingly. we already are using this in the SS2 universe (visual enhancement/functionality tweak mods detecting mission mods/FMs and autodisabling/autoenabling themselves as necessary. cool stuff).
ex. the Repairman mod will detect Secmod and disable itself, but also detect the Minstrel and enable an extra bit that will make it compatible with the fan mission.
Code:DML1 // some Minstrel FM compatibility stuff FINGERPRINT { QVAR "minstrel" == 1 } -ObjProp 168 "DiffPermit" +ObjProp 1682 "DiffPermit" { "quest var values" 0 } -Link 1973 -1420 "Corpse" -Link 1682 -1420 "Corpse"
Last edited by voodoo47; 13th Dec 2020 at 19:35.
Wow, this is exactly what I wanted! It works perfectly! Thank you very much!
This community continues to amaze me, thank you all for your helpful comments! I will use Jax64's solution for now and if I feel like modding it, I might make my own implementation of it later. But this works very well as it is.
By chance I found the Toggleable Lantern is multi useful. To put it another way I'm finding things about lanterns that I didn't know before.At the start of Eastwater Bank Gold after entering the basement, the outside door/gate locks closed permanently. No way out. With no crates available I placed the lantern in the doorway to stop the gate closing and kept my escape route open. Placing an unconscious body didn't do that. Also the lantern was not easily dislodged by walking through the doorway. However I imagine authors, besides wanting to keep a player without a source of light, as discussed above, may sometimes want to prevent the jamming of automated gates. The lantern is also good for standing on when that little extra height is needed, scanning for hidden switches (like other inventory objects it stops revolving and shrinks when something frobbable is near, but more noticeably so) and, should you wish, you can switch the lantern on, perhaps to attract enemy, and still use all weapons including bow and arrow, or other items in inventory.
You don't have to put the lantern down first.
Last edited by Aged Raver; 22nd Dec 2020 at 17:41.
I am glad some here are finding it useful.
As for having some missions disable it, agreeing on a quest variable to fingerprint the DML as already mentioned would be the most ideal solution, such as "NoLantern" or something of the sort. This said, the package should really only be used outside of a mission workspace after acknowledging both what it does and, most importantly, that nearly all missions were designed without it in mind. For those who want it as a convenience, novelty, or for a specific purpose like DiMarzio, this is probably already the case. In any event, perhaps I should include a warning to this effect. It certainly was not my intention to add to the already many factors that can induce headaches during the mission creation process.
Yes, it would. I considered it but opted against it in the interest of using only original resources. I could implement this if necessary, but it would also require making a lit variant of the standard lantern model, as an object's self-illumination is not reflected when rendered in the inventory.
iam a low gamma player too and was thinking about toggleable flares which doesnt run out. i will give this a try. thx
edit: do i have to edit the cam_mod file for this? somehow it does not show up in my inventory... am i doing it wrong? followed the readme file, but without success
edit 2: i clearly haven't understand your writing guys.
Last edited by Mischievous Taffer; 22nd Jan 2021 at 15:20.
You might need to edit cam_mod.ini. Depending on your folder structure. What I did, I unzipped the zipped contents into Thief Gold/USERMODS/lantern_mod folder and added +usermods\lantern_mod at the end of my mod_path in cam_mod.ini. That's all
without the lantern_mod extra folder, it would have worked without any edits.
You could also get a CRT :P
Nothing I do makes this work. I have dumped the contents of the archive into my main Thief 1 Gold root directory, I have dumped it into a folder named "Usermods", I have dumped the contents into a folder called "/Usermods/lantern_mod folder and added +usermods\lantern_mod at the end of my mod_path in cam_mod.ini, I have made edits to my cam_mod.ini as suggested. Nothing I do makes a lantern show up in my inventory. I am not trying to use FM either. I start a new game each time. How do I get this to work?
The following setups all worked for me, using NewDark 1.27 on a Thief Gold installation. (GOG edition + TFix v1.27, without any optional TFix features. I do have the Dromed Basic Toolkit installed as well, but I don't think that's a factor.)
With no cam_mod.ini changes (your C:\Games\Thief may be something else, of course):
- C:\Games\Thief\Usermods\gamesys.dml
- C:\Games\Thief\Usermods\miss_all.dml
- C:\Games\Thief\Usermods\sq_scripts\SimGivePlayer.nut
- C:\Games\Thief\Usermods\sq_scripts\ToggleableLantern.nut
Technically this worked as well:
- C:\Games\Thief\Usermods\dbmods\ToggleableLantern.dml (renamed gamesys.dml)
- C:\Games\Thief\Usermods\dbmods\miss_all\ToggleableLantern.dml (renamed miss_all.dml)
- C:\Games\Thief\Usermods\sq_scripts\SimGivePlayer.nut
- C:\Games\Thief\Usermods\sq_scripts\ToggleableLantern.nut
If I add +usermods\lantern_mod to the end of my cam_mod.ini path as you did, then this worked for me as well:
- C:\Games\Thief\Usermods\lantern_mod\gamesys.dml
- C:\Games\Thief\Usermods\lantern_mod\miss_all.dml
- C:\Games\Thief\Usermods\lantern_mod\sq_scripts\SimGivePlayer.nut
- C:\Games\Thief\Usermods\lantern_mod\sq_scripts\ToggleableLantern.nut
If none of that works, you can try adding this line to your cam.cfg
Next time you try to start a new game and then exit, you should see a dbmod.log file (in C:\Games\Thief or wherever). Somewhere in that file, you should see lines like this:Code:dbmod_log 1
If you don't see that file, I'm not sure what's up. Otherwise, be on the lookout for WARNING or ERROR messages in dbmod.log, or maybe even in your thief.log file. I hope this helps.Code:INFO: found file 'gamesys.dml' in path 'usermods\lantern_mod\', loading... (40200) INFO: found file 'miss_all.dml' in path 'usermods\lantern_mod\', loading... (31900)
I will try all that when I get some time. I did not think about it but, is the updated version of newdark required to get this to work?
mod makers, please ensure you prefix all new archetype names in your mod's .dml files and all classes in your mod's .nut files with a prefix unique to your mod, such as the mod's name.
for example, if the official name of this mod is "lantern mod", a good prefix would be "LanternMod". then your archetype should be LanternModToggleLantern, and your classes should be LanternModSimGivePlayer and LanternModToggleableLantern (if these are too long, shorten the part after the prefix).
if you dont add a unique prefix, playing a mission that happens to already have an archetype called "ToggleLantern" or squirrel classes "SimGivePlayer" or "ToggleableLantern" will result in this mod or the mission breaking in unpredictable ways. and it can conflict with other mods in the same way.
this applies to pretty much everything, any custom resource should also have a custom name, else pain will follow (at some point).
Ok, this is the issue. I already tried all your suggestions above. I just simply hate completely reinstalling Thief yet again and having to move all my previous settings, etc over. I have a backlog of half a dozen upgrades to do in various software that all are a total pain to do , lol.
While it's not exactly a lantern mod, there's another immersion-friendly mobile/controllable light mod that may be of interest to people in this thread.
https://www.ttlg.com/forums/showthread.php?t=151453
https://github.com/saracoth/newdark-mods Fairy Light mod.
I bit the bullet and upgraded to TFix 1.27 & after some discussion on that forum page, I have the lantern mod working. After playing Rowena's Curse and having the in game portable lantern that Rowena put in that mission, I really wanted to get this working.
Hi guys! Is it possible to assign a keybind directly to switch lantern on/off?
Will be very useful not to convulsively choose the item every time you suddenly need to hide in shadows.