torsello Posted September 3, 2015 Posted September 3, 2015 Someone can help me to do an html for this code? Its an NOBLESS NPC script 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.actor.appearance import PcAppearance from net.sf.l2j.gameserver.model.quest import State from net.sf.l2j.gameserver.model.actor.appearance import PcAppearance from net.sf.l2j.gameserver.model.quest import QuestState from net.sf.l2j.gameserver.model.quest.jython import QuestJython as JQuest qn = "8204_NpcNoblesse" NPC=[100009] GOLDBAR= 3470 NOBLESS_TIARA = 7694 QuestId = 8204 QuestName = "NpcNoblesse" QuestDesc = "custom" InitialHtml = "1.htm" print "INFO Loaded: Noblesse Manager" 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(GOLDBAR) if count < 250 and st.getPlayer().getLevel() < 75 : htmltext = "<html><head><body>Sorry, but you dont have enought gb or u low lvl</body></html>" elif st.getPlayer().isNoble() == 1 : htmltext = "<html><head><body>Sorry, But you are alrdy nobles</body></html>" else: st.getPlayer().setTarget(st.getPlayer()) if event == "2": st.takeItems(GOLDBAR,250) st.getPlayer().setNoble(true) st.giveItems(NOBLESS_TIARA,1) st.playSound("ItemSound.quest_finish") st.setState(State.COMPLETED) return "End.htm" st.exitQuest(1) if htmltext != event: st.setState(State.COMPLETED) st.exitQuest(1) return htmltext def onTalk (self,npc,player): st = player.getQuestState(qn) htmltext = "<html><head><body>I have nothing to say to you</body></html>" st.setState(State.STARTED) return InitialHtml QUEST = Quest(QuestId,str(QuestId) + "_" + QuestName,QuestDesc) for npcId in NPC: QUEST.addStartNpc(npcId) QUEST.addTalkId(npcId) Thanks, sorry for my bad english, and i dont know how to create an htm, for the npc 100009 . Quote
0 Rootware Posted September 3, 2015 Posted September 3, 2015 NPC's count have limit in 65535. Use 50009 ID. Quote
0 torsello Posted September 3, 2015 Author Posted September 3, 2015 Thanks, i change the npc id, but now i think that i have to do a html called 1.htm ?, and i dont know what put on 1.html Quote
0 SweeTs Posted September 4, 2015 Posted September 4, 2015 (edited) Copy and htm from htm folder, paste inside your custom folder and rename it to 1 then change the content. Edited September 4, 2015 by SweeTs Quote
0 torsello Posted September 4, 2015 Author Posted September 4, 2015 I've do it , but, someone saids to me that is not declared initial state, and that onTalk method is wrong, have you any idea? . Its l2j C4 Quote
Question
torsello
Someone can help me to do an html for this code? Its an NOBLESS NPC script
Thanks, sorry for my bad english, and i dont know how to create an htm, for the npc 100009 .
4 answers to this question
Recommended Posts
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.