Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /** @author=Cicco23 */
- /*
- Parameters:
- > q = $(query)
- > u = $(user)
- > ul = $(userlevel)
- > uid = $(userid)
- */
- /*Clear useless spaces*/
- /*a fa il parseInt della stringa q. 10 -> DECIMALE*/
- /*var a = parseInt(""+q,10);*/
- var a;
- a = parseFloat(q);
- function powerup(x){
- var flag = true;
- /* str = "The variable is "+x+" "+str; */
- if(ul=="everyone" && x<5) str = str+"\t You've used: FIRE FIST!๐๐ฅ It's effective! ";
- else if(ul=="owner" || (ul=="moderator" && u=="Jason Urgo")) str=str+"\t You've used: HAKAI!!!!! โก๐ฅ Nightbot has been wrecked.";
- /* Harsh's UserID */
- else if(uid=="UCZiV2lTw3mB1ldjKeqZbC7g" && x<20) str=str+"\t You've used: HARSH'S LIGHTNING SLASH! ๐ก๏ธโก It's super-effective!";
- /* NASA's UserID */
- else if(uid=="UCIcvISfbsNdcRs3QM0onerA" && x<20) str=str+"\t You've used: NASA'S CELESTIAL CANNON! ๐ญ ๐ โก It's super-effective!";
- /* Entropy's UserID */
- else if(uid=="UCHx5_btVT_oroVjmAnoFKJw" && x<20) str=str+"\t You've used: ENTROPY'S PONY WAVE! ๐ด๐ฆ Nightbot has been pushed off the ring!";
- /* Emily Rossiter's UserID */
- else if(( uid=="UCcJSrQEuebixfCG-LddcHjQ" || uid=="UC1QQ2foRoPVsz1wXdWnTIaQ" ) && x<20) str=str+"\t You've used: EMILY COOKIE CHARM! ๐ช๐ Nightbot is confused, and fell off the ring!";
- /* Enigmont's UserID */
- else if(uid=="UCiF_EH32BisyKzdRXMW8lJA" && x<20) str=str+"\t You've used: ENIGMONT'S LIGHTNING FIST! ๐โก It's super-effective! Nightbot fainted.";
- /* Cicco23's UserID */
- else if(uid=="UC_c5POSMvg8myR_kU_w-cZA" && x<20) str=str+"\t You've used command: /push Nightbot (Cicco23 you little cheater! ๐ก)";
- /* gotta edit this ASAP xD */
- else if(ul=="moderator" && u=="adeline") str=str+"\t Nightbot got scared by BOT-TERMINATOR A.D.E.L.I.N.E., and fell off the ring!";
- else if(ul=="moderator" && x<20) str=str+"\t You've used: FINAL FLASH! โกโก It's super-effective!";
- else if(ul=="subscriber" && x<25) str=str+"\t You've used: SB CRAB RAVE! ๐ฆ๐ฆ Nightbot is confused, and fell off the ring!";
- else if(ul=="regular" && x<10) str=str+"\t You've used: ROUNDHOUSE FIRE KICK! ๐ฅ๐ฅ It's super-effective!";
- else flag = false;
- return flag;
- }
- if(isNaN(a)) "@"+u+" -> ERROR!!! \" "+q+" \" is NOT a number. Please choose a number between 0 and 100, next time! ๐ ";
- else if(Math.abs(q)>100) "@"+u+" -> ERROR. "+q+" is not a valid number. Please choose a number between 0 and 100, next time! ๐ ";
- else{
- a = Math.abs(Math.round(a));
- var bound = 20+Math.random()*100;
- bound = Math.ceil(bound);
- if(bound>100) bound=100;
- var nb = Math.random()*bound;
- nb = 1+Math.floor(nb);
- var str = "@"+u+" -> Here is your number: "+a+" , the bound is "+bound+" , and Nightbot choose: "+nb+".";
- if(a>bound) str = str+" YOU LOSE... You fell out from the ring. Better luck next time!! ๐ ";
- else if(a==nb) str = str+" OMG IT'S A DRAW!!!!! ๐ฅ ๐ฅ ";
- else if(a>nb) str = str+" YOU WIN!!! FLAWLESS VICTORY! ๐ ๐ฅ ๐ ";
- else{
- var battle = (nb-a);
- if(powerup(battle)) str = str+"\t YOU WIN!!! ๐ ๐ ";
- else str = str+" YOU LOSE... Better luck next time!! ๐ ";
- }
- if(!(ul=="moderator" ||ul=="owner")) str+" [PLEASE WAIT 20sec BEFORE NEXT ROUND!]";
- else str;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement