gopvp and leavepvp commands

Results 1 to 11 of 11
  1. #1
    Valued Member harrychong is offline
    MemberRank
    May 2008 Join Date
    128Posts

    gopvp and leavepvp commands

    hello everyone :D this is my 1st release so flame me if u want :x

    okay what these commands warps you to pvp map and warps you back to where you come from o_O but the leavepvp command runs on .js file :S

    okay here are the commands

    gopvp
    In commandprocessor.java or w/e, add:
    Code:
    else if (splitted[0].equals("@pvp")) {
                if (player.getMapId() != pvpmapidhere) {
                player.saveLocation(SavedLocationType.WORLDTOUR);
                MapleMap t = cserv.getMapFactory().getMap(pvpmapidhere);
                MaplePortal tp = t.getPortal(0);
                player.changeMap(t, tp);
                } else {
                    mc.dropMessage("You're already inside the PVP map.");
                }
            }
    dont forget to change the pvpmaphere to your pvp mapid

    leavepvp.js
    paste it into notepad and save as lpvp.js then put inside script/commands folder. if you don't have, don't use it for now 1st.
    Code:
    importPackage(net.sf.odinms.client);
    importPackage(net.sf.odinms.client.messages);
    importPackage(net.sf.odinms.server);
    importPackage(net.sf.odinms.server.maps);
    importPackage(net.sf.odinms.net.channel);
    
    function getDefinition () {
    	var ret = java.lang.reflect.Array.newInstance(CommandDefinition, 1);
    	ret[0] = new CommandDefinition("leavepvp", "", "", "100"); 
    	return ret;
    }
    
    function execute (c, mc, splitted) {
    	var map = c.getPlayer().getSavedLocation(SavedLocationType.WORLDTOUR);
    	var t = c.getPlayer().getClient().getChannelServer().getMapFactory().getMap(map);
    	var tp = t.getPortal(0);
    	c.getPlayer().changeMap(t, tp);
    	c.getPlayer().clearSavedLocation(SavedLocationType.WORLDTOUR);
    	}
    Last edited by harrychong; 22-08-08 at 04:40 PM.


  2. #2
    Account Upgraded | Title Enabled! shadowerr is offline
    MemberRank
    Jul 2008 Join Date
    Somewhere on earthLocation
    448Posts

    Re: [Release] gopvp and leavepvp commands

    hm .. just like that? u didn't even explain clearly like where are the files suppose to be paste and what will happen after u did that

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

    Re: [Release] gopvp and leavepvp commands

    already been released

  4. #4
    Account Upgraded | Title Enabled! DaichiKokujo is offline
    MemberRank
    Jul 2008 Join Date
    I live nowhereLocation
    504Posts

    Re: [Release] gopvp and leavepvp commands

    Hasn't this already been released? Because PCMaple already has it, it wouldn't be that hard to search through folders and find them

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

    Re: [Release] gopvp and leavepvp commands

    i love these ppl who copy n paste ^^

  6. #6
    Λκαяυz føяeνeя Roamer is offline
    MemberRank
    Jun 2008 Join Date
    215Location
    3,203Posts

    Re: [Release] gopvp and leavepvp commands

    Nice release :D

  7. #7
    Account Upgraded | Title Enabled! xXMicrosoftXx is offline
    MemberRank
    Aug 2008 Join Date
    Australia... or am I?Location
    283Posts

    Re: [Release] gopvp and leavepvp commands

    @leavepvp has been released but @gopvp hasn't but, well its not that hard to make a @gopvp

  8. #8
    Infraction Banned nejevoli is offline
    MemberRank
    May 2008 Join Date
    ♥ In Your HeartLocation
    574Posts

    Re: [Release] gopvp and leavepvp commands

    its just more like a copy & paste thing ._.

  9. #9
    Member Neoz is offline
    MemberRank
    Jul 2008 Join Date
    In Yours and Truly Yours DreamLocation
    78Posts

    Re: [Release] gopvp and leavepvp commands

    *Where is The Rip Sign For Leave PVp ?*

    But nice Release For GoPvp for People Who is lazy

  10. #10
    Valued Member harrychong is offline
    MemberRank
    May 2008 Join Date
    128Posts

    Re: [Release] gopvp and leavepvp commands

    omg i didnt noe that leave pvp had already been released ._.
    anyone can link me to that thread?

    EDIT: and my gopvp does
    Code:
    player.saveLocation(SavedLocationType.WORLDTOUR);

  11. #11
    Infraction Banned nejevoli is offline
    MemberRank
    May 2008 Join Date
    ♥ In Your HeartLocation
    574Posts

    Re: [Release] gopvp and leavepvp commands

    mine looks like this
    else if (splitted[0].equals("@gotopvp")) {
    if (player.getMapId() != 100000203) {
    MapleMap target = cserv.getMapFactory().getMap(100000203); //map to warp to
    MaplePortal targetPortal = target.getPortal(0);
    player.changeMap(target, targetPortal);
    } else {
    mc.dropMessage("You're already inside the PVP map.");
    }
    i dont know if its wrong or what, but its working perfectly for me ._.



Advertisement