globals_debug.js 866 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. const isDebugMode = true;
  2. const debugState = {
  3. lang: { status: true, lang: 'it_IT' },
  4. name: { status: true, name: 'Username' },
  5. menu: { status: true, id: 0 },
  6. customMenu: {
  7. status: true,
  8. getData: () => {
  9. return { mode: 'b', operation: 'plus', difficulty: 1, label: true };
  10. },
  11. },
  12. map: { status: true },
  13. end: { status: false, stop: false },
  14. };
  15. const debugFunctions = {
  16. grid: () => {
  17. const grid = 2;
  18. const h = 1920 / (grid + 0.5);
  19. const v = 1080 / (grid + 0.5);
  20. for (let i = 0; i < grid; i++) {
  21. game.add.geom.rect(
  22. h / 2 + i * h,
  23. 0,
  24. h / 2,
  25. 1080,
  26. '',
  27. 0,
  28. colors.blue,
  29. 0.3
  30. );
  31. game.add.geom.rect(
  32. 0,
  33. v / 2 + i * v,
  34. 1920,
  35. v / 2,
  36. '',
  37. 0,
  38. colors.blue,
  39. 0.3
  40. );
  41. }
  42. },
  43. };