Kour KP Script

Unlimited 1500 KP Daily Rewards

  1. // ==UserScript==
  2. // @name Kour KP Script
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.3
  5. // @description Unlimited 1500 KP Daily Rewards
  6. // @author November2246
  7. // @match *://kour.io/*
  8. // @icon https://www.google.com/s2/favicons?sz=64&domain=kour.io
  9. // @grant none
  10. // @license ISC <3
  11. // @run-at document-start
  12. // ==/UserScript==
  13.  
  14. new MutationObserver((mutations) => {
  15. for (const mutation of mutations) {
  16. for (const node of mutation.addedNodes) {
  17. if (node.tagName === 'SCRIPT' && !node.src) {
  18. if (String(node.textContent).toLowerCase().includes('userscript')) {
  19. node.textContent = 'console.log(`Nice "anticheat" :D`)';
  20. }
  21. }
  22. }
  23. }
  24. }).observe(document, { childList: true, subtree: true });
  25.  
  26. const _fetch = window.fetch;
  27. window.fetch = function () {
  28. if (arguments[0].includes('/api/track')) {
  29. return Promise.reject();
  30. }
  31.  
  32. return _fetch.apply(this, arguments);
  33. }
  34.  
  35. function fixDailyRewards() {
  36. try {
  37. if (!window.firebase.auth()?.currentUser) return;
  38.  
  39. let shouldSet = false;
  40.  
  41. const rewardObj = { lastDailyReward: '9' };
  42. const refKey = 'users/' + window.firebase.auth().currentUser.uid;
  43.  
  44. window.firebase.database().ref(refKey).once('value', e => {
  45. const obj = e.val();
  46.  
  47. Object.keys(obj).forEach(key => {
  48. if (key.startsWith('dailyReward_')) {
  49. rewardObj[key] = null;
  50. shouldSet = true;
  51. }
  52.  
  53. if (key === 'lastDailyReward' && obj[key] !== '9') {
  54. shouldSet = true;
  55. }
  56. });
  57.  
  58. if (shouldSet) {
  59. window.firebase.database().ref(refKey).update(rewardObj);
  60. window.showUserDetails('', window.firebase.auth().currentUser);
  61. }
  62. });
  63.  
  64. } catch { }
  65. }
  66.  
  67. function fakeSetDataNew(a) {
  68. window.unityInstance.SendMessage('FirebasePlayerPrefs2023', 'OnSetData', '{"err":null}&' + [...a].pop());
  69. }
  70.  
  71. Object.defineProperty(window, 'unityInstance', {
  72. get() {
  73. return this._unityInstance;
  74. },
  75. set(v) {
  76. const _setDataNew = window.setDataNew;
  77. window.setDataNew = function () {
  78. if (arguments[1] === 'banned') {
  79. fakeSetDataNew(arguments);
  80. return;
  81. }
  82.  
  83. if (arguments[1].includes("dailyReward_")) {
  84. fakeSetDataNew(arguments);
  85. window.showUserDetails('', window.firebase.auth().currentUser);
  86. return;
  87. }
  88.  
  89. if (arguments[1] === 'lastDailyReward') {
  90. arguments[2] = '9';
  91. }
  92.  
  93. return _setDataNew.apply(this, arguments);
  94. }
  95.  
  96. this._unityInstance = v;
  97.  
  98. const _SendMessage = this._unityInstance.SendMessage;
  99. this._unityInstance.SendMessage = function () {
  100. if (arguments[1] === 'OnLoggedInGoogle') fixDailyRewards();
  101. return _SendMessage.apply(this, arguments);
  102. }
  103. },
  104. });

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址