Ir para conteúdo
  • Cadastre-se
  • 0

Drop Quest.


AikoN~

Pergunta

Gostaria de saber em qual linha do Scripts da Quest eu mudo a (%) de drope do Item que o Mob vai dar?? Queria deixar 100%, a cada Mob morto = 1 Drop.

 

Da forma que se encontra, eu preciso matar uns 8/9 Mobs pra cair um.

 

Código:

import sys
from com.l2jfrozen.gameserver.model.quest import State
from com.l2jfrozen.gameserver.model.quest import QuestState
from com.l2jfrozen.gameserver.model.quest.jython import QuestJython as JQuest

qn = "162_CurseOfFortress"

BONE_FRAGMENT3 = 9607
ELF_SKULL = 9613
BONE_SHIELD = 7114

class Quest (JQuest) :

def __init__(self,id,name,descr): JQuest.__init__(self,id,name,descr)

def onEvent (self,event,st) :
htmltext = event
if event == "30147-04.htm" :
st.set("cond","1")
st.setState(STARTED)
st.playSound("ItemSound.quest_accept")
return htmltext

def onTalk (self,npc,player):
htmltext = "<html><body>You are either not carrying out your quest or don't meet the criteria.</body></html>"
st = player.getQuestState(qn)
if not st : return htmltext

npcId
= npc.getNpcId()
id = st.getState()
if id == CREATED :
st.set("cond","0")
if st.getInt("cond") == 0 :
if player.getRace().ordinal() == 2 :
htmltext = "30147-00.htm"
st.exitQuest(1)
elif player.getLevel() >= 80 :
htmltext = "30147-02.htm"
else:
htmltext = "30147-01.htm"
st.exitQuest(0)
else :
if st.getQuestItemsCount(ELF_SKULL) < 1000 and st.getQuestItemsCount(BONE_FRAGMENT3) < 1000 :
htmltext = "30147-05.htm"
else :
htmltext = "30147-06.htm"
st.giveItems(3470,1)
st.giveItems(BONE_SHIELD,2)
st.takeItems(ELF_SKULL,-1)
st.takeItems(BONE_FRAGMENT3,-1)
st.unset("cond")
st.playSound("ItemSound.quest_finish")
return htmltext

def onKill(self,npc,player,isPet):
st = player.getQuestState(qn)
if not st : return
if st.getState() != STARTED : return

if st.getRandom(4) == 1 :
npcId = npc.getNpcId()
bones = st.getQuestItemsCount(BONE_FRAGMENT3)
skulls = st.getQuestItemsCount(ELF_SKULL)
if npcId in [20639,20640,20645] :
if bones < 1000 :
st.giveItems(BONE_FRAGMENT3,1)
if bones == 1000 and skulls == 1000 :
st.playSound("ItemSound.quest_middle")
st.set ("cond","2")
else:
st.playSound("ItemSound.quest_itemget")
elif skulls < 1000 :
st.giveItems(ELF_SKULL,1)
if bones == 1000 and skulls == 1000 :
st.playSound("ItemSound.quest_middle")
st.set ("cond","2")
else:
st.playSound("ItemSound.quest_itemget")
return

QUEST = Quest(162,qn,"Curse Of Fortress")
CREATED = State('Start', QUEST)
STARTED = State('Started', QUEST)

QUEST.setInitialState(CREATED)
QUEST.addStartNpc(30645)

QUEST.addTalkId(30645)

QUEST.addKillId(20639)
QUEST.addKillId(20640)
QUEST.addKillId(20641)
QUEST.addKillId(20642)
QUEST.addKillId(20644)
QUEST.addKillId(20645)

STARTED.addQuestDrop(20639,ELF_SKULL,1)
STARTED.addQuestDrop(20645,BONE_FRAGMENT3,1)

spacer.png

Link para o comentário
Compartilhar em outros sites

3 respostass a esta questão

Posts recomendados


Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Visitante
Responder esta pergunta...

×   Você colou conteúdo com formatação.   Remover formatação

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Processando...
  • Registre-se

    Faça parte da maior e  mais antigas comunidades sobre Lineage2 da América Latina.





×
×
  • Criar Novo...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.