Save Position

YummyYummy Member Posts: 51
edited November -1 in Working with GS (Mac)
i cannot figure this out, I have an actor

When this actor Is pressed and dragged (I set this up) it moves ,

But I want it to save the position (any ideas)

I have another scene that has the button and I want it to be saved

Thanks Let me know

Comments

  • cbtcbt Member Posts: 644
    Make 2 global attributes;
    PosX and PosY.

    On that actor you drag and drop add;
    Constrain PosX to Self.Position X
    Constrain PosY to Self.Position Y

    On the new scene, to the actor you want, add to the beginning;
    Change Self.Position X to PosX
    Change Self.Position Y to PosY
  • YummyYummy Member Posts: 51
    Thank you!!!!

    But im running into a problem, when i click start game (without going to settings) i see that all the button is at the very bottom but when i open the other window then click back and goto the next scene its all good, any clues of how i can fix this? thanks
  • MotherHooseMotherHoose Member Posts: 2,456
    yuck... just spent the morning trying to get the positions user-set for 25 different drag-able actors!

    Yummy... I think the problem is the initial state of posX, posY is 0,0 ... therefore the actor goes to 0,0 before drag/drop event.

    so have in the opening scene the the constrain.Positions in a rule to happen when touch is released.
    When touch is pressed...your drag constrain Attributes
    When touch is released ... your constrain to self.Postition.

    MH
  • YummyYummy Member Posts: 51
    Ahh yes i see,

    Thank you cbt and mothergoose for your help , i greatly appreciate it!
Sign In or Register to comment.