Occupation Leveling + EXP System

Page 1 of 3 123 LastLast
Results 1 to 15 of 31
  1. #1
    Ooo, shiny! FateJiki is offline
    True MemberRank
    Feb 2008 Join Date
    1,064Posts

    Occupation Leveling + EXP System


    RaGEZONE Recommends

    RaGEZONE Recommends

    Well , I've decided to release my Occupation Leveling + EXP System.

    It's pretty simple. Here it is :

    MapleCharacter.java

    Required Variables in Maplecharacter.java (Figure it out)
    PHP Code:
        public int OccupationLevel;
        public 
    int OccupationExp
    Required Methods : (MapleCharacter.java !)
    PHP Code:
    public int getOccEXP(){
            return 
    this.OccupationExp
    PHP Code:
    public void setOccLevel(int x){
            
    this.OccupationLevel x;
        } 
    PHP Code:
    public void OccupationLevelUp(){
            
    getMap().broadcastMessage(getClient().getPlayer(), MaplePacketCreator.showSpecialEffect(8), false);
            
    getClient().getSession().write(MaplePacketCreator.showSpecialEffect(8));
                    if(
    this.getOccupationLevel() >= 125 && this.hasSecondOccupation() == false){
                
    scripting.npc.NPCScriptManager npc scripting.npc.NPCScriptManager.getInstance();
                
    npc.start(getClient(), 9201**** nullthis);
            }
            
    this.OccupationLevel++;
            
    this.OccupationExp 0;
            
    this.maxhp += 50;
            
    this.maxmp += 50;
            
    this.updateSingleStat(MapleStat.MAXHPmaxhp);
            
    this.updateSingleStat(MapleStat.MAXMPmaxmp);
            
    getClient().getSession().write(MaplePacketCreator.serverNotice(5"Your occupation has leveled up! You are now a Lv." this.getOccupationLevel() + " " this.getOccupation()));

        } 
    PHP Code:
    public int getOccupationLevel(){
            return 
    this.OccupationLevel;
        } 
    PHP Code:
    public void gainOccEXP(int amount){
            
    int totoexp this.OccupationExp amount;
            if(
    totoexp >= getOccupationExpNeeded() && this.getOccupationLevel() < 150){
                
    OccupationLevelUp();
            }
            else {
                
    OccupationExp += amount;
            } 
    PHP Code:
    public int getOccupationExpNeeded(){
            return 
    ExpTable.getExpNeededForLevel(getOccupationLevel()) / 3;

        } 
    MapleMonster.java

    Under
    Code:
    public void giveExpToCharacter(MapleCharacter attacker, int exp, boolean highestDamage, int numExpSharers) {
    put :
    PHP Code:
    if(attacker.getOccupationId() != && attacker.getOccupationLevel() < 150){
                
    int OccEXP exp 12;
                if(
    attacker.getParty() != null){
                    
    attacker.gainOccEXP(OccEXP attacker.getParty().getMembers().size());
                }
                else {
                    
    attacker.gainOccEXP(exp);
                } 
    If you want it to save to the DB, do that yourself, too lazy to finish the tutorial on that.

    Conclusion :
    Feel free to modify this code and/or use it on your server and even leech it to other forums, but ALWAYS remember to give the proper credits, (LxShutdown/FateJiki of RaGeZONE/KryptoDEV !) Never claim this as your own.

    There are not many open-source developers or releases, because people tend to leech. I'm happy to code features and release them, as long as you guys don't claim them as your own.


    Thank you , and if I forgot something, just tell me. I made this tutorial in under 10 minutes.

    Instead of posting "thanks" , please just click the thanks button. :)
    Last edited by FateJiki; 25-04-10 at 05:01 PM.


  2. #2
    Account Inactive Cappe is offline
    InactiveRank
    Aug 2008 Join Date
    330Posts

    Re: [Release] Occupation Leveling + EXP System

    Thanks man! =)

    *Edit* I think you missed
    getOccupationId
    and hasSecondOccupation
    Last edited by Cappe; 25-04-10 at 05:21 PM.

  3. #3
    Account Upgraded | Title Enabled! .:LastBreath:. is offline
    True MemberRank
    Oct 2009 Join Date
    Under your bedLocation
    1,314Posts

    Re: [Release] Occupation Leveling + EXP System

    Nice release, useful to high rate servers.

  4. #4
    Ooo, shiny! FateJiki is offline
    True MemberRank
    Feb 2008 Join Date
    1,064Posts

    Re: [Release] Occupation Leveling + EXP System

    Quote Originally Posted by Cappe View Post
    Thanks man! =)

    *Edit* I think you missed
    getOccupationId
    and hasSecondOccupation
    Just modify it to suit your needs. As there are some methods I didn't include.

  5. #5
    Account Inactive Lordz95 is offline
    InactiveRank
    Apr 2010 Join Date
    SingaporeLocation
    21Posts

    Re: [Release] Occupation Leveling + EXP System

    awesome release. You deserve a 'thanks'!!

  6. #6
    Account Upgraded | Title Enabled! .:LastBreath:. is offline
    True MemberRank
    Oct 2009 Join Date
    Under your bedLocation
    1,314Posts

    Re: [Release] Occupation Leveling + EXP System

    For some noobs it won't be that friendly, because they wont know how to add those functions, and then they well complain.

  7. #7
    Ooo, shiny! FateJiki is offline
    True MemberRank
    Feb 2008 Join Date
    1,064Posts

    Re: [Release] Occupation Leveling + EXP System

    Quote Originally Posted by .:LastBreath:. View Post
    For some noobs it won't be that friendly, because they wont know how to add those functions, and then they well complain.
    I never meant it to be noob-friendly. Implementing this is very simple and if a "coder" or a server-owner can't figure this out, they should learn.

  8. #8
    Hardcore Member NightMareJoker is offline
    MemberRank
    Apr 2010 Join Date
    115Posts

    Re: [Release] Occupation Leveling + EXP System

    Awsome

  9. #9
    Account Inactive iAndy is offline
    InactiveRank
    Nov 2009 Join Date
    474Posts

    Re: [Release] Occupation Leveling + EXP System

    grt rls mang so prao.

    Jk, nice release Julien. Keep at what you do. ;)

  10. #10
    Account Inactive dman765 is offline
    InactiveRank
    Oct 2008 Join Date
    Canada, OntarioLocation
    367Posts

    Re: [Release] Occupation Leveling + EXP System

    ill keep using ur stuff LOL Although u still gotta give me ur repack :P(Deal for his Repack)
    Last edited by dman765; 25-04-10 at 06:52 PM.

  11. #11
    may web.very maple.pls. iAkira is offline
    Alpha MaleRank
    Aug 2009 Join Date
    somewhere..Location
    2,383Posts

    Re: [Release] Occupation Leveling + EXP System

    Quick question u need to add to savetodb and loadfromdb right?

  12. #12
    Account Inactive xMike1x is offline
    InactiveRank
    Dec 2009 Join Date
    TorontoLocation
    577Posts

    Re: [Release] Occupation Leveling + EXP System

    Quote Originally Posted by iAkira View Post
    Quick question u need to add to savetodb and loadfromdb right?
    yes u do.

    ontopic

    great release.
    Sig Removed

  13. #13
    may web.very maple.pls. iAkira is offline
    Alpha MaleRank
    Aug 2009 Join Date
    somewhere..Location
    2,383Posts

    Re: [Release] Occupation Leveling + EXP System

    kk thanks,
    i will test this
    great release <3

  14. #14
    Account Inactive dman765 is offline
    InactiveRank
    Oct 2008 Join Date
    Canada, OntarioLocation
    367Posts

    Re: [Release] Occupation Leveling + EXP System

    Lol ill be sure to use this i think.

  15. #15
    Account Upgraded | Title Enabled! .:LastBreath:. is offline
    True MemberRank
    Oct 2009 Join Date
    Under your bedLocation
    1,314Posts

    Re: [Release] Occupation Leveling + EXP System

    This shit was All I knew you and me only.
    LOL Good release :D




Page 1 of 3 123 LastLast

Advertisement