Skip to content

{HELP} Buffer .Html Problem!

Featured Replies

Well , I've Made A Buffer With Buff_Templates + Html. ( NO JSCRIPT + No QUESTS )

 

And I Have A Problem. Everything Works Correctly.

 

            BUT

 

When I Press a Buff The .HTML Closes And I Have To Press On The NPC Again To Take Buffs..

 

I Hope You Understand What I Mean.

 

Thanx In Advance.

 

P . S : HELP MEEEEEEEEEEEEEEEEEEEEEEE

The problem is that you have not a script to return ur window back . Look what i mean .

Check this one :

 

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 = "9999_NPCBuffer"

 

NPC=[40006]

ADENA_ID=57

QuestId    = 9999

QuestName  = "NPCBuffer"

QuestDesc  = "custom"

InitialHtml = "1.htm"

 

print "importing custom: 9999: NPCBuffer"

 

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(ADENA_ID)

if count < 150000  or st.getPlayer().getLevel() < 40 :

htmltext = "<html><head><body>You dont have enough Adena,<br> or your level is too low. You must be 40 or higher.</body></html>"

else:

st.takeItems(ADENA_ID,0)

st.getPlayer().setTarget(st.getPlayer())

 

if event == "2":

st.takeItems(ADENA_ID,160000)

st.getPlayer().useMagic(SkillTable.getInstance().getInfo(4360,3),False,False)

st.getPlayer().restoreHPMP()

st.getPlayer().useMagic(SkillTable.getInstance().getInfo(4359,3),False,False)

st.getPlayer().restoreHPMP()

st.getPlayer().useMagic(SkillTable.getInstance().getInfo(4358,3),False,False)

st.getPlayer().restoreHPMP()

st.getPlayer().useMagic(SkillTable.getInstance().getInfo(4357,2),False,False)

st.getPlayer().restoreHPMP()

st.getPlayer().useMagic(SkillTable.getInstance().getInfo(4354,4),False,False)

st.getPlayer().restoreHPMP()

st.getPlayer().useMagic(SkillTable.getInstance().getInfo(4353,6),False,False)

st.getPlayer().restoreHPMP()

st.getPlayer().useMagic(SkillTable.getInstance().getInfo(4350,4),False,False)

st.getPlayer().restoreHPMP()

st.getPlayer().useMagic(SkillTable.getInstance().getInfo(4347,6),False,False)

st.getPlayer().restoreHPMP()

return "4.htm" < ----

st.setState(COMPLETED)

 

==================================================================================================

 

Also i will tell you something to know . Script is something like effect or something like an event .

Hope you understood .

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.