Skip to content

Quest Drop Help

Featured Replies

    public String onKill(L2Npc npc, L2PcInstance player, boolean isPet)
    {
        L2PcInstance partyMember = getRandomPartyMember(player, "1");
        if (partyMember == null)
            return null;
        QuestState st = partyMember.getQuestState(getName());

        if (st == null)
            return null;
                int id = npc.getNpcId();
                int cond = st.getInt("cond");
        switch (cond)
        {
            case 1:
                            if (id == MOB1 && st.getQuestItemsCount(QITEM1) == 0)
                            {
                st.giveItems(QITEM1,1);
                                if (st.getQuestItemsCount(QITEM1) >= 1 && st.getQuestItemsCount(QITEM2) >= 1)
                                {
                                    st.set("cond","2");
                                    st.playSound("ItemSound.quest_middle");
                                }


Is this possibly  to give into whole party? dont mind about }{ 

Check 246 Quest

			for (L2PcInstance plr : getPartyMembers(player, npc, "cond", "4"))
			{
				if (!plr.isSubClassActive())
					continue;
				
				QuestState st = plr.getQuestState(qn);
				if (!st.hasQuestItems(RAIN_SONG))
				{
					st.set("cond", "5");
					st.playSound(QuestState.SOUND_MIDDLE);
					st.giveItems(RAIN_SONG, 1);
				}
			}

He copied part of the nobless quest when you kill barakiel.

 

You can delete the subclass check, since you don't need that.

 

 

for (L2PcInstance plr : getPartyMembers(player, npc, "cond", "4"))  this is what you should implent in your quest instead of 2PcInstance partyMember = getRandomPartyMember(player, "1");

 

or         for (L2PcInstance member : player.getParty().getMembers())

 

not sure if this works in IL tho.
 

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.