PDA

View Full Version : 5E Rolling Mirror (Automatic Mirror Image)



jammaster
October 20th, 2021, 19:07
Hello. This is an extension that helps with the Mirror Image spell. It does the following:

Adds a Mirror Image effect to the spell (Note: You may need to remove and add the spell again to your character to see this)
Automatically rolls to decide if a mirror image is hit
Calculates the AC of the images
If the creature is hit, the attack applies to him/her
If a mirror image is hit, it is killed, and the effect is adjusted (or removed if the last image was killed)
Its possible to have up to 19 Mirror Images with this extension
Mirror images do not work if the attacker can see through illusions(with truesight, blindsight or tremorsense)
No mirror image check if the attacker is blinded
The visions distance is taken into account when checking if attacker can see through illusions (If attacker has 10 feet blindsight and attacks from 15 feet away, he does not see through the illusions)


It cannot do the following:

Behave as if the attacker was blind if he is in total darkness without darkvision. This is a shortcoming of Fantasy Grounds


This extension is for D&D 5E, and is tested to work with FGU (Fantasy Grounds Unity). If you use the non unity version, the vision related features will (likely) not work. If they do, please tell me!

The repository can be found at https://bitbucket.org/JamMaster/rollingmirror/src/master/rolling_mirror/.

This extension should be compatible with other extensions, but if not, please tell me and I will try to fix it!

Forge link: https://forge.fantasygrounds.com/shop/items/1053/view

nephranka
October 28th, 2021, 13:22
This ext is working but I had a couple of questions regarding the implementation and its ability to work with another ext. (screen shot showing the issues attached)

1. Implementation: I note that the spell says:" A creature is unaffected by this spell if it can't see, if it relies on senses other than sight, such as blindsight, or if it can perceive illusions as false, as with truesight." Any thought to coding this to turn off if the attacker is blinded, has truesight or has blindsight or tremorsense? It currently does not take these into account.

2. Working with other extensions: There is an ext called Automatic Return Damage by Kent McCullough. It is setup to assist with things like fire shield. It is triggering on every attack whether or not an image is the target/hit. The spell states: "In addition, whenever a creature within 5 feet of you hits you with a melee attack, the shield erupts with flame. " So, it should be turned off if the image it the target. Any chance you could make these work together?

Nice work overall!

jammaster
October 31st, 2021, 14:26
With some help from nephranka, the extension now respects vision impairments/enhancements as the spell describes. Thank you!

nephranka
October 31st, 2021, 14:29
Great work! A worthy addition to my extensive extension list :)

Edit: You can add that it works with tremorsense as well.

Bonkon
November 1st, 2021, 20:50
Good Day Jammaster :)
Thank you for this! I have a paid mirror image extension that is not even close to this one!! The way you made it work with the various visions is incredible!! :)

nephranka
November 12th, 2021, 19:10
Is it possible we can add tremorsense to the list of visions that would see through the mirror images?

jammaster
November 12th, 2021, 19:16
Yes should be no problem. However, i have not found it among the other built-in visions, which makes me wonder if there are more things like this that would have the same effect.

nephranka
November 12th, 2021, 19:50
It is not in the senses that you can code but it is listed a sense for monster (like xorn). I don't know if that factor matters?

jammaster
November 13th, 2021, 13:57
Tremorsense will now bypass the mirror image effect. Beware, thath if the caster is flying or in some other way avoids creating ground vibrations, tremorsense does not help. Since tremorsense is super rare, and its even rarer to encounter creatures that dont create vibrations, i do not plan to implement this special case.

nephranka
November 13th, 2021, 16:12
Tremorsense will now bypass the mirror image effect. Beware, thath if the caster is flying or in some other way avoids creating ground vibrations, tremorsense does not help. Since tremorsense is super rare, and its even rarer to encounter creatures that dont create vibrations, i do not plan to implement this special case.

Cool. I totally get it. There are diminishing returns to so levels of automation and some things just need to handled in the moment. Thanks!

Beemanpat
November 13th, 2021, 17:36
This is a really nice extension. Thank you. Looking forward to using it in actual game play beyond my personal testing. Recommending to the other DMs in my DnD circle. Any chance this will be moving to the Forge?

nephranka
November 15th, 2021, 01:38
Everything seems to be working but now when I have creatures that have any special sight I get a message about mirror images even when the spell is not currently active. Is this expected behavior? It caught my group and me off guard tonight ;)

jammaster
November 15th, 2021, 06:15
Everything seems to be working but now when I have creatures that have any special sight I get a message about mirror images even when the spell is not currently active. Is this expected behavior? It caught my group and me off guard tonight ;)

Adult red dragon has blindsight. I should know, this is what I tested with ��. It doesn't say that anywhere in the combat tracker, but does in the creature's description. Maybe that was it? It's very unlikely tremorsense broke the extension like this

Edit: sorry i just now understood your message. That's actually something that i didn't test, i have to look into that. Very sorry it interfered with your session

nephranka
November 15th, 2021, 11:04
Adult red dragon has blindsight. I should know, this is what I tested with ��. It doesn't say that anywhere in the combat tracker, but does in the creature's description. Maybe that was it? It's very unlikely tremorsense broke the extension like this

Edit: sorry i just now understood your message. That's actually something that i didn't test, i have to look into that. Very sorry it interfered with your session

No worries about the session, we all saw the message and thought "what is that about?" I think the issue here is I only tested when the spell was active and I did not test normal combat without the spell. It seems that with the ext loaded that any creature with blind, true or tremor causes a message "attacker can see through the mirror image illusions" during combat even though no CT entry has mirror images. Does that help explain the screen shot better?

I assume you simply need to check to see the target has mirror images before pushing out the message and that right now there is no check so all attacks push out the message?

jammaster
November 15th, 2021, 11:06
No worries about the session, we all saw the message and thought "what is that about?" I think the issue here is I only tested when the spell was active and I did not test normal combat without the spell. It seems that with the ext loaded that any creature with blind, true or tremor causes a message "attacker can see through the mirror image illusions" during combat even though no CT entry has mirror images. Does that help explain the screen shot better?

I assume you simply need to check to see the target has mirror images before pushing out the message and that right now there is no check so all attacks push out the message?

Yeah. It's a super easy fix, will try to release it after work today

nephranka
November 15th, 2021, 12:31
Yeah. It's a super easy fix, will try to release it after work today

Cool. Thank you for all the effort.

jammaster
November 17th, 2021, 17:38
Hi, sorry for the delay. I fixed it yesterday, but forgot to upload. The issue should be fixed

nephranka
November 17th, 2021, 17:52
I will give it a spin tonight. Thanks!

nephranka
November 18th, 2021, 00:10
The error is gone but now the vision rules are not working. Blinded works and also generates the message.

nephranka
November 19th, 2021, 18:33
I am hoping it will be easy to track it down and get it back to normal operations. Thanks for the working on this!

eporrini
November 30th, 2021, 17:31
I notice the effect applies concentration, which the spell itself does not require. I am not sure yet if it's honoring the concentration, where a hit on the PC would trigger a concentration check. Is this by design or something that can be taken out?

nephranka
December 7th, 2021, 23:49
Just checking in to see if you have been able to resolve the latest bugs/old behaviors?
Thanks!

Dudin
December 16th, 2021, 19:46
+1 to the concentration question. The spell as written shouldn't require concentration and it doesn't seem like you can remove the concentration effect if you cast it using the extension. Can this be removed or am I missing something? :)

jammaster
January 6th, 2022, 11:32
My sincerest apologies for not responding for so long, I no longer receive emails about activity on this thread!

I removed the concentration. Your players need to remove the spell from their characters and add it again to fix this in existing campaigns. It never even occured to me this spell is not concentration :O
@nephranka, on your screenshot I see that you are using version 1.0.2 which is very old. Is it possible that you got the files mixed up? I tested this and it still works as intended. Either way, I will be including the version in the file name from now on.

nephranka
January 6th, 2022, 14:00
My sincerest apologies for not responding for so long, I no longer receive emails about activity on this thread!

I removed the concentration. Your players need to remove the spell from their characters and add it again to fix this in existing campaigns. It never even occured to me this spell is not concentration :O
@nephranka, on your screenshot I see that you are using version 1.0.2 which is very old. Is it possible that you got the files mixed up? I tested this and it still works as intended. Either way, I will be including the version in the file name from now on.

Great to have you back!

I did have an old version. I updated it and tested. In all three cases (blind, true, tremor) the mirror image is still in play.

jammaster
January 7th, 2022, 11:07
Great to have you back!

I did have an old version. I updated it and tested. In all three cases (blind, true, tremor) the mirror image is still in play.

This is really confusing, this is how your situation looks when I test it:
50823

I think this may have something to do with other plugins? Are you using FGU or FGC? Also, is your client updated?
If your client is updated (which it seems to be in your screenshot) and you are using FGU, you can try removing all extension except for mine and add them one by one to see which one has compat issue. Then I can address them

nephranka
January 7th, 2022, 11:23
So this is a new FGU build: 1/4/2022 rules set only your ext v. 1.0.5
Brand new character created

Steps:
Apply MI on test
move turn order
Dbl click in CT the attack of the G cube.
repeat with other monsters

All monsters come from MM

nephranka
January 7th, 2022, 11:26
This is really confusing, this is how your situation looks when I test it:
50823

I think this may have something to do with other plugins? Are you using FGU or FGC? Also, is your client updated?
If your client is updated (which it seems to be in your screenshot) and you are using FGU, you can try removing all extension except for mine and add them one by one to see which one has compat issue. Then I can address them

I do note your screen shot shows you are using the 12/27/2021 rules set.

nephranka
January 7th, 2022, 11:45
Ok. I have found the issue. If the grid is off then it does not work. If the grid is on it works.

jammaster
January 7th, 2022, 16:58
Ok. I have found the issue. If the grid is off then it does not work. If the grid is on it works.

How do you turn it off? I cant find the setting anywhere. I need to make sure this is intended behavior

EDIT: Found it. I uploaded a new version. Let me know if something else is off, especially crashes, i removed a check that I do not fully understand to fix this. But so far everything worked

nephranka
January 7th, 2022, 17:33
How do you turn it off? I cant find the setting anywhere. I need to make sure this is intended behavior

EDIT: Found it. I uploaded a new version. Let me know if something else is off, especially crashes, i removed a check that I do not fully understand to fix this. But so far everything worked

Glad you found it. I tested it and it seems to be working now with or without the grid. Great! I tested all the visions, return dmg and vision distance. All worked. Thank you for working this out. I will let you know if any additional strange behavior occurs.

nephranka
January 7th, 2022, 17:34
Have you considered adding this to the forge?

jammaster
January 7th, 2022, 17:37
Have you considered adding this to the forge?

I don't know what that is so probably no ��.

nephranka
January 7th, 2022, 20:39
I don't know what that is so probably no ��.

It is a place where you can upload your ext and when we update we can get the newest version:
https://forge.fantasygrounds.com/

nephranka
October 26th, 2022, 16:48
Ran into a strange bug. The ext works from the host side completely but the clients do not decrement the image numbers on a successful target of the image and hit. In the screen I have a target then hit with the image number staying at 1. This was taken from the client side. No other exts loaded.

rhagelstrom
November 9th, 2022, 01:17
Ran into a strange bug. The ext works from the host side completely but the clients do not decrement the image numbers on a successful target of the image and hit. In the screen I have a target then hit with the image number staying at 1. This was taken from the client side. No other exts loaded.

Author sees to be MIA. I fixed Mirror Image not decrementing when the source of the attack is a client. You can find the fix on my GitHub

https://github.com/rhagelstrom/RollingMirror

nephranka
November 9th, 2022, 01:38
Author sees to be MIA. I fixed Mirror Image not decrementing when the source of the attack is a client. You can find the fix on my GitHub

https://github.com/rhagelstrom/RollingMirror

Thank you!

jammaster
January 28th, 2023, 11:50
Author sees to be MIA. I fixed Mirror Image not decrementing when the source of the attack is a client. You can find the fix on my GitHub

https://github.com/rhagelstrom/RollingMirror

Thank you for the fix. Do you mind if i merge it into the main repo?

nephranka
January 28th, 2023, 12:12
Welcome back!

rhagelstrom
January 29th, 2023, 01:27
Thank you for the fix. Do you mind if i merge it into the main repo?

Go for it. Glad you are back

MrDDT
January 29th, 2023, 17:34
Thank you for the fix. Do you mind if i merge it into the main repo?

Welcome back, can we get this put on the FORGE? ;)

jammaster
February 2nd, 2023, 16:55
Welcome back, can we get this put on the FORGE? ;)

I will put this on forge this week

jammaster
February 15th, 2023, 22:20
Apologies for the long wait. Here it is:

https://forge.fantasygrounds.com/shop/items/1053/view

nephranka
February 16th, 2023, 00:49
Apologies for the long wait. Here it is:

https://forge.fantasygrounds.com/shop/items/1053/view

Thanks!

MrDDT
February 16th, 2023, 21:03
I tested this out with all my exts and no conflicts and working perfectly thank you so much.

Baron Toth
October 30th, 2023, 19:00
After some assistance, I got this working. The workflow for NPCs- for me, at least- was to add a blank effect on the NPC in the combat tracker, and type

Mirror Image: 3

It won't show up as a clickable effect, but the automation works perfectly. Note that you've got to watch the combat tracker and not roll damage if the hit was to the mirror image. A nice feature request might be to have it coded like immunity- if you roll for damage, you get an effective 0. Thanks, jammaster for a very useful extension.

eriktedesco
January 23rd, 2024, 16:58
Hi all!! Is this extention still working? I deleted and readded the spell, added the effect but all the attack seem to be aimed at the main body of the caster. Strange..

MrDDT
January 24th, 2024, 17:47
Hi all!! Is this extention still working? I deleted and readded the spell, added the effect but all the attack seem to be aimed at the main body of the caster. Strange..

Yes it works. Apply the effect.

Mirror Image: 3

MrDDT
February 12th, 2024, 05:06
@jammaster

I'm having this issue.
The error is in Rolling Mirror, but it's being caused by RR.





I'm getting an error with Rolling Mirror EXT when using RR and suppressing rolls.

RR and Rolling Mirror plays fine when RR isn't suppressing rolls. So my guess is this might on the RR side. Can you check it out and let me know?

Steps.

1)Load Fresh Campaign, Only RR and Rolling Mirror.
2)Set Suppress Dice Animations "on" in RR
3)Put
Mirror Image: 3, on a creature.
4)Attack Creature with effect.


[ERROR] Script execution error: [string "RollingMirror:.._action_attack_override.lua"]:37: attempt to index local 'originalRoll' (a nil value)

I reported it to the Author of Requested Rolls and they replied back with this.


I don't know what the root cause is, but these lines need to convert originalRollId to a string. i.e.
tostring(rRoll.originalRollId)
local originalRoll = originalRolls[rRoll.originalRollId];
originalRolls[rRoll.originalRollId] = nil;

rhagelstrom
April 13th, 2024, 01:57
@jammaster

I'm having this issue.
The error is in Rolling Mirror, but it's being caused by RR.




I reported it to the Author of Requested Rolls and they replied back with this.

Fix for this on my GitHub
https://github.com/rhagelstrom/RollingMirror/releases/tag/v1.0.7

MrDDT
April 15th, 2024, 05:42
Thanks man, this is awesome!