antiblock
Rodnia | Alpha & Omega
  • Chatbox

    You don't have permission to chat.
    Load More
  • 0
Sign in to follow this  
OceanusMT2

Onde Está O Erro?!

Question

 when kill with not npc.is_pc() and pc.get_map_index() == 80 begin   local dropsv34 = {   -- Sapatos    {15180, 1},{15200, 1},{15220, 1},   -- Brincos    {17160, 1},{17180, 1},{17200, 1},   -- Colares    {16160, 1},{16180, 1},{16200, 1},   -- Pulseiras    {14160, 1},{14180, 1},{14200, 1},   -- Escudos 61    {13060, 1},{13080, 1},{13100, 1},{13120, 1}    } ----- linha 85   local premioxf = math.random(1,30)   if premioxf >= 27 then    if pc.level >= 15 and pc.level <= 75 then	 game.drop_item_with_ownership(dropsv34[math.random(1,16)][1], dropsv34[2])    end   end  end

 

 

syserr:

 

SYSERR: Dec 28 00:45:29 :: RunState: LUA_ERROR: [string "dropx"]:85: attempt to index field `?' (a nil value)SYSERR: Dec 28 00:45:29 :: WriteRunningStateToSyserr: LUA_ERROR: quest dropx.start letter

 

 

 

 

sério.... onde esta o erro!?

Share this post


Link to post
Share on other sites

1 answer to this question

  • 0

Olá,

Falta definir a quest e o state, e no game.drop_item_with_ownership no valor da quantidade estava dropsv34[2] ou seja a buscar a lista:{15200, 1} precisas de definir qual dos valores vai buscar o primeiro ou o segundo.

 

 

Tenta esta quest:

quest drop_mob begin	state start begin		when kill with not npc.is_pc() and pc.get_map_index() == 80 begin		   local dropsv34 = {		   -- Sapatos			{15180, 1},{15200, 1},{15220, 1},		   -- Brincos			{17160, 1},{17180, 1},{17200, 1},		   -- Colares			{16160, 1},{16180, 1},{16200, 1},		   -- Pulseiras			{14160, 1},{14180, 1},{14200, 1},		   -- Escudos 61			{13060, 1},{13080, 1},{13100, 1},{13120, 1}			} ----- linha 85		   local premioxf = math.random(1,30)		   if premioxf >= 27 then			if pc.level >= 15 and pc.level <= 75 then			 local randomnum = math.random(1,16)			 game.drop_item_with_ownership(dropsv34[randomnum][1], dropsv34[randomnum][2])			end		   end		end	endend

Share this post


Link to post
Share on other sites
antiblock
Rodnia | Alpha & Omega

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this