How do I transform Json into spreadsheet (XLS or googlesheets)?

0 favourites
  • 6 posts
From the Asset Store
Convert multiple Excel files into JSON files and import them into construct3.
  • I'm planning on making a game with tons of dialogues, so I'm using .json files to put all the text in the game. I'm also planning to:

    1) work with several different narrative designers;

    2) translate all the text to several different languages;

    3) make a "make-your-own-quest" style of editor, where any player can make their own storyline by editing the lines in .json.

    But the narrative designers, translators and (especially) players do not have Construct 3 and it's pretty much impossible to try logically changing .json as it is:

    (spreadsheet as I see it in Construct 3)

    (json file I get if try to download it)

    The "easy" solution to that problem is just selecting all the content inside the Construct 3 json editor spreadsheet and pressing CTRL+C, CTRL+V to paste content inside the google spreadsheets. It does work. But there are several errors with that method. For example, after I will receive new dialogues in google spreadsheets - I need to manually CTRL+C, CTRL+V them inside of Construct 3 engine's json file editor. So it can help if I'm with narrative designers and translators but generic player will not be able to do that on his own, so I'd have to abandon the idea to allow players to make their own content by simply changing .json. Also this way is a bit tedious, since even a small error while selecting / copying / pasting (and backwards) can result in a game being umplayable.

    Is there a way to easily convert json table that Construct 3 generates into XLS (microsoft office) format and backwards (from XLS into json that Construct 3 will understand)?

    I've tried several different automated online JSON->XLS converters but they all change the initial json's Construct 3 spreadsheet into something barely recognisable (structurully-wise).

    If there is no option to do that - I would like to suggest implementing such a converter as a possible next feature inside Construct 3: Import XLS as a json / export json as a XLS. I know devs might have more important things to do but I'm sure I'm not the only one struggling with it. Also, I'm not a programmer myself but I think it shouldn't be too difficult to implement, since the original json file editor in Construct 3 already pretty much looks like a table from windows excel.

    Thanks.

  • You can use CSV file format - export the table from Excel or Google Sheets to a CSV file, add this file to the project. Use CSV2Array addon to load it into an array at runtime.

    But personally I think using the array editor in C3 and simply copying/pasting text between it and Excel is a much easier option. I do this all the time.

  • My recommendation is to learn how to actually use a Json data file as a project file, parsed in via the Json object, rather than a construct array as Json.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • My recommendation is to learn how to actually use a Json data file as a project file, parsed in via the Json object, rather than a construct array as Json.

    Seems like an advice of this kind: "my car tire is flat, please help me" -> "learn how to repair the engine first".

    The whole reason I'm using Construct 3 instead of Unity or Unreal is the "easy to learn no programming knowledge is required" thing. I'm not sure how making things more complicated for me will help me to make things easier. I wanted to know if there is a way to make an easy export to spreadsheet - not spend dozens (or in my case maybe hundreds) of hours learning some stuff I may not need in the future.

    But thanks for an advice.

  • You can use CSV file format - export the table from Excel or Google Sheets to a CSV file, add this file to the project. Use CSV2Array addon to load it into an array at runtime.

    But personally I think using the array editor in C3 and simply copying/pasting text between it and Excel is a much easier option. I do this all the time.

    Thanks, I'll look into it!

  • > My recommendation is to learn how to actually use a Json data file as a project file, parsed in via the Json object, rather than a construct array as Json.

    Seems like an advice of this kind: "my car tire is flat, please help me" -> "learn how to repair the engine first".

    The whole reason I'm using Construct 3 instead of Unity or Unreal is the "easy to learn no programming knowledge is required" thing. I'm not sure how making things more complicated for me will help me to make things easier. I wanted to know if there is a way to make an easy export to spreadsheet - not spend dozens (or in my case maybe hundreds) of hours learning some stuff I may not need in the future.

    But thanks for an advice.

    Just wanted to emphasize that for your previously stated goals, interfacing directly with JSON project files would be the most suitable. JSON is not a programming language, its a data storage format.

    Rather than learning how to build a car engine, I'm trying to tell you that a proper bicycle, that other people are familiar with and know how to use (JSON is a standard, easily modifiable text file), will get you farther than a shopping cart with oars that you're going to need to teach people how to work with (fiddling with c3 arrays as json, importing and exporting between c3 and external spreadsheet software, and utilizing unsuitable formats like csv).

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