Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quest: Move and rework Doing Your Duty from core to database #29747

Open
wants to merge 3 commits into
base: 3.3.5
Choose a base branch
from

Conversation

CraftedRO
Copy link
Contributor

@CraftedRO CraftedRO commented Feb 24, 2024

Changes proposed:

  • Move and rework quest Doing Your Duty from core to database
  • All the credit goes to Dr-J since it's his fix

Issues addressed:

Closes: #29283

Update: #26497

Tests performed:

It does build and have been tested in-game as you can see below:

https://youtu.be/OJnG8_CJ5Ls

Known issues and TODO list: (add/remove lines as needed)

  • Small remaining issue woud be that the Amberpine Footman guid 113948 shoud jump when walking nearby, and Idk what is the spell he use.

Ref video: https://www.youtube.com/watch?v=-Wf6-SQUdEY

@malcrom
Copy link
Contributor

malcrom commented Feb 24, 2024

You monster! That was my first c++ script!

@Krutok
Copy link

Krutok commented Feb 29, 2024

Changes proposed:

* Move and rework quest Doing Your Duty from core to database

* All the credit goes to [Dr-J](https://github.com/dr-j) since it's his fix

Issues addressed:

Closes: #29283

Update: #26497

Tests performed:

It does build and have been tested in-game as you can see below:

https://youtu.be/OJnG8_CJ5Ls

Known issues and TODO list: (add/remove lines as needed)

* [ I also tested the sound and seems fine. ]

@CraftedRO

You specified a wrong item (37247) as a condition and also the condition when the quest is finished or when you have the quest item and want to use the toilet again, the text appears that the toilet is occupied.

With your script you could use the toilet infinitely and thus receive the quest item multiple times.

I fixed that.

DELETE FROM `gossip_menu` WHERE `MenuID` = 9492;
INSERT INTO `gossip_menu` (`MenuID`, `TextID`, `VerifiedBuild`) VALUES
(9492, 12775, 0),
(9492, 12779, 0);
DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 14) AND (`SourceGroup` IN (9492));
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `Comment`) VALUES 
(14, 9492, 12775, 0, 0, 9, 0, 12227, 0, 0, 1, 'Player for which gossip text is shown doesn\'t have quest Doing Your Duty (12227) active'),
(14, 9492, 12775, 0, 1, 2, 0, 37250, 1, 1, 0, 'Player for which gossip text is shown has 1 of item Partially Processed Amberseeds (37250) in backpack or in bank'),
(14, 9492, 12779, 0, 0, 9, 0, 12227, 0, 0, 0, 'Player for which gossip text is shown has quest Doing Your Duty (12227) active'),
(14, 9492, 12779, 0, 0, 2, 0, 37250, 1, 1, 1, 'Player for which gossip text is shown has not 1 of item Partially Processed Amberseeds (37250) in backpack or in bank');

DELETE FROM `gossip_menu_option` WHERE `MenuID` = 9492;
INSERT INTO `gossip_menu_option` (`MenuID`, `OptionID`, `OptionIcon`, `OptionText`, `OptionBroadcastTextID`, `OptionType`, `OptionNpcFlag`, `ActionMenuID`, `ActionPoiID`, `BoxCoded`, `BoxMoney`, `BoxText`, `BoxBroadcastTextID`, `VerifiedBuild`) VALUES
(9492, 0, 0, 'Use the outhouse.', 26332, 1, 1, 0, 0, 0, 0, '', 0, 0),
(9492, 1, 0, 'Use the outhouse.', 26332, 1, 1, 0, 0, 0, 0, '', 0, 0);
DELETE FROM `conditions` WHERE (`SourceTypeOrReferenceId` = 15) AND (`SourceGroup` IN (9492));
INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `Comment`) VALUES 
(15, 9492, 0, 0, 0, 2, 0, 37250, 1, 1, 1, 'Player for which gossip text is shown has not 1 of item Partially Processed Amberseeds (37250) in backpack or in bank'),
(15, 9492, 0, 0, 0, 9, 0, 12227, 0, 0, 0, 'Player for which gossip text is shown has quest Doing Your Duty (12227) active'),
(15, 9492, 0, 0, 0, 20, 0, 0, 0, 0, 0, 'Player for which gossip text is shown is male'),
(15, 9492, 1, 0, 0, 2, 0, 37250, 1, 1, 1, 'Player for which gossip text is shown has not 1 of item Partially Processed Amberseeds (37250) in backpack or in bank'),
(15, 9492, 1, 0, 0, 9, 0, 12227, 0, 0, 0, 'Player for which gossip text is shown has quest Doing Your Duty (12227) active'),
(15, 9492, 1, 0, 0, 20, 0, 1, 0, 0, 0, 'Player for which gossip text is shown is female');

Update Quest Template:

UPDATE `quest_template` SET `RequiredItemId1` = 37247, `RequiredItemCount1` = 1 WHERE `ID` = 12227;

Blizzlike works with the SAI script. with the C++ script you got the quest item immediately when you clicked on the menu text

@CraftedRO
Copy link
Contributor Author

you know you can use review feature and don't post the entire thing again, better delete it, please refrain commenting and don't bloat my PR, thanks.

let me explain something to you, with your conditions the gossip will appear even if the player had trown away the Anderhol's Slider Cider questitem, have you think about this ?

With your script you could use the toilet infinitely and thus receive the quest item multiple times.

this is not true, you cannot use it again after because I know I tested this thing:

Captură de ecran 2024-02-29 154033

@Krutok
Copy link

Krutok commented Mar 1, 2024

I tested it and after the quest was finished I was still able to go to the toilet and get infinite quest items

@CraftedRO
Copy link
Contributor Author

CraftedRO commented Mar 1, 2024

try again on a clean database without your custom modifications

@Krutok
Copy link

Krutok commented Mar 1, 2024

try again on a clean database without your custom modifications

I don't need a clean database and I certainly won't install one. It's just a SmartAI script, nothing else can interfere or get in the way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants