Jump to content

[interlude] Npc Vip


Walef Oliveira

Recommended Posts

Galera estou desinvolvendo 1 Teleport Vip Ja arrumei a area Vip , O Npc Teleport Agora So falta por o teleport para cobrar 1 certo item Vip ou teleportar por accs lvl se alguem quiser me ajuduar a desenvolver esse Npc mande 1 MP pq vai servir para varios membros pq tem varios membros atraz dico Grato.

Em Breve L2 BlackWidow Ultimate

Link to comment
Share on other sites


# ####################

# Created by KhayrusS #

# ####################

import sys

from net.sf.l2j.gameserver.model.actor.instance import L2PcInstance

from java.util import Iterator

from net.sf.l2j.gameserver.datatables import SkillTable

from net.sf.l2j import L2DatabaseFactory

from net.sf.l2j.gameserver.model.quest import State

from net.sf.l2j.gameserver.model.quest import QuestState

from net.sf.l2j.gameserver.model.quest.jython import QuestJython as JQuest

 

qn = "9998_KhayraTeleport"

 

KHAYRA=[55400]

ANCIENT_GOLD=9999

QuestId = 9998

QuestName = "KhayraTeleport"

QuestDesc = "custom"

InitialHtml = "1.htm"

 

print "importing custom: 9998: KhayraTeleport"

 

class Quest (JQuest) :

 

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

 

 

def onEvent(self,event,st):

htmltext = event

count=st.getQuestItemsCount(ANCIENT_GOLD)

if count < 0 :

htmltext = "<html><head><body>Voce Nao tem Ancient Gold suficiente, volte quando tive<br>Obrigada Volte Sempre<br></body></html>"

else:

st.takeItems(ANCIENT_GOLD,0)

st.getPlayer()

 

if event == "1" and count >= 10:

st.takeItems(ANCIENT_GOLD,10)

st.getPlayer().teleToLocation(48000,243376,-6611)

st.setState(COMPLETED)

 

 

if htmltext != event:

st.setState(COMPLETED)

st.exitQuest(1)

return htmltext

 

 

def onTalk (self,npc,player):

st = player.getQuestState(qn)

htmltext = "<html><head><body>Eu nao tenho nada para dizer para voce</body></html>"

st.setState(STARTED)

return InitialHtml

 

QUEST=Quest(QuestId,str(QuestId) + "_" + QuestName,QuestDesc)

CREATED=State('Start',QUEST)

STARTED=State('Started',QUEST)

COMPLETED=State('Completed',QUEST)

 

QUEST.setInitialState(CREATED)

 

for npcId in KHAYRA:

QUEST.addStartNpc(npcId)

QUEST.addTalkId(npcId)

 

Esse eu fiz para interlude mas acho que dá pra ser modificado e usado para Gracia tbm

 

A parte essencial do Script é essa

 

st.getPlayer().teleToLocation(48000,243376,-6611)

 

onde vc poderá adicionar qualquer outro lugar lembrando que é usado as coordenadas como x,y,z

 

Mas acho que para vc editar isso tenha que conhecer pelo menos um pouco do "Script"

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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.

Loading...
  • Join now

    Be part of the largest and oldest communities about Lineage2 in Latin America.





×
×
  • Create New...

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.