Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

ImmortalDreams

Members
  • Posts

    19
  • Joined

  • Last visited

    Never

Posts posted by ImmortalDreams

  1. Hey everyone. I spent some time today editing the source for Eclipse Stable. I fixed the bug where the magic and speed stats got switched, and I made it so the menu music loops. It's available below. Also, I put together another zip with some extra resources I had on hand. Firstly, there are the Eclipse Library Installers.

    I also included:

    1. A list of the Eclipse Evolution Commands.
    2. A list of several sadscript commands for a quick reference.
    3. A Main.ess file with a bunch of extra scripts that were only available on the old website.

    So here you go:

    [Eclipse-Stable.zip](https://dl-web.dropbox.com/get/Eclipse%20Stable/Eclipse-Stable.zip?_subject_uid=274547289&w=AAB_G2uydHypJRZL4q4YQB5WqgQCp1CZ1NvLl_VmAgN7Fw&dl=1)

    [ES Extra.zip](https://dl-web.dropbox.com/get/Eclipse%20Stable/ES%20Extra.zip?_subject_uid=274547289&w=AAAYKO5mWWqPt6DC7jpRoZxs9gjanMkoSmqyThhX6J6iyw&dl=1)

    I was wondering if anyone would be interested in seeing some ES tutorials for things like making a skill system and quests. I made both of those already in the past. Please let me know if you are. Thanks again Crest for uploading ES and EE.
  2. I didn't know anyone besides me still used any of the older versions. I'm seriously thinking about remaking my game with EO, but it's such a long wait until the next one comes out. Plus I made custom quest and skill systems, not to mention tons of other edits in ES.
  3. One thing I dislike about EO and its predesessors is the way the spell system is organized. You can only have a certain amount of spells stored before you have to get rid of some, and they're all in one messy list.

    Personally, I think it would make more sense if there were customizable Spell/Skill categories. That way, someone could have categories for magic oriented skills(spells) as well as other kinds of skills(eg. item related).
  4. > We just don't want to get to the point where most of the other engines have gotten to in that they're almost pre-made games and no one even bothers editing them to try and create a unique game anymore.

    True, but good quests can mean the difference between a unique game and a clone. The results depend on the designer of course.
  5. > So quest log for event system…

    Something like that.

    > We haven't planned out what a potential quest system would be like. One thing I can say for sure is that the current event editor will not be in this version of Eclipse.

    Okay, but I think Eclipse is a bit overdue for a built in quest system.
  6. ScriptedTile:
    ```
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Module: ScriptedTile.ess '
    ' Author: Stephan J.R. van Schaik '
    ' Date: August 30th, 2009. '
    ' Version: 1.0.0 '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Function: ScriptedTile '
    ' Brief: executes when somebody steps on the tile. '
    ' Parameters: '
    ' Index: the index of the player. '
    ' Script: the script to execute. '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    Sub ScriptedTile(Index, Script)
    Select Case Script
    Case 0
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming", "0")

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking", "0")

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Necromancy", "0")
    Exit Sub

    Case 1
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting", "1")
    Call PlayerMsg(Index, "You enter a smelting area.", WHITE)
    Exit Sub

    Case 2
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing", "1")
    Call PlayerMsg(Index, "You enter a smithing area.", WHITE)
    Exit Sub

    Case 3
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking", "1")
    Call PlayerMsg(Index, "You enter a cooking area.", WHITE)
    Exit Sub

    Case Else
    Call PlayerMsg(Index, "No tile script found. Please contact an admin to solve this problem.", WHITE)

    Exit Sub
    End Select
    End Sub

    ```

    So yeah. As you can see, this was a lot of work, and aside from using cloudwolf's quest maker in part, I did this all by myself. I'd hate to see it all go to waste so if anyone can give me some tips or point me in the right direction I would be very grateful.
  7. ScriptedNPC(I apologize for any out of place comments):
    ```
    Sub ScriptedNPC(Index, Script)
    Select Case Script

    'Quest script created using cloudwolf00s Quest Maker (cloudwolf00s Quest Maker is © cloudwolf00 2010)
    'You may not remove this or the above credit!
    Case 0
    Call PlayerMsg(Index, "No NPC script found. Please contact an admin to solve this problem.", WHITE)
    Exit Sub

    'Quest script created using cloudwolf00s Quest Maker (cloudwolf00s Quest Maker is © cloudwolf00 2010)
    'You may not remove this or the above credit!
    Case 1
    'If the player has not started the quest, start the quest for them. This also prevents errors occuring in the script later on
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest1" ) = vbNullString Then

    'Start the quest for the player by setting their status to 0
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest1", "0")

    End If

    'If the player has not started the quest yet
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest1" ) = "0" Then

    'The player has now started the quest - show the start quest message
    text = "Drunk Dunk: I bet you's jes a stink'n newbie 'hic!'" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Am not!" & vbNewLine & vbNewLine & "Drunk Dunk: Prove it or I'll go get drunk again!" & vbNewLine & vbNewLine & GetPlayerName(Index) & " : You're already drunk." & vbNewLine & vbNewLine & "Drunk Dunk: Am not!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Whatever." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": So, how can I prove I'm not a newbie?" & vbNewLine & vbNewLine & "Drunk Dunk: Brink meh back 5 monster eyes."
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    'The player started the quest - set their status to 1
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest1", "1")

    'If the player has started the quest and needs to attempt to finish it
    ElseIf GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest1" ) = "1" Then

    'If the player has the needed item
    If CanTake(Index, 41, 5) = True Then

    'Take the needed item
    Call TakeItem(Index, 41, 5)
    text = "Drunk Dunk: Wha-- yer not a newbie? 'grr!' I guess I owes you this much. 'hic!'" & vbNewLine & vbNewLine & "Drunk Dunk: 'eres yer stink'n XP!" & vbNewLine & vbNewLine & "You get 100 XP!"
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "")

    'Give the player exp
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 100)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    Total = GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Total" )
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Total", Total + 1)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest1", "2")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "")

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name1")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name2")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name3")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name4")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name5")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name6")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name7")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name8")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name9")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name10")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name11")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name12")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name13")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name14")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name15")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name16")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17", "We all hate Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2","Name17")
    End If

    Else

    'The player does not have the item
    text = "Drunk Dunk: Where's me monster eyes?!"
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    End If

    End If

    'If the player has the needed item
    If CanTake(Index, 46, 1) = True Then

    'Take the needed item
    Call TakeItem(Index, 46, 1)
    text = "Drunk Dunk: Who're you?" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": I got you something awesome to put in your beer." & vbNewLine & vbNewLine & "Drunk Dunk: Gimme dat!" & vbNewLine & vbNewLine & "Drunk Dunk drinks the sleeping potion." & vbNewLine & vbNewLine & "Drunk Dunk: Thishh shhtuff is amashhing! 'gulp' Ahh... Shhooo is 'dere more?" & vbNewLine & vbNewLine & "You wait for a long time but Drunk Dunk doesn't fall asleep." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": I have to go see Martie."
    Call CustomMenuShow(Index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest3", "3")
    End If

    'If the player has not started the quest, start the quest for them. This also prevents errors occuring in the script later on
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest7" ) = vbNullString Then

    'Start the quest for the player by setting their status to 0
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest7", "0")

    End If

    'If the player has not started the quest yet
    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest7" ) = "0") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest6" ) = "3") Then

    'The player has now started the quest - show the start quest message
    text = "Drunk Dunk: Oh the misery of life!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Why are you so misserable?" & vbNewLine & vbNewLine & "Drunk Dunk: I lost it all. I used to be an explorer ya know." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Really?" & vbNewLine & vbNewLine & "Drunk Dunk: Had a family, every reason for living, then they all went away." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": What do you mean by went away?" & vbNewLine & vbNewLine & "Drunk Dunk: They just went away!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Are you drunk again?" & vbNewLine & vbNewLine & "Drunk Dunk: I'm alway's drunk!"
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    'The player started the quest - set their status to 1
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest7", "1")
    End If

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest10" ) = "0") or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest10" ) = "4") Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = "7" Then
    Call GiveCurrency(Index, 59, 1)

    text = GetPlayerName(Index) & ": Hand it over." & vbNewLine & vbNewLine & "Drunk Dunk: What I hand over? 'hic!'" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": The locket." & vbNewLine & vbNewLine & "Drunk Dunk: My shiney!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Aha! So you did steal it! And it's not your shiney. It belongs to the twins." & vbNewLine & vbNewLine & "Drunk Dunk: But it's my shiney!!!" & vbNewLine & vbNewLine & "You put out your hand and he grudgingly gives you the locket."
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14", "8")
    End If
    End If

    Exit Sub

    'Quest script created using cloudwolf00s Quest Maker (cloudwolf00s Quest Maker is © cloudwolf00 2010)
    'You may not remove this or the above credit!
    Case 2
    'If the player has not started the quest, start the quest for them. This also prevents errors occuring in the script later on
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest2" ) = vbNullString Then

    'Start the quest for the player by setting their status to 0
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest2", "0")

    End If

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest2" ) = "0" And GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest1" ) = "2" Then

    'The player has now started the quest - show the start quest message
    text = "Martie: Drunk Dunk over there has been a real pain lately. Me and my customers would like it if he would be quiet more often. Please go to Ashly at the marketplace and ask for a sleeping potion, then come back here and give it to Drunk Dunk."
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    'The player started the quest - set their status to 1
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest2", "1")

    'If the player has started the quest and needs to attempt to finish it
    ElseIf GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest2" ) = "1" Then

    'If the player has given Drunk Dunk the potion
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest3" ) = "3" Then

    'Give the player the stackable reward item
    Call GiveCurrency(Index, 1, 25)
    'Give the player exp
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 250)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    text = "Martie: It didn't work? Oh well. I guess I owe you this." & vbNewLine & vbNewLine & "You get 250 XP!"
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    'The player has completed the quest - set their status to 2
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest2", "2")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q2" ), "")
    Total = GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Total" )
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Total", Total + 1)

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name1")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name2")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name3")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name4")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name5")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name6")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name7")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name8")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name9")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name10")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name11")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name12")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name13")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name14")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name15")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name16")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17", "The Missing Locket")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14","Name17")
    End If

    Else
    'The player is now doing the quest - show the during quest message
    text = "Martie: Did you get that sleeping potion from Ashly?"
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    End If

    End If

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest7" ) = "1") And Not (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = 0) And Not (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = "2") And Not (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = "4") And Not (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = "9") And Not (text = "Martie: You seem to be a reliable help. I wouldn't mind some myself. Well, It's my twin daughters actually. You may have seen them. Their names are Ashly and Amanda and they've refused to talk to each other for three years! I don't know why and they won't tell me. Please ask them what happened three years ago and tell me.") And Not (text = "Martie: Oh, the locket. It was very special to them. It seemed to keep their mother with them. No wonder they despise each other. It's strange that their stories contridict each other. Please, try to convince them that it's neither of their faults. It must have just gotten lost.") And Not (text = "Martie: It didn't work?! Oh what am I going to do with those two?...") And Not (text = "Martie: Oh thank you so very much " & GetPlayerName(Index) & "! You deserve a handsome reward for this!" & vbNewLine & vbNewLine & "You get 500 coins and 250 XP!") Then
    text = GetPlayerName(Index) & ": What's up with Drunk Dunk?" & vbNewLine & vbNewLine & "Martie: Ah, it's a sad story it is." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": He says his wife and children went away. Where'd they go?" & vbNewLine & vbNewLine & "Martie: To the next world. Him and his family were traveling through Gregory's Woods when something killed them. Loosing his wife and children drove him insane. We still don't know what happened that night." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": What do you think happened?" & vbNewLine & vbNewLine & "Martie: How should I know? The only way to find out for sure would be to go to those woods but you wouldn't live through it."
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest7", "2")
    End If

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = vbNullString Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14", "0")
    End If

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest10" ) = "0") or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest10" ) = "4") Then

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = "0") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest2" ) = "2") And Not (text = "Martie: It didn't work? Oh well. I guess I owe you this." & vbNewLine & vbNewLine & "You get 250 XP!") And Not (text = "Drunk Dunk: Oh the misery of life!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Why are you so misserable?" & vbNewLine & vbNewLine & "Drunk Dunk: I lost it all. I used to be an explorer ya know." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Really?" & vbNewLine & vbNewLine & "Drunk Dunk: Had a family, every reason for living, then they all went away." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": What do you mean by went away?" & vbNewLine & vbNewLine & "Drunk Dunk: They just went away!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Are you drunk again?" & vbNewLine & vbNewLine & "Drunk Dunk: I'm alway's drunk!") Then
    text = "Martie: You seem to be a reliable help. I wouldn't mind some myself. Well, It's my twin daughters actually. You may have seen them. Their names are Ashly and Amanda and they've refused to talk to each other for three years! I don't know why and they won't tell me. Please ask them what happened three years ago and tell me."
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14", "1")
    End If

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = "2" Then
    text = "Martie: Oh, the locket. It was very special to them. It seemed to keep their mother with them. No wonder they despise each other. It's strange that their stories contridict each other. Please, try to convince them that it's neither of their faults. It must have just gotten lost."
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14", "3")
    End If

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = "4" Then
    text = "Martie: It didn't work?! Oh what am I going to do with those two?..."
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14", "5")
    End If

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14" ) = "9" Then
    text = "Martie: Oh thank you so very much " & GetPlayerName(Index) & "! You deserve a handsome reward for this!" & vbNewLine & vbNewLine & "You get 500 coins and 250 XP!"
    Call CustomMenuShow(index, "Speech", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 0, text, 0, 0, 8, 1, 0, 286, 315)

    Call GiveCurrency(Index, 1, 500)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 250)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest14", "10")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q14" ), "")
    Total = GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Total" )
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Total", Total + 1)
    End If

    End If
    Exit Sub
    ```
    etc… it ran out of room
  8. ScriptedItem:
    ```
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Module: ScriptedItem.ess '
    ' Author: Stephan J.R. van Schaik '
    ' Date: August 30th, 2009. '
    ' Version: 1.0.0 '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Function: ScriptedItem '
    ' Brief: executes when somebody uses an item. '
    ' Parameters: '
    ' Index: the index of the player. '
    ' Script: the script to execute. '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    Sub ScriptedItem(Index, Script, Slot)
    Select Case Script
    Case 0
    Call PlayerMsg(Index, "This scripted item has no apparent use.", WHITE)

    Exit Sub

    Case 1
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 6)

    Call PlayerMsg(Index, "You learn Air Breeze!", WHITE)
    Call TakeItem(Index, 42, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 2
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 7)

    Call PlayerMsg(Index, "You learn Water Breeze!", WHITE)
    Call TakeItem(Index, 43, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 3
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 8)

    Call PlayerMsg(Index, "You learn Earth Breeze!", WHITE)
    Call TakeItem(Index, 44, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 4
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 9)

    Call PlayerMsg(Index, "You learn Fire Breeze!", WHITE)
    Call TakeItem(Index, 45, 1)

    Else
    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 5
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 10)

    Call PlayerMsg(Index, "You learn Air Wave!", WHITE)
    Call TakeItem(Index, 66, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 6
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 11)

    Call PlayerMsg(Index, "You learn Water Wave!", WHITE)
    Call TakeItem(Index, 67, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 7
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 12)

    Call PlayerMsg(Index, "You learn Earth Wave!", WHITE)
    Call TakeItem(Index, 68, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 8
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 13)

    Call PlayerMsg(Index, "You learn Fire Wave!", WHITE)
    Call TakeItem(Index, 69, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 9
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 14)

    Call PlayerMsg(Index, "You learn Air Shift!", WHITE)
    Call TakeItem(Index, 70, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 10
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 15)

    Call PlayerMsg(Index, "You learn Water Shift!", WHITE)
    Call TakeItem(Index, 71, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 11
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 16)

    Call PlayerMsg(Index, "You learn Earth Shift!", WHITE)
    Call TakeItem(Index, 72, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 12
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 17)

    Call PlayerMsg(Index, "You learn Fire Shift!", WHITE)
    Call TakeItem(Index, 73, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 13
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 18)

    Call PlayerMsg(Index, "You learn Air Flare!", WHITE)
    Call TakeItem(Index, 74, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 14
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 19)

    Call PlayerMsg(Index, "You learn Water Flare!", WHITE)
    Call TakeItem(Index, 75, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 15
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 20)

    Call PlayerMsg(Index, "You learn Earth Flare!", WHITE)
    Call TakeItem(Index, 76, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub

    Case 16
    'If the player can learn the spell
    If CanPlayerLearnSpell(Index) = True Then

    'Learn the spell
        Call PlayerLearnSpell(Index, 21)

    Call PlayerMsg(Index, "You learn Fire Flare!", WHITE)
    Call TakeItem(Index, 77, 1)

    Else

    Call PlayerMsg(Index, "You can't learn any more spells!", RED)

    End If
    Exit Sub
    Case 17
    Call SetPlayerSPEED(Index, +2)
    End Select
    End Sub

    ```
  9. PlayerLevelUp:
    ```
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Module: PlayerLevelUp.ess '
    ' Author: Stephan J.R. van Schaik '
    ' Date: August 30th, 2009. '
    ' Version: 1.0.0 '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Function: PlayerLevelUp '
    ' Brief: executes when a player levels up. '
    ' Parameters: '
    ' Index: the index number of the player. '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    Sub PlayerLevelUp(Index)
    Dim PlayerExp

    If GetPlayerExp(Index) < GetPlayerNextLevel(Index) Then
    Exit Sub
    End If

    Do While GetPlayerExp(Index) >= GetPlayerNextLevel(Index)
    PlayerExp = GetPlayerNextLevel(Index)

    Call PlaySound(Index, "level_up.mp3")
    Call SetPlayerPOINTS(Index, GetPlayerPOINTS(Index) + 1)
    Call SetPlayerExp(Index, GetPlayerExp(Index) - PlayerExp)
    Call SetPlayerHP(Index, GetPlayerMaxHP(Index))
    Call SetPlayerMP(Index, GetPlayerMaxMP(Index))
    Call SetPlayerSP(Index, GetPlayerMaxSP(Index))
    Call SendPlayerData(Index)
    Call SendStats(Index)
    Call SendHP(Index)
    Call SendMP(Index)
    Call SendSP(Index)
    Call SendPTS(Index)
    Loop

    If GetPlayerLevel(Index) = 5 Then

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name1")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name2")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name3")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name4")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name5")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name6")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name7")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name8")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name9")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name10")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name11")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name12")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name13")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name14")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name15")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name16")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17", "Find Sarah")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q6","Name17")
    End If
    End If

    If GetPlayerLevel(Index) = 10 Then

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name1")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name2")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name3")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name4")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name5")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name6")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name7")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name8")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name9")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name10")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name11")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name12")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name13")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name14")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name15")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name16")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17", "Potion Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q10","Name17")
    End If

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name1")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name2")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name3")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name4")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name5")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name6")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name7")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name8")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name9")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name10")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name11")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name12")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name13")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name14")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name15")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name16")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17", "Sword Making")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q11","Name17")
    End If

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name1")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name2")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name3")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name4")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name5")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name6")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name7")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name8")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name9")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name10")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name11")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name12")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name13")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name14")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name15")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name16")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17", "Meet Lillian")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q17","Name17")
    End If
    End If

    If GetPlayerLevel(Index) = 15 Then

    If (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name1")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name2")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name3")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name4")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name5")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name6")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name7")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name8")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name9")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name10")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name11")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name12")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name13")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name14")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name15")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name16", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name16")

    ElseIf (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = "") Or (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17" ) = vbNullString) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name17", "A Poisonous Mistake")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Q18","Name17")
    End If
    End If
    End Sub

    ```
  10. OnNPCDeath(Some more quest stuff):
    ```
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Module: OnNPCDeath.ess '
    ' Author: Stephan J.R. van Schaik '
    ' Date: August 30th, 2009. '
    ' Version: 1.0.0 '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Function: OnNPCDeath '
    ' Brief: executes when an NPC dies. '
    ' Parameters: '
    ' Index: the index of the player who killed the NPC. '
    ' Map: the map the NPC died on. '
    ' NPC: the NPC number. '
    ' MapNPC: the MapNPC number. '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    Sub OnNPCDeath(Index, Map, NPC, MapNPC)
    Call BattleMsg(Index, "You killed a " & GetNPCName(NPC) & ".", BRIGHTRED, LEFT)

    If NPC = 38 Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest13" ) = "1" Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest13", "2")
    Call BattleMsg(Index, "Defeated 1/1 Kruckalens.", YELLOW, LEFT)
    End If
    End If

    If NPC = 39 Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest15" ) > "7" Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest15", GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest15" ) + 1)
    Quest15Kills = GetVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest15")
    Call BattleMsg(Index, "Defeated " & Quest15Kills  - 1 & "/5 Ogers.", YELLOW, LEFT)
    ElseIf Not GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest15" ) = "7" Then
    Call BattleMsg(Index, "Defeated 5/5 Ogers.", YELLOW, LEFT)
    End If
    End If
    End Sub

    ```
  11. OnNewChar(Includes some quest stuff):
    ```
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Module: OnNewChar.ess '
    ' Author: Stephan J.R. van Schaik '
    ' Date: August 30th, 2009. '
    ' Version: 1.0.0 '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Function: OnNewChar '
    ' Brief: executes when a player creates a new character. '
    ' Parameters: '
    ' Index: the index number of the player. '
    ' CharNum: the number of the created character. '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    Sub OnNewChar(Index, CharNum)
    Call GiveCurrency(Index, 1, 25)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Total", "0")

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking", "0")
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Necromancy", "0")

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Mining", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Mining", "Next_Level",90)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Mining", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Mining", "TotalXP", 0)

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Fishing", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Fishing", "Next_Level", 90)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Fishing", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Fishing", "TotalXP", 0)

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Farming", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Farming", "Next_Level", 90)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Farming", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Farming", "TotalXP", 0)

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Smithing", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Smithing", "Next_Level", 120)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Smithing", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Smithing", "TotalXP", 0)

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Crafting", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Crafting", "Next_Level", 120)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Crafting", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Crafting", "TotalXP", 0)

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "Next_Level", 120)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "TotalXP", 0)

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Herbalist", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Herbalist", "Next_Level", 120)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Herbalist", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Herbalist", "TotalXP", 0)

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Enchant", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Enchant", "Next_Level", 120)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Enchant", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Enchant", "TotalXP", 0)

    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Necromancy", "Level", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Necromancy", "Next_Level", 380)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Necromancy", "XP", 0)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Necromancy", "TotalXP", 0)

    'Set Default Quest Status(the color) to red
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14_Status", 12)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15_Status", 12)

    'Any class quests
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1", "Meet Drunk Dunk")
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2", "Meet Aggie")

    If GetPlayerClass(Index)=0 Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Max", "500")
    'Squire only quests
    End If

    If GetPlayerClass(Index)=1 Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Max", "500")
    End If
    End Sub

    ```
  12. MenuScripts(includes my skill system and some quest stuff):
    ```
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Module: MenuScripts.ess '
    ' Author: Stephan J.R. van Schaik '
    ' Date: August 30th, 2009. '
    ' Version: 1.0.0 '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    ' Function: MenuScripts '
    ' Brief: executes when a player clicks on a custom menu. '
    ' Parameters: '
    ' Index: the index number of the player who clicked. '
    ' ElementIndex: the index number of the clicked element. '
    ' ElementType: the type of the clicked element. '
    '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
    Sub MenuScripts(Index, ElementIndex, ElementType)
    Dim MenuTitle
    Dim FieldMessage

    MenuTitle = GetPlayerMenuClickTitle(Index)
    FieldMessage = GetPlayerMenuClickMsg(Index)

    Call PutCharVar(Index, "Menu", "Title", MenuTitle)

    Select Case MenuTitle
    Case "hello"
    Select Case ElementType
    Case ELEMENT_PICTURE
    Call PlayerMsg(Index, "You clicked on picture number " & ElementIndex & "!", YELLOW)

    Case ELEMENT_FIELD
    Call PlayerMsg(Index, "You clicked on field number " & ElementIndex & "!", YELLOW)

    Case ELEMENT_LABEL
    Call PlayerMsg(Index, "You clicked on label number " & ElementIndex & "!", YELLOW)

    Case Else
    Call PlayerMsg(Index, "Unknown element type!", BRIGHTRED)
    End Select

    Case "Quest8"
    Select Case ElementType
    Case ELEMENT_PICTURE
    If ElementIndex = 1 Then
    Call CustomMenuClose(Index)
    text = "Jess: You've gota know! Everyone should know!" & vbNewLine & vbNewLine & "Mr. O'Riley: It's those woods. Gregory's Woods you call 'em. Ever since that creepy hermit Gregory moved there five years ago, we've been getting  a heck lot more monsters around here." & vbNewLine & vbNewLine & "Jess: I swear to god they must have come from the Dark Realm itself!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Are you accusing Gregory of bringing the monsters here?" & vbNewLine & vbNewLine & "Mr. O'Riley: Hell yeah! Who else? They all showed up around the same time." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": But I met Gregory! He didn't seem so bad." & vbNewLine & vbNewLine & "Mr. O'Riley/Jess: YOU MET HIM?!!" & vbNewLine & vbNewLine & "Jess: Maybe yer contaminated!"
    Call CustomMenuShow(index, "Quest8_2", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 2, text, 0, 0, 8, 1, 0, 286, 315)
    Call CustomMenuPicture(index, 0, "\GUI\Button_Previous.bmp", 10, 275)
    Call CustomMenuPicture(index, 1, "\GUI\Button_Next.bmp", 245, 275)
    End If
    End Select

    Case "Quest8_2"
    Select Case ElementType
    Case ELEMENT_PICTURE
    If ElementIndex = 0 Then
    Call CustomMenuClose(Index)
    text = "Jess: Hey daddy, it's one of them city folks!" & vbNewLine & vbNewLine & "Mr. O'Riley: About time they sent someone out here. We've been waiting long enough." & vbNewLine & vbNewLine & "Jess: That's an understatement." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": What's the big deal? I come from Caderlene, sure, but--" & vbNewLine & vbNewLine & "Jess: You hear that daddy? This one's from the capital!" & vbNewLine & vbNewLine & "Mr. O'Riley: Thank the lord! Our salvation is at hand!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": WHOA! Slow down guys. What's going on?" & vbNewLine & vbNewLine & "They stare at you blankly for awhile." & vbNewLine & vbNewLine & "Mr. O'Riley: You mean you don't know?"
    Call CustomMenuShow(index, "Quest8", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 2, text, 0, 0, 8, 1, 0, 286, 315)
    Call CustomMenuPicture(index, 1, "\GUI\Button_Next.bmp", 245, 275)
    End If

    If ElementIndex = 1 Then
    Call CustomMenuClose(Index)
    text = "Mr. O'Riley: or insane!" & vbNewLine & vbNewLine & "Jess: Or maybe yer---" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Shut up! Just shut up!" & vbNewLine & vbNewLine & "They stop talking." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Now what can I do that will put you at ease?" & vbNewLine & vbNewLine & "Mr. O'Riley: Make 'em leave and make sure 'e never comes back!"
    Call CustomMenuShow(index, "Quest8_3", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 2, text, 0, 0, 8, 1, 0, 286, 315)
    Call CustomMenuPicture(index, 0, "\GUI\Button_Previous.bmp", 10, 275)
    End If

    End Select

    Case "Quest8_3"
    Select Case ElementType
    Case ELEMENT_PICTURE
    If ElementIndex = 0 Then
    Call CustomMenuClose(Index)
    text = "Jess: You've gotta know! Everyone should know!" & vbNewLine & vbNewLine & "Mr. O'Riley: It's those woods. Gregory's Woods you call 'em. Ever since that creepy hermit Gregory moved there five years ago, we've been getting  a heck lot more monsters around here." & vbNewLine & vbNewLine & "Jess: I swear to god they must have come from the Dark Realm itself!" & vbNewLine & vbNewLine & GetPlayerName(Index) & ": Are you accusing Gregory of bringing the monsters here?" & vbNewLine & vbNewLine & "Mr. O'Riley: Hell yeah! Who else? They all showed up around the same time." & vbNewLine & vbNewLine & GetPlayerName(Index) & ": But I met Gregory! He didn't seem so bad." & vbNewLine & vbNewLine & "Mr. O'Riley/Jess: YOU MET HIM?!!" & vbNewLine & vbNewLine & "Jess: Maybe yer contaminated!"
    Call CustomMenuShow(index, "Quest8_2", "\GUI\Quest.bmp", 1)
    Call CustomMenuLabel(Index, 2, text, 0, 0, 8, 1, 0, 286, 315)
    Call CustomMenuPicture(index, 0, "\GUI\Button_Previous.bmp", 10, 275)
    Call CustomMenuPicture(index, 1, "\GUI\Button_Next.bmp", 245, 275)
    End If
    End Select

    Case "Skills"
    Select Case ElementType
    Case ELEMENT_PICTURE

    If ElementIndex = 5 Then
    Call CustomMenuLabel(Index, 19, "Cooking", 104, 8, 8, 7, 0, 286, 315)
    Call CustomMenuLabel(Index, 23,"Level: " & GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "Level"), 104, 30, 7, 7, 0, 286, 315)
    Call CustomMenuLabel(Index, 37,"XP: " & GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP") & "/" & GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "Next_Level"), 104, 50, 7, 7, 0, 286, 315)
    Call CustomMenuLabel(Index, 38,"Total XP: " & GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "TotalXP"), 104, 70, 7, 7, 0, 286, 315)

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2" Then
    Call CustomMenuClose(Index)
    Call CustomMenuShow(Index, "Skills", "\GUI\Skills.bmp", 1)

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "1") And (CanTake(Index, 6, 1)) Then
    Call CustomMenuPicture(Index, 1, "\GUI\Skills\Mining\Button_Mining.bmp", 0, 0)
    Else
    Call CustomMenuPicture(Index, 1, "\GUI\Skills\Mining\Button_Null_Mining.bmp", 0, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 2, "\GUI\Skills\Fishing\Button_Fishing.bmp", 0, 32)
    Else
    Call CustomMenuPicture(Index, 2, "\GUI\Skills\Fishing\Button_Null_Fishing.bmp", 0, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 4, "\GUI\Skills\Farming\Button_Farming.bmp", 0, 64)
    Else
    Call CustomMenuPicture(Index, 4, "\GUI\Skills\Farming\Button_Null_Farming.bmp", 0, 64)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "1") Or (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11" ) >= "2") Then
    Call CustomMenuPicture(Index, 3, "\GUI\Skills\Smith\Button_Smith.bmp", 32, 0)
    Else
    Call CustomMenuPicture(Index, 3, "\GUI\Skills\Smith\Button_Null_Smith.bmp", 32, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 18, "\GUI\Skills\Craft\Button_Craft.bmp", 32, 32)
    Else
    Call CustomMenuPicture(Index, 18, "\GUI\Skills\Craft\Button_Null_Craft.bmp", 32, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 5, "\GUI\Skills\Cook\Button_Cook.bmp", 32, 64)
    Else
    Call CustomMenuPicture(Index, 5, "\GUI\Skills\Cook\Button_Null_Cook.bmp", 32, 64)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "0") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest10" ) >= "2") Then
    Call CustomMenuPicture(Index, 22, "\GUI\Skills\Herbalist\Button_Herbalist.bmp", 64, 0)
    Else
    Call CustomMenuPicture(Index, 22, "\GUI\Skills\Herbalist\Button_Null_Herbalist.bmp", 64, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "0") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest170" ) >= "2") Then
    Call CustomMenuPicture(Index, 20, "\GUI\Skills\Enchant\Button_Enchant.bmp", 64, 32)
    Else
    Call CustomMenuPicture(Index, 20, "\GUI\Skills\Enchant\Button_Null_Enchant.bmp", 64, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Necromancy" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 21, "\GUI\Skills\Necromancy\Button_Necromancy.bmp", 64, 64)
    Else
    Call CustomMenuPicture(Index, 21, "\GUI\Skills\Necromancy\Button_Null_Necromancy.bmp", 64, 64)
    End If

    If GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "1" Then

    If CanTake(Index, 56, 1) = True Then
    Call CustomMenuPicture(Index, 30, "\GUI\Skills\Cook\Button_Fish.bmp", 0, 96)
    Else
    Call CustomMenuPicture(Index, 30, "\GUI\Skills\Cook\Button_Null_Fish.bmp", 0, 96)
    End If

    If CanTake(Index, 57, 1) = True Then
    Call CustomMenuPicture(Index, 31, "\GUI\Skills\Cook\Button_Squid.bmp", 32, 96)
    Else
    Call CustomMenuPicture(Index, 31, "\GUI\Skills\Cook\Button_Null_Squid.bmp", 32, 96)
    End If

    If CanTake(Index, 58, 1) = True Then
    Call CustomMenuPicture(Index, 32, "\GUI\Skills\Cook\Button_Lobster.bmp", 64, 96)
    Else
    Call CustomMenuPicture(Index, 32, "\GUI\Skills\Cook\Button_Null_Lobster.bmp", 64, 96)
    End If

    If CanTake(Index, 81, 1) = True Then
    Call CustomMenuPicture(Index, 33, "\GUI\Skills\Cook\Button_SmallMeat.bmp", 96, 96)
    Else
    Call CustomMenuPicture(Index, 33, "\GUI\Skills\Cook\Button_Null_SmallMeat.bmp", 96, 96)
    End If

    If CanTake(Index, 83, 1) = True Then
    Call CustomMenuPicture(Index, 34, "\GUI\Skills\Cook\Button_BigMeat.bmp", 128, 96)
    Else
    Call CustomMenuPicture(Index, 34, "\GUI\Skills\Cook\Button_Null_BigMeat.bmp", 128, 96)
    End If

    If (CanTake(Index, 85, 1) = True) And (CanTake(Index, 26, 1) = True) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Bread.bmp", 32, 128)
    Else
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If

    End If
    End If
    End If

    If ElementIndex = 30 Then
    If CanTake(Index, 56, 1) = True Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) = "4" Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 78, 1)
    Call TakeItem(Index, 56, 1)
    Call PlayerMsg(Index, "You successfully cook a fish!", WHITE)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", + 12)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 12)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 56, 1) Then
    Call CustomMenuPicture(Index, 30, "\GUI\Skills\Cook\Button_Null_Fish.bmp", 0, 96)
    End If
    Else
    Call TakeItem(Index, 56, 1)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 56, 1) Then
    Call CustomMenuPicture(Index, 30, "\GUI\Skills\Cook\Button_Null_Fish.bmp", 0, 96)
    End If
    End If
    End If

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) = "2" Then
    Call GiveCurrency(Index, 78, 1)
    Call TakeItem(Index, 56, 1)
    Call PlayerMsg(Index, "You successfully cook a fish!", WHITE)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", + 12)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 12)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 56, 1) Then
    Call CustomMenuPicture(Index, 30, "\GUI\Skills\Cook\Button_Null_Fish.bmp", 0, 96)
    End If

    If CanTake(Index, 78, 10) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17", "3")
    End If
    End If
    End If
    End If

    If ElementIndex = 31 Then
    If CanTake(Index, 57, 1) = True Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) = "4" Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 79, 1)
    Call TakeItem(Index, 57, 1)
    Call PlayerMsg(Index, "You successfully cook a squid!", WHITE)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", + 25)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 25)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 57, 1) Then
    Call CustomMenuPicture(Index, 31, "\GUI\Skills\Cook\Button_Null_Squid.bmp", 32, 96)
    End If
    Else
    Call TakeItem(Index, 57, 1)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 57, 1) Then
    Call CustomMenuPicture(Index, 31, "\GUI\Skills\Cook\Button_Null_Squid.bmp", 32, 96)
    End If
    End If
    End If
    End If
    End If

    If ElementIndex = 32 Then
    If CanTake(Index, 58, 1) = True Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) = "4" Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 80, 1)
    Call TakeItem(Index, 58, 1)
    Call PlayerMsg(Index, "You successfully cook a lobster!", WHITE)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", + 50)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 50)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 58, 1) Then
    Call CustomMenuPicture(Index, 32, "\GUI\Skills\Cook\Button_Null_Lobster.bmp", 64, 96)
    End If
    Else
    Call TakeItem(Index, 58, 1)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 58, 1) Then
    Call CustomMenuPicture(Index, 32, "\GUI\Skills\Cook\Button_Null_Lobster.bmp", 64, 96)
    End If
    End If
    End If
    End If
    End If

    If ElementIndex = 33 Then
    If CanTake(Index, 81, 1) = True Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) = "4" Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 82, 1)
    Call TakeItem(Index, 81, 1)
    Call PlayerMsg(Index, "You successfully cook a small piece of meat!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 12)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", + 12)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 81, 1) Then
    Call CustomMenuPicture(Index, 33, "\GUI\Skills\Cook\Button_Null_SmallMeat.bmp", 96, 96)
    End If
    Else
    Call TakeItem(Index, 81, 1)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 81, 1) Then
    Call CustomMenuPicture(Index, 33, "\GUI\Skills\Cook\Button_Null_SmallMeat.bmp", 96, 96)
    End If
    End If
    End If
    End If
    End If

    If ElementIndex = 34 Then
    If CanTake(Index, 83, 1) = True Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) = "4" Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 84, 1)
    Call TakeItem(Index, 83, 1)
    Call PlayerMsg(Index, "You successfully cook a piece of meat!", WHITE)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", + 50)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 50)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 83, 1) Then
    Call CustomMenuPicture(Index, 34, "\GUI\Skills\Cook\Button_Null_BigMeat.bmp", 128, 96)
    End If
    Else
    Call TakeItem(Index, 83, 1)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 83, 1) Then
    Call CustomMenuPicture(Index, 34, "\GUI\Skills\Cook\Button_Null_BigMeat.bmp", 128, 96)
    End If
    End If
    End If
    End If
    End If

    If ElementIndex = 35 Then
    If (CanTake(Index, 85, 1) = True) And (CanTake(Index, 26, 1) = True) Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) = "4" Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 25, 5)
    Call TakeItem(Index, 85, 1)
    Call TakeItem(Index, 26, 1)
    Call PlayerMsg(Index, "You successfully bake some rolls!", WHITE)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", + 25)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 25)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 85, 1) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If

    If Not CanTake(Index, 26, 1) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If
    Else
    Call TakeItem(Index, 85, 1)
    Call TakeItem(Index, 26, 1)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 85, 1) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If

    If Not CanTake(Index, 26, 1) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If
    End If
    End If
    End If
    End If

    If ElementIndex = 36 Then
    If (CanTake(Index, 85, 1) = True) And (CanTake(Index, 26, 1) = True) Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) = "4" Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 24, 1)
    Call TakeItem(Index, 85, 1)
    Call TakeItem(Index, 26, 1)
    Call PlayerMsg(Index, "You successfully bake a loaf of bread!", WHITE)
    Call PutVar("Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Cooking", "XP", + 25)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 25)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 85, 1) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If

    If Not CanTake(Index, 26, 1) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If
    Else
    Call TakeItem(Index, 85, 1)
    Call TakeItem(Index, 26, 1)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 85, 1) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If

    If Not CanTake(Index, 26, 1) Then
    Call CustomMenuPicture(Index, 35, "\GUI\Skills\Cook\Button_Null_Roll.bmp", 0, 128)
    Call CustomMenuPicture(Index, 36, "\GUI\Skills\Cook\Button_Null_Bread.bmp", 32, 128)
    End If
    End If
    End If
    End If
    End If

    If ElementIndex = 3 Then
    Call CustomMenuLabel(Index, 19, "Smithing", 104, 8, 8, 7, 0, 286, 315)
    Call CustomMenuLabel(Index, 23,"Level: " & GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Smithing", "Level"), 104, 30, 7, 7, 0, 286, 315)
    Call CustomMenuLabel(Index, 37,"XP: " & GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Smithing", "XP") & "/" & GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Smithing", "Next_Level"), 104, 50, 7, 7, 0, 286, 315)
    Call CustomMenuLabel(Index, 38,"Total XP: " & GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Smithing", "TotalXP"), 104, 70, 7, 7, 0, 286, 315)

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11" ) >= "2" Then
    Call CustomMenuClose(Index)
    Call CustomMenuShow(Index, "Skills", "\GUI\Skills.bmp", 1)

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "1") And (CanTake(Index, 6, 1)) Then
    Call CustomMenuPicture(Index, 1, "\GUI\Skills\Mining\Button_Mining.bmp", 0, 0)
    Else
    Call CustomMenuPicture(Index, 1, "\GUI\Skills\Mining\Button_Null_Mining.bmp", 0, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 2, "\GUI\Skills\Fishing\Button_Fishing.bmp", 0, 32)
    Else
    Call CustomMenuPicture(Index, 2, "\GUI\Skills\Fishing\Button_Null_Fishing.bmp", 0, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 4, "\GUI\Skills\Farming\Button_Farming.bmp", 0, 64)
    Else
    Call CustomMenuPicture(Index, 4, "\GUI\Skills\Farming\Button_Null_Farming.bmp", 0, 64)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "1") Or (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11" ) >= "2") Then
    Call CustomMenuPicture(Index, 3, "\GUI\Skills\Smith\Button_Smith.bmp", 32, 0)
    Else
    Call CustomMenuPicture(Index, 3, "\GUI\Skills\Smith\Button_Null_Smith.bmp", 32, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 18, "\GUI\Skills\Craft\Button_Craft.bmp", 32, 32)
    Else
    Call CustomMenuPicture(Index, 18, "\GUI\Skills\Craft\Button_Null_Craft.bmp", 32, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 5, "\GUI\Skills\Cook\Button_Cook.bmp", 32, 64)
    Else
    Call CustomMenuPicture(Index, 5, "\GUI\Skills\Cook\Button_Null_Cook.bmp", 32, 64)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "0") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest10" ) >= "2") Then
    Call CustomMenuPicture(Index, 22, "\GUI\Skills\Herbalist\Button_Herbalist.bmp", 64, 0)
    Else
    Call CustomMenuPicture(Index, 22, "\GUI\Skills\Herbalist\Button_Null_Herbalist.bmp", 64, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "0") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest170" ) >= "2") Then
    Call CustomMenuPicture(Index, 20, "\GUI\Skills\Enchant\Button_Enchant.bmp", 64, 32)
    Else
    Call CustomMenuPicture(Index, 20, "\GUI\Skills\Enchant\Button_Null_Enchant.bmp", 64, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Necromancy" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 21, "\GUI\Skills\Necromancy\Button_Necromancy.bmp", 64, 64)
    Else
    Call CustomMenuPicture(Index, 21, "\GUI\Skills\Necromancy\Button_Null_Necromancy.bmp", 64, 64)
    End If

    If GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "1" Then
    Call CustomMenuPicture(Index, 10, "\GUI\Skills\Smith\Button_Null_IronShield.bmp", 0, 128)
    Call CustomMenuPicture(Index, 11, "\GUI\Skills\Smith\Button_Null_IronSword.bmp", 32, 128)
    Call CustomMenuPicture(Index, 12, "\GUI\Skills\Smith\Button_Null_2HandIronSword.bmp", 64, 128)
    Call CustomMenuPicture(Index, 13, "\GUI\Skills\Smith\Button_Null_IronBody.bmp", 96, 128)

    Call CustomMenuPicture(Index, 14, "\GUI\Skills\Smith\Button_Null_SteelShield.bmp", 0, 160)
    Call CustomMenuPicture(Index, 15, "\GUI\Skills\Smith\Button_Null_SteelSword.bmp", 32, 160)
    Call CustomMenuPicture(Index, 16, "\GUI\Skills\Smith\Button_Null_2HandSteelSword.bmp", 64, 160)
    Call CustomMenuPicture(Index, 17, "\GUI\Skills\Smith\Button_Null_SteelBody.bmp", 96, 160)

    If (CanTake(Index, 10, 2) = True) And (CanTake(Index, 8, 5) = True) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_IronBar.bmp", 0, 96)
    Else
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    End If

    If (CanTake(Index, 10, 4) = True) And (CanTake(Index, 8, 7) = True) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_SteelBar.bmp", 32, 96)
    Else
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If (CanTake(Index, 10, 2) = True) And (CanTake(Index, 9, 5) = True) Then
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_SilverBar.bmp", 64, 96)
    Else
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    End If

    If (CanTake(Index, 10, 2) = True) And (CanTake(Index, 11, 5) = True) Then
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_GoldBar.bmp", 96, 96)
    Else
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)
    End If

    End If

    If GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "1" Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)

    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 29, 5) = True) Then
    Call CustomMenuPicture(Index, 10, "\GUI\Skills\Smith\Button_IronShield.bmp", 0, 128)
    Else
    Call CustomMenuPicture(Index, 10, "\GUI\Skills\Smith\Button_Null_IronShield.bmp", 0, 128)
    End If

    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 29, 5) = True) Then
    Call CustomMenuPicture(Index, 11, "\GUI\Skills\Smith\Button_IronSword.bmp", 32, 128)
    Else
    Call CustomMenuPicture(Index, 11, "\GUI\Skills\Smith\Button_Null_IronSword.bmp", 32, 128)
    End If

    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 29, 7) = True) Then
    Call CustomMenuPicture(Index, 12, "\GUI\Skills\Smith\Button_2HandIronSword.bmp", 64, 128)
    Else
    Call CustomMenuPicture(Index, 12, "\GUI\Skills\Smith\Button_Null_2HandIronSword.bmp", 64, 128)
    End If

    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 29, 15) = True) Then
    Call CustomMenuPicture(Index, 13, "\GUI\Skills\Smith\Button_IronBody.bmp", 96, 128)
    Else
    Call CustomMenuPicture(Index, 13, "\GUI\Skills\Smith\Button_Null_IronBody.bmp", 96, 128)
    End If

    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 31, 5) = True) Then
    Call CustomMenuPicture(Index, 14, "\GUI\Skills\Smith\Button_SteelShield.bmp", 0, 160)
    Else
    Call CustomMenuPicture(Index, 14, "\GUI\Skills\Smith\Button_Null_SteelShield.bmp", 0, 160)
    End If

    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 31, 5) = True) Then
    Call CustomMenuPicture(Index, 15, "\GUI\Skills\Smith\Button_SteelSword.bmp", 32, 160)
    Else
    Call CustomMenuPicture(Index, 15, "\GUI\Skills\Smith\Button_Null_SteelSword.bmp", 32, 160)
    End If

    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 31, 7) = True) Then
    Call CustomMenuPicture(Index, 16, "\GUI\Skills\Smith\Button_2HandSteelSword.bmp", 64, 160)
    Else
    Call CustomMenuPicture(Index, 16, "\GUI\Skills\Smith\Button_Null_2HandSteelSword.bmp", 64, 160)
    End If

    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 31, 15) = True) Then
    Call CustomMenuPicture(Index, 17, "\GUI\Skills\Smith\Button_SteelBody.bmp", 96, 160)
    Else
    Call CustomMenuPicture(Index, 17, "\GUI\Skills\Smith\Button_Null_SteelBody.bmp", 96, 160)
    End If

    End If

    End If
    End If

    If ElementIndex = 6 Then
    If (CanTake(Index, 10, 2) = True) And (CanTake(Index, 8, 5) = True) Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11" ) = "5" Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 29, 1)
    Call TakeItem(Index, 10, 2)
    Call TakeItem(Index, 8, 5)
    Call PlayerMsg(Index, "You successfully make an iron bar!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 12)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 8, 7) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)
    End If

    If Not CanTake(Index, 8, 5) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    End If
    Else
    Call TakeItem(Index, 10, 2)
    Call TakeItem(Index, 8, 5)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 8, 7) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)

    End If

    If Not CanTake(Index, 8, 5) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    End If
    End If
    End If

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11" ) = "2" Then
    Call GiveCurrency(Index, 29, 1)
    Call TakeItem(Index, 10, 2)
    Call TakeItem(Index, 8, 5)
    Call PlayerMsg(Index, "You successfully make an iron bar!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 12)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 8, 7) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)

    End If

    If Not CanTake(Index, 8, 5) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    End If

    If CanTake(Index, 29, 5) Then
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11", "3")
    End If
    End If
    End If
    End If

    If ElementIndex = 7 Then
    If (CanTake(Index, 10, 4) = True) And (CanTake(Index, 8, 7) = True) Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 31, 1)
    Call TakeItem(Index, 10, 4)
    Call TakeItem(Index, 8, 7)
    Call PlayerMsg(Index, "You successfully make a steel bar!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 25)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 8, 7) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)

    End If

    If Not CanTake(Index, 8, 5) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    End If

    Else
    Call TakeItem(Index, 10, 4)
    Call TakeItem(Index, 8, 7)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 8, 7) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)

    End If

    If Not CanTake(Index, 8, 5) Then
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    End If
    End If
    End If

    End If

    If ElementIndex = 8 Then
    If (CanTake(Index, 10, 2) = True) And (CanTake(Index, 9, 5) = True) Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 30, 1)
    Call TakeItem(Index, 10, 2)
    Call TakeItem(Index, 9, 5)
    Call PlayerMsg(Index, "You successfully make a silver bar!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 25)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)

    End If

    If Not CanTake(Index, 9, 5) Then
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    End If

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If
    Else
    Call TakeItem(Index, 10, 2)
    Call TakeItem(Index, 9, 5)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)

    End If

    If Not CanTake(Index, 9, 5) Then
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    End If

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If
    End If
    End If
    End If

    If ElementIndex = 9 Then
    If (CanTake(Index, 10, 2) = True) And (CanTake(Index, 11, 5) = True) Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 32, 1)
    Call TakeItem(Index, 10, 2)
    Call TakeItem(Index, 11, 5)
    Call PlayerMsg(Index, "You successfully make a gold bar!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 25)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    End If

    If Not CanTake(Index, 11, 5) Then
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)
    End If
    Else
    Call TakeItem(Index, 10, 2)
    Call TakeItem(Index, 11, 5)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 10, 4) Then
    Call CustomMenuPicture(Index, 7, "\GUI\Skills\Smith\Button_Null_SteelBar.bmp", 32, 96)
    End If

    If Not CanTake(Index, 10, 2) Then
    Call CustomMenuPicture(Index, 8, "\GUI\Skills\Smith\Button_Null_SilverBar.bmp", 64, 96)
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)
    Call CustomMenuPicture(Index, 6, "\GUI\Skills\Smith\Button_Null_IronBar.bmp", 0, 96)
    End If

    If Not CanTake(Index, 11, 5) Then
    Call CustomMenuPicture(Index, 9, "\GUI\Skills\Smith\Button_Null_GoldBar.bmp", 96, 96)
    End If
    End If
    End If
    End If

    If ElementIndex = 10 Then
    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 29, 5) = True) Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 4, 1)
    Call TakeItem(Index, 29, 5)
    Call PlayerMsg(Index, "You successfully make an iron shield!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 50)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 29, 5) Then
    Call CustomMenuPicture(Index, 10, "\GUI\Skills\Smith\Button_Null_IronShield.bmp", 0, 128)
    Call CustomMenuPicture(Index, 11, "\GUI\Skills\Smith\Button_Null_IronSword.bmp", 32, 128)
    End If

    If Not CanTake(Index, 29, 7) Then
    Call CustomMenuPicture(Index, 12, "\GUI\Skills\Smith\Button_Null_2HandIronSword.bmp", 64, 128)
    End If

    If Not CanTake(Index, 29, 15) Then
    Call CustomMenuPicture(Index, 13, "\GUI\Skills\Smith\Button_Null_IronBody.bmp", 96, 128)
    End If
    Else
    Call TakeItem(Index, 29, 5)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 29, 7) Then
    Call CustomMenuPicture(Index, 12, "\GUI\Skills\Smith\Button_Null_IronBody.bmp", 96, 128)
    End If

    If Not CanTake(Index, 29, 5) Then
    Call CustomMenuPicture(Index, 10, "\GUI\Skills\Smith\Button_Null_IronShield.bmp", 0, 128)
    Call CustomMenuPicture(Index, 11, "\GUI\Skills\Smith\Button_Null_IronSword.bmp", 32, 128)
    End If

    If Not CanTake(Index, 29, 15) Then
    Call CustomMenuPicture(Index, 13, "\GUI\Skills\Smith\Button_Null_IronBody.bmp", 96, 128)
    End If
    End If
    End If
    End If

    If ElementIndex = 11 Then
    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11" ) = "5" Then
    If (CanTake(Index, 27, 1) = True) And (CanTake(Index, 29, 5) = True) Then
    Chance = Rand(1, 2)
    If Chance = 1 Then
    Call GiveCurrency(Index, 22, 1)
    Call TakeItem(Index, 29, 5)
    Call PlayerMsg(Index, "You successfully make an iron sword!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 50)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)

    If Not CanTake(Index, 29, 7) Then
    Call CustomMenuPicture(Index, 12, "\GUI\Skills\Smith\Button_Null_2HandIronSword.bmp", 64, 128)
    End If

    If Not CanTake(Index, 29, 5) Then
    Call CustomMenuPicture(Index, 10, "\GUI\Skills\Smith\Button_Null_IronShield.bmp", 0, 128)
    Call CustomMenuPicture(Index, 11, "\GUI\Skills\Smith\Button_Null_IronSword.bmp", 32, 128)
    End If

    If Not CanTake(Index, 29, 15) Then
    Call CustomMenuPicture(Index, 13, "\GUI\Skills\Smith\Button_Null_IronBody.bmp", 96, 128)
    End If

    Else
    Call TakeItem(Index, 29, 5)
    Call PlayerMsg(Index, "You failed and lost your ingredients!", WHITE)

    If Not CanTake(Index, 29, 7) Then
    Call CustomMenuPicture(Index, 12, "\GUI\Skills\Smith\Button_Null_2HandIronSword.bmp", 64, 128)
    End If

    If Not CanTake(Index, 29, 5) Then
    Call CustomMenuPicture(Index, 10, "\GUI\Skills\Smith\Button_Null_IronShield.bmp", 0, 128)
    Call CustomMenuPicture(Index, 11, "\GUI\Skills\Smith\Button_Null_IronSword.bmp", 32, 128)
    End If

    If Not CanTake(Index, 29, 15) Then
    Call CustomMenuPicture(Index, 13, "\GUI\Skills\Smith\Button_Null_IronBody.bmp", 96, 128)
    End If
    End If
    End If
    End If

    If GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11" ) = "3" Then
    Call GiveCurrency(Index, 22, 1)
    Call TakeItem(Index, 29, 5)
    Call PlayerMsg(Index, "You successfully make an iron sword!", WHITE)
    Call SetPlayerExp(Index, GetPlayerExp(Index) + 25)
    Call PlayerLevelUp(Index)
    Call SendStats(Index)
    Call PutVar("Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11", "4")
    If Not CanTake(Index, 29, 7) Then
    Call CustomMenuPicture(Index, 12, "\GUI\Skills\Smith\Button_Null_2HandIronSword.bmp", 64, 128)
    End If

    If Not CanTake(Index, 29, 5) Then
    Call CustomMenuPicture(Index, 10, "\GUI\Skills\Smith\Button_Null_IronShield.bmp", 0, 128)
    Call CustomMenuPicture(Index, 11, "\GUI\Skills\Smith\Button_Null_IronSword.bmp", 32, 128)
    End If

    If Not CanTake(Index, 29, 15) Then
    Call CustomMenuPicture(Index, 13, "\GUI\Skills\Smith\Button_Null_IronBody.bmp", 96, 128)
    End If
    End If
    End If

    ```
    etc… it ran out of room
  13. EDIT

    Because Robin is so insistent on blocking any posts having to do with older versions of Eclipse, and because Origins is supposed to be better in about a million ways, how would I go about recoding and redoing all the things I spent hours on?

    I started my project long before Origins came out. If I hadn't I would have used it instead. I'm a decent coder but VB6 isn't something I'm at all familiar with. I'm eager to learn though.

    I have VB6 so I do intend to add some features to the source from various tutorials , but can anyone tell me how I could possibly turn these into Origins material?

    See part of the code here: [http://pastebin.com/embed_js.php?i=uNxUC9q8"](http://pastebin.com/embed_js.php?i=uNxUC9q8)

    So yeah. As you can see, this was a lot of work, and aside from using cloudwolf's quest maker in part, I did this all by myself. I'd hate to see it all go to waste so if anyone can give me some tips or point me in the right direction I would be very grateful.
  14. Okay, so before you go bashing me because I'm still using stable, know that I'm not experienced enough with coding in VB6 to use Origins, plus I already have an original Quest System and an original Skill System made with custom menus.

    The issue I'm having is that I don't know how to add onto the source. I have VB6 and managed to fix at least some of the speed/magic swap bug.

    That was because the code was already there and all I had to do was change a few things. I have a good eye for code and how it works to a degree, even when it's not something I've used before, as long as it's similar enough to some other programing languages I know.

    Anyways, to the point. I would like to add two buttons to frmStable. One for opening the Skill custom menu, and one for opening the Quest custom menu. That way, people wont have to type commands to open them.

    Any help is much appreciated.

    Here's the Skill custom menu code from Commands.ess(This is just the initial window. More complex options are coded in MenuScripts.ess.):
    ```
    Call CustomMenuShow(Index, "Skills", "\GUI\Skills.bmp", 1)

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "1") And (CanTake(Index, 6, 1)) Then
    Call CustomMenuPicture(Index, 1, "\GUI\Skills\Mining\Button_Mining.bmp", 0, 0)
    Else
    Call CustomMenuPicture(Index, 1, "\GUI\Skills\Mining\Button_Null_Mining.bmp", 0, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 2, "\GUI\Skills\Fishing\Button_Fishing.bmp", 0, 32)
    Else
    Call CustomMenuPicture(Index, 2, "\GUI\Skills\Fishing\Button_Null_Fishing.bmp", 0, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 4, "\GUI\Skills\Farming\Button_Farming.bmp", 0, 64)
    Else
    Call CustomMenuPicture(Index, 4, "\GUI\Skills\Farming\Button_Null_Farming.bmp", 0, 64)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "1") Or (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest11" ) >= "2") Then
    Call CustomMenuPicture(Index, 3, "\GUI\Skills\Smith\Button_Smith.bmp", 32, 0)
    Else
    Call CustomMenuPicture(Index, 3, "\GUI\Skills\Smith\Button_Null_Smith.bmp", 32, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 18, "\GUI\Skills\Craft\Button_Craft.bmp", 32, 32)
    Else
    Call CustomMenuPicture(Index, 18, "\GUI\Skills\Craft\Button_Null_Craft.bmp", 32, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 5, "\GUI\Skills\Cook\Button_Cook.bmp", 32, 64)
    Else
    Call CustomMenuPicture(Index, 5, "\GUI\Skills\Cook\Button_Null_Cook.bmp", 32, 64)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "0") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest10" ) >= "2") Then
    Call CustomMenuPicture(Index, 22, "\GUI\Skills\Herbalist\Button_Herbalist.bmp", 64, 0)
    Else
    Call CustomMenuPicture(Index, 22, "\GUI\Skills\Herbalist\Button_Null_Herbalist.bmp", 64, 0)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Mining" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Fishing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Farming" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smelting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Smithing" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Crafting" ) = "0") And (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Cooking" ) = "0") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest170" ) >= "2") Then
    Call CustomMenuPicture(Index, 20, "\GUI\Skills\Enchant\Button_Enchant.bmp", 64, 32)
    Else
    Call CustomMenuPicture(Index, 20, "\GUI\Skills\Enchant\Button_Null_Enchant.bmp", 64, 32)
    End If

    If (GetVar( "Scripts\Skills\" & GetPlayerName(Index) & ".ini", "Triggers", "Necromancy" ) = "1") And (GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Quest17" ) >= "2") Then
    Call CustomMenuPicture(Index, 21, "\GUI\Skills\Necromancy\Button_Necromancy.bmp", 64, 64)
    Else
    Call CustomMenuPicture(Index, 21, "\GUI\Skills\Necromancy\Button_Null_Necromancy.bmp", 64, 64)
    End If

    Exit Sub
    ```

    Here's the Quest custom menu code from Commands.ess(This is just the initial window. More complex options are coded in MenuScripts.ess.):
    ```
    Call CustomMenuShow(Index, "Quests", "\GUI\Quest.bmp", 1)
    Call CustomMenuPicture(Index, 16, "\GUI\World\Button_LightRealm.bmp", 0, 0)
    If Not GetPlayerClass(Index) = 0 And Not GetPlayerClass(Index) = 1 Then
    Call CustomMenuPicture(Index, 17, "\GUI\World\Button_Dunes.bmp", 32, 0)
    Call CustomMenuPicture(Index, 18, "\GUI\World\Button_Jungle.bmp", 64, 0)
    Call CustomMenuPicture(Index, 19, "\GUI\World\Button_DarkRealm.bmp", 96, 0)
    Call CustomMenuPicture(Index, 20, "\GUI\World\Button_Orthia.bmp", 128, 0)
    Call CustomMenuPicture(Index, 21, "\GUI\World\Button_WinterLands.bmp", 160, 0)
    Else
    Call CustomMenuPicture(Index, 17, "\GUI\World\Button_Null_Dunes.bmp", 32, 0)
    Call CustomMenuPicture(Index, 18, "\GUI\World\Button_Null_Jungle.bmp", 64, 0)
    Call CustomMenuPicture(Index, 19, "\GUI\World\Button_Null_DarkRealm.bmp", 96, 0)
    Call CustomMenuPicture(Index, 20, "\GUI\World\Button_Null_Orthia.bmp", 128, 0)
    Call CustomMenuPicture(Index, 21, "\GUI\World\Button_Null_WinterLands.bmp", 160, 0)
    End If
    Call CustomMenuLabel(Index, 22, "Light Realm Progress - " & GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Total") & "/" & GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Max"), 0, 48, 14, 15, 0, 286, 315)
    Call CustomMenuLabel(Index, 0, "Possible Quests", 0, 72, 11, 15, 0, 286, 315)
    Call CustomMenuLabel(Index, 1, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1" ), 0, 92, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name1_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 2, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2" ), 0, 106, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name2_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 3, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3" ), 0, 120, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name3_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 4, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4" ), 0, 134, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name4_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 5, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5" ), 0, 148, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name5_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 6, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6" ), 0, 162, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name6_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7" ), 0, 176, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name7_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 8, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8" ), 0, 190, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name8_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 9, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9" ), 0, 204, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name9_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 10, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10" ), 0, 218, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name10_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 11, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11" ), 0, 232, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name11_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 12, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12" ), 0, 246, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name12_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 13, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13" ), 0, 260, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name13_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 14, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14" ), 0, 274, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name14_Status" ), 0, 286, 315)
    Call CustomMenuLabel(Index, 15, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15" ), 0, 288, 7, GetVar( "Scripts\Quests\" & GetPlayerName(Index) & ".ini", "Quests", "Name15_Status" ), 0, 286, 315)
    Exit Sub
    ```
  15. I made a little program for making map outlines for Eclipse!

    Help File:

    > Welcome to MapOutliner!
    >
    > I made this program for Eclipse which you can download from the website below.
    > http://www.touchofdeathforums.com/
    >
    > While creating dozens of maps for your Eclipse game, you may find them hard to maintain. Especially if you have a massive game world under construction. This program is here to help you keep track of where each map connects to one another and where a specific map is in general.
    >
    > To choose which direction(s) you can move into another map from, left click on one of these squares.
    >
    > ![](http://i906.photobucket.com/albums/ac270/neoyarn/Exmp1.png?t=1296873576)
    >
    > Click again to cycle through the options.
    >
    > ![](http://i906.photobucket.com/albums/ac270/neoyarn/exmp2.png?t=1296873618)
    >
    > The blue lines represent where you can move out of the map.
    >
    > To keep track of which map file number the map belongs to and what you named it in-game, right click on a square.
    >
    > Press the 'N' Key to start a new outline.
    > Press the 'S' Key to save an outline.
    > Press the 'O' Key to open an outline.
    > Press 'F9' to take a screen shot of your outline.
    >
    > If you want more squares in your grid then you will have to have multiple projects.
    > For example - I have a MapOutline project for every realm and area in my game.
    > Dividing your game into areas like that can make your outlines easier to manage.
    >
    > One last thing - If you get any error messages, just press ignore.
×
×
  • Create New...