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

feat: The Paleworm loot and mount #1758

Merged
merged 1 commit into from
Oct 30, 2023
Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,8 @@ monster.loot = {
{ name = "bloody tears", chance = 1500 },
{ name = "ghost chestplate", chance = 150 },
{ name = "spooky hood", chance = 150 },
{ name = "pale worm's scalp", chance = 1200 },
{ name = "spectral scrap of cloth", chance = 250 },
{ name = "fabulous legs", chance = 150 },
{ name = "phantasmal axe", chance = 150 },
{ name = "ghost backpack", chance = 150 },
Expand Down
25 changes: 25 additions & 0 deletions data-otservbr-global/scripts/actions/mounts/haze_mount.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
local config = {
[32629] = { mountId = 162, message = "You are now versed to ride the haze!" },
}

local hazemount = Action()

function hazemount.onUse(player, item, fromPosition, target, toPosition, isHotkey)
local mount = config[item.itemid]

if not mount then
return true
end

if not player:hasMount(mount.mountId) then
player:addMount(mount.mountId)
player:say(mount.message, TALKTYPE_MONSTER_SAY)
item:remove(1)
else
player:sendTextMessage(19, "You already have this mount")
end
return true
end

hazemount:id(32629)
hazemount:register()