Jump to content
The Dark Mod Forums

X-Ray Glasses Script Update


snatcher

Recommended Posts

Iris: X-Ray Glasses Script Update

Hey,

I have fixed & simplified the "Peculiar Lenses" (or X-Ray Glasses) script for "Iris" (current official version) by @Wellingtoncrab

1) With the glasses on, if we use the inventory grid we currently get:

iris-2023-07-28-20-15-28-3265-65-567-27-

I have exchanged:

overlayHandle = $player1.createOverlay(getKey("gui"), ZOOM_GUI_LAYER);

with:

overlayHandle = $player1.createOverlay(getKey("gui"), -1);

And now the inventory grid shows up in the proper layer:

iris-2023-07-28-20-19-26-3264-59-564-82-


2) There's a "Cooldown period" going on when you use the glasses that prevents players from getting the glasses on and off instantly. I personally find it a little unnerving that I am forced to wait when, in example, I put on or remove the glasses by mistake. I understand the reasons why this was done but it isn't well executed (lack of graphical context) and I find it at times a little frustrating and I have removed all references to "xrayGlassesCooldown".

3) There's a "loot_loop()" method that prevents the glasses from moving away from the inventory when picking up loot. Once again, I kind of understand the reasons why this was done but I don't understand why it is limited to a single item and it breaks consistency in example, when players pick up or select a different item. When I first played Iris I was at times puzzled because I didn't understand why glasses sometimes stay and other times vanish and I have removed it.

Find attached to this post the *.pk4 which includes the old and new versions of the xray_glasses script. Download it and place it in "/fms/iris/".

Please note this script will not work in any mission other than "Iris".

zzz_iris_xray_glasses_script.pk4

TDM Modpack 4.0

Link to comment
Share on other sites

Written In Stone: X-Ray Glasses Script Update

I have fixed & simplified the "Magic Glasses" (or X-Ray Glasses) script for "Written in Stone" (current official version) by @Dragofer, @Amadeus, @B1k3rdude.

1) With the glasses on, if we use the inventory grid we currently get:

written-2023-07-29-19-07-44-312-83-562-6

I have changed:

overlayHandle = $player1.createOverlay(getKey("gui"), ZOOM_GUI_LAYER);

with:

overlayHandle = $player1.createOverlay(getKey("gui"), -1);

And now the inventory grid shows up in the proper layer:

written-2023-07-29-19-10-28-312-83-562-6


2) There's a "Cooldown period" going on when you use the glasses that prevents players from getting the glasses on and off instantly. I personally find it a little unnerving that I am forced to wait when, in example, I put on or remove the glasses by mistake. I understand the reasons why this was done but it isn't well executed (lack of graphical context) and I find it at times a little frustrating and I have removed all references to "xrayGlassesCooldown". For this to work I also had to edit written_misc.script.

3) There's a "loot_loop()" method that prevents the glasses from moving away from the inventory while (wearing the glasses and) picking up items. Once again, I understand the reasons why this was done and while this script is better than the one found in "Iris" it has its problems: if you pick up an item (other than loot) while wearing the glasses you cannot tell which item you just picked because the inventory quickly switches back to the glasses.

Find attached to this post the *.pk4 which includes old and new versions of the xray_glasses script and written_misc.script. Download it and place it in "/fms/written/".

Please note this script will not work in any mission other than "Written in Stone".

zzz_written_xray_glasses_script.pk4

Edited by snatcher

TDM Modpack 4.0

Link to comment
Share on other sites

Allow me to complete this exercise by saying there still are issues with the X-Ray glasses in "Written in Stone" when trying to use them along with the Spyglass. Right now the Spyglass is kind of restricted but not too much, and the code to limit usage of the Spyglass is all over the place. This can change, but not today.

TDM Modpack 4.0

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • nbohr1more

      Was checking out old translation packs and decided to fire up TDM 1.07. Rightful Property with sub-20 FPS areas yay! ( same areas run at 180FPS with cranked eye candy on 2.12 )
      · 2 replies
    • taffernicus

      i am so euphoric to see new FMs keep coming out and I am keen to try it out in my leisure time, then suddenly my PC is spouting a couple of S.M.A.R.T errors...
      tbf i cannot afford myself to miss my network emulator image file&progress, important ebooks, hyper-v checkpoint & hyper-v export and the precious thief & TDM gamesaves. Don't fall yourself into & lay your hands on crappy SSD
       
      · 5 replies
    • OrbWeaver

      Does anyone actually use the Normalise button in the Surface inspector? Even after looking at the code I'm not quite sure what it's for.
      · 7 replies
    • Ansome

      Turns out my 15th anniversary mission idea has already been done once or twice before! I've been beaten to the punch once again, but I suppose that's to be expected when there's over 170 FMs out there, eh? I'm not complaining though, I love learning new tricks and taking inspiration from past FMs. Best of luck on your own fan missions!
      · 4 replies
    • The Black Arrow

      I wanna play Doom 3, but fhDoom has much better features than dhewm3, yet fhDoom is old, outdated and probably not supported. Damn!
      Makes me think that TDM engine for Doom 3 itself would actually be perfect.
      · 6 replies
×
×
  • Create New...