Multiple choices input

HI connoisseurs of Hype js coding.

I’m working on a questionnaire, where the user is presented with multiple choices. (23.5 KB)
I was provided with the example html file with linked counter.js file written in classic bare-bones JavaScript.
I did the parsing of the delivered assets:

  1. I made a new JS Function, named it documentonload()
    and copied the js code part from the html body of the example file delivered.
  2. I activated documentonload() as Action on Scene Load in Scene Inspector.
  3. I made another JS Function and called it counter(). Copied the whole content of counter.js ‘as it’,
    and activated it on the first frame as Timeline Action.

I provided all buttons with their unique element IDs accordingly to naming convention in counter.js

Something isn’t right, though.

1 Like

Just Globalise the COUNTER function in the Hype counter() function

COUNTER = function() {..

i.e remove the var tag

1 Like

Thank you Mark for looking at the code, problem solved!