Jump to content

Chance de drop


RachadoPT
 Share

Recommended Posts

Buenas, alguien ahí que me ayude creando uma quest que quando qualquier mob es muerto, tiene 1% de chance de cair un item de uma lista en la quest.

 

Esto asi hace lo que quiera?

when kill with not npc.is_pc() begin
			local drop_chance = number(1,100)
			if drop_chance == 1 then
				local nr = number(1,7)
				bola = { x , x , x , x , x , x , x }
				game.drop_item_with_ownership(tonumber(bola[nr], 1))
			end
		end

el "x" sera el vnum del item

 

Si eso esta bien, podrian decirmelo porfa?

 

Gracias, RachadoPT

Link to comment
Share on other sites

  • Dilong locked this topic
Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...