Bu kod, verilen özelliklerin bir kere alındıktan sonra tekrar alınmamasını sağlar. Eğer oyuncu 92-94 seviye görevini sıfırlayıp tekrar yaparsa, daha önce alınan özellikleri tekrar almaya çalışırsa hata mesajı alır.
Python:
Python:
quest isobiyolog begin
state start begin
when login begin
setstate(basla)
end
end
state basla begin
when 20084.chat."Biyolog Görevleri ( TEK TIK )" begin
-- diğer kodlar ...
-- özellikler ekleniyor
setstate(epic)
end
end
state epic begin
when 20091.chat."92. Level Epic Görevi" begin
say_title ( " 92.Lv Epic; " )
-- diğer kodlar ...
local has_hp_bonus = affect.has_collect(apply.MAX_HP)
local has_def_bonus = affect.has_collect(apply.DEF_GRADE_BONUS)
local has_att_bonus = affect.has_collect(apply.ATT_GRADE_BONUS)
local s = select ( " +1100 HP " , " Savunma Değeri +120 " , " Saldırı Değeri +60 " )
if s == 1 and not has_hp_bonus then
affect.add_collect(apply.MAX_HP, 1100, 60*60*24*365*60)
setstate(gec2)
elseif s == 2 and not has_def_bonus then
affect.add_collect(apply.DEF_GRADE_BONUS, 120, 60*60*24*365*60)
setstate(gec2)
elseif s == 3 and not has_att_bonus then
affect.add_collect(apply.ATT_GRADE_BONUS, 60, 60*60*24*365*60)
setstate(gec2)
else
say("Zaten bu özelliği aldınız. Farklı bir özellik seçin.")
end
end
end
state gec2 begin
when 20091.chat."94. Level Epic Görevi" begin
say_title ( " 94.Lv Epic; " )
-- diğer kodlar ...
local has_hp_bonus_4k = affect.has_collect(apply.MAX_HP, 4000)
local has_def_bonus_140 = affect.has_collect(apply.DEF_GRADE_BONUS, 140)
local has_att_bonus_70 = affect.has_collect(apply.ATT_GRADE_BONUS, 70)
local s = select ( " +4000 HP " , " Savunma Değeri +140 " , " Saldırı Değeri +70 " )
if s == 1 and not has_hp_bonus_4k then
affect.add_collect(apply.MAX_HP, 4000, 60*60*24*365*60)
setstate(isosifirla)
elseif s == 2 and not has_def_bonus_140 then
affect.add_collect(apply.DEF_GRADE_BONUS, 140, 60*60*24*365*60)
setstate(isosifirla)
elseif s == 3 and not has_att_bonus_70 then
affect.add_collect(apply.ATT_GRADE_BONUS, 70, 60*60*24*365*60)
setstate(isosifirla)
else
say("Zaten bu özelliği aldınız. Farklı bir özellik seçin.")
end
end
end
state isosifirla begin
when 20091.chat."92-94 Görevimi değiştir" begin
-- diğer kodlar ...
end
end
end


