Event Observer & Switching Worlds

Discussion in 'Technical Discussion' started by Kevin W, Jun 29, 2018.

  1. Kevin W

    Kevin W Avid Boxer

    Joined:
    Sep 25, 2015
    Messages:
    367
    Likes Received:
    486
    Hey Team,

    Looking for some clarification here to put my brain to rest!

    Am I right in assuming that event observers do not honour any settings once you switch worlds, IE: any parameter is reset?

    EG:

    World 1:
    Player collects 1 point > Event Observer set to 1 total point collected and does something with 1 point collected > works great.

    World 2:
    Player collects 1 point ( now has 2 in total ) Event Observer set to 2 total points collected and does something with 2 points collected > nothing :(

    If you could clarify that all the settings must be contained within a single world loop that would be great, and if this is the case, I'm sure this should go on the feature list and it seriously limits the power of the event observers imo.

    I did notice: 2.3.6
    updated: event observer now uses running total for coins/currency

    Can you explain what this means please? @Andy @Sean Buildbox
     
  2. AaroArts

    AaroArts Miniboss Boxer

    Joined:
    Jun 22, 2016
    Messages:
    1,532
    Likes Received:
    815
    Regarding the World 2 example:
    Currently, I believe the Event Observer resets the count when you change World (you'd have to collect 2 Points in the new World before it does anything). See this example attached in 2.3.6.
    However, if you're using Event Observers just to change UI in the same World, the count doesn't reset.

    Event Observer now uses running total for coins/currency, means that Total Coins on Event Observers are now adjusted if some are spent.
    For example, if you earn 150 Coins in your game, and your Game Over has an Event Observer for 100 Coins to take you to a Page that says "Hey, you have enough coins for a new Character", when you buy a Character for 100 Coins from that page, then replay and get Game Over again, the Event Observer now knows you only have 50 left, so wouldn't redirect you to the "Hey you..." page, like it did before (at least until you have enough coins again).
     

    Attached Files:

    Kevin W likes this.
  3. Kevin W

    Kevin W Avid Boxer

    Joined:
    Sep 25, 2015
    Messages:
    367
    Likes Received:
    486
    Hey thanks dude, that makes sense and thanks for the clarification on both points, much appreciated.

    As with all things BB, workarounds depend on the overall set up so your example is not going to help for this one, but I'm truly grateful that you spent the time to hook that up for me, very cool :)

    That does give a little more juice to the event observer for sure however it would be awesome to have it adhere globally - I guess for your example it sure was broke before haha

    Thanks again dude, awesome stuffs!
     
    AaroArts likes this.
  4. AaroArts

    AaroArts Miniboss Boxer

    Joined:
    Jun 22, 2016
    Messages:
    1,532
    Likes Received:
    815
    @adrogdesigns Try the BBDoc I uploaded here. Session points are working here and swapping UI.
    But as I say, I'm not using the final release of 2.3.6, I'm still using the last beta.
     
    adrogdesigns likes this.
  5. adrogdesigns

    adrogdesigns Avid Boxer

    Joined:
    Dec 5, 2016
    Messages:
    318
    Likes Received:
    233
    thanks mate ill have a look..
     

Share This Page