{"version":3,"sources":["jsdelivr-header.js","/npm/wmd-ts-number-game@1.0.3/dist/index.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;OCJS,SAAY,mBACZ,YAAe,sBACf,gBAAmB,oBACnB,aAAgB,uBAChB,cAAiB,wBACjB,iBAAoB,2BACpB,gBAAiB,0BAA6B,6BAC9C,eAAkB,kBAG3B,WAOI,SANM,wBACA,qBAEA,YAAY,OAGM,oBAFI,YAES,OAC3B,WAEN,IAAI,GAAiB,EACrB,KAAO,GAAgB,OACb,wBACN,IAAI,QAAqB,mBAEnB,YAAY,GAIM,iBAFI,KAAK,KAM7B,GAAiB,QACX,UAEd,CACJ,YAEU,SAEb,EA/BD","file":"/npm/wmd-ts-number-game@1.0.3/dist/index.js","sourceRoot":"","sourcesContent":["/**\n * Minified by jsDelivr using Terser v5.39.0.\n * Original file: /npm/wmd-ts-number-game@1.0.3/dist/index.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","#!/usr/bin/env node\r\n// Number guessing game\r\nimport { game } from './game.js';\r\nimport { quitApp } from './quitApp.js';\r\nimport { modesOfGame } from './modes.js';\r\nimport { startApp } from './startApp.js';\r\nimport { askToPlay } from './askToPlay.js';\r\nimport { instructions } from './instructions.js';\r\nimport { wellcomeMessage, wellcomeMessageStatic } from './welcomeMessage.js';\r\nimport { askForMode } from './askForMode.js';\r\n/**********************************************************************/\r\n// Call all app functions in a particular sequence\r\n(async () => {\r\n    await wellcomeMessage();\r\n    await instructions();\r\n    // display all modes\r\n    await modesOfGame('all');\r\n    let askToPlayChoice = await askToPlay();\r\n    // based on user choise start or quit app\r\n    if (askToPlayChoice === 'Play Game') {\r\n        await startApp();\r\n        // set the app to run untill stoped\r\n        let playAgainCheck = true;\r\n        while (playAgainCheck) {\r\n            await wellcomeMessageStatic();\r\n            let selectedMode = await askForMode();\r\n            // display mode based on user choice\r\n            await modesOfGame(selectedMode);\r\n            // play games based on mode\r\n            let resultPlayAgain = await game(selectedMode);\r\n            // quit or play again based on result\r\n            if (resultPlayAgain === '👍 Yes') {\r\n                continue;\r\n            }\r\n            else {\r\n                playAgainCheck = false;\r\n                await quitApp();\r\n            }\r\n        }\r\n    }\r\n    else {\r\n        await quitApp();\r\n    }\r\n})();\r\n"]}