Skip to content

Commit

Permalink
Merge branch 'main' into rook-system
Browse files Browse the repository at this point in the history
  • Loading branch information
jprzimba committed Jan 6, 2025
2 parents 03df385 + ae6abee commit f63a83d
Show file tree
Hide file tree
Showing 9 changed files with 342 additions and 181 deletions.
4 changes: 1 addition & 3 deletions data/scripts/actions/items/wheel_scrolls.lua
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,11 @@ function scroll.onUse(player, item, fromPosition, target, toPosition, isHotkey)
end

local scrollData = promotionScrolls[item:getId()]
local scrollKV = player:kv():scoped("wheel-of-destiny"):scoped("scrolls")
if scrollKV:get(scrollData.name) then
if not player:wheelUnlockScroll(scrollData.name) then
player:sendTextMessage(MESSAGE_LOOK, "You have already deciphered this scroll.")
return true
end

scrollKV:set(scrollData.name, true)
player:sendTextMessage(MESSAGE_LOOK, "You have gained " .. scrollData.points .. " promotion points for the Wheel of Destiny by deciphering the " .. scrollData.itemName .. ".")
item:remove(1)
return true
Expand Down
Loading

0 comments on commit f63a83d

Please sign in to comment.