Closed marthiago closed 5 months ago
I am having the same issue and it is the only thing stopping me from having an awesome in-person vtt setup. I am a web dev and I am teaching one of my dnd players web development, would this be a good issue for us to try and solve and make a pull request for?
Hi! Yeah that would be great! I'd assume it's not a difficult issue to fix, but I can't do it right now as I don't have access to a touchscreen laptop any more. A PR is definitely welcome!
My Tutee and I will start on this tonight.
My Tutee and I will start on this tonight.
Have you made any progress? I'm also a JS dev, and it would be great if I could resolve this by tomorrow night. If you've got anything even half-working I'd love to take a look at what you have. I took a quick glance and nothing is obviously wrong.
Experiencing the issue. Even hiding sheets from actors don't work. Temporary workaround is to "minimize" actor sheets and move it out of vision. Any progress?
Not really. I learned a bit about how this module works under the hood, got some minor progress, and then my players came to session with their own workaround that took touch-vtt out of the equation. I lost steam on this because my players want ipad specifically, and I found a showstopper on iPad unrelated to this module (fair enough, iPad isn't officially supported on foundry).
Is this still being worked on? I bought a touch screen and I was really hoping to have this functionality.
Oromis I can provide a video capture of the bug with the log console open, i really need this to work for my weekly game. https://youtu.be/UVtUIw3L14w
Same issue for me. IR Touch screen of my gaming table is opening character sheets. Moving Tokens is not possible because it gets stuck on the "cursor". would also love to have this working again
From what I have heard, @Oromis is no longer working on this module. Anyone else w/Javascript experience want to take a crack? 😅
For now I found a manual workaround for this issue. I think this needs to be done every time Foundry is updated.
foundry.js
script under [FOUNDRY_INSTALATION_DIR]/resources/app/public/scripts/foundry.js
(for Windows it should be located in C:/Program Files/Foundry Virtual Tabletop
)isDouble
variable declaration (just CTRL+F it, it should be in the #handleMouseDown method somewhere around line 31812)const isDouble = (now - this.lcTime) <= 250 && (now - this.lcTime) > 10;
(10 works for me - if
you're doing double clicks very fast you may want to decrease it, but going too low might cause this fix to not work every time)From what I can tell the issue is that there is already an event listener for detecting when the canvas is touched/clicked, so the #handleMouseDown
method is triggered twice, which makes it think it's a double click. Unfortunately the source maps are missing, but I think this is caused by PixiJS which is probably registering an event listener of it's own. I think that it's possible to make Touch VTT listen to PixiJS events instead of native events, but I'm not sure how.
I'm fairly new to Foundry, so this might look really dumb, I hope someone more knowledgeable can make use of my findings.
Thank you @hiszpek !!! Going to try this today.
I just fielded a question on Discord about applying the suggested fix for this issue to the FoundryVTT container I maintain. I thought I'd post my reply here for anyone else that might find it useful.
The container supports applying patches at startup. Here are the steps:
data
volume named something like container_patches
.touch-vtt-issue-61-patch.sh
CONTAINER_PATCHES
to the path of the directory you created. For example, if you created a directory named container_patches
in your data
volume, then set CONTAINER_PATCHES=/data/container_patches
.https://gist.github.com/felddy/bf09dffaefa3f0a469e8effa0a970ea9
The patch will be applied whenever the container is recreated.
The patch provided by @felddy using the workaround suggested by @hiszpek solved the unwanted sheet opening for me. Although I needed a much higher threshold than the suggested 10. (50 is working for me)
Sadly touch-vtt is still not usable for me (foundry version 11.315) because of another remaining issue reported as issue #65 here.
Please check this, if it helps to solve your issue: https://github.com/foundryvtt/foundryvtt/issues/10236#issuecomment-1927292942
Thx :)
Please check this, if it helps to solve your issue: https://github.com/foundryvtt/foundryvtt/issues/10236#issuecomment-1927292942
Thx :)
I am working on my own module thats includes fixing touch as a side goal while staying out of core foundry code as much as possible, replacing the functionality of touchvtt
This issue has been addressed in the latest release.
Hi! Thak you for your wonderful job on this module. I'm currently using Foundry 11 bulild 304. When I touch my token it opens the character sheet. I can move my token, but it happens behind the sheet, so I do not see what is going on. I did not find a way to touch my token without opening it everytime.