Jump to content
  • 0

Question

Posted

Someone good hearted boy for this code?

 

I copied the quest 623_TheFinestFood ... NPC also changed and added to the HTML folder / custom and added a line to the script to turn, but the game handles, and nothing happens, or no message in the log Thanks

 

 

 

 

 

# Tauti Zbrane - v0.1 by disKret & DrLecter

import sys

from com.l2jfrozen import Config

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 = "1010_TautiZbrane"

 

#NPC

VILEM = 25888

 

#ITEMS

LEAF_OF_FLAVA,BUFFALO_MEAT,ANTELOPE_HORN = range(7199,7202)

 

#MOBS, DROPS, CHANCES & REWARDS

BUFFALO,FLAVA,ANTELOPE = [ 21315,21316,21318 ]

DROPLIST = {BUFFALO:[bUFFALO_MEAT,99],FLAVA:[LEAF_OF_FLAVA,99],ANTELOPE:[ANTELOPE_HORN,99]}

REWARDS = [[7152,25000,0,11],[0,73000,34,100]]

 

#needed count

 

class Quest (JQuest) :

 

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

 

def onEvent (self,event,st) :

  cond = st.getInt("cond")

  htmltext = event

  leaf = st.getQuestItemsCount(LEAF_OF_FLAVA)

  meat = st.getQuestItemsCount(BUFFALO_MEAT)

  horn = st.getQuestItemsCount(ANTELOPE_HORN)

  if event == "25888-03.htm" and cond == 0 :

    if st.getPlayer().getLevel() >= 71 :

        st.set("cond","1")

        st.setState(STARTED)

        st.playSound("ItemSound.quest_accept")

    else :

        htmltext = "25888-02.htm"

        st.exitQuest(1)

  elif event == "25888-07.htm" :

    if cond == 2 and leaf == meat == horn == 100 :

        htmltext = "25888-06.htm"

        st.playSound("ItemSound.quest_finish")

        random = st.getRandom(100)

        i = 0

        while i < len(REWARDS) :

            item,adena,chance,chance2=REWARDS

            if chance<=random<= chance2 :

              break

            i = i+1

        st.giveItems(57,adena)

        if item :

          st.giveItems(item,1)

        else :

          st.addExpAndSp(230000,18250)

        st.takeItems(LEAF_OF_FLAVA,-1)

        st.takeItems(BUFFALO_MEAT,-1)

        st.takeItems(ANTELOPE_HORN,-1)

        st.exitQuest(1)

  return htmltext

 

def onTalk (self,npc,player) :

  htmltext = "<html><body>Bohuzel nesplnujes criteria k vykonu sluzby questu</body></html>"

  st = player.getQuestState(qn)

  if st :

      cond = st.getInt("cond")

      leaf = st.getQuestItemsCount(LEAF_OF_FLAVA)

      meat = st.getQuestItemsCount(BUFFALO_MEAT)

      horn = st.getQuestItemsCount(ANTELOPE_HORN)

      if cond == 0 :

          htmltext = "25888-01.htm"

      elif st.getState() == STARTED :

          if cond == 1 :

              htmltext = "25888-05.htm"

          elif cond == 2 and leaf == meat == horn == 100 :

              htmltext = "25888-04.htm"

  return htmltext

 

def onKill(self,npc,player,isPet):

  # todo: with the current code, a player who has completed up to 2 out of 3

  # item collections may consume the party drop (i.e. become the selected

  # player in the random, but get nothing because it was the wrong mob)

  # this ought to be corrected later...

  partyMember = self.getRandomPartyMember(player,"1")

  if not partyMember: return

  st = partyMember.getQuestState(qn)

  if st :

      if st.getState() == STARTED :

        item,chance = DROPLIST[npc.getNpcId()]

        count = st.getQuestItemsCount(item)

        if st.getInt("cond") == 1 and count < 100 :

            numItems, chance = divmod(chance*Config.RATE_DROP_QUEST,100)

            if st.getRandom(100) < chance :

              numItems += 1

            if count + numItems >= 100 :

              numItems = 100 - count

            if numItems != 0 :

              st.giveItems(item,int(numItems))

              if st.getQuestItemsCount(LEAF_OF_FLAVA) == st.getQuestItemsCount(BUFFALO_MEAT) == st.getQuestItemsCount(ANTELOPE_HORN) == 100 :

                st.set("cond","2")

                st.playSound("ItemSound.quest_middle")

              else :

                st.playSound("ItemSound.quest_itemget")

  return

 

QUEST      = Quest(1010,qn, "custom")

CREATED    = State('Start', QUEST)

STARTED    = State('Started', QUEST)

 

QUEST.setInitialState(CREATED)

QUEST.addStartNpc(VILEM)

QUEST.addTalkId(VILEM)

 

for mob in DROPLIST.keys() :

  QUEST.addKillId(mob)

 

for item in range(7199,7202):

    STARTED.addQuestDrop(VILEM,item,1)

1 answer to this question

Recommended Posts

Guest
This topic is now closed to further replies.


  • Posts

    • THE CAMERA DISTORTS – AND THAT CAN EXPOSE YOU ▪ You look at the photo: “looks fine.” But the sensor has already altered it – and without that, the shot doesn’t exist. ▪ Rolling shutter. The frame is read line by line objects slightly “drift”, geometry isn’t perfect that’s not a bug – that’s the baseline. ▪ Sensor noise. Even in good lighting there’s still grain every sensor has its own signature too clean = unnatural. ▪ Aberrations. Color shifts appear near the edges lenses aren’t perfect, and it shows perfect edges with no shift are rare. ▪ Reality ≠ what the camera records. It always adds distortion. ▪ Want to know where your file is “too perfect”? Send it over – we’ll break it down for you. › TG: @mustang_service ( https:// t.me/ mustang_service ) › Channel: Mustang Service ( https:// t.me/ +JPpJCETg-xM1NjNl ) #editing #photoshop #distortion #verification #camera
    • We’re not trying to be “Reborn” or anyone else and you have copy the server concept,the reborn website,the reborn logo,the reborn community board html,lol trash
    • SOCNET is a universal service that combines a digital goods store, an SMM panel, a Telegram bot for purchasing Telegram Stars and a Telegram bot for renting virtual numbers. Here you will find accounts for TikTok, Instagram, Reddit, Twitter, Telegram, Facebook, LinkedIn, WhatsApp, SnapChat, YouTube, Google, Discord, email (Outlook, Hotmail, Gmail, Rambler, Firstmail and others), proxies, virtual servers, advertising accounts, access to ChatGPT 5, gift cards and premium subscriptions to numerous services — and all this at the best prices!   SOCNET STARS is a service that helps you quickly and profitably purchase Telegram Stars and subscribe to Telegram Premium. Using our Telegram bot you can buy Telegram Stars at the lowest prices on the market and use them to pay for gifts, reactions, donations and other features inside Telegram.   Our bot also features a NEW gaming feature — gift slots, where users can win valuable prizes: Telegram gifts, bonuses from our partners and the SOCNET company, stars and premium subscriptions. The game mechanics are completely transparent: no tricks, only real luck decides. You can try it at any time — bets start from just 1 ruble. We also provide the opportunity for a one-time free spin!   Available payment methods: LOLZTEAM, Crypto Bot, Cryptocurrency, Bank cards and SBP ⭐ Our online store ⭐ SOCNET.STORE ⭐ Telegram store ⭐ SOCNET.SHOP ⭐ Our SMM Panel for social media promotion ⭐ SOCNET.PRO ⭐ Our Telegram bot for purchasing Telegram Stars ⭐ SOCNET.CC ⭐ Our SMS Service ⭐ SOCNET.APP ✅ News resources: ➡ Telegram channel ➡ WhatsApp channel ➡ Discord server ✅ Contacts and support: ➡ Telegram support ➡ WhatsApp support ➡ Discord support: socnet_support ➡ Email support: help@socnet.pro We have been operating for a long time and have gathered a huge list of reviews about our work! Our huge list of positive and honest reviews is presented on our website! ⭐We invite you to COOPERATE and EARN with us ⭐ Want to sell your product or service in our stores and make money? Become our partner or suggest mutually beneficial cooperation? You can contact us via the CONTACTS listed in this topic. If you have any questions or problems, our fast customer support is ready to respond to your requests! Refunds for a service that does not fully meet the requirements or quality are issued only if a guarantee and warranty period were specified in the product description. In all other cases, refunds for the service will not be fully processed or issued! By purchasing such a service, you automatically agree to our refund policy for non-provided services! We currently accept Any type of cryptocurrency (Cryptomus, Binance Pay, CryptoBot), any bank cards (VISA, Mastercard, MIR Pay, SBP), LolzTeam Market, Wise, Revolut, Paypal Friends&Families. We value every customer and provide replacements for invalid accounts and services through our contact methods!
    • SOCNET is a universal service that combines a digital goods store, an SMM panel, a Telegram bot for purchasing Telegram Stars and a Telegram bot for renting virtual numbers. Here you will find accounts for TikTok, Instagram, Reddit, Twitter, Telegram, Facebook, LinkedIn, WhatsApp, SnapChat, YouTube, Google, Discord, email (Outlook, Hotmail, Gmail, Rambler, Firstmail and others), proxies, virtual servers, advertising accounts, access to ChatGPT 5, gift cards and premium subscriptions to numerous services — and all this at the best prices!   SOCNET STARS is a service that helps you quickly and profitably purchase Telegram Stars and subscribe to Telegram Premium. Using our Telegram bot you can buy Telegram Stars at the lowest prices on the market and use them to pay for gifts, reactions, donations and other features inside Telegram.   Our bot also features a NEW gaming feature — gift slots, where users can win valuable prizes: Telegram gifts, bonuses from our partners and the SOCNET company, stars and premium subscriptions. The game mechanics are completely transparent: no tricks, only real luck decides. You can try it at any time — bets start from just 1 ruble. We also provide the opportunity for a one-time free spin!   Available payment methods: LOLZTEAM, Crypto Bot, Cryptocurrency, Bank cards and SBP ⭐ Our online store ⭐ SOCNET.STORE ⭐ Telegram store ⭐ SOCNET.SHOP ⭐ Our SMM Panel for social media promotion ⭐ SOCNET.PRO ⭐ Our Telegram bot for purchasing Telegram Stars ⭐ SOCNET.CC ⭐ Our SMS Service ⭐ SOCNET.APP ✅ News resources: ➡ Telegram channel ➡ WhatsApp channel ➡ Discord server ✅ Contacts and support: ➡ Telegram support ➡ WhatsApp support ➡ Discord support: socnet_support ➡ Email support: help@socnet.pro We have been operating for a long time and have gathered a huge list of reviews about our work! Our huge list of positive and honest reviews is presented on our website! ⭐We invite you to COOPERATE and EARN with us ⭐ Want to sell your product or service in our stores and make money? Become our partner or suggest mutually beneficial cooperation? You can contact us via the CONTACTS listed in this topic. If you have any questions or problems, our fast customer support is ready to respond to your requests! Refunds for a service that does not fully meet the requirements or quality are issued only if a guarantee and warranty period were specified in the product description. In all other cases, refunds for the service will not be fully processed or issued! By purchasing such a service, you automatically agree to our refund policy for non-provided services! We currently accept Any type of cryptocurrency (Cryptomus, Binance Pay, CryptoBot), any bank cards (VISA, Mastercard, MIR Pay, SBP), LolzTeam Market, Wise, Revolut, Paypal Friends&Families. We value every customer and provide replacements for invalid accounts and services through our contact methods!
    • SOCNET is a universal service that combines a digital goods store, an SMM panel, a Telegram bot for purchasing Telegram Stars and a Telegram bot for renting virtual numbers. Here you will find accounts for TikTok, Instagram, Reddit, Twitter, Telegram, Facebook, LinkedIn, WhatsApp, SnapChat, YouTube, Google, Discord, email (Outlook, Hotmail, Gmail, Rambler, Firstmail and others), proxies, virtual servers, advertising accounts, access to ChatGPT 5, gift cards and premium subscriptions to numerous services — and all this at the best prices!   SOCNET STARS is a service that helps you quickly and profitably purchase Telegram Stars and subscribe to Telegram Premium. Using our Telegram bot you can buy Telegram Stars at the lowest prices on the market and use them to pay for gifts, reactions, donations and other features inside Telegram.   Our bot also features a NEW gaming feature — gift slots, where users can win valuable prizes: Telegram gifts, bonuses from our partners and the SOCNET company, stars and premium subscriptions. The game mechanics are completely transparent: no tricks, only real luck decides. You can try it at any time — bets start from just 1 ruble. We also provide the opportunity for a one-time free spin!   Available payment methods: LOLZTEAM, Crypto Bot, Cryptocurrency, Bank cards and SBP ⭐ Our online store ⭐ SOCNET.STORE ⭐ Telegram store ⭐ SOCNET.SHOP ⭐ Our SMM Panel for social media promotion ⭐ SOCNET.PRO ⭐ Our Telegram bot for purchasing Telegram Stars ⭐ SOCNET.CC ⭐ Our SMS Service ⭐ SOCNET.APP ✅ News resources: ➡ Telegram channel ➡ WhatsApp channel ➡ Discord server ✅ Contacts and support: ➡ Telegram support ➡ WhatsApp support ➡ Discord support: socnet_support ➡ Email support: help@socnet.pro We have been operating for a long time and have gathered a huge list of reviews about our work! Our huge list of positive and honest reviews is presented on our website! ⭐We invite you to COOPERATE and EARN with us ⭐ Want to sell your product or service in our stores and make money? Become our partner or suggest mutually beneficial cooperation? You can contact us via the CONTACTS listed in this topic. If you have any questions or problems, our fast customer support is ready to respond to your requests! Refunds for a service that does not fully meet the requirements or quality are issued only if a guarantee and warranty period were specified in the product description. In all other cases, refunds for the service will not be fully processed or issued! By purchasing such a service, you automatically agree to our refund policy for non-provided services! We currently accept Any type of cryptocurrency (Cryptomus, Binance Pay, CryptoBot), any bank cards (VISA, Mastercard, MIR Pay, SBP), LolzTeam Market, Wise, Revolut, Paypal Friends&Families. We value every customer and provide replacements for invalid accounts and services through our contact methods!
  • 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..