Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'Create Terrain' button does nothing #15

Closed
K9GM3 opened this issue Dec 17, 2023 · 11 comments
Closed

'Create Terrain' button does nothing #15

K9GM3 opened this issue Dec 17, 2023 · 11 comments

Comments

@K9GM3
Copy link

K9GM3 commented Dec 17, 2023

When I open the Terrain Book and click 'Create Terrain', nothing happens. The 'Add New Terrain' button in the Terrain List also doesn't work.

I'm playing on the latest version in a Firefox browser.

@caewok
Copy link
Owner

caewok commented Dec 20, 2023

Are you sure? On my version, it creates a "New Terrain" in the "All" folder. What I think needs to happen, though, is for some UI message to pop up confirming the creation. Probably open the AE config for that New Terrain...

Screenshot 2023-12-19 at 6 01 04 PM

@K9GM3
Copy link
Author

K9GM3 commented Dec 21, 2023

I tried it again, and nothing appears in any of the folders.

@caewok
Copy link
Owner

caewok commented Dec 21, 2023

Does any error or warning appear in the browser console?

@K9GM3
Copy link
Author

K9GM3 commented Dec 21, 2023

Two of them.

Uncaught (in promise) TypeError: item is undefined [Detected 1 package: terrainmapper] _createActiveEffect https://sansa-seko.moltenhosting.com/modules/terrainmapper/scripts/EffectHelper.js:76 initialize https://sansa-seko.moltenhosting.com/modules/terrainmapper/scripts/EffectHelper.js:60 initialize https://sansa-seko.moltenhosting.com/modules/terrainmapper/scripts/Terrain.js:112 onCreateEffectClick https://sansa-seko.moltenhosting.com/modules/terrainmapper/scripts/TerrainEffectsController.js:153 jQuery 8 _initClickListeners https://sansa-seko.moltenhosting.com/modules/terrainmapper/scripts/TerrainEffectsApp.js:151 activateListeners https://sansa-seko.moltenhosting.com/modules/terrainmapper/scripts/TerrainEffectsApp.js:79 _render https://sansa-seko.moltenhosting.com/scripts/foundry.js:5842 render https://sansa-seko.moltenhosting.com/scripts/foundry.js:5769 onClick https://sansa-seko.moltenhosting.com/modules/terrainmapper/scripts/controls.js:111 _onClickTool https://sansa-seko.moltenhosting.com/scripts/foundry.js:77766 jQuery 9 activateListeners https://sansa-seko.moltenhosting.com/scripts/foundry.js:77721 _render https://sansa-seko.moltenhosting.com/scripts/foundry.js:5842 render https://sansa-seko.moltenhosting.com/scripts/foundry.js:5769 initialize https://sansa-seko.moltenhosting.com/scripts/foundry.js:77672 activate https://sansa-seko.moltenhosting.com/scripts/foundry.js:35016 _onClickLayer https://sansa-seko.moltenhosting.com/scripts/foundry.js:77740 jQuery 2

Uncaught TypeError: layers is undefined [Detected 2 packages: terrainmapper, lib-wrapper] #terrainAt TerrainLayer.js:334 updateTerrainLabel TerrainLayer.js:255 _onMouseMove TerrainLayer.js:239 _onMouseMove Canvas.js:14 _onMouseMove#0 libWrapper-wrapper.js:187 addListeners foundry.js:27346 notifyListeners earcut.js:128 notifyTarget earcut.js:128 propagate earcut.js:128 dispatchEvent earcut.js:128 mapPointerMove earcut.js:128 mapEvent earcut.js:128 onPointerMove earcut.js:128

@computerpro82
Copy link

computerpro82 commented Dec 24, 2023

I am seeing the same symptoms ('Create Terrain' button does nothing) in Chrome Version 120.0.6099.130 (Official Build) (64-bit) with the following errors in the console when I try:

12TerrainLayer.js:334 Uncaught TypeError: Cannot read properties of undefined (reading '0')
at #terrainAt (TerrainLayer.js:334:30)
at TerrainLayer.updateTerrainLabel (TerrainLayer.js:255:36)
at TerrainLayer._onMouseMove (TerrainLayer.js:239:10)
at Canvas._onMouseMove (Canvas.js:14:18)
at 🎁Canvas.prototype._onMouseMove#0 (libWrapper-wrapper.js:187:52)
at mn. (foundry.js:27346:57)
at Na.notifyListeners (earcut.js:128:75)
at Na.notifyTarget (earcut.js:128:75)
at Na.propagate (earcut.js:128:75)
at Na.dispatchEvent (earcut.js:128:75)
at Na.mapPointerMove (earcut.js:128:75)
at Na.mapEvent (earcut.js:128:75)
at yn.onPointerMove (earcut.js:128:75)
#terrainAt @ TerrainLayer.js:334
updateTerrainLabel @ TerrainLayer.js:255
_onMouseMove @ TerrainLayer.js:239
_onMouseMove @ Canvas.js:14
🎁Canvas.prototype._onMouseMove#0 @ libWrapper-wrapper.js:187
(anonymous) @ foundry.js:27346
notifyListeners @ earcut.js:128
notifyTarget @ earcut.js:128
propagate @ earcut.js:128
dispatchEvent @ earcut.js:128
mapPointerMove @ earcut.js:128
mapEvent @ earcut.js:128
onPointerMove @ earcut.js:128
Show 7 more frames
Show less
EffectHelper.js:76 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'uuid')
at EffectHelper._createActiveEffect (EffectHelper.js:76:28)
at EffectHelper.initialize (EffectHelper.js:60:30)
at Terrain.initialize (Terrain.js:112:30)
at TerrainEffectsController.onCreateEffectClick (TerrainEffectsController.js:153:19)
at HTMLButtonElement.dispatch (jquery.min.js:2:43184)
at y.handle (jquery.min.js:2:41168)
_createActiveEffect @ EffectHelper.js:76
initialize @ EffectHelper.js:60
initialize @ Terrain.js:112
onCreateEffectClick @ TerrainEffectsController.js:153
dispatch @ jquery.min.js:2
y.handle @ jquery.min.js:2
await in y.handle (async)
dispatch @ jquery.min.js:2
y.handle @ jquery.min.js:2
5TerrainLayer.js:334 Uncaught TypeError: Cannot read properties of undefined (reading '0')
at #terrainAt (TerrainLayer.js:334:30)
at TerrainLayer.updateTerrainLabel (TerrainLayer.js:255:36)
at TerrainLayer._onMouseMove (TerrainLayer.js:239:10)
at Canvas._onMouseMove (Canvas.js:14:18)
at 🎁Canvas.prototype._onMouseMove#0 (libWrapper-wrapper.js:187:52)
at mn. (foundry.js:27346:57)
at Na.notifyListeners (earcut.js:128:75)
at Na.notifyTarget (earcut.js:128:75)
at Na.propagate (earcut.js:128:75)
at Na.dispatchEvent (earcut.js:128:75)
at Na.mapPointerMove (earcut.js:128:75)
at Na.mapEvent (earcut.js:128:75)
at yn.onPointerMove (earcut.js:128:75)

@Peter360
Copy link

Create Terrain button does nothing
VTT 11 Stable build 315
pf2e 5.11.5

this._source.system.traits is undefined

pf2e.mjs:1617
Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'value')
at ItemPF2e._preCreate (pf2e.mjs:1617:295688)
at #preCreateDocumentArray (foundry.js:13541:31)
at ClientDatabaseBackendPF2e._createDocuments (foundry.js:13428:73)
at ClientDatabaseBackendPF2e.create (commons.js:8629:19)
at async Proxy.createDocuments (commons.js:7958:23)
at async Proxy.create (commons.js:8081:23)
at async Settings.initializeTerrainsItem (settings.js:202:18)
at async Object.fn (module.js:73:3)

@caewok
Copy link
Owner

caewok commented Jan 3, 2024

Should be fixed in v0.1.0.

@caewok caewok closed this as completed Jan 3, 2024
@computerpro82
Copy link

Symptoms remain the same. Console feedback in Chrome is below:
Uncaught (in promise) Error: A listener indicated an asynchronous response by returning true, but the message channel closed before a response was received
EffectHelper.js:76 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'uuid')
at EffectHelper._createActiveEffect (EffectHelper.js:76:28)
at EffectHelper.initialize (EffectHelper.js:60:30)
at Terrain.initialize (Terrain.js:111:30)
at TerrainEffectsController.onCreateEffectClick (TerrainEffectsController.js:154:19)
at HTMLButtonElement.dispatch (jquery.min.js:2:43184)
at y.handle (jquery.min.js:2:41168)
_createActiveEffect @ EffectHelper.js:76
initialize @ EffectHelper.js:60
initialize @ Terrain.js:111
onCreateEffectClick @ TerrainEffectsController.js:154
dispatch @ jquery.min.js:2
y.handle @ jquery.min.js:2
await in y.handle (async)
dispatch @ jquery.min.js:2
y.handle @ jquery.min.js:2
2foundry.js:3687 Foundry VTT | Synchronized official game time in 34ms

@caewok caewok reopened this Jan 8, 2024
@caewok
Copy link
Owner

caewok commented Jan 8, 2024

I think this is because of issue #20. Something changed in PF2e and it will no longer create the item needed to store the terrains.

@caewok
Copy link
Owner

caewok commented Jun 22, 2024

Try in Foundry v12.

@caewok caewok closed this as completed Jun 22, 2024
@K9GM3
Copy link
Author

K9GM3 commented Jun 22, 2024

The new patch works! =D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants