• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Book

Joined
Jun 24, 2009
Messages
103
Reaction score
0
Location
Sweden
hello i should need help with this thing
i book with id 9004 and when some1 click on it its like lottery but i will use this like a "rare item" wich you can loot in demon and so on.. :P to the point now xD
When you right click on it its should be
Gontratulations You Looted 100 Crystal Coins
or else 10 crystal coints or else 1 crystal coin and so on i can add that by my self just need some1 to make so it gives 50 and 100 crystal coins and i will figure out by my self how to fix it
and the chance on 100 crystal coins should me very hard that you get like 25% or somthing like that if some1 could fix i am very happy thankz

Ps..SORRY FOR MY BAD ENGLISH
 
fixed if any1 else need take it; )

actions.xml
Code:
<action itemid="9004" script="goldenbook.lua" />

and in actions/scripts
make file named Goldenbook.lua

LUA:
   function onUse(cid, item, frompos, item2, topos)
   	doTransformItem(item.uid,item.itemid+1)
	cashtype = math.random(1,100)
	cash = math.random(1,15)
	doSendMagicEffect(frompos,2)
	if cashtype >= 0 and cashtype <= 5 then
		doPlayerAddItem(cid,2160,cash)
		doPlayerSendTextMessage(cid,22,"You got out " .. cash*1 .. " crystal coints GZ!")
	elseif cashtype > 35 then
		doPlayerAddItem(cid,2152,cash)
		doPlayerSendTextMessage(cid,22,"You got out " .. cash .. " platinum coins Epic-Fail!")
	end
	doSendAnimatedText(frompos,'BANG!',180)

   	return 1
   
   end

:)
 
Back
Top