VikasSanstha's Recent Forum Activity

  • You do not have permission to view this post

  • For anyone that might read this in the future, this is what was required in the end. I love how simple it turned out to be.

  • That was it. Thanks so much for your help.

  • I put in a text box to confirm AJAX.LastData and it is coming through but not the numeric values, and I get the same error in the console.

    runtime.js:23 [Construct] Failed to parse JSON: SyntaxError: Unexpected token 'A', "AJAX.LastData" is not valid JSON

    at JSON.parse (<anonymous>)

    at ArrayInstance.JSONLoad (runtime.js:23:47)

    at Action._RunObject_ParamsConst (action.js:23:451)

    at EventBlock._RunActions_Fast (eventBlock.js:26:208)

    at EventBlock._RunAndBlock (eventBlock.js:24:415)

    at EventBlock.Run (eventBlock.js:21:393)

    at EventSheet._ExecuteTrigger (eventSheet.js:19:154)

    at EventSheet._TriggerForClass (eventSheet.js:13:302)

    at EventSheet._Trigger (eventSheet.js:12:205)

    at EventSheetManager._Trigger (eventSheetManager.js:15:90)

    Project File

    json file

  • If anyone can help with this, I have spent like 4 hours trying to get it to work to no avail.

  • It's saying it's not a valid json file

    {

    "colors": [ {"r": 255, "g": 0, "b": 0}, {"r": 0, "g": 255, "b": 0}, {"r": 0, "b": 0, "g": 255} ]

    }

    I feel like it's close.

  • I got a CORS error, which I fixed by updating the .htaccess, and that's not happening anymore. I get one error in the console.

    Failed to parse JSON: SyntaxError: Unexpected token 'A', "AJAX.LastData" is not valid JSON

    at JSON.parse (<anonymous>)

    at ArrayInstance.JSONLoad (runtime.js:23:47)

    at Action._RunObject_ParamsConst (action.js:23:451)

    at EventBlock._RunActions_Fast (eventBlock.js:26:208)

    at EventBlock._RunAndBlock (eventBlock.js:24:415)

    at EventBlock.Run (eventBlock.js:21:393)

    at EventSheet._ExecuteTrigger (eventSheet.js:19:154)

    at EventSheet._TriggerForClass (eventSheet.js:13:302)

    at EventSheet._Trigger (eventSheet.js:12:205)

    at EventSheetManager._Trigger (eventSheetManager.js:15:90)

  • Ok, it is https and I have the second bit in place. What comes next if I can ask? I'm sorry I am not very technically competent.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thanks for your reply.

    I have a json file uploaded for testing purposes at vikasapp.org/res/script/randomBgColors.json

    with these contents, for testing

    {

    "colors": [ {"r": 255, "g": 0, "b": 0}, {"r": 0, "g": 255, "b": 0}, {"r": 0, "b": 0, "g": 255} ]

    }

    and I have a barebones .c3p project here on dropbox

    that loads this json via ajax, and has a dictionary and array object, but I really don't understand what to do after that. Any assistance is greatly appreciated. Thank you.

  • Any ideas? I'm sure it must be possible. Any help would be greatly appreciated. Thank you.

  • I have many projects that I want to all share the same set of random background colors

    choose (rgb(255, 154, 162), rgb(255, 183, 178), rgb(255, 218, 193),rgb(226, 240, 203),rgb(181, 234, 215),rgb(199, 206, 234),rgb(175, 228, 254))

    I want the values to all be referenced from one external file, so that if I change the colors, it applies to all projects without me having to do anything further. Can someone suggest a good strategy for doing this? Everything I've tried has not worked.

    Thank you

  • Hi Ashley, are you aware of this issue? Can you please offer any suggestions if possible? Thank you.

    It is referenced in this post as well, from 2011 - construct.net/en/forum/construct-2/how-do-i-18/bring-android-keyboard-90980

VikasSanstha's avatar

VikasSanstha

Member since 24 Jul, 2021

None one is following VikasSanstha yet!

Trophy Case

  • 3-Year Club
  • Forum Contributor Made 100 posts in the forums
  • RTFM Read the fabulous manual
  • Email Verified

Progress

6/44
How to earn trophies