Jump to content
  • 0

Scheme Buffer problem[SOLVED]


Question

Posted

Hi all, I have a server with about 200 players online, when registering in Olympiads await the last second and click in the buff button and enter the buffer scheme fullbuff in Olympiads, is that this problem has been answered in some posts but I've tried everything and nothing works I'm sure it's because those posts are from previous versions to my server, I use l2j high five and it fetches buffer scheme by no retouched to high five, not much but trying and testing codes I get only atribute error here is my code in Python:

 

here the imports:

import sys
from java.lang import System
from java.util import Iterator
from com.l2jserver import Config
from com.l2jserver.gameserver.model.quest import State
from com.l2jserver.gameserver.model.quest import QuestState
from com.l2jserver.gameserver.model.quest.jython import QuestJython as JQuest
from com.l2jserver.gameserver.instancemanager import QuestManager
from com.l2jserver import L2DatabaseFactory
from com.l2jserver.gameserver.datatables import SkillTable
from com.l2jserver.gameserver.datatables import ItemTable
from com.l2jserver.gameserver.model.actor.instance import L2PcInstance
from com.l2jserver.gameserver.model.actor.instance import L2PetInstance
from com.l2jserver.gameserver.model.actor.instance import L2SummonInstance
from com.l2jserver.gameserver.network.serverpackets import SetSummonRemainTime
from com.l2jserver.gameserver.network.serverpackets import SetupGauge
from com.l2jserver.gameserver.model.olympiad import Olympiad

this line:

from com.l2jserver.gameserver.model.olympiad import Olympiad

 

and here the part of the code i modified:

 

def onFirstTalk (self,npc,player):

st = player.getQuestState(QUEST_LOADING_INFO)

              isInOly = st.getPlayer().InOlympiadMode()

if not st : st = self.newQuestState(player)

if player.isGM():

if SCRIPT_RELOAD == True: return reloadPanel(st)

else: return rebuildMainHtml(st)

                elif isInOly == True:

                        return showText(st,"info","You can't use the scheme buffer while you're registered for the Olympiad Games!","False","Return","main")

elif int(System.currentTimeMillis()/1000) > st.getInt("blockUntilTime"):

 

if ENABLE_VIP_BUFFER == False or player.getAccessLevel().getLevel() == VIP_ACCESS_LEVEL and ENABLE_VIP_BUFFER == True:

 

if BUFF_WITH_KARMA == False and player.getKarma() > 0 :

return showText(st,"Info","You have too much <font color=\"FF0000\">karma!</font><br>Come back,<br>when you don't have any karma!","False","Return","main")

 

elif st.player.getLevel() < MIN_LEVEL :

return showText(st,"Info","Your level is too low!<br>You have to be at least level <font color\"LEVEL\">"+str(MIN_LEVEL)+"</font>,<br>to use my services!","False","Return","main")

 

 

elif st.player.isInCombat() :

return showText(st,"Info","You can't buff while you are attacking!<br>Stop your fight and try again!","False","Return","main")

 

else: return rebuildMainHtml(st)

 

else: return showText(st,"Sorry","This buffer is only for VIP's!<br>Contact the administrator for more info!","False","Return","main")

  else: return showText(st,"Sorry","You have to wait a while!<br>if you wish to use my services!","False","Return","main")

 

always get the same error atribute here the image:

http://imageshack.us/photo/my-images/705/failku.png/

failku.png

 

 

 

i test this code and nothing..

elif OlympiadManager.getInstance().isRegistered(player):
return showText(st,"info","You can't use the scheme buffer while you're registered for the Olympiad Games!","False","Return","main")

atribute error: isRegistered

 

I would appreciate any help, and yes i used google translator, thanks in advance.

9 answers to this question

Recommended Posts

  • 0
Posted

delete this

from com.l2jserver.gameserver.model.olympiad import Olympiad

and this:

elif isInOly == True:

                        return showText(st,"info","You can't use the scheme buffer while you're registered for the Olympiad Games!","False","Return","main")

 

And change this:

st = player.getQuestState(QUEST_LOADING_INFO)

                isInOly = st.getPlayer().InOlympiadMode()

 

with

st = player.getQuestState(QUEST_LOADING_INFO)
if st.getPlayer.InOlympiadMode() :
(Use Tab here)return showText(st,"info","You can't use the scheme buffer while you're registered for the Olympiad Games!","False","Return","main")

 

  • 0
Posted

here is the code changed and i deleted the import line ok but im still having problem with atribute error: getplayer

 

	def onFirstTalk (self,npc,player):
	st = player.getQuestState(QUEST_LOADING_INFO)
                if st.getPlayer.InOlympiadMode() :
		return showText(st,"info","You can't use the scheme buffer while you're registered for the Olympiad Games!","False","Return","main")
	if not st : st = self.newQuestState(player)
	if player.isGM(): 
		if SCRIPT_RELOAD == True: return reloadPanel(st)
		else: return rebuildMainHtml(st)
	elif int(System.currentTimeMillis()/1000) > st.getInt("blockUntilTime"):

		if ENABLE_VIP_BUFFER == False or player.getAccessLevel().getLevel() == VIP_ACCESS_LEVEL and ENABLE_VIP_BUFFER == True:

			if BUFF_WITH_KARMA == False and player.getKarma() > 0 :
				return showText(st,"Info","You have too much <font color=\"FF0000\">karma!</font><br>Come back,<br>when you don't have any karma!","False","Return","main")

			elif st.player.getLevel() < MIN_LEVEL :
				return showText(st,"Info","Your level is too low!<br>You have to be at least level <font color\"LEVEL\">"+str(MIN_LEVEL)+"</font>,<br>to use my services!","False","Return","main")


			elif st.player.isInCombat() :
				return showText(st,"Info","You can't buff while you are attacking!<br>Stop your fight and try again!","False","Return","main")

			else: return rebuildMainHtml(st)

 

look here the picture:

http://imageshack.us/a/img201/6243/fail2oc.png

fail2oc.png

 

 

thanks for taking your time answering ,greetings.

  • 0
Posted

here is the code changed and i deleted the import line ok but im still having problem with atribute error: getplayer

Lawl I forgot the ()

getPlayer()

  • 0
Posted

still having the same atribute error: 'getplayer' using this:

		st = player.getQuestState(QUEST_LOADING_INFO)
                if st.getPlayer().InOlympiadMode() :
		return showText(st,"info","You can't use the scheme buffer while you're registered for the Olympiad Games!","False","Return","main")

 

i dont know why, the scheme buffer have this atribute st.getplayer() in other part above of the script and it works fine,thanks in advance.

  • 0
Posted

yes this work    if player.InOlympiadMode() :    but now appear atribute error: 'InOlympiadMode' and i have the import for l2pcinstance ,this error will haunt me to death XD thanks .

  • 0
Posted

i found the problem in other website ,now is working i go post for other people

 

this is the change:

 

the import i add from com.l2jserver.gameserver.model.olympiad import OlympiadManager

 

and the restriction is

  if OlympiadManager.getInstance().isRegisteredInComp(player) :

return showText(st,"Info","You are in <font color=\"FF0000\">Olympiad!</font><br>Come back,<br>when you are out of Olympiad!","False","Return","main")

 

when you join olys and go to the buffer show this:

 

http://imageshack.us/a/img401/345/solvedx.png

solvedx.png

 

thanks for your help and interest, a greeting.

Guest
This topic is now closed to further replies.


  • Posts

    • Dark mode should be on by default instead. Please fix the flickering on refresh.
    • Hello, We’re preparing to launch something new on L2network.eu… ⚠️   A premium SponsorAuction system is coming soon — introducing a new way to gain maximum visibility on the platform.     👉 Important: Your standard fixed sponsor spots are NOT going anywhere. They will remain available as always.   🔥 So what’s new? We’re adding a limited auction-based premium spot that will stand above everything else. This special placement will: Appear above all servers in the toplist Be visible on every page of the platform Deliver the highest possible exposure   💥 And here’s the catch: Only a very limited number of these premium spots will exist Access will be decided through competitive bidding This means: 👉 The most visible position on L2Network will no longer be bought — it will be won. ⏳ The first auction is opening soon. Early bidders will have the advantage. Get ready — because once it starts, competition will be intense. ------------------------------------------------------------------------------------ We've spent the last week rebuilding how your server pages work behind the scenes. Every server listed on L2Network now has a smarter, more discoverable detail page — and it's already pulling in better Google rankings. Here's what's new and how it helps you get more votes and players. ⭐ Star Ratings in Google Search Your server page now tells Google exactly how players have rated you. When someone searches for your server (or related Lineage 2 keywords), Google can now display golden stars next to your listing in the search results. REAL Stats- Live stats 📖 Auto-Generated Server Summary At the top of every detail page, there's now a clean intro paragraph describing your server in plain language — chronicle, rates, age, rating, and a call-to-action. It's built automatically from your existing server data, so you don't have to write anything. Players landing on your page see what your server is about within 2 seconds, instead of having to dig through tables.   ❓ FAQ Section on Every Page Every server page now has a Frequently Asked Questions block answering things like: What chronicle is this server? What are the rates? Is it L2OFF or L2J? When did it launch? How is it rated by players? These are auto-generated from your server settings — no work for you. Bonus: Google sometimes shows these directly in search results as expandable answers, giving you even more screen space in SERPs.   📈 What You Can Expect Over the next 2-4 weeks as Google re-crawls every detail page: What    Expected change Star ratings showing in Google searches    Servers with 5+ votes get ★ stars Click-through rate from search results    📈 Up to 35% higher Long-tail keyword rankings (e.g. "interlude x100", "high five pvp")    📈 Better positions Mobile click rate    📈 Improved with new layout
    • Thank you very much. It would also be good if you looked into this issue. UnknownSoldier has been manipulating me to make me look bad. He deleted all the evidence I uploaded and left all the insults against me. You'll also see that on April 26th, he reopened the thread and then locked it again just so his friend from Argentina could post: links down :l XD   In the thread: https://maxcheaters.com/topic/253997-sourceservercliente-l2devs-files-l2devscom/page/2/ They do this so they can later tell people that I deleted the links because it was a lie, and so on. Realize that all the damage you're causing is related to this same person. Regards and thank you very much! 🙂 PS: I would like UnknownSoldier to publish the evidence for why he has repeatedly called me a SCAMMER and explain why he also says that to other people. This person is using forum privileges to smear and discredit those who don't work with him. I WANT ALL THE EVIDENCE OF WHAT HE'S SAYING.  
    • Theres a lot of drama going on about Guytis scamming people. I want real, solid proof showing that he scammed anyone attach everything you have.   About reputation: we’re all adults here, yet some are acting like kids fighting over pixels. Think before spreading rumors. False claims don’t make you look better they make you look worse.   I’m waiting for actual evidence that he scammed any user. If there’s nothing to back it up, I’ll deal with it myself. Time’s running out this has been going on long enough.
    • I’ve read the whole topic about Baylee and Protojah. From what I can see, Baylee wanted to buy some htmls and they agreed on a price. Later, Baylee changed her mind and decided not to go through with it. The product wasn’t delivered because Baylee changed her mind. Even if she initially agreed to the price, to avoid confusion. if the files had been sent and payment not made, I would call it a scam. But since they weren’t sent, this isn’t a scam.   I want to stress that I try to be fair to everyone, no matter the situation.   Yeah, Protojah did put in time and effort, and that’s fine, but disagreements happen all the time, even in real life jobs, no matter what the work is. I’m going to lock this topic to avoid more drama. Please keep all personal issues in private messages. And before anyone says anything else I’m not taking sides. I don’t protect scammers and I ban them, but since this isn’t a scam, you both should resolve this situation in DMs.
  • Topics

×
×
  • Create New...

Important Information

This community uses essential cookies to function properly. Non-essential cookies and third-party services are used only with your consent. Read our Privacy Policy and 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..