letmesg=awaitmessage.author.send("I'm going to ask you some questions about the anime's info. Just reply with the answer and use good grammar and spelling and be as accurate as possible. To cancel the process, just leave the question unanswered for a few minutes and I'll let you know that the question timed out and is not longer answerable.")
letmesg=awaitmessage.author.send("I'm going to ask you some questions about the anime's info. Just reply with the answer and use good grammar and spelling and be as accurate as possible. To cancel the process, just leave the question unanswered for a few minutes and I'll let you know that the question timed out and is not longer answerable.")
.catch(()=>{returnmessage.reply("Something went wrong there! Most likely, your DMs are closed.");});
.catch(()=>{returnmessage.reply("Something went wrong there! Most likely, your DMs are closed.");});
options.name=awaitask(mesg,"What is the anime's name?",60000,true);if(!options.name){return;}
if(options.name.length>75){clearDM();returndmch.send("The anime name can't be more than 75 characters!");}
options.plot=awaitask(mesg,"How would you describe the anime? Give a very brief description of things like its plot, main characters, and setting.",240000,true);if(!options.plot){returnclearDM();;}
if(options.plot.length>500){clearDM();returndmch.send("Oi! I said give a \"very brief\" description of the anime!");}
options.japname=awaitask(mesg,"What is the anime's japanese name? (The romanization, not the Japanese characters.)",120000,true);if(!options.japname){returnclearDM();}
if(options.japname.length>75){clearDM();returndmch.send("The japanese name can't be more than 75 characters!");}
options.studios=awaitask(mesg,"What studio created the anime? If there are multiple studios, please separate them with a comma.",120000,true);if(!options.studios){returnclearDM();}
if(options.studios.length>150){clearDM();returndmch.send("No way there were actually that many studios...");}
options.studios=options.studios.split(/,\s+/gm);
if(options.studios.length>5){clearDM();returndmch.send("No way there were actually that many studios...");}
options.publishers=awaitask(mesg,"What company published the anime? If there are multiple publishers, please separate them with a comma.",120000,true);if(!options.publishers){returnclearDM();}
if(options.publishers.length>150){clearDM();returndmch.send("No way there were actually that many publishers...");}
if(options.publishers.length>5){clearDM();returndmch.send("No way there were actually that many publishers...");}
options.airStartDate=awaitask(mesg,"When did the anime start?",120000,true);if(!options.airStartDate){returnclearDM();}
options.airEndDate=awaitask(mesg,"When did the anime end?",120000,true);if(!options.airStartDate){returnclearDM();}
options.lastUpdate=awaitask(mesg,"When was the last time a new episode was released for the anime?",120000,true);if(!options.lastUpdate){returnclearDM();}
options.isComplete=awaitask(mesg,"Is the anime completed? (If the most recent season has finished, you may only say \"no\" if the next season is *confirmed* by the *studio or publishers* or the next season is in the works.",60000,true);if(!options.isComplete){returnclearDM();}
if(!['y','yes','ye','n','no'].includes(options.isComplete.trim().toLowerCase())){clearDM();returndmch.send("You must specify yes or no! Please try again.");}
options.seasons=awaitask(mesg,"How many seasons does the anime have?",120000,true);if(!options.seasons){returnclearDM();}
if(isNaN(options.seasons)||Number(options.seasons<1)){clearDM();returndmch.send("You either didn't give a number, or it was < 1.");}
options.seasons=Number(options.seasons);
options.episodes=awaitask(mesg,"How many episodes does the anime have?",120000,true);if(!options.episodes){returnclearDM();}
if(isNaN(options.episodes)||Number(options.episodes<1)){clearDM();returndmch.send("You either didn't give a number, or it was < 1.");}
options.episodes=Number(options.episodes);
options.genres=awaitask(mesg,"What genre(s) describe the anime? If there are multiple genres, please separate them with a comma.",120000,true);if(!options.genres){returnclearDM();}
if(options.genres.length>150){clearDM();returndmch.send("That's too many genres!");}
options.genres=options.genres.split(/,\s+/gm);
if(options.genres.length>7){clearDM();returndmch.send("That's too many genres!");}
options.tags=awaitask(mesg,"What tags describe the anime? Please separate tags with a comma, and *do not put the # in the tag!*.",120000,true);if(!options.tags){returnclearDM();}
if(options.tags.length>200){clearDM();returndmch.send("That's too many tags!");}
options.tags=options.tags.split(/,\s+/gm);
if(options.tags.length>25){clearDM();returndmch.send("That's too many tags!");}
options.streamAt=awaitask(mesg,"What streaming services can you use to watch the anime? If there are multiple stream sites, please separate them with a comma. Please include only legal, licensed industries such as Netflix, Funimation, Crunchyroll, or Hulu. 9anime, cartooncrazy, and similar sites are illegal and won't be listed here.",120000,true);if(!options.streamAt){returnclearDM();}
if(options.streamAt.length>150){clearDM();returndmch.send("No way there are actually that many streaming sites to watch the anime on...");}
if(options.streamAt.length>7){clearDM();returndmch.send("No way there are actually that many streaming sites to watch the anime on...");}
options.thumbnail=awaitask(mesg,"Give me an image **URL** *do not upload the image* to use for the anime",120000,true);if(!options.thumbnail){returnclearDM();}
if(options.thumbnail.length>350){clearDM();returndmch.send("That URL is a bit too long. Consider uploading it to imgur or another image sharing site and trying again.");}
.addField('Length',`**# of Seasons:** ${options.seasons}\n**# of Episodes:** ${options.episodes}`)
.addField('Length',`**# of Seasons:** ${options.seasons}\n**# of Episodes:** ${options.episodes}`)
.addField('Airing',`**Began:** ${options.airStartDate}\n**Ended:** ${options.isComplete?options.airEndDate:'This anime is still airing!'}`)
.addField('Airing',`**Began:** ${options.airStartDate}\n**Ended:** ${options.isComplete?options.airEndDate:'This anime is still airing!'}`)
.addField('Other',`**Genre(s):** ${foptions.genres}\n**Tags:** ${foptions.tags}\n**Characters:** ${foptions.characters}\n**Stream this at:** ${foptions.streamAt}`)
.addField('Other',`**Genre(s):** ${foptions.genres}\n**Tags:** ${foptions.tags}\n**Characters:** ${foptions.characters}\n**Stream this at:** ${foptions.streamAt}`)
.setColor("c375f0")
.setColor("c375f0")
.setImage(options.thumbnail)
.setFooter('Natsuki',client.user.avatarURL())
.setFooter('Natsuki',client.user.avatarURL())
.setTimestamp()
.setTimestamp();
);
try{
am=awaitmessage.channel.send(amEmbed);
awaitam.react('👍');
awaitam.react('👎');
}catch{returnmessage.channel.send(":thinking: hmmm... something went wrong there. I might not have permissions to add reactions to messages, and this could be the issue.");}
returnmessage.author.send(`Your anime has been ${!queue?"added":"submitted"}`);
}else{
returnmessage.author.send("Oh, okay. I'll discard that then!");
}
});
rc.on("end",collected=>{if(!collected.size){returnmessage.author.send("Looks like you ran out of time! Try again?");}});
}catch{returnmessage.channel.send("Hmm... there was some kind of error when I tried to submit that anime. Try again, and if it keeps not working, then go yell at my devs!");}