PDA

View Full Version : Can I update tokens in existing encounters?



ArcaneTheWoof
April 4th, 2025, 11:49
I'm updating the Tomb of Annihilation campaign module to 2024 rules, and one of the things I've been doing is changing the tokens of the monsters using a newer set with higher-resolution artwork (plus tokens for some of the monsters that didn't have any). However, changing the token assigned to a monster doesn't propagate to the encounters that monster has been placed in. If I add the monster to the encounter again, the newly-added monster will have the new token. So, since it seems that the token change doesn't automatically propagate, is there a way to force the propagation manually? It's a big campaign and it'll be a huge pain to go through and manually replace every instance of every monster in every encounter...

Moon Wizard
April 4th, 2025, 17:40
The tokens for each encounter can be customized; so they are set when the NPC is dragged to the encounter. You can override by unlocking the encounter; and dragging the new token to the encounter NPC row token field.

Regards,
JPG

Nylanfs
April 4th, 2025, 18:00
Note: these changes are ONLY limited to that campaign. A new campaign would have the default info.

Moon Wizard
April 4th, 2025, 18:04
Though the change file for that module could be copied between campaigns manually in File Explorer if needed.

Regards,
JPG

ddavison
April 4th, 2025, 18:14
The change file Moon Wizard mentions can be found in a sub-folder of the campaign's folder called moduledb. You will see one or more XML files there that are named after modules you have activated. Any modifications or overrides you have made to those modules within the current campaign will be there. As Moon Wizard states, you can copy that to the moduledb folder of a new campaign and your changes will be copied over.

nerothewoof
April 5th, 2025, 00:42
Okay, sorry if I was unclear; as I stated in the question, I’m aware that you can update the token by dragging in the updated monster again and then placing that monster onto the map again. This means I’ll have to go through the campaign and do this for hundreds of monsters. Doing this is awful.

Surely there’s a way to quickly sweep through all instances of a monster in the campaign and update their tokens so that you don’t have to go through this arduous manual process? Surely if I place 200 instances of a Soldier monster in dozens of encounters across a campaign, then update the Soldier with a new token, there’s a way to say “all Soldiers use this new token” that isn’t “manually place all 200 soldiers again”? Surely?

ArcaneTheWoof
April 5th, 2025, 00:45
(That last message was from me. My phone logged me in to the wrong account and I didn’t notice.)

LordEntrails
April 5th, 2025, 01:24
Okay, sorry if I was unclear; as I stated in the question, I’m aware that you can update the token by dragging in the updated monster again and then placing that monster onto the map again. This means I’ll have to go through the campaign and do this for hundreds of monsters. Doing this is awful.

Surely there’s a way to quickly sweep through all instances of a monster in the campaign and update their tokens so that you don’t have to go through this arduous manual process? Surely if I place 200 instances of a Soldier monster in dozens of encounters across a campaign, then update the Soldier with a new token, there’s a way to say “all Soldiers use this new token” that isn’t “manually place all 200 soldiers again”? Surely?
No. Open the encounter. Replace the token shown in the encounter. Then when you add the Encounter to the map it will use the new token. Yes you will have to do this to each encounter, but not to each instance of an NPC on the map.

There is no way to replace all instances of "orc" with a new token in a purchased module. You can do it via xml if you created the module, but purchased ones are protected via encryption so you can not access the xml directly.

If it's important to you, you can add the enhancement request to the https://www.fantasygrounds.com/featurerequests

ArcaneTheWoof
April 5th, 2025, 01:30
It is important to me and I’ll be requesting it, thank you; with the new 2024 rules, I don’t think it’s too out there that users will want to update purchased legacy content, and having to do all of the monsters individually is… cumbersome. Thanks for pointing me to the request form :)

Zacchaeus
April 5th, 2025, 09:36
Just to clarify what it is you are doing or want to do.

If you simply want to change the token of an NPC in an encounter then open the encounter and drag in a new token and drop it onto the token to the left of the number on the line for that monster in the encounter. This will change the token for all of the NPCs in that encounter on that line (so if you have 10 soldiers in the encounter then changing that one token will change the token for all of them). This won't change the token for any of the same NPCs in any other encounter nor on the NPC list. There is no need to replace the NPC on the map; the token that you allocate will be used when the encounter is placed. The token in the encounter links directly to the token assets and not to the token on the NPC; hence the reason why you are able to update the token in the encounter and why changing the token in the NPC list doesn't update those in any encounter.

If, on the other hand, you want to replace the NPC in the encounter to the 2024 version of the NPC then you will have to delete the existing NPCs in the encounter and add in the new ones and then replace those new ones on the map. If you are also changing the token then doing so in the NPC list before adding the NPC to the encounter will use that token.

snupy
April 6th, 2025, 21:48
There is no way to replace all instances of "orc" with a new token in a purchased module. You can do it via xml if you created the module, but purchased ones are protected via encryption so you can not access the xml directly.

If it's important to you, you can add the enhancement request to the https://www.fantasygrounds.com/featurerequests

If the file is not encrypted how do you do it by editing the xml?

Zacchaeus
April 6th, 2025, 22:13
Encounters are listed in the db.xml for the campaign in the <battle> </battle> section of the code. You would need to go through each encounter listed there and find for example:


<token type="token">tokens/F_goblin_Archer[goblin,hobgoblin,chieftan].webm@TP153 Goblins Animated</token>

And replace it with the token you want.

NPCs are listed in the xml under <npc> </npc> and again you'd need to go through them all and change the name and location to the token you want.

A lot easier to do it inside FGVTT and a lot less prone to error I'd suggest.

snupy
April 6th, 2025, 22:23
Encounters are listed in the db.xml for the campaign in the <battle> </battle> section of the code. You would need to go through each encounter listed there and find for example:


<token type="token">tokens/F_goblin_Archer[goblin,hobgoblin,chieftan].webm@TP153 Goblins Animated</token>

And replace it with the token you want.

NPCs are listed in the xml under <npc> </npc> and again you'd need to go through them all and change the name and location to the token you want.

A lot easier to do it inside FGVTT and a lot less prone to error I'd suggest.

Thanks! Well I guess with the XML file you could try multiple search and replace or awk or whatever. Although that is very error prone indeed.

Griogre
April 6th, 2025, 22:40
You would edit the XML that contains the referenced "Orc" NPC and by changing the token path from the current one to the path of your replacement token. FYI, token in the XML means the top down graphic and the element you are looking for in the NPC starts with <token>. These days there are also 2.5D images and pictures for each NPC as well. If you don't put anything in the 2.5D element FGU uses the <token> path for that and if nothing is in either FGU will default to a letter token.

As mentioned above most source NPCs are from a source module that is encrypted, a good example of one that is not encrypted is the 5E SRD Bestiary

Edit it would not be as error prone as you think since the part before and after the actual graphics name won't change if all the NPCs are from the same source.

snupy
April 7th, 2025, 07:46
You would edit the XML that contains the referenced "Orc" NPC and by changing the token path from the current one to the path of your replacement token. FYI, token in the XML means the top down graphic and the element you are looking for in the NPC starts with <token>. These days there are also 2.5D images and pictures for each NPC as well. If you don't put anything in the 2.5D element FGU uses the <token> path for that and if nothing is in either FGU will default to a letter token.

As mentioned above most source NPCs are from a source module that is encrypted, a good example of one that is not encrypted is the 5E SRD Bestiary

Edit it would not be as error prone as you think since the part before and after the actual graphics name won't change if all the NPCs are from the same source.

Thanks for the explanation!

Nylanfs
April 7th, 2025, 13:01
But make sure you backup your data before making changes! Also follow the 3-2-1 rule!