Discussion for the unofficial, community-developed addons, extensions and scripts built for the Waze Map Editor.

The official index of these tools is the Community Plugins, Extensions and Tools wiki page.
Post by pvo11
wlodek76 wrote: Is it possible to get these both scripts to work together better :?:
I mean that WME Road Closures hides icon of WME Live Map Alerts Overlay :-/
Maybe it is possible to manage their Z-Index and get icons on the top.
I've prepared a new version which changes index of "Road Closures" layer (Z-Index change didn't help) to be lower than "LiveMap Alerts Overlay" layer. It works fine the Road Closure line is shown under the alert icons but the "LiveMap Alerts Overlay" doesn't show the alert details in this case therefore I dint not post the new version and I will contact davielde directly to find common solution.
wlodek76 wrote: Btw. Did you think about linking all the segments into a one long line. The dashed line will have a continuity in drawing then. Ex. by checking start and end of each segment or their angles ;)
Yes, I thought about it but it is not so important and it has no priority I will do it probably later together with changing width of the line based on the zoom.
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
wlodek76 wrote: Try this simple code, it seems to be a solution and it works fine.
I've posted new version with simplified modification of your code. It works fine. Thank you for your sample.
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
wlodek76 wrote: Unfortunatelly your method in v0.4 doesn't work at least for me :?
Could you send me a permalink to this or does it not work everywhere?
wlodek76 wrote: I think you must to sort both Z-Index and apply them to both layers, because layers could be loaded in different order.
I think it is not necessary to set same values when they are in correct order therefore I didn't use sorting.
wlodek76 wrote: Btw. IMO perhaps lines are too wide, maybe strokeWidth 12,10,10 instead of 14,12,12 should be enough. However it could be a personal thing, I prefer thinner, narrower lines here ;)
I think the width should depend on zoom :-) but it should completely cover the road.
wlodek76 wrote: Fix B a small improvement for situation where we do not have WME LiveMap Alerts Overlay installed ;)
I've tested the version 0.4 in FF and Chome, both with and without WME LiveMap Alerts Overlay and everything worked correct. It is strange. I will try to test it with different script order in the Mokeys.
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
pvo11 wrote:I will try to test it with different script order in the Mokeys.
I've changed the execution order of the scripts but it works fine too.

There are two differences between your and my code.
1) I don't search for my own layer because I have it in the variable closuresLayer
2) I don't set setZIndex if there is no change
Włodzimierz could you apply this two changes to your version to see if some of them is the reason of the problem in your browser?
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
It is strange with your new version is the road closure line in the front of alerts icons. With the old version was the line behind the icons.
Closule_alert.jpg
(4.4 KiB) Downloaded 1008 times
This means now I have the behavior as Włodzimierz has and I can test it.
This cold be the differnce. Włodzimierz probably modified both scripts and I did may test with unmodified WME LiveMap Alerts Overlay.
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
wlodek76 wrote: I will try to investigate the problem and I will test it more acuratelly. Maybe it is something with the layer ordering :roll:. I have more then 10 different scripts for wme installed :-)
I've tested my script with your code with the new version of WME LiveMap Alerts Overlay an the behavior is same as with my code. The line is in the front of the icons on my computer in both browsers.
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
It works on my computer now; the new version of WME LiveMap Alerts Overlay has different uniqueName = "__livemap_alerts". Therefore my script didn't find the layer.
I will wait with the new release for Włodzimierz's tests.
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
wlodek76 wrote: Btw. Davielde did some proposed changes in his code and the layer is named now __livemap_alerts
I found the same but you are faster. :) . We made the posts in the same time.
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
I've posted new version 0.5 which works correctly with WME Live Map Alerts Overlay 0.2.
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message

Post by pvo11
Version 0.6 released.
  • line width depends on zoom now
  • error drawing segments with both ends outside visible area corrected (long segments and/or higher zoom)
pvo11
Map Editor - Level 5
Map Editor - Level 5
Posts: 1763
Has thanked: 263 times
Been thanked: 1014 times
Send a message