Modificare quest G Skill

Înainte de a posta o problemă, caută în acest forum și poate găsești rezolvare.
Închis
Avatar utilizator
DragonA7X
Nivel 3

Nivel 3
Mesaje: 434
Membru din: 06 Apr 2017, 10:41
Aprecieri: 100  
Mulţumiri: 3  
Medalii

*Problemă: Salut! Questul pe care il folosesc e bun, dar as dori sa adaug inca o functie in care sa blocheze si sa anunte jucatorul ca skillul ales de transformare in P. Master inca nu este G. Master. Cine ma poate ajuta?
*Tipologie server: PvP PvM
*Resursă folosită:
*ServerFiles utilizat: Happiness
*Syserr:
*Poză:
*Detalii suplimentare:

Cod: Selectaţi tot

quest item_skill_p begin
   state start begin
      
      -- DEFAULT --
      when 50512.use with pc.get_skill_group() == 0 begin
         say("Nu ai nicio competenta aleasa!")
         say("")
      end
      
      
      -- WARRIOR --
      when 50512.use with pc.get_job() == 0 and pc.get_skill_group() == 1 begin
         say_title("Alege o competenta:")
         say("")
         local mandi = select("Incizia Tripa","Vartejul Sabiei","Iures","Aura Sabiei","Izbitura","Inchide")
         if mandi == 1 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(1) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(1, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 2 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(2) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(2, 59)
               pc.remove_item(50512, 1)
            end   
         end            
         if mandi == 3 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(3) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(3, 59)
               pc.remove_item(50512, 1)
            end   
         end            
         if mandi == 4 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(4) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(4, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 5 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(5) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(5, 59)
               pc.remove_item(50512, 1)
            end
         end
      end
      when 50512.use with pc.get_job() == 0 and pc.get_skill_group() == 2 begin
         say_title("Alege o competenta:")
         say("")

         local mandi = select("Atacul Spiritului","Zdrobire","Zdruncinare","Corp Rezistent","Atacul Sabiei","Inchide")
         if mandi == 1 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(16) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(16, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 2 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(17) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(17, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 3 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(18) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(18, 59)
               pc.remove_item(50512, 1)
            end
         end            
         if mandi == 4 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(19) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(19, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 5 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(20) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(20, 59)
               pc.remove_item(50512, 1)
            end
         end
      end
      
      
      -- ASSASSIN --
      when 50512.use with pc.get_job() == 1 and pc.get_skill_group() == 1 begin
         say_title("Alege o competenta:")
         say("")
         local mandi = select("Ambuscada","Atac Mortal","Rulant","Camuflaj","Norul","Inchide")
         if mandi == 1 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(31) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(31, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 2 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(32) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(32, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 3 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(33) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(33, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 4 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(34) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(34, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 5 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(35) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(35, 59)
               pc.remove_item(50512, 1)
            end
         end
      end
      when 50512.use with pc.get_job() == 1 and pc.get_skill_group() == 2 begin
         say_title("Alege o competenta:")
         say("")
         local mandi = select("Foc repetat","Ploaie de Sageti","Sageata de Foc","Mers de Fulg","Sageata Otravita","Inchide")
         if mandi == 1 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(46) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(46, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 2 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(47) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(47, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 3 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(48) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(48, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 4 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(49) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(49, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 5 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(50) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(50, 59)
               pc.remove_item(50512, 1)
            end
         end
      end
      
      
      -- SURA --
      when 50512.use with pc.get_job() == 2 and pc.get_skill_group() == 1 begin
         say_title("Alege o competenta:")
         say("")
         local mandi = select("Lovitura Degetului","Vartejul Dragonului","Tais Vrajit","Teama","Armura Vrajita","Risipirea Magiei","Inchide")
         if mandi == 1 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(61) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(61, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 2 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(62) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(62, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 3 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(63) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(63, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 4 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(64) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(64, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 5 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(65) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(65, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 6 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(66) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(66, 59)
               pc.remove_item(50512, 1)
            end
         end
      end
      when 50512.use with pc.get_job() == 2 and pc.get_skill_group() == 2 begin
         say_title("Alege o competenta:")
         say("")
         local mandi = select("Lovitura Intunecata","Lovitura Focului","Spiritul Flacarii","Protectia Intunecata","Lovitura Spiritului","Sfera Intunecata","Inchide")
         if mandi == 1 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(76) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(76, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 2 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(1) >= 40 then
            else
               pc.set_skill_level(77, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 3 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(78) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(78, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 4 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(79) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(79, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 5 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(80) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(80, 59)
               pc.remove_item(50512, 1)
            end
         end
            if mandi == 6 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(81) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(81, 59)
               pc.remove_item(50512, 1)
            end
         end
      end
      
      
      -- SHAMAN --
      when 50512.use with pc.get_job() == 3 and pc.get_skill_group() == 1 begin
         say_title("Alege o competenta:")
         say("")
         local mandi = select("Talismant Zburator","Aruncarea Dragonului","Ragetul Dragonului","Binecuvantare","Reflexie","Forta Dragonului","Inchide")
         if mandi == 1 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(91) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(91, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 2 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(92) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(92, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 3 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(93) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(93, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 4 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(94) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(94, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 5 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(95) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(95, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 6 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(96) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(96, 59)
               pc.remove_item(50512, 1)
            end
         end
      end
      when 50512.use with pc.get_job() == 3 and pc.get_skill_group() == 2 begin
         say_title("Alege o competenta:")
         say("")
         local mandi = select("Aruncarea Fulgerului","Chemarea Fulgerului","Gheara Fulgerului","Leac","Accelerare","Atac Fortat","Inchide")
         if mandi == 1 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(106) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(106, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 2 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(107) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(107, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 3 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(108) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(108, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 4 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(109) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(109, 59)
               pc.remove_item(50512, 1)
            end
         end         
         if mandi == 5 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(110) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(110, 59)
               pc.remove_item(50512, 1)
            end
         end
         if mandi == 6 and pc.count_item(50512) >= 1 then
            if pc.get_skill_level(111) >= 40 then
               syschat("Aceasta competenta este deja P. Master!")
            else
               pc.set_skill_level(111, 59)
               pc.remove_item(50512, 1)
            end
         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

Poftim, incearca-l: quest-uri/curcubeu-t79227.html
Pentru acest mesaj, [RaffaeL] for the post:
DragonA7X
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
DragonA7X
Nivel 3

Nivel 3
Mesaje: 434
Membru din: 06 Apr 2017, 10:41
Aprecieri: 100  
Mulţumiri: 3  
Medalii

Multumesc Raffael, am sa il incerc de indata ce ajung acasa.

[ Postat de pe Android ] Imagine
Avatar utilizator
DragonA7X
Nivel 3

Nivel 3
Mesaje: 434
Membru din: 06 Apr 2017, 10:41
Aprecieri: 100  
Mulţumiri: 3  
Medalii

Am testat questul, dar nu imi functioneaza din cauza "say_albastru2" etc. Am incercat sa inlocuiesc fiecare say_albastru2 rosu etc cu say simplu iar cand dau sa folosesc itemu, nu se intampla nimic. Nu inteleg de ce.

Edit: Am reusit sa il fac sa functioneze, uitasem sa modific "say_title_center" in unu simplu. Imi place cum functioneaza questul, dar as vrea sa stiu daca pot modifica sa il fac sa o ia pe rand gen: M1, M2, M3 etc pana la P Master. Multumesc
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

DragonA7X scrie: ↑26 Sep 2019, 09:07 Am testat questul, dar nu imi functioneaza din cauza "say_albastru2" etc. Am incercat sa inlocuiesc fiecare say_albastru2 rosu etc cu say simplu iar cand dau sa folosesc itemu, nu se intampla nimic. Nu inteleg de ce.

Edit: Am reusit sa il fac sa functioneze, uitasem sa modific "say_title_center" in unu simplu. Imi place cum functioneaza questul, dar as vrea sa stiu daca pot modifica sa il fac sa o ia pe rand gen: M1, M2, M3 etc pana la P Master. Multumesc
Bineinteles ca se poate. Poftim: https://pastebin.ro/HaPqaxDFUC
Pentru acest mesaj, [RaffaeL] for the post:
DragonA7X
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
DragonA7X
Nivel 3

Nivel 3
Mesaje: 434
Membru din: 06 Apr 2017, 10:41
Aprecieri: 100  
Mulţumiri: 3  
Medalii

Functioneaza asa cum voiam. :-bd Mai trebuie adaugata o functie in care nu foloseste toate Pietrele Curcubeu deodata pentru o singura folosire pentru ca am testat acum si daca am 20 in inventar si vreau sa folosesc doar 1, dispar toate.

Edit: Am gasit functia pe care o cautam, tot dintr-un quest facut de tine. Am pus la ultima linie in loc de "item.remove" "pc.remove_item(50512, 1)" si functioneaza. La folosire acum dispare cate una. Multumesc mult pentru ajutor ^:)^ \:D/
Avatar utilizator
Ley
Nivel 9

Nivel 9
Mesaje: 1934
Membru din: 09 Feb 2017, 22:30
Server: Colossus2
Regat: Jinno
Aprecieri: 221  
Mulţumiri: 1338  
Medalii

Problemă rezolvată.
Imagine
Afișează semnătura
Închis
Răspunsuri
1
Vizualizări
280
Răspunsuri
1
Vizualizări
493
Răspunsuri
2
Vizualizări
651
Răspunsuri
4
Vizualizări
422

Înapoi la “Probleme rezolvate”

  • Informaţie
  • Cine este conectat

    Utilizatori ce ce navighează pe acest forum: Google [Bot] și 36 vizitatori