5E Character Create Playlist

Thread: Bug in code

  1. #1

    Bug in code

    Found a case when 'power_page.lua', 'onPowerWindowAdded' is been called before its 'onInit' for this class..

    I was under the impression 'onInit' would always be called first ?

    Not sure if this is a special case due to this been in a list of items, or if its possible to in-general manage to call functions on classes before they are initialised...

    I've attached a zip with a campaign and the 5e rule set file with debug chat in the onInit and onPowerWindowAdded functions.

    You just need to open the campaign 'camp', open character 'bob' and swap to the 'actions' tab.

    ( just unzip and place into FGC or FGU with an unpacked 5e ruleset... etc.. )

    -pete

    Moderator:
    Moved to a more appropriate place.
    Attached Files Attached Files
    Last edited by Zacchaeus; September 25th, 2020 at 17:50.

  2. #2
    When a window is initialized, then all the child control onInit functions are called in order of definition; then the windowinstance onInit is called. It is possible that due to events or script calls that other functions within a window/control script can be called before the onInit function.

    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 Product Walkthrough Playlist

Log in

Log in