Skip to content

Commit

Permalink
Added quest for 'goldbarren'.
Browse files Browse the repository at this point in the history
  • Loading branch information
Lead0b110010100 authored and Lead0b110010100 committed Apr 23, 2020
1 parent dd025d6 commit eb5dc35
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 0 deletions.
23 changes: 23 additions & 0 deletions main/srv1/share/locale/germany/quest/goldbars.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
quest goldbars begin
state start begin
when 80003.use or 80004.use or 80005.use or 80006.use or 80007.use begin
local barrenInfo = {
[80003] = 50000000,
[80004] = 100000000,
[80005] = 250000000,
[80006] = 500000000,
[80007] = 1000000000,
}

local iVnum = item.vnum

if pc.get_money() + barrenInfo[iVnum] >= GOLD_MAX or pc.get_money() + barrenInfo[iVnum] < 0 then
syschat("Du trägst zuviel Yang bei dir.")
return
end

item.remove()
pc.change_gold(barrenInfo[iVnum])
end
end
end
1 change: 1 addition & 0 deletions main/srv1/share/locale/germany/quest/quest_list
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,4 @@ warehouse_item_destroyer.lua
soulstone.lua
level_info.lua
change_name_item.lua
goldbars.lua
2 changes: 2 additions & 0 deletions main/srv1/share/locale/germany/quest/questlib.lua
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ CONFIRM_TIMEOUT = 2
MALE = 0
FEMALE = 1

GOLD_MAX = 10000000000 + 1

--quest.create = function(f) return coroutine.create(f) end
--quest.process = function(co,args) return coroutine.resume(co, args) end
setstate = q.setstate
Expand Down

0 comments on commit eb5dc35

Please sign in to comment.