Getting width of entire scene.

I would like to get the width of the entire scene and use it in an actors prototype but I can't seem to find it. Can someone kindly point me in the right direction?

The reason is that I have scenes with different sizes and would like to access the width dynamically.

Thanks in advance!

Comments

  • jamie_cjamie_c ImagineLabs.rocks Member, PRO Posts: 5,772
    If you put and actor on in your Scene and then Unlock it's Behaviors. You will be able to get access to the Scene settings through the Expression Editor.
  • jmachado999jmachado999 Member Posts: 52
    So not possible from a prototype?
    Thank you!
  • natzuurnatzuur Member Posts: 304
    edited January 2014
    @jmachado999 A sort of workaround to this would be to place an actor on the right of the scene at the edge and have a global attribute for scene width you create. Then constrain the attribute to self.positionX
  • SocksSocks London, UK.Member Posts: 12,822
    edited January 2014
    So not possible from a prototype?
    Thank you!

    Get the unlocked actor to pass some useful information into a '.game' level attribute (which any actor can access).
  • jamie_cjamie_c ImagineLabs.rocks Member, PRO Posts: 5,772
    What @Socks said...
  • natzuurnatzuur Member Posts: 304
    Yeah you can pass it that way, but that still means an unlocked actor for every scene and manually setting up the logic for that. Although that wouldn't be so bad if you create a custom behavior and just drag it in to the unlocked actor each time, but that does mean unlocking an actor for every scene.

    The other options is to use the method I listed above, one time set up, drag and drop, but you do need to position it.
Sign In or Register to comment.