EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Development::Development (https://www.eqemulator.org/forums/forumdisplay.php?f=590)
-   -   Task System (preliminary work) (https://www.eqemulator.org/forums/showthread.php?t=25894)

So_1337 09-30-2008 11:36 AM

I just wanted to stop in and mention that this task system is hot like fire. Excellent work.

ChaosSlayer 09-30-2008 11:44 AM

Quote:

Originally Posted by Andrew80k (Post 157261)
Most of the time, but not all, the things you are required to loot either have to be turned in to the quest giver, or they are no drop. Depends on the task. It's sort of up to the task creator.

well how do you turn in 50 quest items to an npc AT ONCE? =)
Or can task system handles this 1 item at a time? and count the turn ins?

Derision 09-30-2008 03:02 PM

Quote:

Originally Posted by ChaosSlayer (Post 157263)
well how do you turn in 50 quest items to an npc AT ONCE? =)
Or can task system handles this 1 item at a time? and count the turn ins?

The task system counts the turn ins, so you can turn in 25 one day, and then 25 the next day to complete the activity, or whatever, until you have turned in a total of 50.

Quote:

Originally Posted by joligario (Post 157254)
Wrote my first task today... wow that can get involved!

Yeah, it really needs a GUI to assist in writing the tasks.

Quote:

4. In activities, even though activitytype is over-ridden if text3 is populated, setting it to 0 will produce erroneous results in the task window. Currently you have default set to 0.
The activitytype is not overridden if text3 is populated (i.e. the task system will still handle it if the activity is not under Perl quest control), it is just not displayed as 'Deliver To', 'Kill', etc. You're right though, the default activitytype of 0 is invalid. I've just comitted a change to the SVN to send activities that have an activitytype of 0 as a type 9 to the client, which should fix that problem. I'll look into the other issues you raised.

Quote:

Originally Posted by joligario (Post 157254)

1. Under the rewards, if there is a cash reward can you display the amount or at least have it say Cash?
2. The reward text does not show on the task screen unless it is an item.

There is a flag in the packet struct which makes the client display 'You gain experience!' if it is set. I am not aware of a flag that will make it display details of a cash reward, however:

In Rev24, I fixed it so the Reward text field will be displayed even if RewardID==0, so if you want a task to have a cash-only reward, set RewardID to 0 and put the details of the cash reward in the Reward field. If you want to give an item and cash and want the player to know they will get both, then the only way currently is to put the ItemID in the RewardID field, and then put eg. 'Item x and 20 plat' in the Reward text field.

trevius 09-30-2008 05:16 PM

Quote:

Originally Posted by Derision (Post 157275)
Yeah, it really needs a GUI to assist in writing the tasks.

LOL, I would love to see what GeorgeS could do as a tool for this. But it sounds like a tool would be as hard to make as the system itself was. :P

joligario 10-01-2008 11:52 PM

Next suggestion:

Alter the task table to have minlevel and maxlevel fields
Create a bool function for CheckTaskLevel()
Create perl quest function quest::istaskappropriate(taskid)

With those, we could let the system do the level checks for us. Not really a big deal, but just might be handy.

joligario 10-02-2008 01:31 AM

Display messages
 
Odd text display. Here is what I am talking about. Please look at this task with your previous and new revisions. You'll notice the text gets cut short also.

SQL Code:
Code:

INSERT INTO tasks VALUES(13, 0, 'They\'re a Bit Short','[1, They might as well call you a scout, because you\'ll be going out and doing some scouting on some very high-profile sites. These sites are rumored to be burial grounds for priests of an ancient civilization, but there is not much information on them than that. Enough delay, get going and explore the single dwarven hut along the path in the north.][2, If your findings are correct, there\'s nothing around there that even remotely suggests an ancient burial ground. It\'s unfortunate, but there\'s one more spot you need to check before we give up all hope. Go ahead and explore the large rock tower on goblin isle. Be careful, if there is a burial ground, there\'s no telling what kind of creatures lurk nearby.][3, It\'s unfortunate that you weren\'t able to find any remnants at all. Perhaps there will be more to find next time. In the meantime, you need to report your findings, so speak with Tarerd Gahar. That is all.]','Money and Experience', 0, 1433, 2000, 0, 68, 1);

INSERT INTO activities VALUES (13, 0, 0, 5, 'the dwarven hut', '', '', 1, 0, 1, 0, 68, 0);
INSERT INTO activities VALUES (13, 1, 1, 5, 'the large rock tower', '', '', 1, 0, 1, 0, 69, 0);
INSERT INTO activities VALUES (13, 2, 2, 4, '', '', 'Speak with Tarerd Gahar', 0, 2, 1, 0, 202, 0);

INSERT INTO proximities VALUES (68, 1, 390, 410, 2060, 2080, -10, 10);
INSERT INTO proximities VALUES (69, 1, -8515, -8455, -1260, -1200, 20, 70);

butcher\Gibi_Bilgum.pl:
Code:

#BeginFile: butcher\Gibi_Bilgum.pl (68090)
#Quest file for Butcherblock Mountains - Gibi Bilgum: They're a Bit Short

sub EVENT_SAY {
  if($text=~/hail/i) {
    quest::say("Get a load of my sister over yonder. She doesn't know when to give up the swashbuckling. Idiocy is more like it. She's not the only one around here with some [tasks] that need... well, tasking. You might say I'm a taskmaster, only without the whip. I'm not sure how to even use a whip though, so maybe it's for the best.");
  }
  if($text=~/tasks/i) {
    if($ulevel >= 12) {
      if(quest::istaskactive(13)) {
        quest::say("They're a Bit Short is already in progress.");
      }
      else {
        quest::taskselector(13); #Task: They're a Bit Short
      }
    }
    else {
      quest::say("I don't have any tasks suitable to one of your experience.");
    }
  }
}

sub EVENT_ITEM {
  quest::say("I have no use for this, $name.");
  plugin::return_items(\%itemcount);
}

#EndFile: butcher\Gibi_Bilgum.pl (68090)

poknowledge\#Tarerd_Gahar.pl:
Code:

#Tarerd_Gahar.pl
#The Magic Pool

sub EVENT_SAY {
  if($text=~/hail/i) {
    if(quest::istaskactivityactive(13,2)) {
      quest::say("Thanks for contacting me, $name. Your information on this matter has been most useful.");
      $client->Message(7,"The ideal of burial grounds nearby is one that can not be easily overlooked. That's exactly why you were sent to check these areas out. Sadly none of them turned out to be the rumored burial grounds, but there's plenty more land to cover, so you maybe called upon again. You'll be recieving some payment, mostly for your time investment, but partially for the danger involved. Good job.");
      quest::updatetaskactivity(13,2);
    }
    else {
      quest::say("I'm sorry, I have neither the time nor the patience to chat right now.");
    }
  }
  if($text=~/pool/i) {
    quest::say("Oh Tatlan and Wicas sent you did they? I'll tell you what I told them, nothing is free. If you want to know about the pools then I need something [from you] first.");
  }
  if($text=~/from me/i) {
    quest::say("I'm sure it'll be easy for an adventurer as you. I am working on a potion, and I cannot currently travel to gather my last component. If you could bring me the blood of a Sarnak I'd be willing to share what I know.");
  }
}

sub EVENT_ITEM {
  if(plugin::check_handin(\%itemcount, 22519 => 1)) { #Sarnak Blood
    quest::say("Ahh this is exactly what I was looking for. All the information I've gathered from these pools has come from Myrist. Thiran will give you the book I used as a reference. Give him this note so he knows I sent you.");
    quest::summonitem(15958); #Note From Tarerd
  }
  else {
    quest::say("I don't need this."); #text made up
    plugin::return_items(\%itemcount);
  }
}

#END of FILE Zone:poknowledge  ID:202060 -- Tarerd_Gahar


Derision 10-02-2008 12:54 PM

Quote:

3. Under description, can you set up a description for the initial task window? For example: [0, This is my general description.][1, This is my description for step 1][2,3, This is my description for shared steps 2 and 3.]. Currently it is blank if step 1 and 2 are shared but if there is only 1 step, the main task window shows the entire text from the first step.
The way it works is that the entire description is sent to the client and it is the client which decides which portion to display based on which activity you are on. Are you saying it is not working like live ?

I think it maybe be possible to have an extra field in the task table for a description which is only displayed in the task selector window. If this new field was null, then it could just behave as at present.

Quote:

Alter the task table to have minlevel and maxlevel fields
Create a bool function for CheckTaskLevel()
Create perl quest function quest::istaskappropriate(taskid)
This would be simple to do. Could let them default to 0 meaning no level restriction. Anyone else have any input on this feature (and the extra field for a description specific to the task selector window) ?

Quote:

Odd text display. Here is what I am talking about. Please look at this task with your previous and new revisions. You'll notice the text gets cut short also.
I just ran through this task and can't see what you are referring to. Which text gets cut short ?

joligario 10-02-2008 01:48 PM

Old method (before you stated rev24 was made):
http://i409.photobucket.com/albums/p...q/EQ000011.jpghttp://i409.photobucket.com/albums/p...q/EQ000012.jpg
http://i409.photobucket.com/albums/p...q/EQ000013.jpghttp://i409.photobucket.com/albums/p...q/EQ000014.jpg

As you can see, the reward "Money and Experience" does not show up under rewards or on the main task screen. The entire 1st step is shown instead.

joligario 10-02-2008 01:49 PM

New code (using cavedude's PEQ after you said rev24 was made):
http://i409.photobucket.com/albums/p...q/EQ000007.jpghttp://i409.photobucket.com/albums/p...q/EQ000008.jpg
http://i409.photobucket.com/albums/p...q/EQ000009.jpghttp://i409.photobucket.com/albums/p...q/EQ000010.jpg

The entire first step is shown again, however it is truncated. The following steps have no text any more. Money and Experience now shows up as a reward but not on the main task window.

Derision 10-02-2008 02:23 PM

Putting the non-display of the reward on the task selection window aside for now, I don't see the other problems you are seeing:

http://www.rama.demon.co.uk/abs-task1.jpg

http://www.rama.demon.co.uk/abs-task2.jpg

http://www.rama.demon.co.uk/abs-task3.jpg

I think I am running Rev29, but I have made no changes to the task code since Rev24. This is on Linux. I'll try a Windows build on the off chance there is some incompatibilty that has crept in. Guess I should also test with your task as the only active one, as that is a difference between your test and mine.

janusd 10-02-2008 05:23 PM

Adding the level check would be a big help as there were some Live quests that had level requirements before the quest giver would hand out those quests. You can see in the quest list for PoK in Alla http://everquest.allakhazam.com/db/q....html?zone=158 that soem quests have a level minimum before the giver would hand it out. Or like this quest http://everquest.allakhazam.com/db/q...tml?quest=3157 I remember from Live. I know when I was piddling around years ago after they added these armor quests, I started a noob and ran through Gloomingdeep. Once I left, I went to the armor guys. They only give quests in order, but I had to level to the appropriate level before later quests would be given.

Derision 10-03-2008 05:57 AM

Quote:

Originally Posted by joligario (Post 157527)
The entire first step is shown again, however it is truncated. The following steps have no text any more. Money and Experience now shows up as a reward but not on the main task window.

What client are you using? By the look of it, it is the 6.2 client, however the order of the fields in the Quest Journal (Objective/Status/Zone) is different to how my 6.2 client displays it (Zone/Objective/Status).

joligario 10-03-2008 06:08 AM

Yes, I see that... I am using Titanium.

Derision 10-03-2008 06:14 AM

Quote:

Originally Posted by joligario (Post 157583)
Yes, I see that... I am using Titanium.

But that isn't the Titanium UI. Is it a custom one, or did you copy the 6.2 UI into your Titanium directory ?

Edit: I did a /loadskin default_old and still can't reproduce this :(

joligario 10-03-2008 01:14 PM

I installed Titanium and did loadskin default old. Other than that I haven't changed it...


All times are GMT -4. The time now is 08:07 AM.

Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.