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

TFS v0.3 (Alpha 4)

Ward_214

Pro PvP
Joined
Dec 11, 2008
Messages
297
Reaction score
0
Can someone help with the questboxes? What I have to do to it for them to work... I've tried actionid and uniqueid the same, actionid this.. unique id that.. tried the scripts, and nothing STILL seems to work, it sucks.. you know you cant have a good server people want to play unless you have SOME quests... please help!
 
Open your map editor, set the actionid of chest to 2000. Set the uniqueid of chest, to any FREE uniqueid(it will be used for look, was quest done or not). Open chest in mapeditor, and put the reward into chest(IN MAPEDITOR). Done.

Hint 1. Update your server, or atleast the system.lua to TFS 0.3 beta 3.
Hint 2. Do not test all these with your GM char, it will work only with normal players.
 
Or just back to the old system.

Code:
	<!-- Old quest system-->
	<action itemid="1740" script="quests/old_system.lua"/>
	<action fromid="1747" toid="1749" script="quests/old_system.lua"/>

Code:
local annihilatorReward = {1990, 2400, 2431, 2494}
function onUse (cid, item, fromPosition, itemEx, toPosition)
	if item.uid > 1000 and item.uid < 10000 then
		local itemWeight = getItemWeightById(item.uid, 1, FALSE)
		local playerCap = getPlayerFreeCap(cid)
		if isInArray(annihilatorReward, item.uid) == TRUE then
			if getPlayerStorageValue(cid, 30015) == -1 then
				if playerCap >= itemWeight then
					if item.uid == 1990 then
						local container = doPlayerAddItem(cid, 1990, 1)
						doAddContainerItem(container, 2326, 1)
					else
						doPlayerAddItem(cid, item.uid, 1)
					end
					doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemNameById(item.uid) .. '.')
					setPlayerStorageValue(cid, 30015, 1)
				else
					doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemNameById(item.uid) .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
				end
			else
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "It is empty.")
			end
		elseif getPlayerStorageValue(cid, item.uid) == -1 then
			if playerCap >= itemWeight then
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemNameById(item.uid) .. '.')
				doPlayerAddItem(cid, item.uid, 1)
				setPlayerStorageValue(cid, item.uid, 1)
			else
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemNameById(item.uid) .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
			end
		else
			doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "It is empty.")
		end
	else
		return FALSE
	end
	return TRUE
end

And set chest's UNIQUE ID as ITEM ID of the reward.
 
Back
Top