Action Black Knight Quest tfs 0.3.5

Joined
Jun 24, 2009
Messages
103
Best answers
0
Reaction score
0
Location
Sweden
hello this is a simple black knight quest script


add in data/actions/actions.xml

Code:
		<!-- Black Knight Quest-->
	<action uniqueid="7518" script="black knight/bkreward1.lua" />
    <action uniqueid="7519" script="black knight/bkreward2.lua" />

add in data/actions/scripts/black knight
createfile named bkreward1.lua

Lua:
function onUse(cid, item, frompos, item2, topos)


if item.uid ==7518 then
queststatus = getPlayerStorageValue(cid,7618)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a Crown Shield.")
doPlayerAddItem(cid,2519,1)
setPlayerStorageValue(cid,7618,1)
else
doPlayerSendTextMessage(cid,22,"You already done this quest.")
end
else
return 0
end

return 1
end
add in data/actions/scripts/black knight
createfile named bkreward2.lua


Lua:
function onUse(cid, item, frompos, item2, topos)


if item.uid ==7519 then
queststatus = getPlayerStorageValue(cid,7619)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a Crown Armor.")
doPlayerAddItem(cid,2487,1)
setPlayerStorageValue(cid,7619,1)
else
doPlayerSendTextMessage(cid,22,"You already done this quest.")
end
else
return 0
end

return 1
end
HTML:
make sure the chests got id
7519-crown armor 7518-crown shield
Rep++ If its helped you !;)
 
Last edited:

StreamSide

Joseluis Gonzalez
Support Team
Joined
Aug 31, 2007
Messages
3,329
Best answers
33
Reaction score
832
Location
Arica - Chile
why is he creating that! xd
in new tfs is put 2 codes into the box and done! :D
 
Top