Results 1 to 4 of 4
  1. #1
    mijago
    mijago is offline
    Guest
    Join Date
    2013 Apr
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Rep Power
    0

    Create quests Metin2

    Well, I'm not a professional Quester, but teach it to those who do not know, be happy: D

    Come learn the basics of doing quests.
    Lately I've seen, both in skype as forum, people who need a lot of quests that are very simple.
    I come here to do a little tutorial on the basics of quests, for those unaware.

    The first thing we must know is that ALL quests start at:

    quest name begin

    Where to put the name in the name of the quest. So give the order to start the quest.

    After that, we proceed to the state.

    state start begin

    Now, let's see, quest serves to start the quest, and the state, serves to ... ?

    The state is a division of type quest, all quests in the initial state will always start and from there we can change the state to be able to perform various actions.

    And we continue to onset of action:

    When action begin

    In When there are several types of actions:
    - Button;
    - Enter;
    - Info;
    - Kill;
    - Leave;
    - Letter;
    - Levelup;
    - Login;
    - Logout;
    - Target;
    - Unmount;
    - Chat;
    - Click;
    - Use.

    Where are the most common:
    - Button;
    - Info;
    - Kill;
    - Letter;
    - Levelup;
    - Login;
    - Target;
    - Chat;
    - Click;
    - Use.

    Now, where do you usually use these kinds of when?

    If you look in quests biologist use up all these whens.
    But we'll focus more on login, because it will be used in the example.



    Come on then translate these first 3 lines of a quest:

    When you start the quest name, the state start begin, causing the action to start.

    Sounds complicated portuquês talking?

    Let's talk in question, in language. Honeymoon:

    Code:
    quest teste begin
    state start begin
      when login begin
       say("Vais mudar de state")
       set_state(aprender)
      end
    end
    state aprender begin
      when login begin
       say("Estás no state aprender")
      end
    end
    end
    Well, let's see a little bit.

    quest begin test
    Top of quest.

    state start begin
    Home state start.

    When login begin
    Start of when, this will cause the player character when they log in (when we teleportamos including a map) suffers an action.

    say ("You'll change your state")
    It is the action that the player will suffer when logs.

    set_state (learn)
    Change to state that the player suffers another action.

    end
    Closed when.

    end
    Closed state.

    state learning begin
    Home of the new state that we did.

    When login begin
    Start of when, this will cause the player character when they log in (when we teleportamos including a map) suffers an action different from the action of the state start.

    say ("You learn in state")
    It is the action that the player will learn to suffer in the state.

    end
    Closed when.

    end
    Closed state.

    end
    Closing the quest.


    Easy?
    So, let's proceed.

    Is there anyway to change state between quests?

    Yes, the function set_quest_state ("nome_da_quest", "nome_do_state").
    Consider:

    Code:
    quest teste4 begin
    state start begin
      when 9010.chat."Ae" begin
       say("Ae cara")
       set_quest_state("teste5", "hi")
      end
    end
    end
    Code:
    quest teste5 begin
    state start begin
      when 9003.chat."Olá" begin
       say("Olá")
       set_state(hi)
      end
    end
    state hi begin
      when 9001.chat."Hi" begin
       say("Hello, nice to meet you!")
      end
    end
    end
    What will happen here?

    When the npc 9010 and click on the option Ae, a message will appear saying Ae guy and will switch to state hi, teste5 quest that will cause the npc go to 9001 and click on the option Hi, the message Hello, nice to meet you!

    It's simple!
    That is, the state hi will only be activated when the end test4 quest!

    What are the ends?

    Like give begin to start something, in the end close.

    How do we know how to put on a quest ends?

    It is simple and easy, so a quest to work, plus a good syntax, needs to be properly closed.
    That said, watching the quest, we can deduce that:

    - The quest, state and When are mandatory bring an end forever.
    That is, in all quests always necessary, the third end, these three are required!

    One for the quest, one for the state and one for when.
    Besides these, if also the lead end, always!

    For example:
    Code:
    quest aprender begin
    state start begin
      when login begin
       say("Já sei usar os ends")
      end -> end do when
    end -> end do state
    end  -> end da quest
    Simple, no?

    And if you want to use 2 When a quest, I always have to change state?

    No, not always, only when a player suffers an action say, quite different from the first, ie, if it is to put in several npc When, for example, to open multiple stores, so before getting a second when, would have to close the first.
    That is:
    Code:
    quest teste2 begin
    state start begin
      when 9003.chat."The End" begin
       say("Oi")
      end -> end do primeiro when
      when 9003.chat."The End2" begin
       say("Adeus")
      end -> end do segundo when
    end -> end do state
    end -> end da quest
    And the same goes for the state, but not with the quest because the quest includes all this, if you close a quest, you can not add another in the same document.

    Structure of a quest

    This can be as you like, but if in doubt we advise ends to put to use what I use:
    This way we know what we're close.

    That's it!
    Any doubt and say if they want another day, another topic of these, let us know!

    I hope I have been explicit.

  2. #2
    Seratbzw
    Seratbzw is offline
    New member
    Join Date
    2013 Apr
    Posts
    16
    Thanks
    0
    Thanked 1 Time in 1 Post
    Rep Power
    0
    Jeah its really helpful for me, cause i started to writing quests, but i had need some help and now i got these.

  3. #3
    P.o.X
    P.o.X is offline
    Member-in-training P.o.X's Avatar
    Join Date
    2012 May
    Posts
    64
    Thanks
    11
    Thanked 11 Times in 7 Posts
    Rep Power
    0
    i`m pro at creating quests,this language seems to be lua programming,if u learn lua u can do this easy.

  4. #4
    Sparkk
    Sparkk is offline
    New member Sparkk's Avatar
    Join Date
    2013 Sep
    Location
    Marseille, France
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Rep Power
    0
    Effectively, the programming language is the famous Lua known in several games such as Half-Life, Garry's Mod, ...
    I'm also experimented in this language and if anoyone needs help, I will be able to help you with anything you need, unless it's limited to the possible.

    Writing quests will not be easy when you don't know any language, so you should learn Lua basics before you can go make quests.
    Last edited by Sparkk; 2013-10-29 at 01:23 AM.

Similar Threads

  1. [Info] quests epic3 (up lvl)
    By thidi in forum Aika Online
    Replies: 1
    Last Post: 2013-01-24, 08:30 PM
  2. Replies: 2
    Last Post: 2012-09-05, 01:34 AM
  3. [Metin2]metin2client.bin,metin2.bin decrypt request
    By P.o.X in forum Research Requests
    Replies: 2
    Last Post: 2012-05-27, 12:45 AM
  4. [Info] Pack of quests
    By Proaikagamer in forum Aika Online
    Replies: 13
    Last Post: 2012-01-13, 07:28 AM
  5. [Release] DmgMod for Metin2
    By Dantes999 in forum Metin2
    Replies: 7
    Last Post: 2011-12-06, 11:30 PM
Visitors found this page by searching for:

metin2 programming quest

how to create quest in metin2

metin2 codes in the quest

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •