Last active
July 24, 2021 19:22
-
-
Save JacobLinCool/232e6c17fe919d6d80769f2017f2fe7d to your computer and use it in GitHub Desktop.
Export & Import Champion Island Game Data
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
KEYS = [ | |
"KITSUNE_climbingintro_VIDEO_SEEN", | |
"KITSUNE_marathonoutro_VIDEO_SEEN", | |
"KITSUNE_fsOneEighty_COMPLETE", | |
"KITSUNE_SLEEPING_CAT", | |
"KITSUNE_CONSTRUCTION", | |
"KITSUNE_HOT_SPRING", | |
"KITSUNE_rugby_rating", | |
"KITSUNE_pingpong:hard_rating", | |
"KITSUNE_TUT_MOVE", | |
"KITSUNE_swim:ballad_rating", | |
"KITSUNE_skateoutro_VIDEO_SEEN", | |
"KITSUNE_skate_rating", | |
"KITSUNE_LANTERN_4", | |
"KITSUNE_skate:park2_rating", | |
"KITSUNE_marathon_TUTORIAL_SEEN", | |
"KITSUNE_archeryoutro_VIDEO_SEEN", | |
"KITSUNE_BIRTHDAY", | |
"KITSUNE_archery_score", | |
"KITSUNE_archery_rating", | |
"KITSUNE_LANTERN_1", | |
"KITSUNE_FIRST_PLACE", | |
"KITSUNE_swim:ballad_score", | |
"KITSUNE_kickFlip_COMPLETE", | |
"KITSUNE_rugbyintro_VIDEO_SEEN", | |
"KITSUNE_skate:park2_score", | |
"KITSUNE_pingpong:ultra_rating", | |
"KITSUNE_marathon:1500m_rating", | |
"KITSUNE_", | |
"KITSUNE_LANTERN_2", | |
"KITSUNE_climbingoutro_VIDEO_SEEN", | |
"KITSUNE_skateintro_VIDEO_SEEN", | |
"KITSUNE_LANTERN_LIGHT", | |
"KITSUNE_swimintro_VIDEO_SEEN", | |
"KITSUNE_archery_TUTORIAL_SEEN", | |
"KITSUNE_pingpong:hard_score", | |
"KITSUNE_swimoutro_VIDEO_SEEN", | |
"KITSUNE_rugby_TUTORIAL_SEEN", | |
"KITSUNE_climbing:hard_score", | |
"KITSUNE_swim:rock_rating", | |
"KITSUNE_PLAYER_TEAM", | |
"KITSUNE_swim_TUTORIAL_SEEN", | |
"KITSUNE_swim_rating", | |
"KITSUNE_PLAYER_LOC", | |
"KITSUNE_marathon_score", | |
"KITSUNE_WATER_GATE", | |
"KITSUNE_outro_VIDEO_SEEN", | |
"KITSUNE_pingpong_rating", | |
"KITSUNE_marathon:1500m_score", | |
"KITSUNE_ARROWS", | |
"KITSUNE_RACE", | |
"KITSUNE_pingpongoutro_VIDEO_SEEN", | |
"KITSUNE_RAIN", | |
"KITSUNE_ACTION_PROMPT", | |
"KITSUNE_pingpong:ultra_score", | |
"KITSUNE_marathonintro_VIDEO_SEEN", | |
"KITSUNE_TROPHY_MASTER", | |
"KITSUNE_PORCUPINE", | |
"KITSUNE_skate_score", | |
"KITSUNE_climbing_score", | |
"KITSUNE_climbing_TUTORIAL_SEEN", | |
"KITSUNE_LOST_PADDLE", | |
"KITSUNE_pingpongintro_VIDEO_SEEN", | |
"KITSUNE_LANTERN_3", | |
"KITSUNE_TRAIN_VISIBLE", | |
"KITSUNE_TUTORIAL_BEGIN", | |
"KITSUNE_BOW_TRIGGER", | |
"KITSUNE_TUTORIAL_DONE", | |
"KITSUNE_COACH", | |
"KITSUNE_ONI", | |
"KITSUNE_SUBMITTED_SCORES", | |
"KITSUNE_LUCKY_ARROW", | |
"KITSUNE_rugbyoutro_VIDEO_SEEN", | |
"KITSUNE_MOMOTARO", | |
"KITSUNE_FAN", | |
"KITSUNE_marathon_rating", | |
"KITSUNE_LOST_BOOK", | |
"KITSUNE_climbing:hard_rating", | |
"KITSUNE_GHOST", | |
"KITSUNE_DRIFTWOOD", | |
"KITSUNE_PLAYER_POS", | |
"KITSUNE_skate_TUTORIAL_SEEN", | |
"KITSUNE_climbing_rating", | |
"KITSUNE_LEADERBOARD_FIRST", | |
"KITSUNE_archeryintro_VIDEO_SEEN", | |
"KITSUNE_swim:rock_score", | |
"KITSUNE_DEVICE", | |
"KITSUNE_intro_VIDEO_SEEN", | |
"KITSUNE_pingpong_TUTORIAL_SEEN", | |
"KITSUNE_rugby_score", | |
"KITSUNE_TRAIN_TRACKS", | |
"KITSUNE_noseGrab_COMPLETE", | |
"KITSUNE_CHASE", | |
"KITSUNE_swim_score", | |
"KITSUNE_INTRO", | |
"KITSUNE_barrelRoll_COMPLETE", | |
"KITSUNE_pingpong_score", | |
"KITSUNE_TUT_ACTION", | |
]; | |
function exportGameData() { | |
const data = []; | |
for (let i = 0; i < KEYS.length; i++) { | |
data.push(localStorage.getItem(KEYS[i])); | |
} | |
console.log(btoa(JSON.stringify(data)).length); | |
prompt("Copy Your Game Data:", btoa(JSON.stringify(data))); | |
return "Exported."; | |
} | |
function importGameData() { | |
if (!confirm("Importing Game Data Will Overwrite The Old One! Are You Sure?")) return "Cancelled."; | |
const data = JSON.parse(atob(prompt("Paste Your Game Data: ", ""))); | |
for (let i = 0; i < KEYS.length; i++) { | |
localStorage.setItem(KEYS[i], data[i]); | |
} | |
return "Imported."; | |
} | |
(() => { | |
const isImport = confirm("Export (Cancel) or Import (OK) Game Data?"); | |
if (isImport) { | |
importGameData(); | |
} else { | |
exportGameData(); | |
} | |
})(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function exportGameData(){const E=[];for(let _=0;_<KEYS.length;_++)E.push(localStorage.getItem(KEYS[_]));return console.log(btoa(JSON.stringify(E)).length),prompt("Copy Your Game Data:",btoa(JSON.stringify(E))),"Exported."}function importGameData(){if(!confirm("Importing Game Data Will Overwrite The Old One! Are You Sure?"))return"Cancelled.";const E=JSON.parse(atob(prompt("Paste Your Game Data: ","")));for(let _=0;_<KEYS.length;_++)localStorage.setItem(KEYS[_],E[_]);return"Imported."}KEYS=["KITSUNE_climbingintro_VIDEO_SEEN","KITSUNE_marathonoutro_VIDEO_SEEN","KITSUNE_fsOneEighty_COMPLETE","KITSUNE_SLEEPING_CAT","KITSUNE_CONSTRUCTION","KITSUNE_HOT_SPRING","KITSUNE_rugby_rating","KITSUNE_pingpong:hard_rating","KITSUNE_TUT_MOVE","KITSUNE_swim:ballad_rating","KITSUNE_skateoutro_VIDEO_SEEN","KITSUNE_skate_rating","KITSUNE_LANTERN_4","KITSUNE_skate:park2_rating","KITSUNE_marathon_TUTORIAL_SEEN","KITSUNE_archeryoutro_VIDEO_SEEN","KITSUNE_BIRTHDAY","KITSUNE_archery_score","KITSUNE_archery_rating","KITSUNE_LANTERN_1","KITSUNE_FIRST_PLACE","KITSUNE_swim:ballad_score","KITSUNE_kickFlip_COMPLETE","KITSUNE_rugbyintro_VIDEO_SEEN","KITSUNE_skate:park2_score","KITSUNE_pingpong:ultra_rating","KITSUNE_marathon:1500m_rating","KITSUNE_","KITSUNE_LANTERN_2","KITSUNE_climbingoutro_VIDEO_SEEN","KITSUNE_skateintro_VIDEO_SEEN","KITSUNE_LANTERN_LIGHT","KITSUNE_swimintro_VIDEO_SEEN","KITSUNE_archery_TUTORIAL_SEEN","KITSUNE_pingpong:hard_score","KITSUNE_swimoutro_VIDEO_SEEN","KITSUNE_rugby_TUTORIAL_SEEN","KITSUNE_climbing:hard_score","KITSUNE_swim:rock_rating","KITSUNE_PLAYER_TEAM","KITSUNE_swim_TUTORIAL_SEEN","KITSUNE_swim_rating","KITSUNE_PLAYER_LOC","KITSUNE_marathon_score","KITSUNE_WATER_GATE","KITSUNE_outro_VIDEO_SEEN","KITSUNE_pingpong_rating","KITSUNE_marathon:1500m_score","KITSUNE_ARROWS","KITSUNE_RACE","KITSUNE_pingpongoutro_VIDEO_SEEN","KITSUNE_RAIN","KITSUNE_ACTION_PROMPT","KITSUNE_pingpong:ultra_score","KITSUNE_marathonintro_VIDEO_SEEN","KITSUNE_TROPHY_MASTER","KITSUNE_PORCUPINE","KITSUNE_skate_score","KITSUNE_climbing_score","KITSUNE_climbing_TUTORIAL_SEEN","KITSUNE_LOST_PADDLE","KITSUNE_pingpongintro_VIDEO_SEEN","KITSUNE_LANTERN_3","KITSUNE_TRAIN_VISIBLE","KITSUNE_TUTORIAL_BEGIN","KITSUNE_BOW_TRIGGER","KITSUNE_TUTORIAL_DONE","KITSUNE_COACH","KITSUNE_ONI","KITSUNE_SUBMITTED_SCORES","KITSUNE_LUCKY_ARROW","KITSUNE_rugbyoutro_VIDEO_SEEN","KITSUNE_MOMOTARO","KITSUNE_FAN","KITSUNE_marathon_rating","KITSUNE_LOST_BOOK","KITSUNE_climbing:hard_rating","KITSUNE_GHOST","KITSUNE_DRIFTWOOD","KITSUNE_PLAYER_POS","KITSUNE_skate_TUTORIAL_SEEN","KITSUNE_climbing_rating","KITSUNE_LEADERBOARD_FIRST","KITSUNE_archeryintro_VIDEO_SEEN","KITSUNE_swim:rock_score","KITSUNE_DEVICE","KITSUNE_intro_VIDEO_SEEN","KITSUNE_pingpong_TUTORIAL_SEEN","KITSUNE_rugby_score","KITSUNE_TRAIN_TRACKS","KITSUNE_noseGrab_COMPLETE","KITSUNE_CHASE","KITSUNE_swim_score","KITSUNE_INTRO","KITSUNE_barrelRoll_COMPLETE","KITSUNE_pingpong_score","KITSUNE_TUT_ACTION"],confirm("Export (Cancel) or Import (OK) Game Data?")?importGameData():exportGameData(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment