Quick question about MoveNodeToSlot, is it random?

Home 4 Forums iOS / tvOS Starter Kits The Story Tellers Kit 2 for iOS or tvOS Apps Quick question about MoveNodeToSlot, is it random?

This topic contains 3 replies, has 2 voices, and was last updated by  Martin Ortiz 1 year, 5 months ago.

  • May 4, 2018 at 7:50 pm #183609

    I actually want it to be random….

    Does MoveNodeToSlot place sprites into random slots? Or is it in order?

    SLOT0, SLOT1, SLOT2, SLOT3…….

  • May 5, 2018 at 1:59 pm #183639

    You’re making me remember code here =) . Soooo if the Slot has already been occupied it would move onto the next one. Think of it a little bit like the Game of Life board game where a piece moves from one spot to the next (assuming you only ever spun a 1). So yeah it would be in order.

  • May 5, 2018 at 2:09 pm #183641

    Lemme answer your emailed question here too…

    Do you have recommendations? Also I need to do this, and leave the already correctly placed puzzle pieces alone, how do I distinguish between a completed puzzle piece and a free puzzle piece?

    Do a search in the code for func listenForPairing. Scroll down a bit and just to make it easy look for the line that plays the click sound. Look for “click.caf”

    Anywhere under there, you could write…

    element1.name = “Rename”

    And that would name it something different and should keep it from being affected by other events that reference the original name.

  • May 5, 2018 at 2:26 pm #183642

    OK thanks

You must be logged in to reply to this topic.

Become part of the CartoonSmart Team with our Affiliate Program

Make recurring money when you refer a subscriber. 30 day tracking. Commissions 33%-50%!

Uh oh, missing your affiliate ID. Create one real quick