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

Alatar

Members
  • Posts

    558
  • Joined

  • Last visited

    Never

Everything posted by Alatar

  1. Easy boys. There is no need to get off topic. We know that this kind of threads gets a lots of replys in short time, and your whole discussion is pointless for anyone who is interested in searching new updates or feedback this version of the engine. It's going to be DDX8, it has been decided. That's all :P If you two want to argue about DD7-8 why don't you create a topic in the 'Debate' section?
  2. I like the idea of "Players will go through a tutorial, learn the basics, spawn in a massive world, and explore their way through it" but you need to keep the motivation daily to keep players interested. Nice project, although i've seen a few mapping erros on the screens, it looks good. Keep on that!
  3. What aren't you understanding about it? Do you understand how graphics are displayed on the engine? Think about it like a movie :P How can we perceive 'movement' on a movie/TV/monitor?
  4. @skystudios: > uhhm will it work in the vb6 portable version? I highly reccommend not using the portable version.
  5. Hello! Months ago I've worked on an idea to edit the form of the Map Editor. Yesterday I've found that source in the depths of my computer and decided to release it here as a tutorial. It's a form redesign, not a new map editor or something like that. Here's a screenie: ![](http://i52.tinypic.com/2cpap6p.png) **To-Do List**: - Remove frmProperties and stuff. - Work on the 'ToDo attributes. **Alatar's Map Editor Redesign** This is for EO 2.0 It's a simple tutorial and it's all Client-Side so let's start. First of all you need to **DOWNLOAD** the edited Form and replace your old one by this new one: **[LINK](http://www.mediafire.com/?16gc732d91tdnc8)**. Ok, now: In **modGlobals** at the bottom add: ``` 'mapeditor globals Public MapEditorFrame As Long Public IsAttributeReady As Boolean ``` In **modGameEditors**, in MapEditorInit after: ``` If Options.Debug = 1 Then On Error GoTo errorhandler ```Add: ``` MapEditorFrame = 1 IsAttributeReady = False ``` Find: ``` frmEditor_Map.width = 7425 ```Replace the 7425 with 6360. Find: ``` ' set shops for the shop attribute frmEditor_Map.cmbShop.AddItem "None" For i = 1 To MAX_SHOPS frmEditor_Map.cmbShop.AddItem i & ": " & Shop(i).Name Next ' we're not in a shop frmEditor_Map.cmbShop.ListIndex = 0 ```Delete or comment it. Find MapEditorMouseDown, replace the entire sub with this: ``` Public Sub MapEditorMouseDown(ByVal Button As Integer, ByVal X As Long, ByVal Y As Long, Optional ByVal movedMouse As Boolean = True) Dim i As Long Dim CurLayer As Long Dim tmpDir As Byte ' If debug mode, handle error then exit out If Options.Debug = 1 Then On Error GoTo errorhandler ' find which layer we're on For i = 1 To MapLayer.Layer_Count - 1 If frmEditor_Map.optLayer(i).Value Then CurLayer = i Exit For End If Next If Not isInBounds Then Exit Sub If Button = vbLeftButton Then If MapEditorFrame = 1 Then 'Alatar If EditorTileWidth = 1 And EditorTileHeight = 1 Then 'single tile MapEditorSetTile CurX, CurY, CurLayer Else ' multi tile! MapEditorSetTile CurX, CurY, CurLayer, True End If ElseIf MapEditorFrame = 2 Then 'Alatar With Map.Tile(CurX, CurY) 'Alatar If frmEditor_Map.optAttribs.Value Then If IsAttributeReady = False Then Exit Sub ' blocked tile If frmEditor_Map.optAttribute(1).Value Then .Type = TILE_TYPE_BLOCKED ' warp tile If frmEditor_Map.optAttribute(2).Value Then .Type = TILE_TYPE_WARP .Data1 = EditorWarpMap .Data2 = EditorWarpX .Data3 = EditorWarpY End If ' item spawn If frmEditor_Map.optAttribute(3).Value Then .Type = TILE_TYPE_ITEM .Data1 = ItemEditorNum .Data2 = ItemEditorValue .Data3 = 0 End If ' npc avoid If frmEditor_Map.optAttribute(4).Value Then .Type = TILE_TYPE_NPCAVOID .Data1 = 0 .Data2 = 0 .Data3 = 0 End If ' key If frmEditor_Map.optAttribute(5).Value Then .Type = TILE_TYPE_KEY .Data1 = KeyEditorNum .Data2 = KeyEditorTake .Data3 = 0 End If ' key open If frmEditor_Map.optAttribute(6).Value Then .Type = TILE_TYPE_KEYOPEN .Data1 = KeyOpenEditorX .Data2 = KeyOpenEditorY .Data3 = 0 End If ' resource If frmEditor_Map.optAttribute(7).Value Then .Type = TILE_TYPE_RESOURCE .Data1 = ResourceEditorNum .Data2 = 0 .Data3 = 0 End If ' door If frmEditor_Map.optAttribute(8).Value Then .Type = TILE_TYPE_DOOR .Data1 = EditorWarpMap .Data2 = EditorWarpX .Data3 = EditorWarpY End If ' npc spawn If frmEditor_Map.optAttribute(9).Value Then .Type = TILE_TYPE_NPCSPAWN .Data1 = SpawnNpcNum .Data2 = SpawnNpcDir .Data3 = 0 End If ' shop If frmEditor_Map.optAttribute(10).Value Then .Type = TILE_TYPE_SHOP .Data1 = EditorShop .Data2 = 0 .Data3 = 0 End If ' bank If frmEditor_Map.optAttribute(11).Value Then .Type = TILE_TYPE_BANK .Data1 = 0 .Data2 = 0 .Data3 = 0 End If ' heal If frmEditor_Map.optAttribute(12).Value Then .Type = TILE_TYPE_HEAL .Data1 = MapEditorHealType .Data2 = MapEditorHealAmount .Data3 = 0 End If ' trap If frmEditor_Map.optAttribute(13).Value Then .Type = TILE_TYPE_TRAP .Data1 = MapEditorHealAmount .Data2 = 0 .Data3 = 0 End If ' slide If frmEditor_Map.optAttribute(14).Value Then .Type = TILE_TYPE_SLIDE .Data1 = MapEditorSlideDir .Data2 = 0 .Data3 = 0 End If End If End With If frmEditor_Map.optBlock.Value Then If movedMouse Then Exit Sub ' find what tile it is X = X - ((X \ 32) * 32) Y = Y - ((Y \ 32) * 32) ' see if it hits an arrow For i = 1 To 4 If X >= DirArrowX(i) And X = DirArrowY(i) And Y
  6. My questions for you are: Do you know VB6? Why you wan't to make your own version? Would you be able to provide support to it? Wouldn't be better just to work on your game and if everythings go right then think on creating a 'custom' version of the engine? Just a few tips that I throw, only because I've seen a lot of 'versions' that are just a regular version of EO with a bunch of tutorials added. PS: Just to be clear I'm not talking about Vertigo Dawn or Galaxy for example, I'm talking about Motus, Chronicles, Omega, Nitro, etc.
  7. I voted "Yes, but I do not think it's a necessary addition." because it could be useful for some people.
  8. You have to edit that file, the main.jpg and add the button into it. Take a look on how the other buttons works and you will find out that only when a button is hover the proper graphics are displayed. Until then it's not shown at all. That's why the buttons are added to the main.jpg
  9. Awesome work jcsnider and congrats! I will download the new version to test when I catch some time. The tutorial looks funny =P
  10. Best of lucks to everyone! :D
  11. @cudauhoan: > how to make it allways show up? Edit the "client\data files\graphics\gui\main\main.jpg" and add the proper graphic.
  12. Alatar

    [EO] GM/DEV Tags

    @DimenXion: > Any idea how the text is being drawn so far away from the sprite? :/ > If GetPlayerSprite(Index) < 1 Or GetPlayerSprite(Index) > NumCharacters Then > TextX = ConvertMapX(GetPlayerX(Index) * PIC_X) + Player(Index).XOffset + (PIC_X \ 2) - getWidth(TexthDC, (Trim$(GetPlayerName(Index)))) > TextY = ConvertMapY(GetPlayerY(Index) * PIC_Y) + Player(Index).YOffset - 16 > Else > ' Determine location for text > TextX = ConvertMapX(GetPlayerX(Index) * PIC_X) + Player(Index).XOffset + (PIC_X \ 2) - getWidth(TexthDC, (Trim$(GetPlayerName(Index)))) > **TextY = ConvertMapY(GetPlayerY(Index) * PIC_Y) + Player(Index).YOffset - (DDSD_Character(GetPlayerSprite(Index)).lHeight) + 16** > End If That determines the Y-Axis for the drawname.
  13. @Ariel: > I wish someone will upgrade it to CS:DE! > > i would but i have no idea how to display the list box XD Haven't worked on CS:DE so i cannot help you with that. This system was created for EO. @hedgy: > PicQuestLog and everything inside it is grey when I press the quest button ingame, no list or anything. I can't get it to work, could anyone help me with it? > The rest of this system seems to work great, thanks Alatar! What version are you using? Did you installed it by your own or are you using the one with stuff already added? @totalwar235: > can anyone please compile v1.2? Sorry, I always forget to compile this kind of stuff :P Re-uploading now. EDIT: done: http://www.mediafire.com/?0ef5z3a9wa5tiif
  14. @Justn: > Awesome job man glad u got around to finishing this.. it has come a long way can't wait to try it out when I get home next week :)))))) Thanks :) @Murdoc: > This is great.. if im upgrading from 1.1 do i need to replace all of the extra files? Yes. @DarkBeast: > hay were do you get the buttons www.google.com
  15. 5 days left :o I may try something simple just for the fun of it but I'm not sure if I could get it on time :P
  16. Use a PictureBox and place the health bar inside.
  17. **Version 1.2**: >! **Alatar's Quest System v1.2** >! Screenshots: >! >! ![](http://img440.imageshack.us/img440/8051/screenier.jpg) ![](http://i53.tinypic.com/2jfgbd5.jpg) >! * * * >! Hello and welcome. This is a tutorial for EO 2.0, and also includes the entire project if you wan't to use it right away without the need of following the tutorial. I've started with the idea of this system months ago, and although I abandon it a few times and moved to other things, finally in the past few days I've manage to finish it. I'm just learning to program like many here, so this was my first 'big' personal challenge. So please report any error or suggestion and I will try to do my best ^^ Ok, let's go to the important. (And please forgive me, English is not my main language) >! **Features** >! This quest system is a bit different to others due to the fact that it allow developers to create dinamyc quests with different purpose and itinerary, like "_go talk to X npc, then kill X amount of X npc, then talk to Y npc and gather X amount of X item, finally come back and talk to me_". Each quest can have several tasks to do, each of one fully customizable. The quest system also has a fully working QuestLog and QuestSpeech window. >! **Types of Tasks** >! * **GoSlay**: Kill **X** amount of **X** npc's. * **GoGather**: Gather **X** amount of **X** item. * **GoTalk**: Interact with **X** npc. * **GoTravel**: Reach **X** map. * **GoGive**: Give **X** amount of **X** item to **X** npc. * **GoKill**: Kill **X** amount of players. * **GoTrain**: Hit **X** amount of times **X** resource. * **GoGet**: Get **X** amount of **X** item from **X** npc. >! **To-Do List** >! * - >! **How it Works** To open the Quest Editor type /editquest. >! **Changelog from v1.1 to v1.2** >! >! * Redesigned the Quest UDT. * Fixed experience reward. * Added [?] and [!] symbols over npc's heads. * Added requirements and rewards to the questlog. * Added graphics to quest GUI. * Fixed finished quest speech when having a repeatitive quest. * Added completed quests to the quest log. * Removed Delete key procedure that was used for testing only. * Starting a quest now works with shopkeepers also. * Fixed GoKill bug that added +1 to the current count of every quest active. * Added multiple rewards, multiple take-item-on-the-end and multiple give-item-on-the-start. * Fixed currency issues on GoGive, GoGet and GoGather. * Fixed an exploit on give item on start. >! Ok, let's go with the code. :huh: >! There are two ways to use this. >! **Way 1** [Download the full system](http://www.mediafire.com/?7xi5xe6xny1yg5i) already added to a blank EO and go test it. That's all, you don't need to follow the steps. >! **Way 2** Install the system on your own EO manually, following the steps below and **remember** to [download the extra files](http://www.mediafire.com/?4e8jd54chvmdwxs) and add them to your project: >! **Server Side** >! **Add the modSvQuest to your project.** >! **modCombat** >! Find: ``` If Len(Trim$(NPC(npcNum).AttackSay)) > 0 Then ```Above, after the Else, put ``` If NPC(npcNum).Behaviour = NPC_BEHAVIOUR_FRIENDLY Or NPC(npcNum).Behaviour = NPC_BEHAVIOUR_SHOPKEEPER Then Call CheckTasks(attacker, QUEST_TYPE_GOTALK, npcNum) Call CheckTasks(attacker, QUEST_TYPE_GOGIVE, npcNum) Call CheckTasks(attacker, QUEST_TYPE_GOGET, npcNum) If NPC(npcNum).Quest = YES Then If Player(attacker).PlayerQuest(NPC(npcNum).Quest).Status = QUEST_COMPLETED Then If Quest(NPC(npcNum).Quest).Repeat = YES Then Player(attacker).PlayerQuest(NPC(npcNum).Quest).Status = QUEST_COMPLETED_BUT Exit Function End If End If If CanStartQuest(attacker, NPC(npcNum).QuestNum) Then 'if can start show the request message (speech1) QuestMessage attacker, NPC(npcNum).QuestNum, Trim$(Quest(NPC(npcNum).QuestNum).Speech(1)), NPC(npcNum).QuestNum Exit Function End If If QuestInProgress(attacker, NPC(npcNum).QuestNum) Then 'if the quest is in progress show the meanwhile message (speech2) QuestMessage attacker, NPC(npcNum).QuestNum, Trim$(Quest(NPC(npcNum).QuestNum).Speech(2)), 0 Exit Function End If End If End If ``` Sub PlayerAttackNpc, find: ``` ' send death to the map ```Above place this: ``` Call CheckTasks(attacker, QUEST_TYPE_GOSLAY, npcNum) ``` Sub PlayerAttackNpc, find: ``` Call OnDeath(victim) ```Above place this: ``` Call CheckTasks(attacker, QUEST_TYPE_GOKILL, victim) ``` **modGeneral** >! In InitServer find: ``` ChkDir App.Path & "\Data\", "spells" ```past this below: ``` ChkDir App.Path & "\Data\", "quests" ``` In ClearGameData find: ``` Call ClearAnimations ```past this below: ``` Call SetStatus("Clearing quests...") Call ClearQuests ``` In LoadGameData find: ``` Call LoadAnimations ```past this below: ``` Call SetStatus("Loading quests...") Call LoadQuests ``` **modHandleData** >! Find: ``` HandleDataSub(CPartyLeave) = GetAddress(AddressOf HandlePartyLeave) ```Paste: ``` HandleDataSub(CRequestEditQuest) = GetAddress(AddressOf HandleRequestEditQuest) HandleDataSub(CSaveQuest) = GetAddress(AddressOf HandleSaveQuest) HandleDataSub(CRequestQuests) = GetAddress(AddressOf HandleRequestQuests) HandleDataSub(CPlayerHandleQuest) = GetAddress(AddressOf HandlePlayerHandleQuest) HandleDataSub(CQuestLogUpdate) = GetAddress(AddressOf HandleQuestLogUpdate) ``` At the end of the module add this: >! ``` Sub HandleRequestEditQuest(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long) Dim Buffer As clsBuffer >! ' Prevent hacking If GetPlayerAccess(Index) < ADMIN_DEVELOPER Then Exit Sub End If >! Set Buffer = New clsBuffer Buffer.WriteLong SQuestEditor SendDataTo Index, Buffer.ToArray() Set Buffer = Nothing End Sub >! Sub HandleSaveQuest(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long) Dim n As Long Dim Buffer As clsBuffer Dim QuestSize As Long Dim QuestData() As Byte Set Buffer = New clsBuffer Buffer.WriteBytes Data() >! ' Prevent hacking If GetPlayerAccess(Index) < ADMIN_DEVELOPER Then Exit Sub End If >! n = Buffer.ReadLong 'CLng(Parse(1)) >! If n < 0 Or n > MAX_QUESTS Then Exit Sub End If ' Update the Quest QuestSize = LenB(Quest(n)) ReDim QuestData(QuestSize - 1) QuestData = Buffer.ReadBytes(QuestSize) CopyMemory ByVal VarPtr(Quest(n)), ByVal VarPtr(QuestData(0)), QuestSize Set Buffer = Nothing ' Save it Call SendUpdateQuestToAll(n) Call SaveQuest(n) Call AddLog(GetPlayerName(Index) & " saved Quest #" & n & ".", ADMIN_LOG) End Sub >! Sub HandleRequestQuests(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long) SendQuests Index End Sub >! Sub HandlePlayerHandleQuest(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long) Dim Buffer As clsBuffer Dim QuestNum As Long, Order As Long, i As Long, n As Long Dim RemoveStartItems As Boolean Set Buffer = New clsBuffer Buffer.WriteBytes Data() QuestNum = Buffer.ReadLong Order = Buffer.ReadLong '1 = accept quest, 2 = cancel quest If Order = 1 Then RemoveStartItems = False 'Alatar v1.2 For i = 1 To MAX_QUESTS_ITEMS If Quest(QuestNum).GiveItem(i).Item > 0 Then If FindOpenInvSlot(Index, Quest(QuestNum).RewardItem(i).Item) = 0 Then PlayerMsg Index, "You have no inventory space. Please delete something to take the quest.", BrightRed RemoveStartItems = True Exit For Else If Item(Quest(QuestNum).GiveItem(i).Item).Type = ITEM_TYPE_CURRENCY Then GiveInvItem Index, Quest(QuestNum).GiveItem(i).Item, Quest(QuestNum).GiveItem(i).Value Else For n = 1 To Quest(QuestNum).GiveItem(i).Value If FindOpenInvSlot(Index, Quest(QuestNum).GiveItem(i).Item) = 0 Then PlayerMsg Index, "You have no inventory space. Please delete something to take the quest.", BrightRed RemoveStartItems = True Exit For Else GiveInvItem Index, Quest(QuestNum).GiveItem(i).Item, 1 End If Next End If End If End If Next If RemoveStartItems = False Then 'this means everything went ok Player(Index).PlayerQuest(QuestNum).Status = QUEST_STARTED '1 Player(Index).PlayerQuest(QuestNum).ActualTask = 1 Player(Index).PlayerQuest(QuestNum).CurrentCount = 0 PlayerMsg Index, "New quest accepted: " & Trim$(Quest(QuestNum).Name) & "!", BrightGreen End If '/alatar v1.2 ElseIf Order = 2 Then Player(Index).PlayerQuest(QuestNum).Status = QUEST_NOT_STARTED '2 Player(Index).PlayerQuest(QuestNum).ActualTask = 1 Player(Index).PlayerQuest(QuestNum).CurrentCount = 0 RemoveStartItems = True 'avoid exploits PlayerMsg Index, Trim$(Quest(QuestNum).Name) & " has been canceled!", BrightGreen End If If RemoveStartItems = True Then For i = 1 To MAX_QUESTS_ITEMS If Quest(QuestNum).GiveItem(i).Item > 0 Then If HasItem(Index, Quest(QuestNum).GiveItem(i).Item) > 0 Then If Item(Quest(QuestNum).GiveItem(i).Item).Type = ITEM_TYPE_CURRENCY Then TakeInvItem Index, Quest(QuestNum).GiveItem(i).Item, Quest(QuestNum).GiveItem(i).Value Else For n = 1 To Quest(QuestNum).GiveItem(i).Value TakeInvItem Index, Quest(QuestNum).GiveItem(i).Item, 1 Next End If End If End If Next End If SavePlayer Index SendPlayerData Index SendPlayerQuests Index Set Buffer = Nothing End Sub >! Sub HandleQuestLogUpdate(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long) SendPlayerQuests Index End Sub ``` **modTypes** >! In Private Type PlayerRec, find: ``` Dir As Byte ```Paste: ``` PlayerQuest(1 To MAX_QUESTS) As PlayerQuestRec ``` In Private Type NpcRec, find: ``` Level As Long ```Paste: ``` Quest As Byte QuestNum As Long ``` **modEnumerations** >! Find: ``` SPartyVitals ```Paste: ``` SQuestEditor SUpdateQuest SPlayerQuest SQuestMessage ``` Find: ``` CPartyLeave ```Paste: ``` CRequestEditQuest CSaveQuest CRequestQuests CPlayerHandleQuest CQuestLogUpdate ``` **modPlayer** >! Find: ``` Call SendHotbar(Index) ```Paste: ``` Call SendQuests(Index) ``` In PlayerWarp, find: ``` ' if same map then just send their co-ordinates If mapNum = GetPlayerMap(Index) Then SendPlayerXYToMap Index ```Paste: ``` Call CheckTasks(Index, QUEST_TYPE_GOREACH, mapNum) ``` In PlayerWarp find: ``` TempPlayer(Index).GettingMap = YES ```Paste: ``` Call CheckTasks(Index, QUEST_TYPE_GOREACH, mapNum) ``` In PlayerMapGetItem, find: ``` SendActionMsg GetPlayerMap(Index), Msg, White, 1, (GetPlayerX(Index) * 32), (GetPlayerY(Index) * 32) ```Paste: ``` Call CheckTasks(Index, QUEST_TYPE_GOGATHER, GetItemNum(Trim$(Item(GetPlayerInvItemNum(Index, n)).Name))) ``` In CheckResource find: ``` SendMapSound Index, rX, rY, SoundEntity.seResource, Resource_index ```Paste: ``` Call CheckTasks(Index, QUEST_TYPE_GOTRAIN, Resource_index) ``` >! **Client Side** >! **Add the modQuests to your project. Add the frmEditor_Quest to your project. Replace your frmEditor_NPC and frmMain with the ones that I provide you.** >! **modGameEditors** >! In NpcEditorInit find: ``` .txtDamage.text = NPC(EditorIndex).Damage ```Paste: ``` .chkQuest.Value = NPC(EditorIndex).Quest .scrlQuest.Value = NPC(EditorIndex).QuestNum ``` **modEnumerations** >! Find: ``` SPartyVitals ```Paste: ``` SQuestEditor SUpdateQuest SPlayerQuest SQuestMessage ``` Find: ``` CPartyLeave ```Paste: ``` CRequestEditQuest CSaveQuest CRequestQuests CPlayerHandleQuest CQuestLogUpdate ``` **modHandleData** >! Find: ``` HandleDataSub(SPartyVitals) = GetAddress(AddressOf HandlePartyVitals) ```Paste: ``` HandleDataSub(SQuestEditor) = GetAddress(AddressOf HandleQuestEditor) HandleDataSub(SUpdateQuest) = GetAddress(AddressOf HandleUpdateQuest) HandleDataSub(SPlayerQuest) = GetAddress(AddressOf HandlePlayerQuest) HandleDataSub(SQuestMessage) = GetAddress(AddressOf HandleQuestMessage) ``` At the end of the module, past this: ``` Private Sub HandleQuestEditor() Dim i As Long With frmEditor_Quest Editor = EDITOR_TASKS .lstIndex.Clear >! ' Add the names For i = 1 To MAX_QUESTS .lstIndex.AddItem i & ": " & Trim$(Quest(i).Name) Next >! .Show .lstIndex.ListIndex = 0 QuestEditorInit End With >! End Sub >! Private Sub HandleUpdateQuest(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long) Dim n As Long Dim Buffer As clsBuffer Dim QuestSize As Long Dim QuestData() As Byte Set Buffer = New clsBuffer Buffer.WriteBytes Data() n = Buffer.ReadLong ' Update the Quest QuestSize = LenB(Quest(n)) ReDim QuestData(QuestSize - 1) QuestData = Buffer.ReadBytes(QuestSize) CopyMemory ByVal VarPtr(Quest(n)), ByVal VarPtr(QuestData(0)), QuestSize Set Buffer = Nothing End Sub >! Private Sub HandlePlayerQuest(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long) Dim Buffer As clsBuffer Dim i As Long >! Set Buffer = New clsBuffer Buffer.WriteBytes Data() For i = 1 To MAX_QUESTS Player(MyIndex).PlayerQuest(i).Status = Buffer.ReadLong Player(MyIndex).PlayerQuest(i).ActualTask = Buffer.ReadLong Player(MyIndex).PlayerQuest(i).CurrentCount = Buffer.ReadLong Next RefreshQuestLog Set Buffer = Nothing End Sub >! Private Sub HandleQuestMessage(ByVal Index As Long, ByRef Data() As Byte, ByVal StartAddr As Long, ByVal ExtraVar As Long) Dim Buffer As clsBuffer Dim i As Long, QuestNum As Long, QuestNumForStart As Long Dim Message As String Set Buffer = New clsBuffer Buffer.WriteBytes Data() QuestNum = Buffer.ReadLong Message = Trim$(Buffer.ReadString) QuestNumForStart = Buffer.ReadLong frmMain.lblQuestName = Trim$(Quest(QuestNum).Name) frmMain.lblQuestSay = Message frmMain.lblQuestSubtitle = "Info:" frmMain.picQuestDialogue.Visible = True If QuestNumForStart > 0 And QuestNumForStart ! Find: ``` SendRequestEditSpell ```Paste: ``` Case "/editquest" If GetPlayerAccess(MyIndex) < ADMIN_DEVELOPER Then GoTo Continue SendRequestEditQuest ``` **modTypes** >! In Private Type PlayerRec, find: ``` Step As Byte ```Paste: ``` PlayerQuest(1 To MAX_QUESTS) As PlayerQuestRec ``` In Private Type NpcRec, find: ``` Level As Long ```Paste: ``` Quest As Byte QuestNum As Long ``` **modText** >! In DrawNpcName find this: ``` Call DrawText(TexthDC, TextX, TextY, Name, color) ```Paste this: ``` Dim i As Long For i = 1 To MAX_QUESTS 'check if the npc is the next task to any quest: [?] symbol If Quest(i).Name "" Then If Player(MyIndex).PlayerQuest(i).Status = QUEST_STARTED Then If Quest(i).Task(Player(MyIndex).PlayerQuest(i).ActualTask).NPC = npcNum Then Name = "[?]" TextX = ConvertMapX(MapNpc(Index).x * PIC_X) + MapNpc(Index).XOffset + (PIC_X \ 2) - getWidth(TexthDC, (Trim$(Name))) If NPC(npcNum).Sprite < 1 Or NPC(npcNum).Sprite > NumCharacters Then TextY = ConvertMapY(MapNpc(Index).y * PIC_Y) + MapNpc(Index).YOffset - 16 Else TextY = ConvertMapY(MapNpc(Index).y * PIC_Y) + MapNpc(Index).YOffset - (DDSD_Character(NPC(npcNum).Sprite).lHeight / 4) End If Call DrawText(TexthDC, TextX, TextY, Name, QBColor(Yellow)) Exit For End If End If 'check if the npc is the starter to any quest: [!] symbol 'can accept the quest as a new one? If Player(MyIndex).PlayerQuest(i).Status = QUEST_NOT_STARTED Or Player(MyIndex).PlayerQuest(i).Status = QUEST_COMPLETED_BUT Then 'the npc gives this quest? If NPC(npcNum).QuestNum = i Then Name = "[!]" TextX = ConvertMapX(MapNpc(Index).x * PIC_X) + MapNpc(Index).XOffset + (PIC_X \ 2) - getWidth(TexthDC, (Trim$(Name))) If NPC(npcNum).Sprite < 1 Or NPC(npcNum).Sprite > NumCharacters Then TextY = ConvertMapY(MapNpc(Index).y * PIC_Y) + MapNpc(Index).YOffset - 16 Else TextY = ConvertMapY(MapNpc(Index).y * PIC_Y) + MapNpc(Index).YOffset - (DDSD_Character(NPC(npcNum).Sprite).lHeight / 4) End If Call DrawText(TexthDC, TextX, TextY, Name, QBColor(Yellow)) Exit For End If End If End If Next ``` **modConstants** >! Find: ``` Public Const MAX_MAINBUTTONS As Long = 6 ```Replace the 6 for a 7. >! **modGeneral** >! In LoadGUI find ``` frmMain.picHotbar.Picture = LoadPicture(App.Path & "\data files\graphics\gui\main\hotbar.jpg") ```Paste: ``` frmMain.picQuestLog.Picture = LoadPicture(App.Path & "\data files\graphics\gui\main\questlog.jpg") frmMain.picQuestDialogue.Picture = LoadPicture(App.Path & "\data files\graphics\gui\main\questdialogue.jpg") ``` In cacheButtons find: ``` ' main - party With MainButton(6) .fileName = "party" .state = 0 ' normal End With ``` Paste: ``` ' main - quest With MainButton(7) .fileName = "quest" .state = 0 ' normal End With ``` >! * * * >! And that's all! Tell me if anything goes wrong. I hope that this system could be useful to your project, and if you use it please give credits ;) >! **_- Alatar_** >! * * * >! Special thanks to Erwin and people who help here bugfixing while I was inactive. :) And to the people who reported bugs ^^ >! * * * >! **All Versions** >! * Alatar's Quest System v1.2: [Link](http://www.touchofdeathforums.com/smf2/index.php/topic,70502.msg863386.html#msg863386) * Alatar's Quest System v1.1: [Link](http://www.touchofdeathforums.com/smf/index.php/topic,70502.msg809248.html#msg809248) * Alatar's Quest System v1.0: [Link](http://www.touchofdeathforums.com/smf/index.php/topic,70502.msg758371.html#msg758371). >! * * * >! **Extras** >! * [Convert quests from v1.0 to v1.1](http://www.touchofdeathforums.com/smf/index.php/topic,70502.msg809345.html#msg809345) * [Update your whole system from v1.0 to v1.1](http://www.touchofdeathforums.com/smf/index.php/topic,70502.msg809347.html#msg809347) **Changelog** * Redesigned the Quest UDT. * Fixed experience reward. * Added [?] and [!] symbols over npc's heads. * Added requirements and rewards to the questlog. * Added graphics to quest GUI. * Fixed finished quest speech when having a repeatitive quest. * Added completed quests to the quest log. * Removed Delete key procedure that was used for testing only. * Starting a quest now works with shopkeepers also. * Fixed GoKill bug that added +1 to the current count of every quest active. * Added multiple rewards, multiple take-item-on-the-end and multiple give-item-on-the-start. * Fixed currency issues on GoGive, GoGet and GoGather. * Fixed an exploit on give item on start.
  18. I've been reading this thread's pages and I wanted to make clear that the Delete key was used for testing only. Please remove it from your system. On the other hand I've been testing the reported bugs and fixed most of them. Right now i'm working with the GoKill system and the Multiple Reward stuff. PS: I've also seen lots of problems installing the system due to not properly reading the instruction. I'm thinking on making the installing extra files more obvious :P
  19. Screen update after a very long timeā€¦ ![](http://img440.imageshack.us/img440/8051/screenier.jpg)
  20. This looks awesome. Nice work!
  21. I said July but this could be sooner. Anyways I don't wank to raise no-one expectations at the point they start with the 'oh is it already?!' 'WEN AR U RELESIN THIS' and stuff. :) PS: If anyone find another bug or has a comment or something to say about the system then this is the moment.
  22. I've been around since '07-08 I think, but I made the account on 29-01-2009 :)
×
×
  • Create New...