Quantcast
Channel: RaGEZONE - MMO Development Forums
Viewing all articles
Browse latest Browse all 14581

[Release] Auto-Item v117

$
0
0
An auto item code for lazy people who are lazy, and don't want to add an AIO shop. The items go up to level 100.

PHP Code:

if(GameConstants.isAran(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442000, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442146, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442080, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442150, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442151, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442152, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442133, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442154, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442075, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1442068, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isArcher(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452002, (short)1);
                    
gainItem(1462001, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452001, (short)1);
                    
gainItem(1462003, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452005, (short)1);
                    
gainItem(1462004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452007, (short)1);
                    
gainItem(1462005, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452008, (short)1);
                    
gainItem(1462007, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452011, (short)1);
                    
gainItem(1462008, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452014, (short)1);
                    
gainItem(1462009, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452147, (short)1);
                    
gainItem(1462012, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452134, (short)1);
                    
gainItem(1462018, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1452060, (short)1);
                    
gainItem(1462016, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isBandit(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332063, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332008, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332162, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332011, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332014, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332015, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332018, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332023, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332027, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332052, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isBrawler(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482000, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482002, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482006, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482007, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482008, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482009, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482010, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482011, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1482012, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
            }
        }else if(
GameConstants.isCannon(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532000, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532002, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532006, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532007, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532008, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532009, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532010, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532011, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1532012, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
            }
        }else if(
GameConstants.isDemon(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312078, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312080, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312082, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312084, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312085, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312086, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312087, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312056, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312015, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1312030, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break; 
            }
        }else if(
GameConstants.isDualBlade(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332063, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332008, (short)1);
                    
gainItem(1342000, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332162, (short)1);
                    
gainItem(1342001, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332011, (short)1);
                    
gainItem(1342002, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332014, (short)1);
                    
gainItem(1342003, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332015, (short)1);
                    
gainItem(1342004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332018, (short)1);
                    
gainItem(1342005, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332023, (short)1);
                    
gainItem(1342006, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332027, (short)1);
                    
gainItem(1342007, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1332052, (short)1);
                    
gainItem(1342008, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isEvan(job) || GameConstants.isMage(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382000, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382017, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382120, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382138, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382076, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382053, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382142, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382111, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1382060, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isGunner(job) || GameConstants.isJett(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492000, (short)1);
                    
gainItem(2330000, (short)1);
                    
gainItem(2330000, (short)1);
                    
gainItem(2330000, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492002, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492006, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492007, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492008, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492009, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492010, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492011, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1492012, (short)1);
                    
gainItem(2330004, (short)1);
                    
gainItem(2330004, (short)1);
                    
gainItem(2330004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isMercedes(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522000, (short)1);
                    
gainItem(1352000, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522002, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522006, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522007, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522008, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522009, (short)1);
                    
gainItem(1352002, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522010, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522011, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1522012, (short)1);
                    
gainItem(1352003, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isOneHandedWarrior(job) || GameConstants.isMihile(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302007, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302008, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302020, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302030, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302011, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302012, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302170, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302054, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302023, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1302056, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isPhantom(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362046, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362048, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362050, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362052, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362053, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362054, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362055, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362036, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362012, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1362013, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isSpearman(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432000, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432001, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432002, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432005, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432006, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432007, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432010, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432011, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1432105, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        }else if(
GameConstants.isNightLord(job)){
            switch(
getLevel()){
                case 
10:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472000, (short)1);
                    
gainItem(2070004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
20:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472004, (short)1);
                    
gainItem(2070004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
30:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472008, (short)1);
                    
gainItem(2070004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
40:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472014, (short)1);
                    
gainItem(2070004, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
50:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472018, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
60:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472022, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
70:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472027, (short)1);
                    
gainItem(2070005, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
80:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472031, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
90:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472033, (short)1);
                    
gainItem(2070005, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
                case 
100:
                    
gainItem(5062001, (short)1);//prem miracle cube
                    
gainItem(1472053, (short)1);
                    
gainItem(2070005, (short)1);
                    
dropMessage(5"You have gained a level " getLevel() + " weapon, and a Premium Miracle Cube!");
                    break;
            }
        } 

Just add this into your levelUp() method in MapleCharacter, and make sure it's after the player's level is updated.

Also add this into MapleCharacter.

PHP Code:

public final void gainItemPeriod(final int id, final short quantity, final int period) { //period is in days
        
gainItem(idquantityfalseperiod, -1"");
    }

    public final 
void gainItemPeriod(final int id, final short quantity, final long period, final String owner) { //period is in days
        
gainItem(idquantityfalseperiod, -1owner);
    }

    public final 
void gainItem(final int id, final short quantity) {
        
gainItem(idquantityfalse0, -1"");
    }

    public final 
void gainItemSilent(final int id, final short quantity) {
        
gainItem(idquantityfalse0, -1""getClient(), false);
    }

    public final 
void gainItem(final int id, final short quantity, final boolean randomStats) {
        
gainItem(idquantityrandomStats0, -1"");
    }

    public final 
void gainItem(final int id, final short quantity, final boolean randomStats, final int slots) {
        
gainItem(idquantityrandomStats0slots"");
    }

    public final 
void gainItem(final int id, final short quantity, final long period) {
        
gainItem(idquantityfalseperiod, -1"");
    }

    public final 
void gainItem(final int id, final short quantity, final boolean randomStats, final long period, final int slots) {
        
gainItem(idquantityrandomStatsperiodslots"");
    }

    public final 
void gainItem(final int id, final short quantity, final boolean randomStats, final long period, final int slots, final String owner) {
        
gainItem(idquantityrandomStatsperiodslotsownergetClient());
    }

    public final 
void gainItem(final int id, final short quantity, final boolean randomStats, final long period, final int slots, final String owner, final MapleClient cg) {
        
gainItem(idquantityrandomStatsperiodslotsownercgtrue);
    }
    
    

    public final 
void gainItem(final int id, final short quantity, final boolean randomStats, final long period, final int slots, final String owner, final MapleClient cg, final boolean show) {
        if (
quantity >= 0) {
            final 
MapleItemInformationProvider ii MapleItemInformationProvider.getInstance();
            final 
MapleInventoryType type GameConstants.getInventoryType(id);

            if (!
MapleInventoryManipulator.checkSpace(cgidquantity"")) {
                return;
            }
            if (
type.equals(MapleInventoryType.EQUIP) && !GameConstants.isThrowingStar(id) && !GameConstants.isBullet(id)) {
                final 
Equip item = (Equip) (randomStats ii.randomizeStats((Equipii.getEquipById(id)) : ii.getEquipById(id));
                if (
period 0) {
                    
item.setExpiration(System.currentTimeMillis() + (period 24 60 60 1000));
                }
                if (
slots 0) {
                    
item.setUpgradeSlots((byte) (item.getUpgradeSlots() + slots));
                }
                if (
owner != null) {
                    
item.setOwner(owner);
                }
                
item.setGMLog("Received from interaction " this.id FileoutputUtil.CurrentReadable_Time());
                final 
String name ii.getName(id);
                if (
id 10000 == 114 && name != null && name.length() > 0) { //medal
                    
final String msg "You have attained title <" name ">";
                    
cg.getPlayer().dropMessage(-1msg);
                    
cg.getPlayer().dropMessage(5msg);
                }
                
MapleInventoryManipulator.addbyItem(cgitem.copy());
            } else {
                
MapleInventoryManipulator.addById(cgidquantityowner == null "" ownernullperiod"Received from interaction " this.id FileoutputUtil.CurrentReadable_Date());
            }
        } else {
            
MapleInventoryManipulator.removeById(cgGameConstants.getInventoryType(id), id, -quantitytruefalse);
        }
        if (
show) {
            
cg.getSession().write(InfoPacket.getShowItemGain(idquantitytrue));
        }
    }; 

Also needed in GameConstants:
PHP Code:

public static boolean isArcher(int job){
        return (
job >= 300 && job <= 322) || (job >= 1300 && job <= 1312) || (job >= 3300 && job <= 3312);
    }
    
    public static 
boolean isMage(int job){
        return (
job >= 200 && job <= 232) || (job >= 1200 && job <= 1212) || (job >= 3200 && job <= 3212);
    }
    
    public static 
boolean isNightLord(int job){
        return (
job == 400) || (job >= 410 && job <= 412) || (job >= 1400 && job <= 1412);
    }
    
    public static 
boolean isOneHandedWarrior(int job){
        return (
job >= 100 && job <= 122) || (job >= 1100 && job <= 1112);
    }
    
    public static 
boolean isSpearman(int job){
        return (
job >= 130 && job <= 132);
    }
    
    public static 
boolean isBandit(int job){
        return 
job == 400 || (job >= 420 && job <= 422);
    }
    
    public static 
boolean isGunner(int job){
        return 
job == 500 || (job >= 520 && job <= 522) || (job >= 3500 && job <= 3512);
    }
    
    public static 
boolean isBrawler(int job){
        return 
job == 500 || (job >= 510 && job <= 512) || (job >= 1500 && job <=1512);
    } 

Let me know if I forgot any weapons or jobs. I tend to forget stuff.

Viewing all articles
Browse latest Browse all 14581

Trending Articles