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

#5139 added prior mapID to onChangeMap #5140

Open
wants to merge 9 commits into
base: develop
Choose a base branch
from

Conversation

Jmr3366
Copy link
Contributor

@Jmr3366 Jmr3366 commented Jan 18, 2025

Identify the Bug or Feature request

#5139 to add prior mapID.

Description of the Change

When using the onChangeMap event, the output will now include both the going to mapID and the coming from mapID

Possible Drawbacks

There is a change in the macro.args passed output so any macro that does not account for two string parameters will likely fail and/or generate an error.

Release Notes

When the onChangeMap macro code is executed per the wiki,
it will now return two map ID's
landing mapID, launched from mapID


This change is Reviewable

Jmr3366 and others added 2 commits January 18, 2025 10:41
I placed the priorMapID above some error checks causing inconsistent results.
@cwisniew
Copy link
Member

@Jmr3366 have you tested this when loading a new campaign because I think this might send the zone id of the previous campaign

@Jmr3366
Copy link
Contributor Author

Jmr3366 commented Jan 19, 2025

Yes Sir, you are correct. I did test loading a campaign several times but it was the same one and I didn't catch that. Let me dig deeper

@Jmr3366
Copy link
Contributor Author

Jmr3366 commented Jan 19, 2025

@cwisniew I added the checks to priorMapID.
It seems at times the ZoneLoadedListener event is NOT triggered every time

When I load a campaign fresh from a MT closed state, it triggers every time (eg close MT, open it, load a camp.).
When I have MapTool open and load a new campaign, it triggers.
If I open another campaign, it stops triggered until I change maps (then it does trigger).
However loading a new campaign again it does NOT trigger (until I change maps).

-edit/updated-

Test process:
campaignA: 3mb
campaignB: 14mb (a copy of A with more stuff )
campaignC: 62mb

fresh build running via ide
Load 1 campaignA: onChangeMap 0F1F5C9FEFF34A9C8022602214146A13
Load 2 campaignB: onChangeMap 0F1F5C9FEFF34A9C8022602214146A13
Load 3 campaignC: onChangeMap D167B57E0AB94AF69E430F21665CA215
Load 4 campaignA: nothing
Load 5-7 campB,C,A: nothing

New Camp, add library token, add onChangeMap macro,
add Map (triggered): onChangeMap 689AECFA1A7E40458614C7DD65D720EF

Closing MT resets this.
This may be a new bug (not certain) and believe it's unrelated to what I've done re: priorMapID addition

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

Successfully merging this pull request may close these issues.

2 participants