any1 besides me see this?
i dont like itemc and i dont even no if that works so i usevar itemc = Math.floor(Math.random()*Item.length);
Math.random() means random
*item.length means random multiplied by the length of the variable "length"
Math.floor opens for math equations I believe, im not that familiar with that one but it opens the room for math equations as I've seen
Code:var rand = Math.floor(Math.random() * itemset.length);
To all people who think i leeched this... i did NOT leech this. The only thing that was from any other part of code was the
and that was from... ugh i forgot his name... i think its kippieeej. He PMd me and example of array and random item. So i DIDNT leech this. And kippieej (or w/e his name is) didnt give me this exact code. he just taught me array and random!Code:var rand = Math.floor(Math.random() * itemSet.length);
btw see where it says
go ahead and change those codes to watever you want. I placed this in map 0 as a second option to sera. instead of job choice items they get more NX more mesos and 1 of any kind of board except super board. but you can change it around if you want. this should work fine but if it does not post here and ill quickly fix it for you!Code:var itemSet = new Array(itemcode,itemcode,itemcode);
Code:// [Coder]Luke of CLMaplestory Coded this! var itemSet = new Array(1442012,1442013,1442014,1442015,1442016,1442017,1442026,1442027,1442028,1442029,1442030); var rand = Math.floor(Math.random() * itemSet.length); function start() { cm.sendYesNo("Hello! I'ill give you a free item at random! Maybe its some kind of board...Well anyway I will warp you to the next map after your selection, and you cant talk to sera either. I will max your skills and reset your stats too though! So choose wisely!") } function action(mode, type, selection) { if (mode > 0){ cm.warp(1,0); cm.getChar().maxAllSkills(); cm.resetStats(); cm.gainNX(250000); cm.gainMeso(100000000); cm.gainItem(itemSet[rand],1); cm.sendOk("Have fun with your board and enjoy!"); } cm.dispose(); }


Reply With Quote


