config.ts 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. import { _decorator, Component, Node } from 'cc';
  2. const { ccclass, property } = _decorator;
  3. @ccclass('config')
  4. export class config {
  5. public static Platform = {
  6. platform: "douyin",
  7. // platform: "wx"
  8. }
  9. public static API = {
  10. login : "/snake/user/login",
  11. info : "/snake/user/info",
  12. get_dyopen_id : "/snake/user/get_dyopen_id",
  13. sync_integral : "/snake/user/sync_integral",
  14. user_ranking : "/snake/user/user_ranking",
  15. user_car_list : "/snake/user/user_car_list",
  16. }
  17. public static STATIC_API = {
  18. levels : "/snakestatic/levels.json",
  19. regions : "/snakestatic/regions.json",
  20. car_list : "/snakestatic/car_list.json",
  21. rankings: (region_id)=>{
  22. return `/snakestatic/rankings/${region_id}.json`
  23. }
  24. }
  25. public static AD_TYPE = {
  26. UNKNOWN:""
  27. }
  28. public static status = {
  29. SUCCESS:10000
  30. }
  31. public static item_type = {
  32. box_blue:1,
  33. box_zise:2,
  34. box_yellow:3,
  35. box_green:4,
  36. box_red:5,
  37. wall:6,
  38. coin:7,
  39. scores:8,
  40. box_fenhong:9,
  41. box_huanglv:10,
  42. box_qing:11,
  43. box_zi:12,
  44. box_huang:13,
  45. }
  46. public static buff_type = {
  47. dun:1, //盾无敌时间
  48. xing:2, //获取积分翻倍
  49. xi:3 //吸收周边的积分
  50. }
  51. public static collider_dir = {
  52. top:1,
  53. left:2,
  54. right:3
  55. }
  56. public static PREFAB={
  57. game:"prefabs/game"
  58. }
  59. public static AUDIO={
  60. loading_bgm:"bgm/loading_bgm",
  61. }
  62. public static UI = {
  63. ui_setting:"ui/setting",
  64. home:"ui/home"
  65. }
  66. }