Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- a=["has been following","for","days","day"];
- b=["подписан на канал","уже","дней","день"];
- for(i=0;i<a.length;i++){
- t=t.replace(a[i], b[i]);
- }
- if(t.includes('is not following')){
- if(t.split(' ')[0] === '@realdjox'){
- unsub = 'RealDjox здесь дольше всех CoolCat';
- }
- else{
- emotes = ['NotLikeThis', 'PoroSad', 'BibleThump', 'peepoSad'];
- unsub=t.split(' ')[0] + ' не подписан на канал ' + emotes[Math.floor(Math.random() * emotes.length)];
- }
- t=unsub;
- }
- t_split = t.split(' ');
- days = t_split[t_split.length - 2];
- if(days%100 >= 11 && days%100 <= 14){
- t=t.replace('дней','дней');
- }
- else{
- switch(days%10){
- case 1:
- t=t.replace('дней', 'день');
- break;
- case 2:
- case 3:
- case 4:
- t=t.replace('дней','дня');
- break;
- default:
- t=t.replace('дней','дней');
- break;
- }
- }
- if(t.includes('@realdjox уже')){
- t=t.replace('@realdjox', 'RealDjox');
- }
- if (t.toLowerCase().includes('could not find a twitch account')){
- t='Не удалось найти пользователя -> ' + t.split(' ').pop();
- }
- if (t.toLowerCase().includes('could not get users from twitch api')){
- t='Не удалось получить пользователей из Twitch API, имя пользователя недействительно -> ' + t.split(' ').pop();
- }
- if (t.toLowerCase().includes('remote server')){
- t='Ошибка сервера 404: пользователь не найден.';
- }
- if(t.split(' ')[0] === '@lizkasosiska19'){
- t = t + ' [P.S. с 01.11.2020]'
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement