{"version":3,"sources":["main.js"],"names":["catchOptionsArray","type","name","commonName","about","record","proTip","imageUrl","moreInfoUrl","scenes","app","Vue","el","data","game","canvas","document","getElementById","showLoading","showWelcome","showGame","showCatch","showCastButton","showReelButton","scene","sceneRegion","sceneLearnMoreUrl","selectedCatch","catchOptions","audioTrack","audioIsPlaying","computed","mounted","this","$nextTick","addEventListener","e","sceneCatchOptions","filter","catchOptionsForScene","Math","floor","random","length","reset","gtag","event_category","event_label","watch","val","oldVal","style","display","resize","body","position","methods","doCast","doReelIn","setScene","Audio","loop","option","indexOf","playAgain","resetGame","stopAudio","playAudio","play","pause","learnMore"],"mappings":"AAAA,IAAIA,kBAAoB,CACtB,CACEC,KAAM,OACNC,KAAM,UACNC,WAAY,cACZC,MAAO,oKACPC,OAAQ,qFACRC,OAAQ,8GACRC,SAAU,wCACVC,YAAa,wDACbC,OAAQ,CAAC,iBAAiB,6BAA6B,qBAEzD,CACER,KAAM,OACNC,KAAM,kBACNC,WAAY,iBACZC,MAAO,+KACPC,OAAQ,sFACRC,OAAQ,2GACRC,SAAU,+CACVC,YAAa,uDACbC,OAAQ,CAAC,iBAAiB,6BAA6B,qBAEzD,CACER,KAAM,OACNC,KAAM,kBACNC,WAAY,iBACZC,MAAO,uMACPC,OAAQ,0FACRC,OAAQ,iEACRC,SAAU,+CACVC,YAAa,uDACbC,OAAQ,CAAC,iBAAiB,6BAA6B,qBAEzD,CACER,KAAM,OACNC,KAAM,gBACNC,WAAY,eACZC,MAAO,6KACPC,OAAQ,6FACRC,OAAQ,8GACRC,SAAU,6CACVC,YAAa,sDACbC,OAAQ,CAAC,iBAAiB,6BAA6B,qBAEzD,CACER,KAAM,OACNC,KAAM,cACNC,WAAY,YACZC,MAAO,yLACPC,OAAQ,6GACRC,OAAQ,4GACRC,SAAU,uCACVC,YAAa,sDACbC,OAAQ,CAAC,iBAAiB,6BAA6B,qBAEzD,CACER,KAAM,OACNC,KAAM,2BACNC,WAAY,cACZC,MAAO,+MACPC,OAA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A4C,GAArCA,EAAOrD,OAAOsD,QAAQ9B,KAAKT,QAEpCwC,UAAW,WACT/B,KAAKnB,KAAK8B,QACVX,KAAKX,gBAAiB,EACtBW,KAAKV,gBAAiB,EACtBU,KAAKd,aAAc,EACnBc,KAAKb,UAAW,EAChBa,KAAKZ,WAAY,EACjBwB,KAAK,QAAS,aAAc,CAC1BC,eAAkB,eAClBC,YAAed,KAAKT,SAGxByC,UAAW,WACThC,KAAKnB,KAAK8B,QACVX,KAAKX,gBAAiB,EACtBW,KAAKV,gBAAiB,EACtBU,KAAKd,aAAc,EACnBc,KAAKb,UAAW,EAChBa,KAAKZ,WAAY,EACdY,KAAKJ,YACNI,KAAKiC,YAEPrB,KAAK,QAAS,cAAe,CAC3BC,eAAkB,eAClBC,YAAed,KAAKT,SAGxB2C,UAAW,WACTlC,KAAKJ,WAAWuC,OAChBnC,KAAKH,gBAAiB,EACtBe,KAAK,QAAS,QAAS,CACrBC,eAAkB,eAClBC,YAAe,aAGnBmB,UAAW,WACTjC,KAAKJ,WAAWwC,QAChBpC,KAAKH,gBAAiB,EACtBe,KAAK,QAAS,QAAS,CACrBC,eAAkB,eAClBC,YAAe,cAGnBuB,UAAW,WACTzB,KAAK,QAAS,UAAW,CACvBC,eAAkB,eAClBC,YAAed,KAAKP","file":"main.min.js","sourcesContent":["var catchOptionsArray = [\r\n {\r\n type: \"fish\",\r\n name: \"Walleye\",\r\n commonName: \"17\\\" Walleye\",\r\n about: \"Walleye prefer clear-water lakes and can be found in large rivers like the Mississippi. They stay in deep water during the day and move to the shallows at night.\",\r\n record: \"Tony Brothers hooked the state record 35-inch, 18 lb walleye in 1933 on High Lake.\",\r\n proTip: \"Cast or troll minnows, leaches, night crawlers or small plugs. These large-eyed fish see well in low light.\",\r\n imageUrl: \"assets/dist/img/fish/fish-walleye.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/walleye.html\",\r\n scenes: [\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"],\r\n },\r\n {\r\n type: \"fish\",\r\n name: \"Smallmouth Bass\",\r\n commonName: \"13\\\" Smallmouth\",\r\n about: \"Perhaps the state's scrappiest game fish, \\\"smallies\\\" like rocky streams or lakes where they can find their favorite food: crayfish. In summer, they seek deep, cool waters.\",\r\n record: \"Leon Stefonek hooked the state record 9 lb, 1 oz smallmouth in 1950 on Indian Lake.\",\r\n proTip: \"Fish quietly and cast near old logs or rocks using natural baits like hellgrammites or dragonfly larvae.\",\r\n imageUrl: \"assets/dist/img/fish/fish-smallmouthbass.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/smbass.html\",\r\n scenes: [\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"],\r\n },\r\n {\r\n type: \"fish\",\r\n name: \"Largemouth Bass\",\r\n commonName: \"14\\\" Largemouth\",\r\n about: \"Largemouth bass is the largest member of the sunfish family. \\\"Bucketmouth\\\" has excellent sight, smell and hearing. It prefers warm water and likes to hide under lily pads, docks or in weedy areas.\",\r\n record: \"Robert Milkowski hooked the state record 11 lb, 3 oz largemouth in 1940 on Lake Ripley.\",\r\n proTip: \"Don’t forget to use a weedless bait or you may lose your lure!\",\r\n imageUrl: \"assets/dist/img/fish/fish-largemouthbass.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/lmbass.html\",\r\n scenes: [\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"],\r\n },\r\n {\r\n type: \"fish\",\r\n name: \"Northern Pike\",\r\n commonName: \"23\\\" Northern\",\r\n about: \"Northern pike spawn along marshy shorelines or marshy streams flowing into lakes. During the day, they lurk in weed beds and feed on whatever passes their trap-like jaws.\",\r\n record: \"J.A. Rahn hooked the state record 45.5-inch, 38 lb northern pike in 1952 on Lake Puckaway.\",\r\n proTip: \"Use a steel leader and keep your bait moving! Hungry northern pike will bite on nearly anything that swims.\",\r\n imageUrl: \"assets/dist/img/fish/fish-northernpike.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/npike.html\",\r\n scenes: [\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"],\r\n },\r\n {\r\n type: \"fish\",\r\n name: \"Muskellunge\",\r\n commonName: \"55\\\" Musky\",\r\n about: \"The musky, or muskie, is the largest predatory fish in the state, inhabiting waters from rivers to Great Lakes. They live alone, searching weed beds and tangles of old logs for prey.\",\r\n record: \"Louis Spray hooked the famed state record 63.5-inch, 69 lb and 1 oz musky in 1949 on the Chippewa Flowage.\",\r\n proTip: \"Bring big bait and a steel leader for these fighters! Jerk baits, spoons and bucktails are popular lures.\",\r\n imageUrl: \"assets/dist/img/fish/fish-muskie.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/musky.html\",\r\n scenes: [\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"],\r\n },\r\n {\r\n type: \"fish\",\r\n name: \"King (or Chinook) Salmon\",\r\n commonName: \"30\\\" Chinook\",\r\n about: \"Native to the Pacific Ocean, king (or Chinook) salmon are stocked from state fish hatcheries into the Great Lakes' tributaries and harbors. From there, the young fish head for the open waters of the lake.\",\r\n record: \"Josh Bostedt hooked the state record 47.5-inch, 44 lb and 15 oz Chinook salmon in 1994 on Lake Michigan.\",\r\n proTip: \"Fish for Chinook in open waters during the summer and near shore in the fall.\",\r\n imageUrl: \"assets/dist/img/fish/fish-chinooksalmon.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/troutsalmon.html\",\r\n scenes: [\"Lake Michigan\"]\r\n },\r\n {\r\n type: \"fish\",\r\n name: \"Coho Salmon\",\r\n commonName: \"22\\\" Coho\",\r\n about: \"Coho salmon were stocked in the Great Lakes to help control alewives. The Pacific Ocean-natives are raised in fish hatcheries and stocked into tributaries of Lake Michigan as young fish.\",\r\n record: \"John Gregory hooked the state record 38-inch, 26 lb and 1.9 oz coho salmon in 1999 on Lake Michigan.\",\r\n proTip: \"Try trolling on the Great Lakes using shiny flashers or fish for coho near spawning streams in the fall.\",\r\n imageUrl: \"assets/dist/img/fish/fish-cohosalmon.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/troutsalmon.html\",\r\n scenes: [\"Lake Michigan\"]\r\n },\r\n {\r\n type: \"fish\",\r\n name: \"Rainbow Trout\",\r\n commonName: \"25\\\" Rainbow\",\r\n about: \"Rainbow trout, or steelheads, were introduced to the Great Lakes for sport fishing. Native to the Pacific Ocean, young fish raised in hatcheries are stocked into Great Lakes' tributaries and inland waters.\",\r\n record: \"Debbie Morrison hooked the state record 42.5-inch, 27 lb and 2 oz rainbow trout in 1997 on Lake Michigan.\",\r\n proTip: \"Fish at night! Use anything from minnows to flies to catch these hard-fighting fish.\",\r\n imageUrl: \"assets/dist/img/fish/fish-rainbowtrout.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/troutsalmon.html\",\r\n scenes: [\"Lake Michigan\"]\r\n }, \r\n {\r\n type: \"fish\",\r\n name: \"Lake Trout\",\r\n commonName: \"28\\\" Lake Trout\",\r\n about: \"Lake trout, or lakers, naturally reproduce in a few northen lakes and, to a limited extent, in lakes Superior and Michigan. They are also stocked in some of the state's deepest, coldest lakes.\",\r\n record: \"Waino Roose hooked the state record 47 lb lake trout in 1946 on Lake Superior.\",\r\n proTip: \"Fish the shallows with live or cut bait in the early season and troll the deep waters later in the year. In winter, bobbing or jigging works well.\",\r\n imageUrl: \"assets/dist/img/fish/fish-laketrout.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/troutsalmon.html\",\r\n scenes: [\"Lake Michigan\"]\r\n },\r\n {\r\n type: \"fish\",\r\n name: \"Brown Trout\",\r\n commonName: \"24\\\" Brown\",\r\n about: \"Sport fish the Great Lakes for brown trout in early spring, before other species begin to bite. Anglers can wade, fish from piers with live bait or artificial lures or troll in inshore water with imitation minnows or other plugs.\",\r\n record: \"Roger Hellen hooked the state record 40.6-inch, 41 lb and 8 oz brown trout in 2010 on Lake Michigan.\",\r\n proTip: \"Brown trout love mayflies! Fish inland streams during mid-May to mid-June using dry flies. In fall spawning season, use gold-colored lures.\",\r\n imageUrl: \"assets/dist/img/fish/fish-browntrout.jpg\",\r\n moreInfoUrl: \"https://dnr.wi.gov/topic/fishing/species/troutsalmon.html\",\r\n scenes: [\"Lake Michigan\"]\r\n },\r\n {\r\n type: \"message\",\r\n name: \"\",\r\n commonName: \"Darn, that one got away\",\r\n about: \"\",\r\n record: \"\",\r\n proTip: \"\",\r\n imageUrl: \"assets/dist/img/fish/catch-got-away.svg\",\r\n moreInfoUrl: \"\",\r\n scenes: [\"Lake Michigan\",\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"]\r\n },\r\n {\r\n type: \"message\",\r\n name: \"\",\r\n commonName: \"Oops, you caught a boot\",\r\n about: \"\",\r\n record: \"\",\r\n proTip: \"\",\r\n imageUrl: \"assets/dist/img/fish/catch-boot.svg\",\r\n moreInfoUrl: \"\",\r\n scenes: [\"Lake Michigan\",\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"]\r\n },\r\n {\r\n type: \"message\",\r\n name: \"\",\r\n commonName: \"Oh no! You broke your line\",\r\n about: \"\",\r\n record: \"\",\r\n proTip: \"\",\r\n imageUrl: \"assets/dist/img/fish/catch-line-broke.svg\",\r\n moreInfoUrl: \"\",\r\n scenes: [\"Lake Michigan\",\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"]\r\n },\r\n {\r\n type: \"message\",\r\n name: \"\",\r\n commonName: \"You lost your bait, try again\",\r\n about: \"\",\r\n record: \"\",\r\n proTip: \"\",\r\n imageUrl: \"assets/dist/img/fish/catch-lost-bait.svg\",\r\n moreInfoUrl: \"\",\r\n scenes: [\"Lake Michigan\",\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"]\r\n },\r\n {\r\n type: \"message\",\r\n name: \"\",\r\n commonName: \"Hook snagged, go fish\",\r\n about: \"\",\r\n record: \"\",\r\n proTip: \"\",\r\n imageUrl: \"assets/dist/img/fish/catch-snagged.svg\",\r\n moreInfoUrl: \"\",\r\n scenes: [\"Lake Michigan\",\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"]\r\n },\r\n {\r\n type: \"message\",\r\n name: \"\",\r\n commonName: \"Nothin’ but seaweed\",\r\n about: \"\",\r\n record: \"\",\r\n proTip: \"\",\r\n imageUrl: \"assets/dist/img/fish/catch-seaweed.svg\",\r\n moreInfoUrl: \"\",\r\n scenes: [\"Lake Michigan\",\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"]\r\n },\r\n {\r\n type: \"message\",\r\n name: \"\",\r\n commonName: \"Patience is a virtue\",\r\n about: \"\",\r\n record: \"\",\r\n proTip: \"\",\r\n imageUrl: \"assets/dist/img/fish/catch-patience.svg\",\r\n moreInfoUrl: \"\",\r\n scenes: [\"Lake Michigan\",\"Lake Winnebago\",\"Eagle River Chain of Lakes\",\"Chippewa Flowage\"]\r\n }\r\n];\r\n\r\nvar app = new Vue({\r\n el: '#app',\r\n /* variables */\r\n data: {\r\n game: null,\r\n canvas: document.getElementById(\"renderCanvas\"),\r\n showLoading: false,\r\n showWelcome: true,\r\n showGame: false,\r\n showCatch: false,\r\n showCastButton: false,\r\n showReelButton: false,\r\n scene: 'Lake Winnebago',\r\n sceneRegion: 'Central Wisconsin',\r\n sceneLearnMoreUrl: '',\r\n selectedCatch:{},\r\n catchOptions:catchOptionsArray,\r\n audioTrack:{},\r\n audioIsPlaying: false,\r\n },\r\n computed:{\r\n },\r\n mounted: function () {\r\n this.$nextTick(function () {\r\n // Code that will run only after the entire view has been rendered\r\n //window.addEventListener(\"resize\", this.resizeCanvas, false);\r\n \r\n document.addEventListener('game:ReelInStarted', function (e) { \r\n //console.log(e);\r\n app.showReelButton = false;\r\n }, false); \r\n document.addEventListener('game:ReelInEnded', function (e) { \r\n //console.log(e);\r\n var sceneCatchOptions = app.catchOptions.filter(app.catchOptionsForScene);\r\n app.selectedCatch = sceneCatchOptions[Math.floor(Math.random() * sceneCatchOptions.length)]; \r\n app.showCatch = true;\r\n app.game.reset();\r\n\r\n gtag('event', 'Caught', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': app.selectedCatch.commonName\r\n });\r\n\r\n }, false); \r\n document.addEventListener('game:CastStarted', function (e) { \r\n //console.log(e);\r\n app.showCastButton = false; \r\n }, false); \r\n document.addEventListener('game:CastEnded', function (e) { \r\n //console.log(e) \r\n app.showReelButton = true; \r\n }, false); \r\n \r\n })\r\n },\r\n watch: {\r\n showGame: function (val, oldVal) {\r\n if(val){ \r\n document.getElementById('renderCanvas').style.display = \"block\";\r\n this.game.resize();\r\n }\r\n },\r\n showCatch: function (val, oldVal) {\r\n document.body.style.position = val ? \"fixed\" : null;\r\n },\r\n },\r\n methods:{\r\n doCast: function(e){\r\n this.game.doCast();\r\n gtag('event', 'Cast', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': this.scene\r\n });\r\n },\r\n doReelIn: function(e){\r\n this.game.doReelIn();\r\n gtag('event', 'Change Lake', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': this.scene\r\n });\r\n \r\n },\r\n setScene: function(e){\r\n this.scene = e;\r\n switch (e) {\r\n case 'Chippewa Flowage':\r\n this.sceneRegion = \"Northern Wisconsin\";\r\n this.sceneLearnMoreUrl = \"/article/fishing/best-places-to-fish-in-wisconsin-chippewa-flowage\";\r\n this.audioTrack = new Audio('assets/dist/audio/chippewa.mp3');\r\n break;\r\n case 'Eagle River Chain of Lakes':\r\n this.sceneRegion = \"Northern Wisconsin\";\r\n this.sceneLearnMoreUrl = \"/article/fishing/best-places-to-fish-in-wisconsin-eagle-river-chain\";\r\n this.audioTrack = new Audio('assets/dist/audio/eagleriver.mp3');\r\n break;\r\n case 'Lake Michigan':\r\n this.sceneRegion = \"Eastern Wisconsin\";\r\n this.sceneLearnMoreUrl = \"/article/things-to-do/fall-means-world-class-musky-salmon-action\";\r\n this.audioTrack = new Audio('assets/dist/audio/lakemi.mp3');\r\n break;\r\n case 'Lake Winnebago':\r\n this.sceneRegion = \"Central Wisconsin\";\r\n this.sceneLearnMoreUrl = \"/article/fishing/best-places-to-fish-in-wisconsin-lake-winnebago\";\r\n this.audioTrack = new Audio('assets/dist/audio/winnebago.mp3');\r\n break; \r\n default:\r\n this.sceneRegion = \"\";\r\n this.sceneLearnMoreUrl = \"\";\r\n this.audioTrack = null;\r\n }\r\n this.audioTrack.loop = true;\r\n\r\n this.game.setScene(e);\r\n this.game.reset();\r\n this.showCastButton = true;\r\n this.showReelButton = false;\r\n this.showWelcome = false;\r\n this.showGame = true;\r\n gtag('event', 'Start Fishing', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': this.scene\r\n });\r\n\r\n },\r\n catchOptionsForScene: function(option){\r\n return option.scenes.indexOf(this.scene) >= 0;\r\n },\r\n playAgain: function(){\r\n this.game.reset();\r\n this.showCastButton = true;\r\n this.showReelButton = false;\r\n this.showWelcome = false;\r\n this.showGame = true;\r\n this.showCatch = false;\r\n gtag('event', 'Fish Again', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': this.scene\r\n });\r\n },\r\n resetGame: function(){ \r\n this.game.reset();\r\n this.showCastButton = false;\r\n this.showReelButton = false;\r\n this.showWelcome = true;\r\n this.showGame = false;\r\n this.showCatch = false;\r\n if(this.audioTrack){\r\n this.stopAudio();\r\n }\r\n gtag('event', 'Change Lake', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': this.scene\r\n }); \r\n },\r\n playAudio: function(){\r\n this.audioTrack.play(); \r\n this.audioIsPlaying = true;\r\n gtag('event', 'Audio', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': 'Enabled'\r\n }); \r\n },\r\n stopAudio: function(){\r\n this.audioTrack.pause();\r\n this.audioIsPlaying = false;\r\n gtag('event', 'Audio', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': 'Disabled'\r\n });\r\n },\r\n learnMore: function(){\r\n gtag('event', 'Explore', {\r\n 'event_category': 'Fishing Game',\r\n 'event_label': this.sceneLearnMoreUrl\r\n });\r\n }\r\n }\r\n });"]}