How do I make scroll button and scroll panel remember previous location with user simulated touch?

0 favourites
  • 2 posts
From the Asset Store
All popular touch mechanics - scrolling, zooming, swiping
  • I have multiple panels that open and close. When a user opens a panel they have previously used, I want the scroll button and the panel to be where it last was. The panel has objects that move with touch panel and scroll button with bar.

    I was using RexRainbow's simulate touch plug-in but it doesn't work with C3. I had it working with the plug-in.

    Here is what it was:

    Event: variable=PanelOpenTrue

    Action: SimulateKeyEvent Simulate touch:ButtonX start at (variablelastlocation, Scrollbar.Y) on layer Panel1.Layername

    Action: System wait 0.05 seconds

    Action: SimulateKeyEvent Simulate touch:Button.Active end

    Button has variable named Active.

    I am running into the problem of the button moving but the touch panel is not moving with the button. Once I click on the button the panel moves into the correction position. This is why I need a user simulated touch.

    How can I do this in C3?

    Note: sometimes the panels have new content requiring objects in panel to be destroyed on close panel and then objects created on open panel.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • MasterNedyah

    Without going into details, an easy would be to use Local Storage to remember scroll position which is updated every time scroll moves. On opening the panel, position can be retrieved from Local Storage

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)