• 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!

How to make cc quest?

Status
Not open for further replies.

Majeski20

New Member
Joined
Apr 21, 2008
Messages
602
Reaction score
4
Location
Sweden
Hi again.

I just wonder. If i want a chest that gives 15cc, how to do ;S?
Im using SimOne mapeditor.

not working:
actionid 15
uniqueid 2160

Thanks.
 
PHP:
<action uniqueid="5000" script="15cc.lua" />


PHP:
function onUse(cid, item, fromPosition, itemEx, toPosition)

  if getPlayerStorageValue(cid,5000) == 1 then
      doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR,"You have done this quest.")
      return TRUE
  end
      doPlayerSetStorageValue(cid,5000,1)
      doPlayerAddItem(cid,2160,15)
      doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR,"You have found 15 crystal coins.")
      return TRUE
end


:D
 
He is using SimOne and not RME. Read the first post next time u dump f*****

Ont: I guess you can script it?

Shut the fuck up bitch, nobody is perfect. Now suck your fathers dic|<

Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)

  if getPlayerStorageValue(cid,5000) == 1 then
      doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR,"You have done this quest.")
 else
      doPlayerSetStorageValue(cid,5000,1)
      doPlayerAddItem(cid,2160,15)
      doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR,"You have found 15 crystal coins.")
  end
      return TRUE
end

this shud work
 
Lua Script Error: [action Interface]
Data/actions/script/15cc.lua onUse

Data/actions/script/15cc.lua:6 attempt to call global ´doPlayerSetStorageValue´ <a nil value>


What is wrong :(?
 
Last edited:
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	if getPlayerStorageValue(cid, 5000) == 1 then
		doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR,"You have done this quest.")
	else
		setPlayerStorageValue(cid, 5000, 1)
		doPlayerAddItem(cid, 2160, 15)
		doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR,"You have found 15 crystal coins.")
	end
	return TRUE
end
 
Lua Script Error: [action Interface]
Data/actions/script/15cc.lua onUse

Data/actions/script/15cc.lua:6 attempt to call global ´doPlayerSetStorageValue´ <a nil value>


What is wrong :(?

sorry, I only changed Rodo's script a little, didn't notice that...

change

Code:
doPlayerSetStorageValue

to

Code:
setPlayerStorageValue

or just use Cykotitan's script :P
 
Status
Not open for further replies.
Back
Top