Learn Basic JavaScript by Building a Role Playing Game - Step 139

Tell us what’s happening:

I’m just a beginner and I find out something that I don’t understand in javascript rôle playing game, step 139 , the step is asking for six value but we only have four ? or Am I wrong ? Thx for replying

Your code so far

<!-- file: index.html -->

/* file: styles.css */

/* file: script.js */
// User Editable Region

locations.push({
  name: "lose",
  "button text": ["REPLAY?", "REPLAY?", "REPLAY?"],
  "button functions": [restart, restart, restart],
  text: "You die. &#x2620;"
});

// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36

Challenge Information:

Learn Basic JavaScript by Building a Role Playing Game - Step 139

You should be adding an object to the array directly, not using .push().
Your ‘editable region’ is inside the array.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.