Accessing custom *scene* attributes?

IgnisIgnis Member Posts: 72
edited November -1 in Working with GS (Mac)
I wonder if I'm just blind and not seeing this in the editor? I can access all of the Game attributes and actor attributes (custom or built-in), but I just added a custom scene attribute and I can't determine how to access it from the Expression Editor pop-up window.

The reason I want to do this: I have a camera window (currently IPhone size) that moves about a larger scene, let's call it "medium city" for sake of discussion, 720w by 680h. In future scenes, however, I might increase this scene size to "large city" at 1200w by 1000h or something like that. I'd really like to read these dimensions for multiple usage methods, i.e. determining where in each scene an object should be moved to, or to re-spawn in the upper-right corner which would vary depending on the scene size... hopefully that's a clear explanation?

Help is appreciated as always, during this learning stage...

Comments

  • firemaplegamesfiremaplegames Member Posts: 3,211
    Only instances of the Actor in the Scene can access Scene attributes. Double-click on the Actor in the Scene, and click on the padlock to access its behaviors.

    I usually have one actor in every Scene that sits just out of view and "broadcasts" things like Scene width, height, the camera position etc... to global game attributes that all the other Actors in the Scene can access.
  • netdzynrnetdzynr Member Posts: 296
    Actors within a scene can also access other actor's attributes directly, without having jump through the hoops of using game-level variables. The limitation, as FMG said, is this only works with instances of actors in the current scene -- you can't use this method with the actors' prototypes.
Sign In or Register to comment.