[NPC] Jukebox NPC

Page 1 of 2 12 LastLast
Results 1 to 15 of 17
  1. #1
    Proficient Member khoacalacan is offline
    MemberRank
    Jan 2007 Join Date
    164Posts

    [NPC] Jukebox NPC

    If you want to listen to your favorite maplestory songs, now you can at the jukebox.

    In your NPCConversationManager.java add:
    Code:
    public void musicChange(String songName) {
                getPlayer().getMap().broadcastMessage(MaplePacketCreator.musicChange(songName));
            }
    And in an npc you want to have the jukebox, add:
    Code:
    /*
        Jukebox NPC
    
        Made by Calan from xDreamerMS
         
    */
    var status = 0;
    var price = 1000000;
    var music = Array("Bgm00/SleepyWood", "Bgm00/FloralLife", "Bgm00/GoPicnic", "Bgm00/Nightmare", "Bgm00/RestNPeace",
    "Bgm01/AncientMove", "Bgm01/MoonlightShadow", "Bgm01/WhereTheBarlogFrom", "Bgm01/CavaBien", "Bgm01/HighlandStar", "Bgm01/BadGuys",
    "Bgm02/MissingYou", "Bgm02/WhenTheMorningComes", "Bgm02/EvilEyes", "Bgm02/JungleBook", "Bgm02/AboveTheTreetops",
    "Bgm03/Subway", "Bgm03/Elfwood", "Bgm03/BlueSky", "Bgm03/Beachway", "Bgm03/SnowyVillage",
    "Bgm04/PlayWithMe", "Bgm04/WhiteChristmas", "Bgm04/UponTheSky", "Bgm04/ArabPirate", "Bgm04/Shinin'Harbor", "Bgm04/WarmRegard",
    "Bgm05/WolfWood", "Bgm05/DownToTheCave", "Bgm05/AbandonedMine", "Bgm05/MineQuest", "Bgm05/HellGate",
    "Bgm06/FinalFight", "Bgm06/WelcomeToTheHell", "Bgm06/ComeWithMe", "Bgm06/FlyingInABlueDream", "Bgm06/FantasticThinking",
    "Bgm07/WaltzForWork", "Bgm07/WhereverYouAre", "Bgm07/FunnyTimeMaker", "Bgm07/HighEnough", "Bgm07/Fantasia",
    "Bgm08/LetsMarch", "Bgm08/ForTheGlory", "Bgm08/FindingForest", "Bgm08/LetsHuntAliens", "Bgm08/PlotOfPixie",
    "Bgm09/DarkShadow", "Bgm09/TheyMenacingYou", "Bgm09/FairyTale", "Bgm09/FairyTalediffvers", "Bgm09/TimeAttack",
    "Bgm10/Timeless", "Bgm10/TimelessB", "Bgm10/BizarreTales", "Bgm10/TheWayGrotesque", "Bgm10/Eregos",
    "Bgm11/BlueWorld", "Bgm11/Aquarium", "Bgm11/ShiningSea", "Bgm11/DownTown", "Bgm11/DarkMountain",
    "Bgm12/AquaCave", "Bgm12/DeepSee", "Bgm12/WaterWay", "Bgm12/AcientRemain", "Bgm12/RuinCastle", "Bgm12/Dispute",
    "Bgm13/CokeTown", "Bgm13/Leafre", "Bgm13/Minar'sDream", "Bgm13/AcientForest", "Bgm13/TowerOfGoddess",
    "Bgm14/DragonLoad", "Bgm14/HonTale", "Bgm14/CaveOfHontale", "Bgm14/DragonNest", "Bgm14/Ariant", "Bgm14/HotDesert",
    "Bgm15/MureungHill", "Bgm15/MureungForest", "Bgm15/WhiteHerb", "Bgm15/Pirate", "Bgm15/SunsetDesert",
    "BgmEvent/FunnyRabbit", "BgmEvent/FunnyRabbitFaster",
    "BgmGL/amoria", "BgmGL/chapel", "BgmGL/cathedral", "BgmGL/Amorianchallenge",
    "BgmJp/Feeling", "BgmJp/BizarreForest", "BgmJp/Hana", "BgmJp/Yume", "BgmJp/Bathroom", "BgmJp/BattleField", "BgmJp/FirstStepMaster");
    
    function start() {
        status = -1;
        action(1, 0, 0);
    }
    
    function action(mode, type, selection) {
        if (mode == -1) {
            cm.dispose();
        } else {
            if (status >= 2 && mode == 0) {
                cm.sendOk("You're done now, go away.");
                cm.dispose();
                return;
            }
            if (mode == 1)
                status++;
            else
                status--;
            if (status == 0) {
                var jukebox = "#b#eJukebox#k#n";
                jukebox += "\r\nListen to your favorite MapleStory songs for only "+price+" mesos\r\n";
                for (var i = 0; i < music.length; i++) {
                    jukebox += "\r\n#L" + i + "# " +music[i]+ "#l";
                }
                cm.sendSimple(jukebox);
            } else if (status == 1) {
                if (selection >= 0) {
                    cm.sendYesNo("Do you want change the music to "+music[selection]+" for the cost of "+price+" mesos?");
                    mc = selection;
                } else {
                    cm.sendOk("WTF there's no info on this item, report this to the forums!");
                    cm.dispose();
                }
            } else if (status == 2) {
                if (cm.getMeso() > price) {
                    cm.gainMeso(-price);
                    cm.musicChange(music[mc]);
                    cm.dispose();
                } else {
                    cm.sendOk("You don't have enough mesos!");
                    cm.dispose();
                }        
            } else {
                cm.dispose();
            }
        }
    }


  2. #2
    Valued Member candyman1111 is offline
    MemberRank
    Aug 2008 Join Date
    142Posts

    Re: [Release] Jukebox NPC

    already been released ^^

  3. #3
    Proficient Member khoacalacan is offline
    MemberRank
    Jan 2007 Join Date
    164Posts

    Re: [Release] Jukebox NPC

    Mine's more organized o.o

  4. #4
    Alpha Member Gmanpopinjay is offline
    MemberRank
    Dec 2007 Join Date
    1,588Posts

    Re: [Release] Jukebox NPC

    Thx For Release Mate Ill Add To My Server =)

  5. #5
    Account Upgraded | Title Enabled! xkush is offline
    MemberRank
    May 2008 Join Date
    New yorkLocation
    498Posts

    Re: [Release] Jukebox NPC

    is there any way this can make the music change for like, if a character changes the music, it goes along with them as they move maps? and another can it change the music for the whole channel or serveR? D:

  6. #6
    mikethemak is offline
    MemberRank
    Apr 2008 Join Date
    Ragezone Spam SectionLocation
    1,019Posts

    Re: [Release] Jukebox NPC

    Do these really get a lot of use? This isnt flame or anything, its a serious question. Ive never had 1 in my serv...just kinda wondering o.O

  7. #7
    Valued Member candyman1111 is offline
    MemberRank
    Aug 2008 Join Date
    142Posts

    Re: [Release] Jukebox NPC

    no1 i just use !music

  8. #8
    Account Upgraded | Title Enabled! EspadaFung is offline
    MemberRank
    Jul 2008 Join Date
    Home, don't stalk meLocation
    1,030Posts

    Re: [Release] Jukebox NPC

    hmm, i saw the chatbox, there's a tip..
    how u add it in huh? o.o

  9. #9
    You've got my respect! Traitor is offline
    MemberRank
    Apr 2008 Join Date
    Portland,OregonLocation
    959Posts

    Re: [Release] Jukebox NPC

    I do have a slightly better version, but this is almost exactly like it.
    Cool work (Arrays are awesome)

  10. #10
    Alpha Member Gmanpopinjay is offline
    MemberRank
    Dec 2007 Join Date
    1,588Posts

    Re: [Release] Jukebox NPC

    i just like coke town music lol

  11. #11
    RaGEZONE = FLaMEZONE thisisakevin is offline
    MemberRank
    Jul 2008 Join Date
    284Posts

    Re: [Release] Jukebox NPC

    this is really old... o.o

  12. #12
    Alpha Member Gmanpopinjay is offline
    MemberRank
    Dec 2007 Join Date
    1,588Posts

    Re: [Release] Jukebox NPC

    eh some people might need it? and like he said he added more music

  13. #13
    Apprentice Element0 is offline
    MemberRank
    Aug 2008 Join Date
    19Posts

    Re: [Release] Jukebox NPC

    not exactly sure, but it think u missed some.
    "BgmUI/ShopBgm"
    "BgmUI/Title"
    "BgmUI/WCSelect"
    "BgmGL/NLCtown"
    "BgmGL/NLChunt"
    "BgmGL/NLCupbeat"
    "BgmGL/HauntedHouse"

  14. #14
    Account Upgraded | Title Enabled! Jasd123 is offline
    MemberRank
    May 2008 Join Date
    Behind You.Location
    1,179Posts

    Re: [Release] Jukebox NPC

    already been released like twice :p

  15. #15
    Account Upgraded | Title Enabled! BlessTheKnife is offline
    MemberRank
    Sep 2009 Join Date
    554Posts

    Re: Jukebox NPC

    zzzz. It changed all the players in the same map's music too O_O



Page 1 of 2 12 LastLast

Advertisement