DICE PACKS BUNDLE
  1. #1

    Debug.chat not working in named-script onInit function

    I just noticed while doing some testing that a Debug.chat('test') line in an onInit function of a named script is not showing up in chat.
    I'm assuming the chat may not be available when that function is called, or perhaps it's something else.
    Here's a little ext to make it easy to replicate.

    EDIT: Comm.addChatMessage also seems to be unusable when called from onInit like this.
    Attached Files Attached Files
    Last edited by bmos; August 3rd, 2022 at 15:06.

  2. #2
    MeAndUnique shared Interface.onDesktopInit as an alternate approach, so if this is just 'intended behavior' I get it and would suggest it be added to https://fantasygroundsunity.atlassia...6645578/script.
    Last edited by bmos; August 3rd, 2022 at 15:45.

  3. #3
    If you use Debug.chat in the global scripts, those are actually called before the chat window exists; so there is no chat window to write to. In those scenarios, the application falls back to writing to console log.

    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
  •  
5E Character Create Playlist

Log in

Log in