never change, robtop
This commit is contained in:
parent
2fe2f5f926
commit
6d52140e32
7 changed files with 28 additions and 11 deletions
|
@ -108,7 +108,7 @@ module.exports = async (app, req, res) => {
|
||||||
let arr = x.split(':')
|
let arr = x.split(':')
|
||||||
authorList[arr[0]] = [arr[1], arr[2]]})
|
authorList[arr[0]] = [arr[1], arr[2]]})
|
||||||
|
|
||||||
let levelArray = preRes.map(x => app.parseResponse(x)).filter(x => x[1])
|
let levelArray = preRes.map(x => app.parseResponse(x)).filter(x => x[2])
|
||||||
let parsedLevels = []
|
let parsedLevels = []
|
||||||
|
|
||||||
levelArray.forEach((x, y) => {
|
levelArray.forEach((x, y) => {
|
||||||
|
@ -128,7 +128,7 @@ module.exports = async (app, req, res) => {
|
||||||
if (level.author != "-" && app.config.cacheAccountIDs) app.userCache(req.id, level.accountID, level.playerID, level.author)
|
if (level.author != "-" && app.config.cacheAccountIDs) app.userCache(req.id, level.accountID, level.playerID, level.author)
|
||||||
|
|
||||||
//this is broken if you're not on page 0, blame robtop
|
//this is broken if you're not on page 0, blame robtop
|
||||||
if (filters.page == 0 && y == 0) {
|
if (filters.page == 0 && y == 0 && splitBody[3]) {
|
||||||
let pages = splitBody[3].split(":");
|
let pages = splitBody[3].split(":");
|
||||||
|
|
||||||
if (filters.gauntlet) { // gauntlet page stuff
|
if (filters.gauntlet) { // gauntlet page stuff
|
||||||
|
|
BIN
assets/gdps/robtopgames_icon.png
Normal file
BIN
assets/gdps/robtopgames_icon.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4 KiB |
BIN
assets/gdps/robtopgames_logo.png
Normal file
BIN
assets/gdps/robtopgames_logo.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 175 KiB |
|
@ -11,16 +11,16 @@ class Level {
|
||||||
if (!levelInfo[2]) return;
|
if (!levelInfo[2]) return;
|
||||||
this.name = levelInfo[2];
|
this.name = levelInfo[2];
|
||||||
this.id = levelInfo[1];
|
this.id = levelInfo[1];
|
||||||
this.description = Buffer.from(levelInfo[3], "base64").toString() || "(No description provided)";
|
this.description = Buffer.from((levelInfo[3] || ""), "base64").toString() || "(No description provided)";
|
||||||
this.author = author[1] || "-"
|
this.author = author[1] || "-"
|
||||||
this.playerID = levelInfo[6]
|
this.playerID = levelInfo[6]
|
||||||
this.accountID = author[2] || 0
|
this.accountID = author[2] || 0
|
||||||
this.difficulty = difficulty[levelInfo[9]]
|
this.difficulty = difficulty[levelInfo[9]] || "Unrated"
|
||||||
this.downloads = +levelInfo[10]
|
this.downloads = +levelInfo[10] || 0
|
||||||
this.likes = +levelInfo[14]
|
this.likes = +levelInfo[14] || 0
|
||||||
this.disliked = levelInfo[14] < 0
|
this.disliked = levelInfo[14] < 0
|
||||||
this.length = length[levelInfo[15]] || "XL"
|
this.length = length[levelInfo[15]] || "XL"
|
||||||
this.stars = +levelInfo[18]
|
this.stars = +levelInfo[18] || 0
|
||||||
this.orbs = orbs[levelInfo[18]] || 0
|
this.orbs = orbs[levelInfo[18]] || 0
|
||||||
this.diamonds = levelInfo[18] < 2 ? 0 : parseInt(levelInfo[18]) + 2
|
this.diamonds = levelInfo[18] < 2 ? 0 : parseInt(levelInfo[18]) + 2
|
||||||
this.featured = levelInfo[19] > 0
|
this.featured = levelInfo[19] > 0
|
||||||
|
@ -31,10 +31,10 @@ class Level {
|
||||||
if (download) { this.editorTime = +levelInfo[46] || 0; this.totalEditorTime = +levelInfo[47] || 0 }
|
if (download) { this.editorTime = +levelInfo[46] || 0; this.totalEditorTime = +levelInfo[47] || 0 }
|
||||||
if (levelInfo[27]) this.password = levelInfo[27];
|
if (levelInfo[27]) this.password = levelInfo[27];
|
||||||
this.version = +levelInfo[5];
|
this.version = +levelInfo[5];
|
||||||
this.copiedID = levelInfo[30]
|
this.copiedID = levelInfo[30] || "0"
|
||||||
this.twoPlayer = levelInfo[31] > 0
|
this.twoPlayer = levelInfo[31] > 0
|
||||||
this.officialSong = +levelInfo[35] ? 0 : parseInt(levelInfo[12]) + 1
|
this.officialSong = +levelInfo[35] ? 0 : parseInt(levelInfo[12]) + 1
|
||||||
this.customSong = +levelInfo[35]
|
this.customSong = +levelInfo[35] || 0
|
||||||
this.coins = +levelInfo[37]
|
this.coins = +levelInfo[37]
|
||||||
this.verifiedCoins = levelInfo[38] > 0
|
this.verifiedCoins = levelInfo[38] > 0
|
||||||
this.starsRequested = +levelInfo[39]
|
this.starsRequested = +levelInfo[39]
|
||||||
|
|
|
@ -136,7 +136,7 @@ let superSearch = ['*', '*?type=mostliked', '*?type=mostdownloaded', '*?type=rec
|
||||||
let demonListLink = "https://pointercrate.com/"
|
let demonListLink = "https://pointercrate.com/"
|
||||||
let searchFilters = `../api/search/${type == 'saved' ? JSON.parse(localStorage.getItem('saved') || '[]').reverse().toString() : accID || path}?page=[PAGE]${count ? "" : "&count=10"}${window.location.search.replace(/\?/g, "&").replace("page", "nope")}`
|
let searchFilters = `../api/search/${type == 'saved' ? JSON.parse(localStorage.getItem('saved') || '[]').reverse().toString() : accID || path}?page=[PAGE]${count ? "" : "&count=10"}${window.location.search.replace(/\?/g, "&").replace("page", "nope")}`
|
||||||
|
|
||||||
function clean(text) {return text.toString().replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/=/g, "=").replace(/"/g, """).replace(/'/g, "'")}
|
function clean(text) {return (text || "").toString().replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/=/g, "=").replace(/"/g, """).replace(/'/g, "'")}
|
||||||
|
|
||||||
if (type == "followed") {
|
if (type == "followed") {
|
||||||
let followed = localStorage.followed ? JSON.parse(localStorage.followed) : []
|
let followed = localStorage.followed ? JSON.parse(localStorage.followed) : []
|
||||||
|
@ -193,7 +193,7 @@ function Append(firstLoad) {
|
||||||
let noLink = songColor != "whatIfItWasPurple"
|
let noLink = songColor != "whatIfItWasPurple"
|
||||||
|
|
||||||
$('#searchBox').append(`<div class="searchresult" title="${clean(x.description)}">
|
$('#searchBox').append(`<div class="searchresult" title="${clean(x.description)}">
|
||||||
<h1 class="help lessspaced pre" title="${x.name} (${x.id})" style="width: fit-content; padding-right: 1%">${x.name}</h1>
|
<h1 class="help lessspaced pre" title="${x.name} (${x.id})" style="width: fit-content; padding-right: 1%">${clean(x.name)}</h1>
|
||||||
<h2 class="lessSpaced pre smaller inline gdButton help ${hasAuthor ? "" : "green unregistered"}" title="Account ID: ${x.accountID}\nPlayer ID: ${x.playerID}">${hasAuthor && !onePointNine ? `<a href="../u/${x.author}">By ${x.author || "-"}</a>` : `<a ${userSearch ? "" : `href="../search/${x.playerID}?user"`}>By ${x.author || "-"}</a>`}</h2><h2 class="inline" style="margin-left: 1.5%; transform:translateY(30%)"> ${x.copiedID == '0' ? "" : `<a target="_blank" href="../${x.copiedID}"><img class="gdButton valign sideSpace" title="Original: ${x.copiedID}" src="../assets/copied.png" height="12%"></a>`}${x.large ? `<img class="help valign sideSpaceD" title="${x.objects}${x.objects == 65535 ? "+" : ""} objects" src="../assets/large.png" height="12%">` : ''}</h2>
|
<h2 class="lessSpaced pre smaller inline gdButton help ${hasAuthor ? "" : "green unregistered"}" title="Account ID: ${x.accountID}\nPlayer ID: ${x.playerID}">${hasAuthor && !onePointNine ? `<a href="../u/${x.author}">By ${x.author || "-"}</a>` : `<a ${userSearch ? "" : `href="../search/${x.playerID}?user"`}>By ${x.author || "-"}</a>`}</h2><h2 class="inline" style="margin-left: 1.5%; transform:translateY(30%)"> ${x.copiedID == '0' ? "" : `<a target="_blank" href="../${x.copiedID}"><img class="gdButton valign sideSpace" title="Original: ${x.copiedID}" src="../assets/copied.png" height="12%"></a>`}${x.large ? `<img class="help valign sideSpaceD" title="${x.objects}${x.objects == 65535 ? "+" : ""} objects" src="../assets/large.png" height="12%">` : ''}</h2>
|
||||||
<h3 class="lessSpaced help ${noLink ? "" : 'gdButton '}pre ${songColor}" title="${filteredSong} by ${x.songAuthor} (${x.songID})" style="overflow: hidden; max-height: 19%; width: fit-content">${noLink ? filteredSong : `<a target="_blank" style="width: fit-content" href="https://www.newgrounds.com/audio/listen/${x.songID}">${filteredSong}</a>`}</h3>
|
<h3 class="lessSpaced help ${noLink ? "" : 'gdButton '}pre ${songColor}" title="${filteredSong} by ${x.songAuthor} (${x.songID})" style="overflow: hidden; max-height: 19%; width: fit-content">${noLink ? filteredSong : `<a target="_blank" style="width: fit-content" href="https://www.newgrounds.com/audio/listen/${x.songID}">${filteredSong}</a>`}</h3>
|
||||||
<h3 class="lessSpaced" style="width: fit-content" title="">
|
<h3 class="lessSpaced" style="width: fit-content" title="">
|
||||||
|
|
|
@ -20,7 +20,9 @@
|
||||||
[ "envylol", 73, 20, 1, 1],
|
[ "envylol", 73, 20, 1, 1],
|
||||||
[ "EVW", 28, 12, 9, 0 ],
|
[ "EVW", 28, 12, 9, 0 ],
|
||||||
[ "Flub", 25, 3, 12, 1 ],
|
[ "Flub", 25, 3, 12, 1 ],
|
||||||
|
[ "GD Flaaroni", 62, 12, 15, 0 ],
|
||||||
[ "GD Jaden", 74, 13, 12, 1 ],
|
[ "GD Jaden", 74, 13, 12, 1 ],
|
||||||
|
[ "Horny", 102, 7, 12, 1 ],
|
||||||
[ "Juniper", 98, 40, 12, 1 ],
|
[ "Juniper", 98, 40, 12, 1 ],
|
||||||
[ "klaux", 46, 22, 25, 1 ],
|
[ "klaux", 46, 22, 25, 1 ],
|
||||||
[ "Knobbelboy", 37, 10, 14, 0 ],
|
[ "Knobbelboy", 37, 10, 14, 0 ],
|
||||||
|
|
15
servers.json
15
servers.json
|
@ -159,5 +159,20 @@
|
||||||
"authorLink": "https://www.youtube.com/channel/UCRbHwfh_BlMUfTZOvquDuRA",
|
"authorLink": "https://www.youtube.com/channel/UCRbHwfh_BlMUfTZOvquDuRA",
|
||||||
"id": "ausk",
|
"id": "ausk",
|
||||||
"endpoint": "http://gdps.mathieuar.fr/ausk____/"
|
"endpoint": "http://gdps.mathieuar.fr/ausk____/"
|
||||||
|
},
|
||||||
|
|
||||||
|
{
|
||||||
|
"name": "Rob's Abandoned Server",
|
||||||
|
"link": "http://robtopgames.com/",
|
||||||
|
"author": "RobTop",
|
||||||
|
"authorLink": "https://www.youtube.com/channel/UCz_yk8mDSAnxJq0ar66L4sw",
|
||||||
|
"id": "robtopgames",
|
||||||
|
"endpoint": "http://robtopgames.com/database/",
|
||||||
|
"onePointNine": true,
|
||||||
|
"timestampSuffix": " ago",
|
||||||
|
"overrides": {
|
||||||
|
"getGJLevels21": "getGJLevels",
|
||||||
|
"downloadGJLevel22": "downloadGJLevel"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
Loading…
Reference in a new issue