DICE PACKS BUNDLE
  1. #1

    Join Date
    May 2014
    Location
    Sydney, Australia
    Posts
    808

    Faster ruleset debugging cycle

    Hi,

    I am currently doing some ruleset development using eclipse as my ide. I have a project which points to the fg data ruleset folder and I am making changes and testinga lot ('cos I haven't got much idea what I'm doing yet) and the issue that I have is having to keep manually changing to the FZg app and /reload to update or if it's a module change, quit and restart.

    Is there any way to call fg with command line arguments to load a given campaign or to anything like that? Also is there any way to remote control fg using an external program like eclipse or ant? Maybe, again using command line arguments to send chat commands...

    Cheers,

    Ian

  2. #2
    Mask_of_winter's Avatar
    Join Date
    Feb 2009
    Location
    USA Eastern Time Zone (GMT -5/-4)
    Posts
    2,479
    Blog Entries
    1
    In the chat window type /reload
    Writer for Just Insert Imagination and co-host of the Wild Die Podcast.
    Find me on G+ to get in on one-shots, check out my YouTube and Twitch channel and follow me on Twitter @Mask_of_Winter

  3. #3
    For modules, you can close and reactivate from the Module Activation screen.

    For rulesets, the /reload chat command is the the mechanism. Also, make sure to use the Debug.chat/Debug.console commands to help you output Lua variables to uncover details of issues.

    Regards,
    JPG

  4. #4
    Valarian's Avatar
    Join Date
    Mar 2007
    Location
    Worcestershire, UK
    Posts
    2,567
    Without a visual layout editor (Psicodelix's project), there's no way to check the results of the XML changes without loading the changes in to FG. Editor on one screen, FG on a second. Type /reload to view the changes just done in the editor in the FG window. If you're working in a ruleset in the rulesets folder, this is the quickest method. Extensions can also be worked on in the unzipped form, in a sub-folder of extensions. Modules, as yet, can't.
    Using Ultimate license - that means anyone can play.
    Valarian's Fantasy Grounds Rulesets

  5. #5

    Join Date
    May 2014
    Location
    Sydney, Australia
    Posts
    808
    I know that I can manually switch from eclipse to fg and type /reload in the chat window but Inwas looking fir a way to automate this and/ or other actions from eclipse using ant. It would mean I could just make a change and have fg reload and open a character (for example) without having to do it manually each time. It would require fg client to have a listener for chat commands and a way to send them to it (maybe simply have a command line argument which forwards the command to a running fg).
    I think it might be useful in other situations too you could have an external program sending messages to the chat window.

  6. #6
    Trenloe's Avatar
    Join Date
    May 2011
    Location
    Colorado, USA
    Posts
    33,362
    Another good tip for ruleset/extension debugging: remove all tokens from you /tokens folder while debugging (copy them back when you're playing). All tokens in these folders are loaded each time you type /reload. If you have a bunch of tokens in the /tokens directory it can make a few seconds difference in load time if you temporarily remove them while developing.
    Private Messages: My inbox is forever filling up with PMs. Please don't send me PMs unless they are actually private/personal messages. General FG questions should be asked in the forums - don't be afraid, the FG community don't bite and you're giving everyone the chance to respond and learn!

  7. #7
    The same goes for modules and extensions. Close or disable ones that you are not specifically developing them.

    Also, I usually type /reload in chat entry and drag to F12 so that I reload with a single key press.

    Regards,
    JPG

  8. #8

    Join Date
    May 2014
    Location
    Sydney, Australia
    Posts
    808
    That's a good idea!
    I guess I can make a chat window command to open up a character sheet or open the combat tracker (depending which I'm debugging) and use a F key to reload and open?

  9. #9

    Join Date
    May 2014
    Location
    Sydney, Australia
    Posts
    808
    Whould it be possible to add LuaSocket support? I tried but it seem that FG doesn't support the required dynamic lua package stuff it needs.
    With luasocket maybe I can add a listener socket and send it commands.

    Ian

  10. #10
    If you are trying to send commands between client/host use the OOB message support in the Comm package.

    No plans to add socket support, since this creates some security questions and then you have even more port forwarding issues. The Lua within FG is deliberately sandboxed.

    Regards,
    JPG

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
  •  
Starfinder Playlist

Log in

Log in