Pilsmer's Forum Posts

  • 4 posts
  • Thank you Lionz. I will explore these options.

  • Hi everyone. I am new to Construct 3 and I am just getting to grips with it. I have a good idea about the functionality of my game, but I am struggling to work out the best way to handle event sheets and procedures across multiple layouts.

    Say I have two layouts (Menu and Gameplay), each with their own events sheet. I also have a third event sheet where I hold my functions.

    Q1) Is this the best way to structure my project?

    Q2) What would be the best way of handling the following?

    I press a button on the Menu screen. The resulting actions are

    • Go to Gameplay screen

    • Call a function that animates the game board in the Gameplay screen

    My current solution is to hold the ‘Go to Gameplay layout’ event in the Menu event sheet and then call the function as part of the ‘On start of layout’ event held in the Gameplay event screen. However, I don’t think this is the best solution.

    Any advice, tutorials or documentation on this subject would be greatly appreciated.

    Thank you"

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thank you very much!

  • Hi, Happy New Year.

    I am new to Construct 3 and am using it to build a puzzle game. The format of the game is a 3x3 grid of buttons which each have a pattern of spots on them. I need to get the board layout into a 2d array from a json file.

    So the json looks like this.

    {"1":{"layout": [[0,1],[1,3,4,7],[2],[2,3,6],[4,8],[1,3,5,8],[6],[4,5,7],[3,8]],...},

    "2":{"layout": [[0,3,4],[1,5,7],[1,2],[3],[3,4],[2,5,6,7],[2,3,6],[0,7],[4,8]],...},

    ...}

    In the json, the layout takes the format of a nested list of 9 elements, one for each button. The nested values (of which there is a maximum of 4 in each element) denote the pattern on each button.

    Say that board number 1 is selected from the directory and the value is assigned to a variable called 'boardNum'. How do I assign the layout to a 9x4 array? E.g. layoutArray = boardnum.layout

    One thing I suspect is not ideal is having the nested list in square brackets. I created the json directory in Python and made the layout as a Python list. I can easily change this format if required.

    Thanks in advance for any help you can provide.

    Cheers,

    Pilsmer.

  • 4 posts