DICE PACKS BUNDLE
  1. #1

    Yet another thread that asks about coin weights and extensions, sorta...

    Hello All. First let me say that as a returning user of FG I am glad to see the community is still actively helping one another. This feels welcoming, like putting on an old pair of comfy socks on a cold night. Anyway.. Thanks for that.

    I have a related question to the above topic in the title but have been unable with all my lurking and searching over the last few days to find an answer.

    I have a home-brew world that I am currently exploring with my players using 5e, I have enough custom content and rules that I have decided to give making an extension and corresponding module (for the things that extensions don't handle) a try. This is in its early stages and I am new to both XML and LUA. My question comes down to the following; I would like for any new campaigns I create for this world in FGU to have all the basic things preloaded (like custom languages, coins, etc.) so that I don't spend time entering these items in over and over every time a new campaign starts. I figured out the languages and fonts without much trouble, as I had dealt with that in classic, but I am having issues getting the custom coins to load upfront.

    I have dropped the following text:
    GameSystem.currencies = {"AS";"CP";"GP";"PP";"SP";"TS"};
    into the LUA code and it populates the fields upon creation as you would expect, but i can't seem to nail getting the weights (or values) in also. I expect it is a lack of understanding of the structure on my part, but I would appreciate a push in the right direction.

    Thanks so much in advance,
    Xyvius
    Last edited by Xyvius; December 29th, 2022 at 04:44.

  2. #2
    LOL, Why does this always happen, decided to move on and wait for a reply and came across a format that answered the question for me. Seems like the answer is always found after a I publicly voice my ignorance .

    For any who find this thread and need to know the answer (simple as expected) I found to be:
    GameSystem.currencies = {
    { name = "AS", weight = 0.002, value = 10 },
    { name = "CP", weight = 0.02, value = .01 },
    { name = "GP", weight = 0.02, value = 1 },
    { name = "PP", weight = 0.02, value = 10 },
    { name = "SP", weight = 0.02, value = 0.1 },
    { name = "TS", weight = 0.002, value = 10 },
    };

  3. #3
    Zacchaeus's Avatar
    Join Date
    Dec 2014
    Location
    Scotland
    Posts
    20,828
    The easiest way to do this is set up a new campaign and adjust everything in that campaign how you like it (note that you can adjust the coin weight and values inside FGU now). Then just copy the folder inside your campaigns folder and rename the copy to whatever you want.

    See video Forty Two here for other methods and other things you can do to preserve settings over multiple campaigns https://www.fantasygrounds.com/forum...-do-I-in-Unity
    If there is something that you would like to see in Fantasy Grounds that isn't currently part of the software or if there is something you think would improve a ruleset then add your idea here https://www.fantasygrounds.com/featu...rerequests.php

  4. #4
    Thanks for the share Zacchaeus. I am always impressed with how helpful this community is. I watch your videos and will continue to do so. As for the copy method, I will keep that in mind in the future. Though I must admit that I will probably continue to look into how to set stuff up through an extension, if for no other reason just to learn it... It is how my head works. But, that being said. It's a good thing to know and keep in my "tool-belt". I am looking forward to learning more about XML and LUA.

    Thanks again!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
5E Character Create Playlist

Log in

Log in