human.min.js 76 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378
  1. import * as PIXI from './pixi';
  2. import { Howl, Howler } from './howler.min';
  3. var XORcipher = require('./XORcipher')
  4. import gamen from './gamen';
  5. import NumberText from './NumberText';
  6. import { TimelineLite, Sine, TweenMax, Back } from './TweenMax.min'
  7. import { pixelRatioX, pixelRatioY, windowWidth, windowHeight } from './fitConfig';
  8. var GD, GamePadManager, DataManager;
  9. var GAME_IMG_PATH = 'https://pub.dwstatic.com/wxgame/bugsmatch/BugsMatch/';
  10. var COMMON_IMG_PATH = 'https://pub.dwstatic.com/wxgame/bugsmatch/human/';
  11. var RES_DIR_SOUND = GAME_IMG_PATH + 'sound/';
  12. // source code version
  13. var CACHE_VER = 0.2;
  14. var IMG_VERSION = CACHE_VER;
  15. var SOUND_VERSION = CACHE_VER;
  16. !function (t) {
  17. function e(n) {
  18. if (i[n])
  19. return i[n].exports;
  20. var o = i[n] = {
  21. exports: {},
  22. id: n,
  23. loaded: !1
  24. };
  25. return t[n].call(o.exports, o, o.exports, e),
  26. o.loaded = !0,
  27. o.exports
  28. }
  29. var i = {};
  30. return e.m = t,
  31. e.c = i,
  32. e.p = "",
  33. e(0)
  34. }([function (t, e, i) {
  35. i(4),
  36. i(9),
  37. i(5),
  38. i(6),
  39. i(8),
  40. i(7),
  41. i(10),
  42. i(11),
  43. i(12),
  44. i(13),
  45. i(14),
  46. i(1),
  47. i(2),
  48. i(3)
  49. }
  50. , function (t, e) {
  51. PIXI.Container.prototype.setTouchStartAction = function (t, e, i) {
  52. t.mousedown = t.touchstart = function (n) {
  53. n.stopPropagation(),
  54. GD.fullScreen(),
  55. GD.buttonAction(t),
  56. e && e.call(i, n)
  57. }
  58. .bind(i)
  59. }
  60. ,
  61. PIXI.Container.prototype.setTouchStart = function (t, e, i) {
  62. t.mousedown = t.touchstart = function (t) {
  63. t.stopPropagation(),
  64. GD.fullScreen(),
  65. e && e.call(i, t)
  66. }
  67. .bind(i)
  68. }
  69. ,
  70. PIXI.Container.prototype.setTouchEnd = function (t, e, i) {
  71. t.tap = function (t) {
  72. t.stopPropagation(),
  73. GD.fullScreen(),
  74. e && e.call(i, t)
  75. }
  76. .bind(i),
  77. GD.isMobile || (t.click = function (t) {
  78. t.stopPropagation(),
  79. e && e.call(i, t)
  80. }
  81. .bind(i))
  82. }
  83. ,
  84. PIXI.Container.prototype.setTouchMove = function (t, e, i) {
  85. t.mousemove = t.touchmove = function (t) {
  86. t.stopPropagation(),
  87. e && e.call(i, t)
  88. }
  89. .bind(i)
  90. }
  91. ,
  92. PIXI.Container.prototype.addGamePadEvent = function () {
  93. this.removeGamePadEvent(),
  94. $(GamePadManager).on("padButton", this.onGamePadEvent.bind(this)),
  95. $(GamePadManager).on("padStickX", this.onGamePadStickXEvent.bind(this)),
  96. $(GamePadManager).on("padStickY", this.onGamePadStickYEvent.bind(this))
  97. }
  98. ,
  99. PIXI.Container.prototype.removeGamePadEvent = function () {
  100. $(GamePadManager).off()
  101. }
  102. ,
  103. PIXI.Container.prototype.onGamePadEvent = function (t, e) { }
  104. ,
  105. PIXI.Container.prototype.onGamePadStickXEvent = function (t, e) { }
  106. ,
  107. PIXI.Container.prototype.onGamePadStickYEvent = function (t, e) { }
  108. ,
  109. PIXI.Container.prototype.showLoading = function () {
  110. GD.loading = GD.LoadingView.getInstance(),
  111. GD.loading.init(),
  112. this.addChild(GD.loading)
  113. }
  114. ,
  115. PIXI.Container.prototype.hideLoading = function () {
  116. this.removeChild(GD.loading)
  117. }
  118. }
  119. , function (t, e) {
  120. GD.CommonIntro = function (t, e) {
  121. PIXI.Container.call(this),
  122. this.helpBtn = null,
  123. this.soundpBtn = null,
  124. this.startBtn = null,
  125. this.callBackFunc = null,
  126. this.callBackTarget = null,
  127. this.bg = this.setSpriteTexture(this.bg, "texture", e),
  128. this.addChild(this.bg),
  129. // this.copyText = this.setSpriteTexture(this.copyText, "texture", "copybar_" + t),
  130. // this.copyText.anchor.set(.5),
  131. // this.copyText.x = GD.width / 2,
  132. // this.copyText.y = GD.height - 20,
  133. // this.addChild(this.copyText),
  134. this.gamePadGuide = null,
  135. this.soundPopup = new GD.OptionPopup,
  136. this.soundPopup.on("SOUND_POPUP_CLOSE_EVENT", this.closeSoundPopup.bind(this)),
  137. gamen.loadend()
  138. }
  139. ,
  140. GD.CommonIntro.constructor = GD.CommonIntro,
  141. GD.CommonIntro.prototype = Object.create(PIXI.Container.prototype),
  142. GD.CommonIntro.prototype.init = function () {
  143. GamePadManager.init(),
  144. GamePadManager.isConnected && GD.isShowPadGuide && (this.gamePadGuide || (this.gamePadGuide = new GD.GamePadGuide),
  145. this.showGamePadGuide(),
  146. this.addGamePadEvent()),
  147. GD.isShowPadGuide = !1,
  148. this.setInteractive(!0)
  149. }
  150. ,
  151. GD.CommonIntro.prototype.showGamePadGuide = function () {
  152. this.gamePadGuide.init(),
  153. this.addChild(this.gamePadGuide)
  154. }
  155. ,
  156. GD.CommonIntro.prototype.hideGamePadGuide = function () {
  157. this.removeChild(this.gamePadGuide)
  158. }
  159. ,
  160. GD.CommonIntro.prototype.initHelp = function (t, e, i) {
  161. this.helpBtn = this.setSpriteTexture(this.helpBtn, "texture", t),
  162. this.helpBtn.anchor.set(.5),
  163. this.helpBtn.x = e,
  164. this.helpBtn.y = i,
  165. this.helpBtn.scale.set(1),
  166. this.addChild(this.helpBtn),
  167. this.setTouchStartAction(this.helpBtn),
  168. this.setTouchEnd(this.helpBtn, this.showHelp, this)
  169. }
  170. ,
  171. GD.CommonIntro.prototype.initSound = function (t, e, i) {
  172. this.soundpBtn = this.setSpriteTexture(this.soundpBtn, "texture", t),
  173. this.soundpBtn.anchor.set(.5),
  174. this.soundpBtn.x = e,
  175. this.soundpBtn.y = i,
  176. this.soundpBtn.scale.set(1),
  177. this.addChild(this.soundpBtn),
  178. this.setTouchStartAction(this.soundpBtn),
  179. this.setTouchEnd(this.soundpBtn, this.showSoundPopup, this)
  180. }
  181. ,
  182. GD.CommonIntro.prototype.initStart = function (t, e, i, n, o) {
  183. this.startBtn = this.setSpriteTexture(this.startBtn, "texture", t),
  184. this.startBtn.anchor.set(.5),
  185. this.startBtn.x = e,
  186. this.startBtn.y = i,
  187. this.callBackFunc = n,
  188. this.callBackTarget = o,
  189. this.startBtn.scale.set(1),
  190. this.addChild(this.startBtn),
  191. this.setTouchStartAction(this.startBtn),
  192. this.setTouchEnd(this.startBtn, this.startDataComplete, this)
  193. // this.setTouchEnd(this.startBtn, this.sendStartData, this)
  194. }
  195. ,
  196. GD.CommonIntro.prototype.onGamePadEvent = function (t, e) {
  197. switch (e) {
  198. case "button-1":
  199. this.hideGamePadGuide(),
  200. this.sendStartData();
  201. break;
  202. case "button-2":
  203. this.hideGamePadGuide(),
  204. this.showHelp();
  205. break;
  206. case "button-3":
  207. this.hideGamePadGuide(),
  208. this.showSoundPopup();
  209. break;
  210. case "button-4":
  211. this.hideGamePadGuide()
  212. }
  213. }
  214. ,
  215. GD.CommonIntro.prototype.showHelp = function () {
  216. this.setInteractive(!1),
  217. GD.tutorial.initPage(0, "help_start"),
  218. GD.tutorial.once("TUTORIAL_CLOSE_EVENT", this.hideHelp.bind(this)),
  219. this.addChild(GD.tutorial)
  220. }
  221. ,
  222. GD.CommonIntro.prototype.hideHelp = function () {
  223. this.sendStartData()
  224. }
  225. ,
  226. GD.CommonIntro.prototype.showSoundPopup = function () {
  227. this.setInteractive(!1),
  228. this.soundPopup.show(0),
  229. this.addChild(this.soundPopup)
  230. }
  231. ,
  232. GD.CommonIntro.prototype.closeSoundPopup = function () {
  233. this.removeChild(this.soundPopup),
  234. this.setInteractive(!0)
  235. }
  236. ,
  237. GD.CommonIntro.prototype.sendStartData = function () {
  238. this.showLoading()
  239. DataManager.start(this.startDataComplete, this)
  240. }
  241. ,
  242. GD.CommonIntro.prototype.startDataComplete = function () {
  243. this.hideLoading()
  244. GD.tutorial && this.removeChild(GD.tutorial)
  245. this.callBackFunc.call(this.callBackTarget)
  246. }
  247. ,
  248. GD.CommonIntro.prototype.setInteractive = function (t) {
  249. this.helpBtn.interactive = t,
  250. this.soundpBtn.interactive = t,
  251. this.startBtn.interactive = t,
  252. GamePadManager.isConnected && (t ? this.addGamePadEvent() : this.removeGamePadEvent())
  253. }
  254. ,
  255. GD.CommonIntro.getInstance = function (t, e) {
  256. return GD.commonIntro || (GD.commonIntro = new GD.CommonIntro(t, e)),
  257. GD.commonIntro
  258. }
  259. }
  260. , function (t, e) {
  261. GD.CommonOption = function (t) {
  262. PIXI.Container.call(this),
  263. this.scorePopup = new GD.ScorePopup,
  264. this.scorePopup.on("SCORE_POPUP_CLOSE_EVENT", this.closeScorePopup.bind(this)),
  265. this.optionPopup = new GD.OptionPopup,
  266. this.optionPopup.on("SOUND_POPUP_CLOSE_EVENT", this.closeOptionPopup.bind(this)),
  267. this.optionPopup.on("TUTORIAL_OPEN_EVENT", this.showTutorial.bind(this)),
  268. this.optBtn = this.setSpriteTexture(this.optBtn, "texture", "btn_option_" + t),
  269. this.optBtn.anchor.set(.5),
  270. this.optBtn.x = GD.width - 40,
  271. this.optBtn.y = 90,
  272. this.setTouchStartAction(this.optBtn),
  273. this.setTouchEnd(this.optBtn, function () {
  274. this.setInteractive(!1),
  275. this.emit("OPTION_OPEN_EVENT"),
  276. this.optionPopup.show(1),
  277. this.addChild(this.optionPopup)
  278. }
  279. .bind(this)),
  280. this.achievement = new GD.Achievement
  281. }
  282. ,
  283. GD.CommonOption.constructor = GD.CommonOption,
  284. GD.CommonOption.prototype = Object.create(PIXI.Container.prototype),
  285. GD.CommonOption.prototype.init = function () {
  286. this.removeAll(),
  287. this.addChild(this.optBtn),
  288. this.addChild(this.achievement),
  289. this.setInteractive(!0)
  290. }
  291. ,
  292. GD.CommonOption.prototype.setAchievement = function (t) {
  293. this.achievement.show(t)
  294. }
  295. ,
  296. GD.CommonOption.prototype.setInteractive = function (t) {
  297. this.optBtn.interactive = t
  298. }
  299. ,
  300. GD.CommonOption.prototype.closeOptionPopup = function () {
  301. this.removeChild(this.optionPopup),
  302. this.setInteractive(!0),
  303. this.emit("OPTION_CLOSE_EVENT")
  304. }
  305. ,
  306. GD.CommonOption.prototype.showTutorial = function () {
  307. GD.tutorial.initPage(0, "help_close"),
  308. GD.tutorial.on("TUTORIAL_CLOSE_EVENT", this.hideHelp.bind(this)),
  309. this.addChild(GD.tutorial)
  310. }
  311. ,
  312. GD.CommonOption.prototype.hideHelp = function () {
  313. this.removeChild(GD.tutorial),
  314. this.optionPopup.setInteractive(!0)
  315. }
  316. ,
  317. GD.CommonOption.prototype.closeScorePopup = function () {
  318. this.gameRestart()
  319. }
  320. ,
  321. GD.CommonOption.prototype.finish = function (t) {
  322. gamen.score_view_status ? (this.scorePopup.show(t),
  323. this.addChild(this.scorePopup)) : (GD.exitFullScreen(),
  324. DataManager.finish(t))
  325. }
  326. ,
  327. GD.CommonOption.prototype.gameRestart = function () {
  328. GD.renderer.view.style.display = "inline",
  329. this.emit("GAME_RESTART")
  330. }
  331. ,
  332. GD.CommonOption.prototype.removeAll = function () {
  333. this.removeChildren()
  334. }
  335. ,
  336. GD.CommonOption.getInstance = function (t) {
  337. return GD.commonOption || (GD.commonOption = new GD.CommonOption(t)),
  338. GD.commonOption
  339. }
  340. }
  341. , function (t, e) {
  342. GD = {
  343. loader: null,
  344. stats: null,
  345. width: 504,
  346. height: 861,
  347. leng: "cn",
  348. isMobile: !1,
  349. isDebug: !1,
  350. isShowLog: !1,
  351. isLogin: !1,
  352. unique: null,
  353. pk: null,
  354. sKey: null,
  355. oKey: null,
  356. startTime: null,
  357. medal: [],
  358. soundType: 1,
  359. isAllSound: !0,
  360. isBgmSound: !0,
  361. isEffectSound: !0,
  362. isShowPadGuide: !0,
  363. orientationType: null,
  364. orientationGuide: null,
  365. sound: {},
  366. darkBg: null,
  367. stage: null,
  368. commonIntro: null,
  369. commonOption: null,
  370. tutorial: null,
  371. loading: null
  372. },
  373. GD.init = function (t, e, i, n, o, backgroundColor) {
  374. var gWidth = windowWidth * pixelRatioX
  375. var gHeight = windowHeight * pixelRatioY
  376. GD.width = gWidth
  377. GD.height = gHeight
  378. GD.leng = gamen.game_language
  379. var app = GD.app = new PIXI.Application({
  380. width: gWidth,
  381. height: gHeight,
  382. forceCanvas:true,
  383. backgroundColor: backgroundColor,
  384. clearBeforeRender: false,
  385. resolution: 2,
  386. view: canvas
  387. })
  388. app.renderer.plugins.interaction.mapPositionToPoint = (point, x, y) => {
  389. point.x = x * pixelRatioX
  390. point.y = y * pixelRatioY
  391. }
  392. // requestAnimationFrame(this.update)
  393. this.renderer = app.renderer
  394. this.stage = app.stage
  395. // this.resize()
  396. this.setSpriteTexture()
  397. this.resourceLoad()
  398. }
  399. ,
  400. GD.resourceLoad = function () {
  401. var t = COMMON_IMG_PATH + "image/json/";
  402. GD.loader = PIXI.loader,
  403. GD.loader.add(t + "human_common.json"),
  404. GD.loader.add(t + "human_popup_" + this.leng + ".json")
  405. }
  406. ,
  407. GD.showProgress = function () {
  408. GD.progress = new GD.Progress,
  409. GD.progress.show(),
  410. this.stage.addChild(GD.progress)
  411. }
  412. ,
  413. GD.hideProgress = function () {
  414. GD.progress.hide(),
  415. this.stage.removeChild(GD.progress)
  416. }
  417. ,
  418. GD.resize = function () {
  419. if (GD.renderer) {
  420. var t = GD.width / GD.height
  421. , e = window.innerWidth
  422. , i = window.innerHeight
  423. , n = e / i;
  424. if ($("#gamecontainer")[0]) {
  425. var o = document.getElementById("gamecontainer");
  426. o.style.color = "#FF0000",
  427. n > t ? (e = i * t,
  428. o.style.width = e + "px",
  429. o.style.height = i + "px",
  430. GD.renderer.view.style.width = e + "px",
  431. GD.renderer.view.style.height = i + "px") : (i = e / t,
  432. o.style.width = e + "px",
  433. o.style.height = i + "px",
  434. GD.renderer.view.style.width = e + "px",
  435. GD.renderer.view.style.height = i + "px")
  436. } else
  437. n > t ? e = i * t : i = e / t,
  438. this.renderer.view.style.width = e + "px",
  439. this.renderer.view.style.height = i + "px"
  440. }
  441. gamen.score_view_status || this.setOrientationGuide()
  442. }
  443. ,
  444. GD.render = function () {
  445. GD.renderer.render(GD.root)
  446. }
  447. ,
  448. GD.update = function () {
  449. GD.isDebug && GD.stats.begin(),
  450. requestAnimationFrame(GD.update),
  451. GD.render(),
  452. GD.isDebug && GD.stats.end()
  453. }
  454. ,
  455. GD.buttonAction = function (t, e, i) {
  456. e || (e = 1.2),
  457. i || (i = 1),
  458. t.scale.set(e),
  459. TweenMax.to(t.scale, .2, {
  460. x: i,
  461. y: i
  462. })
  463. }
  464. ,
  465. GD.setSpriteTexture = function () {
  466. PIXI.Container.prototype.setSpriteTexture = function (t, e, i) {
  467. return "sprite" == e ? t ? t.texture = GD.loader.resources[i].texture : t = new PIXI.Sprite(GD.loader.resources[i].texture) : t ? t.texture = PIXI.Texture.fromFrame(i + ".png") : t = new PIXI.Sprite.fromFrame(i + ".png"),
  468. t
  469. }
  470. }
  471. ,
  472. GD.getDarkBg = function () {
  473. return GD.darkBg || (GD.darkBg = new PIXI.Graphics,
  474. GD.darkBg.beginFill(0, .8),
  475. GD.darkBg.drawRect(0, 0, GD.width, GD.height),
  476. GD.darkBg.endFill()),
  477. GD.darkBg
  478. }
  479. ,
  480. GD.log = function (t) {
  481. GD.isShowLog ? (GD.logStr = t + "\n" + GD.logStr,
  482. GD.logText || (GD.logText = new PIXI.Text("", {
  483. font: "14px Arial",
  484. fill: "#F7EDCA",
  485. stroke: "#000",
  486. strokeThickness: 4,
  487. wordWrapWidth: GD.width - 60,
  488. wordWrap: !0
  489. }),
  490. GD.logText.x = 30,
  491. GD.logText.y = 30),
  492. GD.logText.parent || GD.root.addChild(GD.logText),
  493. GD.logText.text = GD.logStr) : console.log(t)
  494. }
  495. ,
  496. GD.fullScreen = function () {
  497. if (GD.isMobile) {
  498. var t = navigator.platform.match(/iPhone|iPod|iPad/);
  499. if (!t) {
  500. var e = GD.renderer.view;
  501. e.requestFullscreen ? e.requestFullscreen() : e.webkitRequestFullScreen ? e.webkitRequestFullScreen() : e.mozRequestFullScreen()
  502. }
  503. }
  504. }
  505. ,
  506. GD.exitFullScreen = function () {
  507. if (GD.isMobile) {
  508. var t = navigator.platform.match(/iPhone|iPod|iPad/);
  509. t || (document.exitFullscreen ? document.exitFullscreen() : document.msExitFullscreen ? document.msExitFullscreen() : document.mozCancelFullScreen ? document.mozCancelFullScreen() : document.webkitCancelFullScreen && document.webkitCancelFullScreen())
  510. }
  511. }
  512. ,
  513. GD.setOrientationGuide = function () {
  514. var t = document.getElementById("rank_layout");
  515. if (t && "none" != t.style.display && com)
  516. return GD.renderer.view.style.display = "none",
  517. void GD.showOrientation(!1);
  518. var e = window.innerWidth / window.innerHeight
  519. , i = GD.width / GD.height;
  520. i > 1 ? GD.orientationType = "phone rotate_x" : GD.orientationType = "phone rotate_y",
  521. e > 1 && 1 > i || 1 > e && i > 1 ? GD.showOrientation(!0) : GD.showOrientation(!1)
  522. }
  523. ,
  524. GD.showOrientation = function (t) {
  525. for (var e = ["Z300C", "TF701T", "TF700T", "TF103C", "TF101-1B251A", "TA2506 10BK", "SM-T805", "SM-T800", "SM-T677", "SM-T670", "SM-P900", "SMP-605", "SMP-600", "SMART-TV", "SmartTV", "SM-905", "SHW-M480W", "SHW-M380", "SHV-E230", "SGP771", "SGP311", "QM0101", "Q109", "MZ68", "MZ601", "MX1080", "MID 1065-8", "MID 1042-8", "ME102A", "LGV940", "LGV700N", "GT-P5110", "FZ-A1", "AT105", "A10-70", "10QS", "10ES"], i = e.length; i--;)
  526. if (navigator.userAgent.match(e[i]))
  527. return;
  528. var n, o, s, r, a, h;
  529. if (GD.isMobile) {
  530. var l = document.getElementsByClassName("xy_wrap").length;
  531. if (t) {
  532. if (n = GD.orientationGuide,
  533. null == n) {
  534. if (n = document.createElement("div"),
  535. n.style.backgroundColor = "#ff7e17",
  536. n.style.position = "absolute",
  537. n.style.left = 0,
  538. n.style.top = 0,
  539. n.style.right = 0,
  540. n.style.bottom = 0,
  541. n.style.margin = "auto",
  542. n.setAttribute("class", "xy_wrap"),
  543. GD.orientationGuide = n,
  544. o = document.createElement("div"),
  545. o.setAttribute("class", "xy_info"),
  546. s = document.createElement("div"),
  547. s.setAttribute("class", GD.orientationType),
  548. r = document.createElement("span"),
  549. r.setAttribute("class", "yes"),
  550. a = document.createElement("span"),
  551. a.setAttribute("class", "no"),
  552. n.appendChild(o),
  553. o.appendChild(s),
  554. o.appendChild(r),
  555. o.appendChild(a),
  556. h = document.createElement("p"),
  557. h.style.left = "0px",
  558. h.style.right = "0px",
  559. h.style.padding = "15px",
  560. h.style.lineHeight = "130%",
  561. h.style.color = "#FFFFFF",
  562. h.style.position = "absolute",
  563. "en" == GD.lang)
  564. h.style.fontSize = "18px",
  565. h.innerHTML = "Please rotate your device.";
  566. else {
  567. var u;
  568. switch (GD.lang) {
  569. case "jp":
  570. u = "お使いの 携?電話を 回?させて 下ください。";
  571. break;
  572. case "en":
  573. u = "ROTATE YOUR PHONE";
  574. break;
  575. case "cn":
  576. u = "如果?幕不能旋?,?打?自?旋?功能。";
  577. break;
  578. default:
  579. u = window.innerWidth > 480 ? "화면 전환이 되지 않는다면, 자동회전 기능을 켜 주세요." : "화면 전환이 되지 않는다면,<br>자동회전 기능을 켜 주세요."
  580. }
  581. h.innerHTML = u
  582. }
  583. o.appendChild(h)
  584. }
  585. 0 == l && (document.body.appendChild(n),
  586. GD.orientationChange(!0),
  587. GD.renderer.view.style.visibility = "hidden")
  588. } else
  589. l > 0 && (document.body.removeChild(GD.orientationGuide),
  590. GD.orientationChange(!1),
  591. GD.renderer.view.style.visibility = "visible")
  592. }
  593. }
  594. ,
  595. GD.orientationChange = function (t) {
  596. t ? GD.soundMute() : GD.isAllSound && GD.soundUnMute()
  597. }
  598. ,
  599. GD.loadSound = function (t, e) {
  600. var index = 0,
  601. options = [],
  602. n = t.length;
  603. for (let o = 0, s = n; s--;) {
  604. let i = t[s];
  605. options[s] = {
  606. key: i,
  607. value: {
  608. src: [RES_DIR_SOUND + i + ".mp3?ver=" + SOUND_VERSION, RES_DIR_SOUND + i + ".ogg?ver=" + SOUND_VERSION, RES_DIR_SOUND + i + ".wav?ver=" + SOUND_VERSION],
  609. onload: function () {
  610. o++;
  611. if (index < n) {
  612. index++;
  613. let option = options[index - 1]
  614. GD.sound[option.key] = new Howl(option.value)
  615. index == n && e();
  616. }
  617. },
  618. onloaderror: function (msg) {
  619. console.error("error:", msg);
  620. o++;
  621. if (index < n) {
  622. index++;
  623. let option = options[index - 1]
  624. GD.sound[option.key] = new Howl(option.value)
  625. index == n && e();
  626. }
  627. }
  628. }
  629. }
  630. }
  631. while (index <= 4) {
  632. let option = options[index]
  633. GD.sound[option.key] = new Howl(option.value);
  634. index++;
  635. }
  636. }
  637. ,
  638. GD.bgmPlay = function (t) {
  639. console.log("bgmplay:", t)
  640. var e = GD.sound.sound_bgm;
  641. e._loop = !0,
  642. t ? e._volume = t : e._volume = .3,
  643. GD.isBgmSound && e.play()
  644. }
  645. ,
  646. GD.bgmStop = function () {
  647. GD.sound.sound_bgm.stop()
  648. }
  649. ,
  650. GD.soundPlay = function (t, e, i) {
  651. var n = GD.sound[t];
  652. e || (e = 1),
  653. e ? n._volume = e : n._volume = 1,
  654. i ? n._loop = i : n._loop = !1,
  655. GD.isEffectSound && n.play()
  656. }
  657. ,
  658. GD.soundStop = function (t) {
  659. GD.isEffectSound && GD.sound[t].stop()
  660. }
  661. ,
  662. GD.soundAllStop = function () {
  663. for (var t in GD.sound)
  664. GD.sound[t].stop()
  665. }
  666. ,
  667. GD.soundMute = function () {
  668. Howler.mute(!0)
  669. }
  670. ,
  671. GD.soundUnMute = function () {
  672. GD.isAllSound && Howler.mute(!1)
  673. }
  674. ,
  675. window.onresize = function (t) {
  676. GD.resize()
  677. }
  678. }
  679. , function (t, e) {
  680. DataManager = {},
  681. DataManager.unique = null,
  682. DataManager.pk = null,
  683. DataManager.Skey = null,
  684. DataManager.Okey = null,
  685. DataManager.callFunc = null,
  686. DataManager.target = null,
  687. DataManager.playInterval = null,
  688. DataManager.start = function (t, e) {
  689. DataManager.callFunc = t,
  690. DataManager.target = e,
  691. gamen.start(DataManager.startDataComplete)
  692. }
  693. ,
  694. DataManager.startDataComplete = function (t, e, i, n, o) {
  695. if (GD.isLogin = t,
  696. GD.isLogin && (GD.sKey = gamen.spkey(n),
  697. GD.oKey = gamen.opkey(o),
  698. GD.unique = XORcipher().xorDecoder(e, GD.sKey),
  699. GD.pk = i,
  700. GD.startTime = Date.now(),
  701. GD.medal = [],
  702. null != gamen.achievement))
  703. for (var s = gamen.achievement.length, r = 0; s > r; ++r) {
  704. var a = XORcipher().xorDecoder(gamen.achievement[r], GD.sKey)
  705. , h = [];
  706. h = a.split("_gamen_"),
  707. GD.medal[r] = [parseInt(h[0]), !1, parseInt(h[1]), h[2], h[3], parseInt(h[5]), h[4]]
  708. }
  709. DataManager.callFunc.call(DataManager.target),
  710. DataManager.playInterval = setInterval(DataManager.promisePlay, .1)
  711. }
  712. ,
  713. DataManager.point = function (t, e) {
  714. if (GD.log(t + " : " + e),
  715. DataManager.otherPoint(t, e),
  716. GD.isLogin) {
  717. t = XORcipher().xorEncoder(t, GD.sKey),
  718. e = XORcipher().xorEncoder(e.toString(), GD.sKey);
  719. var i = Date.now() - GD.startTime
  720. , n = XORcipher().xorEncoder(i.toString(), GD.sKey);
  721. gamen.point(t, e, n)
  722. }
  723. }
  724. ,
  725. DataManager.otherPoint = function (t, e) {
  726. if (GD.isLogin) {
  727. t = XORcipher().xorEncoder(t, GD.oKey),
  728. e = XORcipher().xorEncoder(e.toString(), GD.oKey);
  729. var i = Date.now() - GD.startTime
  730. , n = XORcipher().xorEncoder(i.toString(), GD.oKey);
  731. gamen.otherpoint(t, e, n)
  732. }
  733. }
  734. ,
  735. DataManager.promisePlay = function () {
  736. var t = Date.now() - GD.startTime
  737. , e = XORcipher().xorEncoder(t.toString(), GD.oKey);
  738. gamen.promiseplay(e)
  739. }
  740. ,
  741. DataManager.finish = function (t) {
  742. if (DataManager.playInterval && clearInterval(DataManager.playInterval),
  743. GD.isLogin) {
  744. if (GD.medal.length > 0) {
  745. var e = []
  746. , i = GD.medal.length;
  747. gamen.new_achievement = [];
  748. for (var n = 0; i > n; ++n)
  749. e[n] = GD.medal[n][0] + "_gamen_" + GD.medal[n][2] + "_gamen_" + GD.medal[n][3] + "_gamen_" + GD.medal[n][4] + "_gamen_" + parseInt(GD.medal[n][5]),
  750. gamen.new_achievement[n] = XORcipher().xorEncoder(e[n], GD.sKey)
  751. }
  752. var o = XORcipher().xorEncoder(t.toString(), GD.sKey)
  753. , s = GD.commonOption.gameRestart.bind(GD.commonOption)
  754. , r = XORcipher().xorEncoder(GD.unique, GD.sKey)
  755. , a = XORcipher().xorEncoder(GD.startTime.toString(), GD.sKey)
  756. , h = Date.now()
  757. , l = XORcipher().xorEncoder(h.toString(), this.sKey);
  758. gamen.finish(GD.pk, o, s, r, a, l)
  759. } else
  760. gamen.finish(GD.pk, t, GD.commonOption.gameRestart.bind(GD.commonOption))
  761. }
  762. ,
  763. DataManager.addMedal = function (t, e) {
  764. if (GD.isLogin && GD.medal.length > 0)
  765. for (var i = null, n = 0; n < GD.medal.length; ++n)
  766. if (t == GD.medal[n][0]) {
  767. i = n,
  768. 0 == GD.medal[i][1] && (null == e && (e = 1),
  769. GD.medal[i][5] += e,
  770. GD.medal[i][2] <= GD.medal[i][5] && (GD.medal[i][1] = !0,
  771. GD.commonOption.setAchievement(i + 1)));
  772. break
  773. }
  774. }
  775. GD.DataManager = DataManager
  776. }
  777. , function (t, e) {
  778. GamePadManager = {
  779. isConnected: !1,
  780. init: function () {
  781. try {
  782. gamepadSupport.init()
  783. } catch (t) {
  784. console.log("gamepadSupport is not defined -- gamepad.js")
  785. }
  786. },
  787. showNotSupported: function () { },
  788. updateGamePads: function (t) {
  789. if (this.isConnected = !1,
  790. t)
  791. for (var e in t) {
  792. var i = t[e];
  793. i && (this.isConnected = !0)
  794. }
  795. },
  796. updateButton: function (t, e, i) {
  797. t.pressed && $(this).trigger("padButton", i)
  798. },
  799. updateAxis: function (t, e, i, n, o) {
  800. "stick-1" == n && ("stick-1-axis-x" == i ? $(this).trigger("padStickX", t) : "stick-1-axis-y" == i && $(this).trigger("padStickY", t))
  801. }
  802. }
  803. }
  804. , function (t, e) {
  805. GD.OptionPopup = function () {
  806. PIXI.Container.call(this),
  807. this.darkBg = GD.getDarkBg(),
  808. this.bg = null,
  809. this.type = null,
  810. this.allBtn = this.setSpriteTexture(this.allBtn, "texture", "option_on_0"),
  811. this.allBtn.anchor.set(.5),
  812. this.allBtn.x = 110,
  813. this.setTouchEnd(this.allBtn, function () {
  814. GD.isAllSound = !GD.isAllSound,
  815. this.setAllSoundBtn(),
  816. this.setBgmBtn(!1),
  817. this.setEffectBtn()
  818. }, this),
  819. this.bgmBtn = this.setSpriteTexture(this.bgmBtn, "texture", "option_on_0"),
  820. this.bgmBtn.anchor.set(.5),
  821. this.bgmBtn.x = this.allBtn.x,
  822. this.setTouchEnd(this.bgmBtn, function () {
  823. GD.isAllSound && (GD.isBgmSound = !GD.isBgmSound,
  824. this.setBgmBtn(!0))
  825. }, this),
  826. this.effectBtn = this.setSpriteTexture(this.effectBtn, "texture", "option_on_0"),
  827. this.effectBtn.anchor.set(.5),
  828. this.effectBtn.x = this.allBtn.x,
  829. this.setTouchEnd(this.effectBtn, function () {
  830. GD.isAllSound && (GD.isEffectSound = !GD.isEffectSound,
  831. this.setEffectBtn())
  832. }, this),
  833. this.closeBtn = this.setSpriteTexture(this.closeBtn, "texture", "option_close_btn"),
  834. this.closeBtn.anchor.set(.5),
  835. this.closeBtn.x = 200,
  836. this.setTouchStartAction(this.closeBtn, function () {
  837. this.emit("SOUND_POPUP_CLOSE_EVENT")
  838. }, this),
  839. this.tutorialBtn = this.setSpriteTexture(this.tutorialBtn, "texture", "option_help_btn"),
  840. this.tutorialBtn.anchor.set(.5),
  841. this.setTouchStartAction(this.tutorialBtn),
  842. this.setTouchEnd(this.tutorialBtn, function () {
  843. this.setInteractive(!1),
  844. this.emit("TUTORIAL_OPEN_EVENT")
  845. }, this)
  846. }
  847. ,
  848. GD.OptionPopup.constructor = GD.OptionPopup,
  849. GD.OptionPopup.prototype = Object.create(PIXI.Container.prototype),
  850. GD.OptionPopup.prototype.show = function (t) {
  851. this.removeChild(),
  852. this.type = t;
  853. var e = "option_box_0";
  854. 0 == this.type ? (1 == GD.soundType ? (this.closeBtn.y = -185,
  855. this.allBtn.y = -62) : (e = "option_box1_0",
  856. this.closeBtn.y = -92,
  857. this.allBtn.y = 25,
  858. this.allBtn.y = 30),
  859. this.bgmBtn.y = 70,
  860. this.effectBtn.y = 165) : (e = "option_box_1",
  861. 1 == GD.soundType ? (this.closeBtn.y = -247,
  862. this.allBtn.y = -124,
  863. this.tutorialBtn.y = 230) : (e = "option_box1_1",
  864. this.closeBtn.y = -148,
  865. this.allBtn.y = -27,
  866. this.tutorialBtn.y = 130),
  867. this.bgmBtn.y = 20,
  868. this.effectBtn.y = 115),
  869. this.addChild(this.darkBg),
  870. this.bg = this.setSpriteTexture(this.bg, "texture", e),
  871. this.bg.anchor.set(.5),
  872. this.bg.x = GD.width / 2,
  873. this.bg.y = GD.height / 2,
  874. this.addChild(this.bg),
  875. this.bg.addChild(this.closeBtn),
  876. this.bg.addChild(this.allBtn),
  877. 1 == GD.soundType && (this.bg.addChild(this.bgmBtn),
  878. this.bg.addChild(this.effectBtn)),
  879. 1 == this.type && this.bg.addChild(this.tutorialBtn),
  880. this.setAllSoundBtn(),
  881. this.setBgmBtn(!1),
  882. this.setEffectBtn(),
  883. this.bg.scale.set(.1),
  884. TweenMax.to(this.bg.scale, .15, {
  885. x: 1,
  886. y: 1,
  887. ease: Back.easeOut,
  888. onComplete: this.showComplete.bind(this)
  889. })
  890. }
  891. ,
  892. GD.OptionPopup.prototype.showComplete = function () {
  893. this.setInteractive(!0)
  894. }
  895. ,
  896. GD.OptionPopup.prototype.hide = function () {
  897. this.removeChild()
  898. }
  899. ,
  900. GD.OptionPopup.prototype.setAllSoundBtn = function () {
  901. GD.isAllSound ? (this.allBtn = this.setSpriteTexture(this.allBtn, "texture", "option_on_0"),
  902. GD.soundUnMute()) : (this.allBtn = this.setSpriteTexture(this.allBtn, "texture", "option_off_0"),
  903. GD.soundMute())
  904. }
  905. ,
  906. GD.OptionPopup.prototype.setBgmBtn = function (t) {
  907. GD.isAllSound ? (GD.isBgmSound ? this.bgmBtn = this.setSpriteTexture(this.bgmBtn, "texture", "option_on_0") : this.bgmBtn = this.setSpriteTexture(this.bgmBtn, "texture", "option_off_0"),
  908. t && 1 == this.type && (GD.isBgmSound ? GD.bgmPlay() : GD.bgmStop())) : GD.isBgmSound ? this.bgmBtn = this.setSpriteTexture(this.bgmBtn, "texture", "option_on_1") : this.bgmBtn = this.setSpriteTexture(this.bgmBtn, "texture", "option_off_1")
  909. }
  910. ,
  911. GD.OptionPopup.prototype.setEffectBtn = function () {
  912. GD.isAllSound ? GD.isEffectSound ? this.effectBtn = this.setSpriteTexture(this.effectBtn, "texture", "option_on_0") : this.effectBtn = this.setSpriteTexture(this.effectBtn, "texture", "option_off_0") : GD.isEffectSound ? this.effectBtn = this.setSpriteTexture(this.effectBtn, "texture", "option_on_1") : this.effectBtn = this.setSpriteTexture(this.effectBtn, "texture", "option_off_1")
  913. }
  914. ,
  915. GD.OptionPopup.prototype.setInteractive = function (t) {
  916. this.allBtn.interactive = t,
  917. this.bgmBtn.interactive = t,
  918. this.effectBtn.interactive = t,
  919. this.tutorialBtn.interactive = t,
  920. this.closeBtn.interactive = t
  921. }
  922. ,
  923. GD.OptionPopup.prototype.removeChild = function () {
  924. this.removeChildren(),
  925. this.bg && this.bg.removeChildren(),
  926. this.setInteractive(!1)
  927. }
  928. }
  929. , function (t, e) {
  930. GD.ScorePopup = function () {
  931. PIXI.Container.call(this),
  932. this.darkBg = GD.getDarkBg(),
  933. this.bg = this.setSpriteTexture(this.allBtn, "texture", "gameOver_box"),
  934. this.bg.anchor.set(.5),
  935. this.bg.x = GD.width / 2,
  936. this.bg.y = GD.height / 2,
  937. this.closeBtn = this.setSpriteTexture(this.closeBtn, "texture", "option_close_btn"),
  938. this.closeBtn.anchor.set(.5),
  939. this.closeBtn.x = 267,
  940. this.closeBtn.y = -88,
  941. this.setTouchStartAction(this.closeBtn, function () {
  942. this.emit("SCORE_POPUP_CLOSE_EVENT")
  943. }, this),
  944. this.bg.addChild(this.closeBtn),
  945. this.pointTxt = new NumberText("gameOver_num_", "center", -12),
  946. this.pointTxt.y = 8,
  947. this.bg.addChild(this.pointTxt)
  948. }
  949. ,
  950. GD.ScorePopup.constructor = GD.ScorePopup,
  951. GD.ScorePopup.prototype = Object.create(PIXI.Container.prototype),
  952. GD.ScorePopup.prototype.show = function (t) {
  953. this.removeChild(),
  954. this.pointTxt.setValue(t),
  955. this.addChild(this.darkBg),
  956. this.addChild(this.bg),
  957. this.bg.scale.set(.1),
  958. TweenMax.to(this.bg.scale, .15, {
  959. x: 1,
  960. y: 1,
  961. ease: Back.easeOut,
  962. onComplete: this.showComplete.bind(this)
  963. })
  964. }
  965. ,
  966. GD.ScorePopup.prototype.showComplete = function () {
  967. this.setInteractive(!0)
  968. }
  969. ,
  970. GD.ScorePopup.prototype.setInteractive = function (t) {
  971. this.closeBtn.interactive = t
  972. }
  973. ,
  974. GD.ScorePopup.prototype.removeChild = function () {
  975. this.setInteractive(!1),
  976. this.removeChildren()
  977. }
  978. }
  979. , function (t, e) {
  980. GD.Util = {
  981. zeroStr: function (t, e) {
  982. for (var i = t.toString(), n = e - i.length; n--;)
  983. i = "0" + i;
  984. return i
  985. },
  986. randomNumber: function (t, e) {
  987. var i = 10 * e || 1;
  988. return Math.floor(Math.random() * t * i / i)
  989. },
  990. hitTest: function (t, e) {
  991. return e.x >= t.x && e.x <= t.x + t.width && e.y >= t.y && e.y <= t.y + t.height
  992. },
  993. uniqueArray: function (t) {
  994. for (var e = [], i = 0, n = t.length; n > i; i++)
  995. -1 === e.indexOf(t[i]) && "" !== t[i] && e.push(t[i]);
  996. return e
  997. },
  998. comma: function (t) {
  999. return t = String(t),
  1000. t.replace(/(\d)(?=(?:\d{3})+(?!\d))/g, "$1,")
  1001. },
  1002. shuffle: function (t) {
  1003. var e, i, n;
  1004. for (n = t.length; n; n--)
  1005. e = Math.floor(Math.random() * n),
  1006. i = t[n - 1],
  1007. t[n - 1] = t[e],
  1008. t[e] = i
  1009. },
  1010. grep: function (t, e) {
  1011. return jQuery.grep(t, function (t) {
  1012. return t != e
  1013. })
  1014. },
  1015. getParam: function (t) {
  1016. var e = window.location.search.match(new RegExp("(?:[?&]" + t + "=)([^&]+)"));
  1017. return e ? e[1] : null
  1018. },
  1019. mobileCheck: function () {
  1020. return !!(navigator.userAgent.match(/Android/i) || navigator.userAgent.match(/webOS/i) || navigator.userAgent.match(/iPhone/i) || navigator.userAgent.match(/iPad/i) || navigator.userAgent.match(/iPod/i) || navigator.userAgent.match(/BlackBerry/i) || navigator.userAgent.match(/Windows Phone/i))
  1021. },
  1022. radiansToDegrees: function (t) {
  1023. return t * Math.PI / 180
  1024. },
  1025. degreesToradians: function (t) {
  1026. return 180 * t / Math.PI
  1027. }
  1028. }
  1029. }
  1030. , function (t, e) {
  1031. GD.Achievement = function () {
  1032. PIXI.Container.call(this),
  1033. this.icons = [],
  1034. this.idx = 0
  1035. }
  1036. ,
  1037. GD.Achievement.constructor = GD.Achievement,
  1038. GD.Achievement.prototype = Object.create(PIXI.Container.prototype),
  1039. GD.Achievement.prototype.show = function (t, e) {
  1040. var i = this.setSpriteTexture(null, "texture", "medal_box");
  1041. i.anchor.set(.5),
  1042. i.scale.set(.3),
  1043. i.idx = this.idx,
  1044. i.x = GD.width + 50,
  1045. e ? i.y = e : i.y = 140,
  1046. this.icons.length > 0 && (i.y += 100 * this.icons.length),
  1047. GD.log("game_medal_" + t);
  1048. var n = this.setSpriteTexture(null, "sprite", "game_medal_" + t);
  1049. n.anchor.set(.5),
  1050. n.y = -30,
  1051. i.addChild(n),
  1052. this.addChild(i),
  1053. this.icons.push(i),
  1054. setTimeout(function () {
  1055. TweenMax.to(i, .5, {
  1056. x: GD.width - 50,
  1057. ease: Back.easeOut,
  1058. onComplete: this.iconHide.bind(this),
  1059. onCompleteParams: [i]
  1060. })
  1061. }
  1062. .bind(this), 3),
  1063. this.idx++
  1064. }
  1065. ,
  1066. GD.Achievement.prototype.iconHide = function (t) {
  1067. TweenMax.to(t, .5, {
  1068. x: GD.width + 50,
  1069. delay: 2,
  1070. ease: Back.easeIn,
  1071. onComplete: function () {
  1072. for (var e, i = this.icons.length; i--;)
  1073. if (e = this.icons[i],
  1074. e.idx == t.idx) {
  1075. this.icons.splice(i, 1),
  1076. this.removeChild(e);
  1077. break
  1078. }
  1079. }
  1080. .bind(this)
  1081. })
  1082. }
  1083. ,
  1084. GD.Achievement.prototype.removeAll = function () {
  1085. this.removeChildren()
  1086. }
  1087. }
  1088. , function (t, e) {
  1089. GD.GamePadGuide = function () {
  1090. PIXI.Container.call(this),
  1091. this.guide = this.setSpriteTexture(this.guide, "sprite", "gamePadGuide"),
  1092. this.setTouchEnd(this.guide, function () {
  1093. this.setInteractive(!1),
  1094. this.removeChild(this.guide),
  1095. this.emit("GAME_PAD_GUIDE_CLOSE_EVENT")
  1096. }
  1097. .bind(this))
  1098. }
  1099. ,
  1100. GD.GamePadGuide.constructor = GD.GamePadGuide,
  1101. GD.GamePadGuide.prototype = Object.create(PIXI.Container.prototype),
  1102. GD.GamePadGuide.prototype.init = function () {
  1103. this.removeChild(),
  1104. this.addChild(this.guide),
  1105. this.setInteractive(!0)
  1106. }
  1107. ,
  1108. GD.GamePadGuide.prototype.setInteractive = function (t) {
  1109. this.guide.interactive = t
  1110. }
  1111. ,
  1112. GD.GamePadGuide.prototype.removeChild = function () {
  1113. this.removeChildren()
  1114. }
  1115. }
  1116. , function (t, e) {
  1117. GD.LoadingView = function () {
  1118. PIXI.Container.call(this),
  1119. this.darkBg = GD.getDarkBg(),
  1120. this.img = this.setSpriteTexture(null, "texture", "loadingCircle"),
  1121. this.img.scale.set(.8),
  1122. this.img.anchor.set(.5),
  1123. this.img.x = GD.width / 2,
  1124. this.img.y = GD.height / 2,
  1125. this.addChild(this.img)
  1126. }
  1127. ,
  1128. GD.LoadingView.constructor = GD.LoadingView,
  1129. GD.LoadingView.prototype = Object.create(PIXI.Container.prototype),
  1130. GD.LoadingView.prototype.init = function () {
  1131. this.removeAll(),
  1132. this.addChild(this.darkBg),
  1133. this.addChild(this.img)
  1134. }
  1135. ,
  1136. GD.LoadingView.prototype.removeAll = function () {
  1137. this.removeChildren()
  1138. }
  1139. ,
  1140. GD.LoadingView.prototype.updateTransform = function () {
  1141. PIXI.Container.prototype.updateTransform.call(this),
  1142. this.img.rotation += .1
  1143. }
  1144. ,
  1145. GD.LoadingView.getInstance = function () {
  1146. return GD.loading || (GD.loading = new GD.LoadingView),
  1147. GD.loading
  1148. }
  1149. }
  1150. , function (t, e) {
  1151. GD.Progress = function () {
  1152. this.bg = null,
  1153. this.logo = null,
  1154. this.logoTxt = null,
  1155. this.tween = null,
  1156. PIXI.Container.call(this)
  1157. }
  1158. ,
  1159. GD.Progress.constructor = GD.Progress,
  1160. GD.Progress.prototype = Object.create(PIXI.Container.prototype),
  1161. GD.Progress.prototype.show = function () {
  1162. if (this.bg || (this.bg = new PIXI.Graphics,
  1163. this.bg.beginFill(16777215, 1),
  1164. this.bg.drawRect(0, 0, GD.width, GD.height),
  1165. this.bg.endFill()),
  1166. this.addChild(this.bg),
  1167. !this.logo) {
  1168. var logo = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGwAAABoCAYAAAAU9xXbAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDIxIDc5LjE1NTc3MiwgMjAxNC8wMS8xMy0xOTo0NDowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6NEI5ODVERjI3RjM2MTFFODlFMTM5NTUyODcxNUY3OUMiIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6NEI5ODVERjE3RjM2MTFFODlFMTM5NTUyODcxNUY3OUMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTUgKFdpbmRvd3MpIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN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K4HG8+vlgwaGdaF5mZR06NH7Bt4qw2wtdZGsSrbg0H7quC4wkCdC4q5z/HA6klfZ4jgvr4m41qdPySvmwRoHQyaq0FW8ZAoRHi3G7ulTth9BlHFw2KVFRd4/+9GqjMppXE9OLc75IcDw2OhqUlIyLbA7+cPWHkUDo9eSO3oVWXgFixWHBEBoJgrEfZ9fAaPSK/c+5FfUA7gZEen47jaOOwJa+98tMPHCrVz9qiYB+tMoqkpPCJB0FrLdsdOcYhctQGGUOil1jtWR+uMYdBGh44gsvYqK/+kHrR3RWa93oKqWIbBLXBrguGctD5tBwZtDOexOP0WkWazz+I8ZiiXiQohVm2AId3mq9DZ11xjMcUcVvlvpnyv1O105l8R6iV0FUnVCNinvkqeAFqCIoLXR87VKiK27aj8/cz5mwAzJKzZus4WNBGviDgWdUz5Ve7C/XJqxt0EMKSpIriLm41MizNDbEwVvUzDbt4rK3nT1QwYhqHjmNusQMt5H5E7iK6pJHdVO2BImLfCFuHn+7ZQXi+yMde5Xbg7vlU+VTtgrhdHqPdl7sVKREcJxnWS3MO+wNixYEolFY1gqhPdJ2EPQswS432Ux1BH7y8cBxogpj7qfQDsd5DDB2a48eLSV6gM8vIe4e0zv4HS/wUYAJEhl2U0gO8nAAAAAElFTkSuQmCC"
  1169. this.logo = new PIXI.Sprite.fromImage(logo)
  1170. }
  1171. this.logo.x = GD.width / 2,
  1172. this.logo.y = GD.height / 2,
  1173. this.logo.anchor.set(.5),
  1174. this.logo.scale.set(.1),
  1175. this.logo.rotation = 20,
  1176. this.addChild(this.logo),
  1177. this.tween ? this.tween.kill() : this.tween = new TimelineLite,
  1178. this.tween.to(this.logo, 1, {
  1179. rotation: 0,
  1180. ease: Sine.easeOut
  1181. }),
  1182. this.tween.call(this.showLocoText.bind(this)),
  1183. TweenMax.to(this.logo.scale, 1, {
  1184. x: 1,
  1185. y: 1
  1186. })
  1187. }
  1188. ,
  1189. GD.Progress.prototype.showLocoText = function () {
  1190. if (!this.logoTxt) {
  1191. var logoT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36C65EMhF+qPSQYcD3ysvF/AYIM5N2GpBXnkZYqXnWBsW+Oprzvr3io2jPWtAqLrc9lLu0sDt/f90S1TE4Qc+SpLcm/e2UO39gFBOtj0S2VtwQvsrl6wPEXR1y3zsUm7on59kwri/+Ip0zuUG4n6o93zCpsCTy4zSS11c35elxcJY8yCrvLhaQ0F/DC0/nGMPnfEoHr4rANLbnyHPl7+MCg0OmBVfAb5P5rJP9rAbPURxjk1gV3sPkAqFvUCoylrfdaZFn80Ns2zAsDXBk7dJc4+NWhYi9uHJ+xLbddj6+k9W7nWxuyPZxH24436JsAGU+gHInR/Tn/Krist7APWkLKQ00n1s0dfAcrgNyI4869x7n8zZunAdKaaDGI0rHrLRlVLniVELLOIMO9miqC8pXcEVaY/Gsqdxj6wawP+bCWmz5LSAElgLeZagRbOXW9BayG68OIu8fNWr9cwFkN5mGiusuo9zF275pgWmR8lg4euku7AOYoHzTYWS3KL/UgA/mVDLz7O7nutWP9LOUPuB6O43MJlKsZsJPT2MmqTGsfHTh1qYv21B1ubIhU2eyeoIW6XjKXYB+Dx28WiLIGTWM730ce/92sArzB1ZX/KlxV1P1WDKevcjCuXMtZ3wHSd3ayGr5PFa1t8TMtxGKCqz7bqho8rAUxoNfsngePM/D2cZux43pLu4xXuB8q1QIewFfcyI3zJWKb8C3/WSP+yIym2eNiSbyCqyZFD5VVq0juzm/TDsXPGcwk9n3wG9nzWMJE3FFjDI8met4HylPMS/+Q64jT7Dv53ODe2HutBxR5K+KeRWEUyl35GEqRU8SIuaNX5ffDSOvinoF9LLVNcygfJ+xl2rODoZ1KDhkTm1AoepL5vL03wIMANN/MUNK60tEAAAAAElFTkSuQmCC"
  1192. this.logoTxt = new PIXI.Sprite.fromImage(logoTxt),
  1193. this.logoTxt.anchor.set(.5),
  1194. this.logoTxt.scale.set(1),
  1195. this.logoTxt.y = GD.height / 2
  1196. }
  1197. this.logoTxt.x = GD.width / 2 + 65,
  1198. this.logoTxt.alpha = 0,
  1199. this.addChild(this.logoTxt),
  1200. TweenMax.to(this.logo, .4, {
  1201. x: GD.width / 2 - 95,
  1202. ease: Sine.easeOut
  1203. }),
  1204. TweenMax.to(this.logoTxt, .4, {
  1205. x: GD.width / 2 + 90,
  1206. alpha: 1,
  1207. ease: Sine.easeOut
  1208. }),
  1209. TweenMax.delayedCall(2, this.replay.bind(this))
  1210. }
  1211. ,
  1212. GD.Progress.prototype.replay = function () {
  1213. this.hide(),
  1214. this.show()
  1215. }
  1216. ,
  1217. GD.Progress.prototype.hide = function () {
  1218. TweenMax.killAll(),
  1219. this.tween.clear(),
  1220. this.removeChildren()
  1221. }
  1222. ,
  1223. GD.Progress.prototype.updateTransform = function () {
  1224. PIXI.Container.prototype.updateTransform.call(this)
  1225. }
  1226. }
  1227. , function (t, e) {
  1228. GD.Tutorial = function () {
  1229. PIXI.Container.call(this),
  1230. this.type = 1,
  1231. this.tutorialImg = null,
  1232. this.nowPage = 0,
  1233. this.totalPage = 0,
  1234. this.contents = [],
  1235. this.container = new PIXI.Container,
  1236. this.img = this.setSpriteTexture(this.img, "texture", "temp"),
  1237. this.prevBtn = this.setSpriteTexture(this.prevBtn, "texture", "temp"),
  1238. this.prevBtn.anchor.set(.5),
  1239. this.prevBtn.x = 30,
  1240. this.prevBtn.y = GD.height / 2,
  1241. this.setTouchStartAction(this.prevBtn, function () {
  1242. this.nowPage > 0 && this.initPage(this.nowPage - 1)
  1243. }, this),
  1244. this.addChild(this.prevBtn),
  1245. this.nextBtn = this.setSpriteTexture(this.nextBtn, "texture", "temp"),
  1246. this.nextBtn.anchor.set(.5),
  1247. this.nextBtn.x = GD.width - 30,
  1248. this.nextBtn.y = GD.height / 2,
  1249. this.setTouchStartAction(this.nextBtn, function () {
  1250. this.nowPage + 1 < this.totalPage && this.initPage(this.nowPage + 1)
  1251. }, this),
  1252. this.addChild(this.nextBtn),
  1253. this.closeBtn = this.setSpriteTexture(this.closeBtn, "texture", "temp"),
  1254. this.closeBtn.anchor.set(.5),
  1255. this.closeBtn.x = GD.width / 2,
  1256. this.closeBtn.y = GD.height - 105,
  1257. this.setTouchStartAction(this.closeBtn),
  1258. this.setTouchEnd(this.closeBtn, function () {
  1259. this.emit("TUTORIAL_CLOSE_EVENT")
  1260. }, this),
  1261. this.addChild(this.closeBtn)
  1262. }
  1263. ,
  1264. GD.Tutorial.constructor = GD.Tutorial,
  1265. GD.Tutorial.prototype = Object.create(PIXI.Container.prototype),
  1266. GD.Tutorial.prototype.init = function (t, e) {
  1267. this.removeChild(),
  1268. this.type = 1,
  1269. this.tutorialImg = e,
  1270. this.nowPage = 0,
  1271. this.totalPage = t,
  1272. this.addChild(this.img),
  1273. this.addChild(this.closeBtn),
  1274. this.initPageButton(),
  1275. this.setTutorialImg(),
  1276. this.setInteractive(!0),
  1277. this.setButtons()
  1278. }
  1279. ,
  1280. GD.Tutorial.prototype.initContent = function (t, e) {
  1281. this.removeChild(),
  1282. this.type = 2,
  1283. this.nowPage = 0,
  1284. this.totalPage = t,
  1285. this.contents = e,
  1286. this.addChild(this.container),
  1287. this.addChild(this.closeBtn),
  1288. this.container.addChild(this.contents[0]),
  1289. this.setContent(),
  1290. this.initPageButton(),
  1291. this.setInteractive(!0),
  1292. this.setButtons()
  1293. }
  1294. ,
  1295. GD.Tutorial.prototype.initPage = function (t, e) {
  1296. this.nowPage = t,
  1297. e && (this.closeBtn = this.setSpriteTexture(this.closeBtn, "texture", e)),
  1298. 1 == this.type ? this.setTutorialImg() : this.setContent(),
  1299. this.setButtons()
  1300. }
  1301. ,
  1302. GD.Tutorial.prototype.initPageButton = function () {
  1303. this.totalPage > 1 && (this.prevBtn = this.setSpriteTexture(this.prevBtn, "texture", "help_prev"),
  1304. this.nextBtn = this.setSpriteTexture(this.nextBtn, "texture", "help_next"),
  1305. this.prevBtn.scale.set(1),
  1306. this.nextBtn.scale.set(1),
  1307. this.addChild(this.prevBtn),
  1308. this.addChild(this.nextBtn))
  1309. }
  1310. ,
  1311. GD.Tutorial.prototype.setPrevButtonPos = function (t, e) {
  1312. this.prevBtn.x = t,
  1313. this.prevBtn.y = e
  1314. }
  1315. ,
  1316. GD.Tutorial.prototype.setNextButtonPos = function (t, e) {
  1317. this.nextBtn.x = t,
  1318. this.nextBtn.y = e
  1319. }
  1320. ,
  1321. GD.Tutorial.prototype.setCloseButtonPos = function (t, e) {
  1322. this.closeBtn.x = t,
  1323. this.closeBtn.y = e
  1324. }
  1325. ,
  1326. GD.Tutorial.prototype.setTutorialImg = function () {
  1327. this.img = this.setSpriteTexture(this.img, "texture", this.tutorialImg + (this.nowPage + 1))
  1328. }
  1329. ,
  1330. GD.Tutorial.prototype.setContent = function () {
  1331. this.container.removeChildren();
  1332. var t = this.contents[this.nowPage];
  1333. t.init && t.init(),
  1334. this.container.addChild(t)
  1335. }
  1336. ,
  1337. GD.Tutorial.prototype.setButtons = function () {
  1338. this.totalPage > 0 && (0 == this.nowPage ? (this.prevBtn.alpha = .3,
  1339. this.nextBtn.alpha = 1,
  1340. this.prevBtn.interactive = !1,
  1341. this.nextBtn.interactive = !0) : this.nowPage + 1 == this.totalPage ? (this.prevBtn.alpha = 1,
  1342. this.nextBtn.alpha = .3,
  1343. this.prevBtn.interactive = !0,
  1344. this.nextBtn.interactive = !1) : (this.prevBtn.alpha = 1,
  1345. this.nextBtn.alpha = 1,
  1346. this.prevBtn.interactive = !0,
  1347. this.nextBtn.interactive = !0))
  1348. }
  1349. ,
  1350. GD.Tutorial.prototype.setInteractive = function (t) {
  1351. this.prevBtn.interactive = t,
  1352. this.nextBtn.interactive = t,
  1353. this.closeBtn.interactive = t
  1354. }
  1355. ,
  1356. GD.Tutorial.prototype.removeChild = function () {
  1357. this.setInteractive(!1),
  1358. this.container.removeChildren(),
  1359. this.removeChildren()
  1360. }
  1361. ,
  1362. GD.Tutorial.getInstance = function () {
  1363. return GD.tutorial || (GD.tutorial = new GD.Tutorial),
  1364. GD.tutorial
  1365. }
  1366. }
  1367. ]);
  1368. export default GD