@@ -7775,74 +7775,6 @@ Current version indicated by LITEVER below.
77757775 * }[]}
77767776 **/
77777777 const scenario_sources = [
7778- // Aetherroom.club
7779- {
7780- name: "aetherroom.club",
7781- urlParam: "aether",
7782- inputBox: {
7783- text: "Enter aetherroom.club prompt URL, or 4-digit prompt number",
7784- placeholder: "https://aetherroom.club/1234"
7785- },
7786- extraction: (userInput) => {
7787- userInput = userInput.toLowerCase();
7788- if (userInput.includes("aetherroom.club/")) {
7789- //is a url, extract the ID
7790- userInput = userInput.replace("/api/","/");
7791- userInput = userInput.split("aetherroom.club/")[1];
7792- userInput = userInput.split("/")[0];
7793- userInput = userInput.split("#")[0];
7794- userInput = userInput.split("?")[0];
7795- }
7796- if(!(userInput!="" && is_numeric(userInput) && userInput>0 && userInput<50000))
7797- throw new Error("User input is invalid\n\n Please ensure you have input a valid aetherroom.club URL or ID (e.g. https://aetherroom.club/1234 or just 1234)");
7798- return userInput;
7799- },
7800- fetch: (userInput) => {
7801- return fetch(apply_proxy_url("https://aetherroom.club/api/"+userInput,true))
7802- .then(x => x.json())
7803- .then(data => {
7804- console.log(data);
7805- temp_scenario =
7806- {
7807- "title":data.title?data.title:"",
7808- "desc":data.description?data.description:"",
7809- "opmode":2,
7810- "adventure_context_mod":false,
7811- "adventure_switch_mode":1,
7812- "prompt":data.promptContent?data.promptContent:"",
7813- "memory": data.memory?data.memory:"",
7814- "authorsnote": data.authorsNote?data.authorsNote:"",
7815- "worldinfo": []
7816- };
7817- if (data.worldInfos)
7818- {
7819- for (let w = 0; w < data.worldInfos.length; ++w) {
7820- let keys = data.worldInfos[w].keys;
7821- let entry = data.worldInfos[w].entry;
7822-
7823- let nwi = {
7824- "key": (keys ? keys : ""),
7825- "keysecondary": "",
7826- "keyanti": "",
7827- "content": (entry ? entry : ""),
7828- "comment": "",
7829- "folder": null,
7830- "selective": false,
7831- "constant": false,
7832- "probability":100,
7833- "wigroup":"",
7834- "widisabled":false
7835- };
7836- temp_scenario.worldinfo.push(nwi);
7837- }
7838- }
7839- preview_temp_scenario();
7840- }).catch((error) => {
7841- console.error(error);
7842- throw new Error("Error: Selected scenario is invalid.");
7843- });
7844- }
7845- },
78467778 // Chub.ai
78477779 {
78487780 name: "characterhub.org / chub.ai",
0 commit comments