pplans / foundry-vtt-module-motion-tracker

A module giving life to the Alien RPG motion tracker in foundry VTT
MIT License
6 stars 8 forks source link

[BUG] #49

Open brunocalado opened 2 years ago

brunocalado commented 2 years ago

Hi.

This module is generating an error and not detecting anything.

image

tks

pplans commented 2 years ago

By any chance did you created this scene in a version prior to .5 ? Do you have steps to reproduce ? The module is behaving as intended on my side

brunocalado commented 2 years ago

I don't think so. I create on the last build.

I just created a new scene. Added tokens.

Player vision image

chrome 10 win10 fvtt 9 last system scum and villainy

pplans commented 2 years ago

Oh! Hum, I'll check this tomorrow I am not at home right now. Thanks for the repro. I'll probably add some checks to avoid the crash

brunocalado commented 2 years ago

No rush. Tks

pplans commented 2 years ago

Hum, so I tested with the last version of foundry, using the last version of the module and this configuration with a Scum & Villany scene : Version 97.0.4692.99 (Official Build) (64-bit) Win64 and firefox 96.0.3 64bit, in the same OS I did not got the issue :/

Is there a way you send me the scene ? It might help reproduce it

brunocalado commented 2 years ago

I created a clean world with just 4 actors. It worked.

I went back to my world game. I created new actors. I disabled all modules (find the culprit) and still gereranting an error. image

Error

    at motion_tracker_device.js:449:88
    at Array.some (<anonymous>)
    at motion_tracker_device.js:449:58
    at EmbeddedCollection.find (collection.mjs:46:12)
    at motion_tracker_device.js:449:32
    at EmbeddedCollection.forEach (collection.mjs:84:7)
    at MotionTrackerDevice.update (motion_tracker_device.js:436:10)
    at t.emit (ticker.min.js:8:573)
    at e.update (ticker.min.js:8:3424)
    at _tick (ticker.min.js:8:1433)
(anonymous) @ motion_tracker_device.js:449
(anonymous) @ motion_tracker_device.js:449
find @ collection.mjs:46
(anonymous) @ motion_tracker_device.js:449
forEach @ collection.mjs:84
update @ motion_tracker_device.js:436
t.emit @ ticker.min.js:8
e.update @ ticker.min.js:8
_tick @ ticker.min.js:8
requestAnimationFrame (async)
_tick @ ticker.min.js:8
requestAnimationFrame (async)
e._requestIfNeeded @ ticker.min.js:8
e.start @ ticker.min.js:8
start @ ticker.min.js:8
e.init @ ticker.min.js:8
(anonymous) @ app.min.js:8
t @ app.min.js:8
loadTexturesFinish @ motion_tracker_device.js:347
await in loadTexturesFinish (async)
t.dispatch @ loaders.min.js:8
e._onComplete @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
s @ loaders.min.js:8
e.use @ spritesheet.min.js:8
(anonymous) @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
setTimeout (async)
s @ loaders.min.js:8
t.use @ compressed-textures.min.js:8
(anonymous) @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
setTimeout (async)
s @ loaders.min.js:8
t.use @ compressed-textures.min.js:8
(anonymous) @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
setTimeout (async)
s @ loaders.min.js:8
e.use @ compressed-textures.min.js:8
(anonymous) @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
setTimeout (async)
s @ loaders.min.js:8
e.use @ text-bitmap.min.js:8
(anonymous) @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
setTimeout (async)
s @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
Promise.then (async)
e.use @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
setTimeout (async)
s @ loaders.min.js:8
use @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
setTimeout (async)
s @ loaders.min.js:8
t.eachSeries @ loaders.min.js:8
e._onLoad @ loaders.min.js:8
t.dispatch @ loaders.min.js:8
t._finish @ loaders.min.js:8
t.complete @ loaders.min.js:8
load (async)
t._loadElement @ loaders.min.js:8
t.load @ loaders.min.js:8
(anonymous) @ loaders.min.js:8
s @ loaders.min.js:8
t.eachSeries @ loaders.min.js:8
e._loadResource @ loaders.min.js:8
_boundLoadResource @ loaders.min.js:8
process @ loaders.min.js:8
t.resume @ loaders.min.js:8
e.load @ loaders.min.js:8
loadTextures @ motion_tracker_device.js:277
MotionTrackerDevice @ motion_tracker_device.js:256
_render @ motion_tracker.js:428
await in _render (async)
render @ foundry.js:3021
open @ motion_tracker.js:271
toggle @ motion_tracker.js:298
(anonymous) @ motion_tracker.js:16
dispatch @ jquery.min.js:2
v.handle @ jquery.min.js:2
MCHSXIII commented 1 year ago

I´m having the same problem :( I am running Foundry Vtt V9 Build 280 Currently and motion Tracker V0.58 (Can´t run a newer version bc there are modules I need that dont run on V10) I am using the Star Wars RPG and Wrath and Glory Systems. I can copy and paste characters from maps where It doesnt work to maps where it will work, and sometimes the tracker will then work on them and sometimes the tracker won´t and token that were working before aren´t anymore. Its quite confusing. Currently its working on all of my Star Wars maps (even older ones) and none of my Wrath and Glory maps except newly created ones (until I start messing about a bit and it randomly shuts off again -.-) This is an error I found when the module did work for a bit(Chrome and firefox):

2023-01-20 22_44_48-Foundry Virtual Tabletop • A Standalone Virtual Tabletop Application — Mozilla F

2023-01-20 22_42_24-Betatestworld • Foundry Virtual Tabletop — Mozilla Firefox

Otherwise I am getting this error:

2023-01-20 22_35_11-Troubled_Waters • Foundry Virtual Tabletop — Mozilla Firefox 2023-01-20 22_35_21-Troubled_Waters • Foundry Virtual Tabletop — Mozilla Firefox

2023-01-20 22_31_36-Troubled_Waters • Foundry Virtual Tabletop

MCHSXIII commented 1 year ago

This is such a fun and immersive module I am really hoping to get it back to work :(

MCHSXIII commented 1 year ago

(Also sorry for necromancing this issue, I thought it might provide some context maybe since brunocalado seems to have had a similar problem)

pplans commented 1 year ago

Hey don't be sorry! :) I'll take a look, the module went full v10 and I don't have the v9 anymore but I'll try to figure our how to fix it, eventually I'll put special versions for the v9. So I'll take a look tomorrow, also, hijacking the ticket but, I was planning on doing eventually more templates for the look and feel or providing ways to customise, is this something you'll probably use on your side ?

MCHSXIII commented 1 year ago

Yeah, I can see a few more use cases for it potentially. like maybe a predator heat vision style (maybe even on the map in the fog?), Or a tracker that weakens with terrain. It´s a really immersive gimmick for pretty much any sci fi setting I´d say.

MCHSXIII commented 1 year ago

Also for look and feel maybe an image of the actual tracking device around it instead of a black rectangle? Something retro looking...

pplans commented 1 year ago

yeah I can try to put a frame, I was afraid of breaking the feel with the window title part which I can't easily personalize, I'll give it a try again :) The tracker weakening is definitely a great idea, I'll try to put something up and will credit you for the idea As for the predator heat vision on the map, I'd say I'll make another module separately if I have the time :D

Thanks a lot! I'll try to make a fix for you

pplans commented 1 year ago

Hi can you try this release https://github.com/pplans/foundry-vtt-module-motion-tracker/releases/tag/temporary ? you'll have to manually download it and overwrite your source if your server (hoping that's possible for you). Also, before doing that you might wanna make a backup like zipping the modules/motion_tracker directory in case of.

This should fix the errors related to the motion tracker, that bruno also experienced (sorry bruno I didn't answered before I had a complex year). For the other error you experienced with the imperial_guard unicode file I can't help much :( looks like something in your setup

MCHSXIII commented 1 year ago

Thank you so much, people like you make foundry the great platform it is ❤️ I am not on my computer atm, I will write you back tomorrow with my results.

Im so bad with code I completely overlooked the i_g file error. Its just some error with a compendium I bought were files are registered double, its not creating any problems besides popping up in the console.

MCHSXIII commented 1 year ago

Sorry this took so long, I tried today and its still not working, console is now giving me this error on chrome:

Uncaught DOMException: Failed to execute 'texImage2D' on 'WebGL2RenderingContext': The image element contains cross-origin data, and may not be loaded. at r.upload (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:127584) at r.upload (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:131278) at e.updateTexture (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:231932) at e.bind (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:230260) at eval (eval at (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:218622), :33:30) at t.syncUniforms (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:217617) at t.syncUniformGroup (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:217488) at t.bind (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:217135) at r._renderDefault (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:381868) at r._render (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:381651) foundry.js:3053 Foundry VTT | Rendering ModuleManagement foundry.js:3053 Foundry VTT | Rendering MotionTrackerWindow core.min.js:8 Uncaught DOMException: Failed to execute 'texImage2D' on 'WebGL2RenderingContext': The image element contains cross-origin data, and may not be loaded. at r.upload (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:127584) at r.upload (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:131278) at e.updateTexture (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:231932) at e.bind (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:230260) at eval (eval at (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:218622), :33:30) at t.syncUniforms (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:217617) at t.syncUniformGroup (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:217488) at t.bind (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:217135) at r._renderDefault (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:381868) at r._render (https://xiii.eu.forge-vtt.com/scripts/pixi.min.js:8:381651)

and this error on firefox:
Uncaught DOMException: The operation is insecure. [pixi.min.js:8](https://xiii.eu.forge-vtt.com/scripts/pixi.min.js)
upload core.min.js:8
upload core.min.js:8
updateTexture core.min.js:8
bind core.min.js:8
anonymous pixi.min.js line 8 > Function:33
syncUniforms core.min.js:8
syncUniformGroup core.min.js:8
bind core.min.js:8
_renderDefault mesh.min.js:8
_render mesh.min.js:8
render display.min.js:8
render display.min.js:8
renderAdvanced display.min.js:8
render display.min.js:8
render core.min.js:8
render app.min.js:8
emit ticker.min.js:8
update ticker.min.js:8
_tick ticker.min.js:8

Also in this version it seems to be consistently nonfunctional?
pplans commented 1 year ago

Hello, sorry I am being very busy at the late, I'll try to check it out whenever I can, ty for the callstack it will help a lot

pplans commented 1 year ago

Do you still use that version of Foundry ? Do you still have the issue ?

MCHSXIII commented 1 year ago

I actually just now updated to Foundry V10 Build 290 today, and I just double checked, issue is still the same unfortunately.

pplans commented 11 months ago

Sorry I've been very unreactive this year, 2023 was a bit harsh. Have you tried with the v11 recently ?