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

Fixes and updates regarding the post man quest #308

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions data/XML/quests.xml
Original file line number Diff line number Diff line change
Expand Up @@ -962,12 +962,12 @@
<missionstate id="13" description="You have reported back that you have completed the mission." />
</mission>
<mission name="Mission 7 - Measurements" storageid="12456" startvalue="1" endvalue="8">
<missionstate id="1" description="Kevin wants you to bring him the measurements of Ben, Lokur, Dove, Liane, Chrystal and Olrik." />
<missionstate id="2" description="You have received the measurements from 1 of 6 postofficers." />
<missionstate id="3" description="You have received the measurements from 2 of 6 postofficers." />
<missionstate id="4" description="You have received the measurements from 3 of 6 postofficers." />
<missionstate id="5" description="You have received the measurements from 4 of 6 postofficers." />
<missionstate id="6" description="You have received the measurements from 5 of 6 postofficers." />
<missionstate id="1" description="Kevin wants you to bring him the measurements of Benjamin, Lokur, Dove, Liane, Chrystal and Olrik." />
<missionstate id="2" description="You have received the measurements from 1 of 6 post officers." />
<missionstate id="3" description="You have received the measurements from 2 of 6 post officers." />
<missionstate id="4" description="You have received the measurements from 3 of 6 post officers." />
<missionstate id="5" description="You have received the measurements from 4 of 6 post officers." />
<missionstate id="6" description="You have received the measurements from 5 of 6 post officers." />
<missionstate id="7" description="You have received all measurements, report back to Kevin!" />
<missionstate id="8" description="You have reported back that you have completed the mission." />
</mission>
Expand Down
1 change: 1 addition & 0 deletions data/actions/actions.xml
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,7 @@
<!-- Postman Quest -->
<action itemid="2330" script="quests/postman/package.lua" />
<action itemid="2331" script="quests/postman/present.lua" />
<action uniqueid="3118" script="quests/postman/waldosPosthorn.lua" />

<!-- The Hidden City of Beregar -->
<action actionid="12606" script="quests/the hidden city of beregar/bargateLever.lua" />
Expand Down
10 changes: 10 additions & 0 deletions data/actions/scripts/quests/postman/waldosPostHorn.lua.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
if player:getStorageValue(Storage.postman.Mission08) == 1 then
player:setStorageValue(Storage.postman.Mission08, 2)
player:addItem(2332, 1)
player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "You found Waldo's posthorn.")
else
player:sendTextMessage(MESSAGE_EVENT_ADVANCE, 'The dead human is empty.')
end
return true
end
3 changes: 2 additions & 1 deletion data/items/items.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2950,7 +2950,8 @@
<attribute key="weight" value="1200" />
</item>
<item id="2332" name="Waldo's post horn">
<attribute key="weight" value="2200" />
<attribute key="description" value="It's property of the Postmaster's Guild and only rewarded to loyal members." />
<attribute key="weight" value="1500" />
</item>
<item id="2333" article="a" name="letter to Markwin">
<attribute key="weight" value="50" />
Expand Down
9 changes: 5 additions & 4 deletions data/npc/scripts/Kevin.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ NpcSystem.parseParameters(npcHandler)

function onCreatureAppear(cid) npcHandler:onCreatureAppear(cid) end
function onCreatureDisappear(cid) npcHandler:onCreatureDisappear(cid) end
function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end
function onThink() npcHandler:onThink() end
function onCreatureSay(cid, type, msg) npcHandler:onCreatureSay(cid, type, msg) end
function onThink() npcHandler:onThink() end

local function getPlayerBones(cid)
local player = Player(cid)
Expand All @@ -21,6 +21,7 @@ local function creatureSayCallback(cid, type, msg)
if not npcHandler:isFocused(cid) then
return false
end

local player = Player(cid)
if msgcontains(msg, "mission") then
if player:getStorageValue(Storage.postman.Mission01) < 1 then
Expand Down Expand Up @@ -120,7 +121,7 @@ local function creatureSayCallback(cid, type, msg)
npcHandler:say("Good! Finally, find the technomancer Brodrosch and travel with him to the Isle of Cormaya. After this passage report back to me here. Understood?", cid)
npcHandler.topic[cid] = 7
elseif npcHandler.topic[cid] == 7 then
npcHandler:say("Ok, remember: the Tibian mail service puts trust in you! Don't fail and report back soon. Just tell me about your {MISSION}.", cid)
npcHandler:say("Ok, remember: the Tibian mail service puts trust in you! Don't fail and report back soon. Just tell me about your {mission}.", cid)
player:setStorageValue(Storage.postman.Mission01, 1)
npcHandler.topic[cid] = 0
elseif npcHandler.topic[cid] == 8 then
Expand Down Expand Up @@ -195,7 +196,7 @@ local function creatureSayCallback(cid, type, msg)
player:addItem(2078, 1)
npcHandler.topic[cid] = 0
elseif npcHandler.topic[cid] == 25 then
npcHandler:say("So listen well. Behind the lower left door you will find a bag. The letters in the bag are for none other than Santa Claus! Deliver them to his house on the isle of Vega, USE thebag on his mailbox and report back here.", cid)
npcHandler:say("So listen well. Behind the lower left door you will find a bag. The letters in the bag are for none other than Santa Claus! Deliver them to his house on the isle of Vega, {use} thebag on his mailbox and report back here.", cid)
player:setStorageValue(Storage.postman.Mission09, 1)
npcHandler.topic[cid] = 0
elseif npcHandler.topic[cid] == 26 then
Expand Down