619_RM's Recent Forum Activity

  • dop2000 Well done buddy, it is beautiful.

  • Thank you dop2000 I finally able to crack it. One question though, on my particular setup when the player comes back from the bonus stage and after that, if the user clicks the restart button (Layout Restart) the player position changed to the new location that is the position of EXIT sprite. How can I make the player position to start at Original Start Position when user click the restart button?

    I tried this way but it's not working.

    https://s5.gifyu.com/images/Untitled06458bca7eda1820.jpg

    (I dunno why but I unable to upload any image file may be a bug thus used gifyu.com)

    Please help.

    Re-download this example, it should be more clear now:

    https://www.dropbox.com/s/oo4bpeo5gujxbzz/PortalSystem.c3p?dl=0

  • This should be incorporated as an action into C3.

    Of course it doesn't work - you didn't set array width to 0, you didn't insert new record to the end of the array, you didn't delete the last record when going back..

    See this fixed project:

    https://www.dropbox.com/s/l1le3x8zp3roth9/LayoutHistory.c3p?dl=0

  • You are awesome . . . Thank you.......

    Of course it doesn't work - you didn't set array width to 0, you didn't insert new record to the end of the array, you didn't delete the last record when going back..

    See this fixed project:

    https://www.dropbox.com/s/l1le3x8zp3roth9/LayoutHistory.c3p?dl=0

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You are awesome . . . Thank you.......

    Of course it doesn't work - you didn't set array width to 0, you didn't insert new record to the end of the array, you didn't delete the last record when going back..

    See this fixed project:

    https://www.dropbox.com/s/l1le3x8zp3roth9/LayoutHistory.c3p?dl=0

  • Thanks, dop2000 I created the Array, Please check the c3p. The issue is

    [ Map: MenuLayout>OptionLayout>SubOptionLayout ]

    When the user at "SubOptionLayout" and click back It will lead to "OptionLayout" and then at "OptionLayout" when the user clicks back it again lead to the previous layout that is "SubOptionLayout". So whats happing here is The user is going forward and backwards between "OptionLayout" & "SubOptionLayout" on a loop. :(

    Recording a history is also not too difficult. Create an empty array with width=0. On end of any layout push a new record into the array with LayoutName.

    When you need to go back to previous layout, read last layout name from the array - Array.At(Array.width-1), then delete this index.

  • This is heaven! You guys are providing it for free? Thank you dop2000 & dazedangels. #Respect

  • Thank you tarek2 I appreciate what you have done, providing a capx is so nice of you. Sorry for not making it clear actually I tot it might be worked but you are right for my setup it needs a full history back button.

    > Thank you for your input. Your Layout seems chronological

    > > 619_RM try this one see if it helps

    > >

    > >

    > > https://www.dropbox.com/s/yz0nx7dthyes1s3/go%20back%20previous%20layout.capx?dl=0

    When you press buttons to go directly to the Levels yes is chronological just for simplicity but you are not interested in that, if you look again you are only interested in Event (4 & 6) I deliberately left it not chronological so you can implement it easily with your events, it's just two lines of code sudden be hard.

    I think probably you are looking for something else perhaps a full history? and not just the last layout you visited

  • It worked. Thank you dop2000. One question!

    In my setup there one thing which I missed, if someone goes to MenuLayout>OptionLayout>SubOptionLayout, then he clicks the back button at "SubOptionLayout" he redirects to "OptionsLayout" then if he clicks to the back button again he goes back SubOptionLayout".

    This may be the reason why Constcut doesn't have a back button (history) natively. Is there any workaround or it is better to place a separate back button on each layout?

    Save layout name into the global variable in "On end of layout" event.

  • Thank you for your input. Your Layout seems chronological

    619_RM try this one see if it helps

    https://www.dropbox.com/s/yz0nx7dthyes1s3/go%20back%20previous%20layout.capx?dl=0

  • I dug into the community I found

    LittleStain "Simple way would be creating a global variable LastLayout and before the action to change layout use an action to set LastLayout to the current Layout. In the new layout : On button touched go to layout : LastLayout"

    Tired the same but alas not working maybe because I have many layouts having different names not in sequential order, like "ABCLayoutTrue", "HelpLayoutOptional".... some random names.

    Begeegee has given a capx which what I was looking for but, it does not work on my setup.

    Please help.

    Tagged:

  • Begeegee Please help me I cant make it work.

    Put this CAPX together real quick. It's just a simple project with 4 layouts (3 regular layouts and an Inventory layout). The 3 regular layouts share a single event sheet - note: you don't NEED to do this, as they can still have their own sheets and work. Inventory layout has its own inventory sheet.

    "On Start of Layout", as suggested by Equinox80, the layout name is stored in a global variable called Last_Layout. I've made it a text variable, and one easy way to do it would be to simply use the system expression "LayoutName" to automatically set the variable to the name of the current layout.

    In the Inventory Sheet, when the Back button is pressed, I simply use "Go to layout (by name)" and type in the "Last_Layout" variable.

    Remembering Last Layout CAPX

    Hope this is what you're looking for!

619_RM's avatar

619_RM

Member since 1 Jun, 2019

Twitter
619_RM has 1 followers

Trophy Case

  • 5-Year Club
  • Forum Contributor Made 100 posts in the forums
  • RTFM Read the fabulous manual
  • Great Comment One of your comments gets 3 upvotes
  • Email Verified

Progress

9/44
How to earn trophies