Jump to content
Forgot your email address? ×
×
×
  • Create New...
  • 0

[HELP] Is this quest okay?


RachadoPT

Question

Hi guys, can you please tell me if this quest is okay? 

quest chests begin
	state start begin
		when 38057.use begin
			sex = pc.get_sex()
			local random_nr = number(1,15)
			if sex == 1 then
				random_item = { 41001, 41002, 41003, 41005, 41007, 41009, 41011, 41013, 41015, 41017, 41019, 41021, 41023, 41025, 41027,}
			else
				random_item = { 41001, 41002, 41004, 41006, 41008, 41010, 41012, 41014, 41016, 41018, 41020, 41022, 41024, 41026, 41028,}
			end

			pc.give_item2(tonumber(random_items[random_nr]))
		end
	end
end

I just created this quest for a chest i had with no use, i uploaded it in the quest folder and then i ran the ./qc_x64, there were no errors, but when i click the chest nothing happens...

Link to comment

12 answers to this question

Recommended Posts

  • 0

Is the item type correct?

Im not sure, but im not home now, im at school, can you tell me which is the correct type for a chest? If it is wrong i'll correct it and try again. Thank you man :)

 

Greetz, RachadoPT

Link to comment
  • 0

 

Is the item type correct?

Im not sure, but im not home now, im at school, can you tell me which is the correct type for a chest? If it is wrong i'll correct it and try again. Thank you man :)

 

Greetz, RachadoPT

 

 

The type was wrong.. Now the type is 23 but when i click it, in the chat:

You received nothing...

Link to comment
  • 0

 

 

You are using it for a quest so you need quest type not box tipe:P

 

Oh, sure xDD but i dont know which is the type for quest xD

 

18

 

 

Good ahah, now it's working but when i open the box i receive another item that is not one of the vnums i have in the quest, like reinforce items, blessing marbles, pets, those things ><

Link to comment
  • 0

 

 

 

You are using it for a quest so you need quest type not box tipe:P

 

Oh, sure xDD but i dont know which is the type for quest xD

 

18

 

 

Good ahah, now it's working but when i open the box i receive another item that is not one of the vnums i have in the quest, like reinforce items, blessing marbles, pets, those things ><

 

 

Either you have another quest for that and u dont know it or you have items for that box vnum in special_item_drop.txt something like this

Group	ice02			
{				
	Vnum	50099		
	1	50039	1	60 
	2	71052	1	50 
	3	71051	1	50 
	4	50038	1	40 
	5	40149	1	5 
	6	40147	1	2
	7	70252	1	5 
	8	41133	1	7 
	9	41233	1	7 
	10	90017	1	5 
	11	90016	1	10 
	12	50711	1	2
	13	71055	1	3
	14	50011	10	50
	15	70251	1	70
}

so remove it from there if you have it

  • Love 1
Link to comment
  • 0
quest chests begin
	state start begin
		when 38057.use begin
			sex = pc.get_sex()
			local random_item
			if sex == 1 then
				random_item = { 41001, 41002, 41003, 41005, 41007, 41009, 41011, 41013, 41015, 41017, 41019, 41021, 41023, 41025, 41027,}
			else
				random_item = { 41001, 41002, 41004, 41006, 41008, 41010, 41012, 41014, 41016, 41018, 41020, 41022, 41024, 41026, 41028,}
			end
			pc.give_item2(random_item[math.random(1, table.getn(random_item))])
		end
	end
end
  • Love 1
Link to comment
  • 0
quest chests begin
	state start begin
		when 38057.use begin
			sex = pc.get_sex()
			local random_item
			if sex == 1 then
				random_item = { 41001, 41002, 41003, 41005, 41007, 41009, 41011, 41013, 41015, 41017, 41019, 41021, 41023, 41025, 41027,}
			else
				random_item = { 41001, 41002, 41004, 41006, 41008, 41010, 41012, 41014, 41016, 41018, 41020, 41022, 41024, 41026, 41028,}
			end
			pc.give_item2(random_item[math.random(1, table.getn(random_item))])
		end
	end
end

Thank you man, it worked! :D luv u <3

 

Gratz, RachadoPT ^^

Link to comment

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

Announcements

  • -15% Discount in Metin2 Dev Store (01/10/2021 => 31/12/2021) => Code => 15_PCT_OCT_TO_DEC_2021


  • Read our Rules
  • Activity

    1. 7

      PHOENIX2 !OLDSCHOOL SERVER, PAYTOWIN REMOVED!

    2. 0

      special_item_group and chest apprentice

    3. 2

      Alternative Alternative Zodiac Suit - Ninja M

    4. 0

      character details negative bonus

    5. 0

      Questlib mysql_query function problem

  • Recently Browsing

    • No registered users viewing this page.

Important Information

Terms of Use / Privacy Policy / Guidelines / 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.