Levels importing from unsupported bot

Hi I am trying to migrate from a bot with a similar leveling system as mee6 to lurkr, but the bot i am using (xelA) is not supported Now i can get the data as a json string via an api, so i was wondering if i could get someone here to manually migrate that, or get a pointer how i can do it myself
Solution:
resolved in dms
Jump to solution
33 Replies
EasyThreads
EasyThreadsā€¢6mo ago
:NighthawkInteractionError: BEFORE YOU ASK FOR SUPPORT :NighthawkInteractionError: 1ļøāƒ£ ā€¢ Use the panel in ā #šŸ†˜-help-me to check if your problem is a common issue! Use the buttons to select your problem and the bot will automatically respond with a message only you can see! 2ļøāƒ£ ā€¢ Check the documentation at https://docs.lurkr.gg/ and either use the guides found at the top of the navigation panel, or use the search tool to look for a specific thing you need to do! 3ļøāƒ£ ā€¢ Use the commands /config check and /config troubleshoot to get a better idea what issue you're having! ā“ ā€¢ Still stuck? Ask your question in as much detail as possible to help other people understand what your problem is and help you fix it quickly! ā—ā€¢ This server uses Answer Overflow to index content on the web. By posting in this channel your messages will be indexed on the web to help others find answers. šŸ”— ā€¢ https://www.answeroverflow.com/c/705009450855039039
Almeida
Almeidaā€¢6mo ago
yeah, i can migrate it manually ideally following this format:
interface DataFormat {
levels: {
messageCount: number;
userId: string;
xp: number;
level: number;
user: {
avatar: string | null;
discriminator: string;
username: string;
};
}[];
}
interface DataFormat {
levels: {
messageCount: number;
userId: string;
xp: number;
level: number;
user: {
avatar: string | null;
discriminator: string;
username: string;
};
}[];
}
this is actually the lurkr export format. and i already have a script i can run manually that imports a lurkr export into another server. so if you could match that format, that would be great
JulianusIV
JulianusIVOPā€¢6mo ago
Alright ill make a tool to transform the data for you then, just one more thing You import levels from mee6 automatically already Do you in any way change the amount of xp a person has there to adjust it to lurkrs leveling progression better? Because the xp gain models of the two bots are quite similar and if you already have a transformation algorithm it would be helpful
Almeida
Almeidaā€¢6mo ago
when we import from mee6 we basically just keep the same level and also calculate the progression the user had towards the next level, and transfer that to our xp
JulianusIV
JulianusIVOPā€¢6mo ago
Oh okay that makes sense yeah, ill look into it when im at my pc in a bit thanks for the speedy answers :D
Almeida
Almeidaā€¢6mo ago
here you go
Almeida
Almeidaā€¢6mo ago
this is what we use to calculate the mee6 levels i can make one following that format for lurkr
Almeida
Almeidaā€¢6mo ago
@JulianusIV ^^
JulianusIV
JulianusIVOPā€¢6mo ago
Ah cool thanks, so i can just take over the level and calculate the percentage to the next level and use that as reference to get xp for lurkr nice Ill make a tool later today for it thanks for the info
Almeida
Almeidaā€¢6mo ago
šŸ‘
JulianusIV
JulianusIVOPā€¢6mo ago
does level 2 actually just take 50xp, or is that an oopsie in this file?
Almeida
Almeidaā€¢6mo ago
yeah... it does.
JulianusIV
JulianusIVOPā€¢6mo ago
hmm interesting
Almeida
Almeidaā€¢6mo ago
indeed it is irreversible mistakes from when the bot was first made šŸ˜¢
JulianusIV
JulianusIVOPā€¢6mo ago
i guess its done originally for nicer total xp values?
Lurkr
Lurkrā€¢6mo ago
:icon_levelup: @JulianusIV has reached level 3
JulianusIV
JulianusIVOPā€¢6mo ago
oh also just curious doing some curve fitting i saw that the total xp for each level is pretty much perfectly described by the function
f(x) = 50xĀ² - 100x + 150
f(x) = 50xĀ² - 100x + 150
is that actually what the bot uses, or does it just go by the list you sent?
Almeida
Almeidaā€¢6mo ago
its pretty similar to that, if not that its actually 100 + 50 * (level - 1) ** 2
JulianusIV
JulianusIVOPā€¢6mo ago
yeah that can almost be rewritten lol id have to do some algebra, but its at the very least really close yep they overlap perfectly in desmos cool is the message count absolutely needed, or can it be omitted? the old bot doesnt supply that metric, and getting it from discord is a bit iffy, since it doesnt exactly expose the search endpoint to bot users also the discriminator can just be 0 for everyone now, no? bots dont get xp anyways
Almeida
Almeidaā€¢6mo ago
you can set it the messageCount to 0 and yeah, the discriminator to "0"
JulianusIV
JulianusIVOPā€¢6mo ago
aigth cool thanks
Lurkr
Lurkrā€¢6mo ago
:icon_levelup: @JulianusIV has reached level 4
JulianusIV
JulianusIVOPā€¢6mo ago
xp here is total xp i assume? so xp needed to get to the current level + current level progress
Almeida
Almeidaā€¢6mo ago
yep. also you can omit level completely thats derived from xp, not actually stored
JulianusIV
JulianusIVOPā€¢6mo ago
sorry for the lot of questions just wanna make sure i dont screw something up here
Almeida
Almeidaā€¢6mo ago
you're fine
JulianusIV
JulianusIVOPā€¢6mo ago
oh alright then i have it easily accessible tho so ill just fill it
Almeida
Almeidaā€¢6mo ago
šŸ‘ not a problem
JulianusIV
JulianusIVOPā€¢6mo ago
is it alright if i dm you the file instead of sending it here publically? @Almeida
Almeida
Almeidaā€¢6mo ago
yep
Lurkr
Lurkrā€¢6mo ago
:icon_levelup: @Almeida has reached level 25
Solution
Almeida
Almeidaā€¢6mo ago
resolved in dms
Want results from more Discord servers?
Add your server