[Cerere]Quest

Avatar utilizator
SebiSzeb
Nivel 1

Nivel 1
Mesaje: 89
Membru din: 18 Ian 2019, 00:25
Aprecieri: 35  
Mulţumiri: 0
Medalii

Ma poate cineva ajuta cu un quest gen {schimba alchimia } Modificat in felul urmator ! Cand pun alchimia pe NPC sa nu mai apara fereastra de la quest cu informatii . Sa schimbe direct alchimia cu alta ! las si quest mai jos !



quest schimba_alchimia begin
state start begin
when 20001.chat."Schimba alchimia!" begin
say_title("Alchimist:")
say("")
say("Salutare tanarule razboinic!")
say("Am facut o noua descoperire")
say("Alchiama Piatra Dragon de claritate excelenta,")
say("cu bonusuri slabe pot fi schimba pentru 250000000 yang")
say("in alta Piatra Dragon de claritate excelenta cu bonusuri diferite!")
say_reward("!!ATENTIE!!")
say_reward("Daca Piatra Dragon este +1/+2/+3/+4/+5/+6")
say_reward("dupa ce ii resetati bonusurile v-a revenii la +0!")
say_reward("!!ATENTIE!!")
say_reward("Daca vrei sa incerci noua tehnica")
say_reward("trage Piatra dragon veche pe mine!")
say("")
end
when 20001.take with item.get_vnum() == 114400 or item.get_vnum() == 114410 or item.get_vnum() == 114420 or item.get_vnum() == 114430 or item.get_vnum() == 114440
or item.get_vnum() == 114450 or item.get_vnum() == 114460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(114400,1)
end
end
when 20001.take with item.get_vnum() == 124400 or item.get_vnum() == 124410 or item.get_vnum() == 124420 or item.get_vnum() == 124430 or item.get_vnum() == 124440
or item.get_vnum() == 124450 or item.get_vnum() == 124460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(124400,1)
end
end
when 20001.take with item.get_vnum() == 134400 or item.get_vnum() == 134410 or item.get_vnum() == 134420 or item.get_vnum() == 134430 or item.get_vnum() == 134440
or item.get_vnum() == 134450 or item.get_vnum() == 134460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(134400,1)
end
end
when 20001.take with item.get_vnum() == 144400 or item.get_vnum() == 144410 or item.get_vnum() == 144420 or item.get_vnum() == 144430 or item.get_vnum() == 144440
or item.get_vnum() == 144450 or item.get_vnum() == 144460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(144400,1)
end
end
when 20001.take with item.get_vnum() == 154400 or item.get_vnum() == 154410 or item.get_vnum() == 154420 or item.get_vnum() == 154430 or item.get_vnum() == 154440
or item.get_vnum() == 154450 or item.get_vnum() == 154460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(154400,1)
end
end
when 20001.take with item.get_vnum() == 164400 or item.get_vnum() == 164410 or item.get_vnum() == 164420 or item.get_vnum() == 164430 or item.get_vnum() == 164440
or item.get_vnum() == 164450 or item.get_vnum() == 164460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(164400,1)
end
end
end
end
Avatar utilizator
[RaffaeL]
Software Developer

Software Developer
Mesaje: 3223
Membru din: 19 Mar 2016, 12:58
Server: ...
Aprecieri: 15  
Mulţumiri: 2502  
  Rezolvări prob.: 2
Discord: Copiază ID
 Contact:
Medalii

SebiSzeb scrie:Ma poate cineva ajuta cu un quest gen {schimba alchimia } Modificat in felul urmator ! Cand pun alchimia pe NPC sa nu mai apara fereastra de la quest cu informatii . Sa schimbe direct alchimia cu alta ! las si quest mai jos !


quest schimba_alchimia begin
state start begin
when 20001.chat."Schimba alchimia!" begin
say_title("Alchimist:")
say("")
say("Salutare tanarule razboinic!")
say("Am facut o noua descoperire")
say("Alchiama Piatra Dragon de claritate excelenta,")
say("cu bonusuri slabe pot fi schimba pentru 250000000 yang")
say("in alta Piatra Dragon de claritate excelenta cu bonusuri diferite!")
say_reward("!!ATENTIE!!")
say_reward("Daca Piatra Dragon este +1/+2/+3/+4/+5/+6")
say_reward("dupa ce ii resetati bonusurile v-a revenii la +0!")
say_reward("!!ATENTIE!!")
say_reward("Daca vrei sa incerci noua tehnica")
say_reward("trage Piatra dragon veche pe mine!")
say("")
end
when 20001.take with item.get_vnum() == 114400 or item.get_vnum() == 114410 or item.get_vnum() == 114420 or item.get_vnum() == 114430 or item.get_vnum() == 114440
or item.get_vnum() == 114450 or item.get_vnum() == 114460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(114400,1)
end
end
when 20001.take with item.get_vnum() == 124400 or item.get_vnum() == 124410 or item.get_vnum() == 124420 or item.get_vnum() == 124430 or item.get_vnum() == 124440
or item.get_vnum() == 124450 or item.get_vnum() == 124460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(124400,1)
end
end
when 20001.take with item.get_vnum() == 134400 or item.get_vnum() == 134410 or item.get_vnum() == 134420 or item.get_vnum() == 134430 or item.get_vnum() == 134440
or item.get_vnum() == 134450 or item.get_vnum() == 134460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(134400,1)
end
end
when 20001.take with item.get_vnum() == 144400 or item.get_vnum() == 144410 or item.get_vnum() == 144420 or item.get_vnum() == 144430 or item.get_vnum() == 144440
or item.get_vnum() == 144450 or item.get_vnum() == 144460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(144400,1)
end
end
when 20001.take with item.get_vnum() == 154400 or item.get_vnum() == 154410 or item.get_vnum() == 154420 or item.get_vnum() == 154430 or item.get_vnum() == 154440
or item.get_vnum() == 154450 or item.get_vnum() == 154460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(154400,1)
end
end
when 20001.take with item.get_vnum() == 164400 or item.get_vnum() == 164410 or item.get_vnum() == 164420 or item.get_vnum() == 164430 or item.get_vnum() == 164440
or item.get_vnum() == 164450 or item.get_vnum() == 164460 begin
local nume_item = item.get_vnum()
say_title("Alchimist:")
say("")
say("Esti sigur ca doresti sa schimbi "..item_name(nume_item).."?")
say_reward("Daca alchimia este +1/+2/+3/+4/+5/+6 aceasta va revenii la +0!")
say_reward("Acest lucru te v-a costa 250000000 yang!")
say_reward("Doresti sa continui?")
say("")
local dcs = select("Da","Nu")
if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
return
elseif dcs == 1 then
item.remove()
pc.change_gold(-250000000)
pc.give_item2(164400,1)
end
end
end
end
Doar renunta la partea de info, si anume la tot ce inseamna "say", si lasa doar functiile "take".
Imagine
Imagine
https://www.youtube.com/watch?v=GhYkCIETEto
Do everything, if you know what you're doing, else... Imagine
Ma gasesti si aici: Discord https://discord.gg/5J5GnyZVSR
Afișează semnătura
Avatar utilizator
SebiSzeb
Nivel 1

Nivel 1
Mesaje: 89
Membru din: 18 Ian 2019, 00:25
Aprecieri: 35  
Mulţumiri: 0
Medalii

am incercat ...dar ramane local dcs = select("Da","Nu") si apare DA NU si daca il sterg nu mai merge deloc ..
Avatar utilizator
[RaffaeL]
Software Developer

Software Developer
Mesaje: 3223
Membru din: 19 Mar 2016, 12:58
Server: ...
Aprecieri: 15  
Mulţumiri: 2502  
  Rezolvări prob.: 2
Discord: Copiază ID
 Contact:
Medalii

SebiSzeb scrie:am incercat ...dar ramane local dcs = select("Da","Nu") si apare DA NU si daca il sterg nu mai merge deloc ..
:) Nu am inteles de ce primesc aceeasi piatra ca si prima schimbata, dar mna...l-am rescris dupa cel pus de tine:

Cod: Selectaţi tot

quest schimba_alchimia begin
	state start begin
		when 20001.take begin
			local ds_stones = {
				["ds1"] = {114400, 114410, 114420, 114430, 114440, 114450, 114460},
				["ds2"] = {124400, 124410, 124420, 124430, 124440, 124450, 124460},
				["ds3"] = {134400, 134410, 134420, 134430, 134440, 134450, 134460},
				["ds4"] = {144400, 144410, 144420, 144430, 144440, 144450, 144460},
				["ds5"] = {154400, 154410, 154420, 154430, 154440, 154450, 154460},
				["ds6"] = {164400, 164410, 164420, 164430, 164440, 164450, 164460},
			}

			for i in ds_stones do
				for q = 1, table.getn(ds_stones["ds1"]), 1 do
					if (item.get_vnum(take) == ds_stones["ds1"][q]) then
						item.remove(take)
						pc.give_item2(114400, 1)
					end
				end
				for r = 1, table.getn(ds_stones["ds2"]), 1 do
					if (item.get_vnum(take) == ds_stones["ds2"][r]) then
						item.remove(take)
						pc.give_item2(124400, 1)
					end
				end
				for s = 1, table.getn(ds_stones["ds3"]), 1 do
					if (item.get_vnum(take) == ds_stones["ds3"][s]) then
						item.remove(take)
						pc.give_item2(134400, 1)
					end
				end
				for t = 1, table.getn(ds_stones["ds4"]), 1 do
					if (item.get_vnum(take) == ds_stones["ds4"][t]) then
						item.remove(take)
						pc.give_item2(144400, 1)
					end
				end
				for u = 1, table.getn(ds_stones["ds5"]), 1 do
					if (item.get_vnum(take) == ds_stones["ds5"][u]) then
						item.remove(take)
						pc.give_item2(154400, 1)
					end
				end
				for v = 1, table.getn(ds_stones["ds6"]), 1 do
					if (item.get_vnum(take) == ds_stones["ds6"][v]) then
						item.remove(take)
						pc.give_item2(164400, 1)
					end
				end
			end
		end
	end
end
Imagine
Imagine
https://www.youtube.com/watch?v=GhYkCIETEto
Do everything, if you know what you're doing, else... Imagine
Ma gasesti si aici: Discord https://discord.gg/5J5GnyZVSR
Afișează semnătura
Avatar utilizator
SebiSzeb
Nivel 1

Nivel 1
Mesaje: 89
Membru din: 18 Ian 2019, 00:25
Aprecieri: 35  
Mulţumiri: 0
Medalii

era vorba sa schimbe npc-ul respectiv alchimia legendara praff pentru 250kk in ceva mai ok D:
Avatar utilizator
[RaffaeL]
Software Developer

Software Developer
Mesaje: 3223
Membru din: 19 Mar 2016, 12:58
Server: ...
Aprecieri: 15  
Mulţumiri: 2502  
  Rezolvări prob.: 2
Discord: Copiază ID
 Contact:
Medalii

SebiSzeb scrie:era vorba sa schimbe npc-ul respectiv alchimia legendara praff pentru 250kk in ceva mai ok D:
In cazul asta, schimba pc.give_item2(114400, 1) pentru ["ds1"] cu pc.give_item2(124400, 1), si tot asa...In felul asta primesc probabil claritatea urmatoare, nu stiu cum sunt diferentiate, nu imi place alchimia.
Imagine
Imagine
https://www.youtube.com/watch?v=GhYkCIETEto
Do everything, if you know what you're doing, else... Imagine
Ma gasesti si aici: Discord https://discord.gg/5J5GnyZVSR
Afișează semnătura
Avatar utilizator
SebiSzeb
Nivel 1

Nivel 1
Mesaje: 89
Membru din: 18 Ian 2019, 00:25
Aprecieri: 35  
Mulţumiri: 0
Medalii

functioneaza perfect questu,insa am adaugat sa ceara yang ,dar nu reusesc sa bag mesaj de protectie ( nu ai suficient yang pentru a face asta )
Avatar utilizator
SebiSzeb
Nivel 1

Nivel 1
Mesaje: 89
Membru din: 18 Ian 2019, 00:25
Aprecieri: 35  
Mulţumiri: 0
Medalii

for i in ds_stones do
for q = 1, table.getn(ds_stones["ds1"]), 1 do
if (item.get_vnum(take) == ds_stones["ds1"][q]) then
item.remove(take)
pc.change_gold(-150000000)
pc.give_item2(9600, 1)
end
end

ceva gen asta if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")
Avatar utilizator
[RaffaeL]
Software Developer

Software Developer
Mesaje: 3223
Membru din: 19 Mar 2016, 12:58
Server: ...
Aprecieri: 15  
Mulţumiri: 2502  
  Rezolvări prob.: 2
Discord: Copiază ID
 Contact:
Medalii

SebiSzeb scrie:functioneaza perfect questu,insa am adaugat sa ceara yang ,dar nu reusesc sa bag mesaj de protectie ( nu ai suficient yang pentru a face asta )
for i in ds_stones do
for q = 1, table.getn(ds_stones["ds1"]), 1 do
if (item.get_vnum(take) == ds_stones["ds1"][q]) then
item.remove(take)
pc.change_gold(-150000000)
pc.give_item2(9600, 1)
end
end

ceva gen asta if pc.get_gold()<250000000 then
say("Nu ai suficient yang pentru a face asa ceva")

Cod: Selectaţi tot

quest schimba_alchimia begin
	state start begin
		when 20001.take begin
			local ds_stones = {
				["ds1"] = {114400, 114410, 114420, 114430, 114440, 114450, 114460},
				["ds2"] = {124400, 124410, 124420, 124430, 124440, 124450, 124460},
				["ds3"] = {134400, 134410, 134420, 134430, 134440, 134450, 134460},
				["ds4"] = {144400, 144410, 144420, 144430, 144440, 144450, 144460},
				["ds5"] = {154400, 154410, 154420, 154430, 154440, 154450, 154460},
				["ds6"] = {164400, 164410, 164420, 164430, 164440, 164450, 164460},
			}
			local msg = "Nu ai suficient yang pentru a face asa ceva"
			local req = 250000000
			local yang = pc.get_gold()

			for i in ds_stones do
				if yang < req then
					chat(tostring(msg))
					return
				else
					for q = 1, table.getn(ds_stones["ds1"]), 1 do
						if (item.get_vnum(take) == ds_stones["ds1"][q]) then
							item.remove(take)
							pc.give_item2(114400, 1)
							pc.change_gold(-req)
						end
					end
					for r = 1, table.getn(ds_stones["ds2"]), 1 do
						if (item.get_vnum(take) == ds_stones["ds2"][r]) then
							item.remove(take)
							pc.give_item2(124400, 1)
						end
					end
					for s = 1, table.getn(ds_stones["ds3"]), 1 do
						if (item.get_vnum(take) == ds_stones["ds3"][s]) then
							item.remove(take)
							pc.give_item2(134400, 1)
							pc.change_gold(-req)
						end
					end
					for t = 1, table.getn(ds_stones["ds4"]), 1 do
						if (item.get_vnum(take) == ds_stones["ds4"][t]) then
							item.remove(take)
							pc.give_item2(144400, 1)
							pc.change_gold(-req)
						end
					end
					for u = 1, table.getn(ds_stones["ds5"]), 1 do
						if (item.get_vnum(take) == ds_stones["ds5"][u]) then
							item.remove(take)
							pc.give_item2(154400, 1)
							pc.change_gold(-req)
						end
					end
					for v = 1, table.getn(ds_stones["ds6"]), 1 do
						if (item.get_vnum(take) == ds_stones["ds6"][v]) then
							item.remove(take)
							pc.give_item2(164400, 1)
							pc.change_gold(-req)
						end
					end
				end
			end
		end
	end
end
Pentru acest mesaj, [RaffaeL] a primit 2 (de) mulţumiri
SebiSzeb • alinjuve23
Imagine
Imagine
https://www.youtube.com/watch?v=GhYkCIETEto
Do everything, if you know what you're doing, else... Imagine
Ma gasesti si aici: Discord https://discord.gg/5J5GnyZVSR
Afișează semnătura
Avatar utilizator
SebiSzeb
Nivel 1

Nivel 1
Mesaje: 89
Membru din: 18 Ian 2019, 00:25
Aprecieri: 35  
Mulţumiri: 0
Medalii

Rezolvat Mersi Raf !
Închis

Înapoi la “Cereri Rezolvate”

  • Informaţie