Skip to content

Commit

Permalink
Lua code format - (Stylua)
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Oct 31, 2024
1 parent 3906dd3 commit d49be77
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions data/scripts/actions/items/mystery_box.lua
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
local mysterybox = Action()

function mysterybox.onUse(player, item, fromPosition, target, toPosition, isHotkey)
local items = {25361, 25360}
local randomItem = items[math.random(#items)]
player:addItem(randomItem, 1)
player:getPosition():sendMagicEffect(CONST_ME_MAGIC_BLUE)
item:remove(1)
return true
local items = { 25361, 25360 }
local randomItem = items[math.random(#items)]
player:addItem(randomItem, 1)
player:getPosition():sendMagicEffect(CONST_ME_MAGIC_BLUE)
item:remove(1)
return true
end


mysterybox:id(26186)
mysterybox:register()

0 comments on commit d49be77

Please sign in to comment.