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

few scripts ? can u help ?

breadmaker

New Member
Joined
Jul 16, 2010
Messages
160
Reaction score
3
Hello,
I need few scripts for TFS 0.3.5pl1:

1) Gate of Exprience Door [teleport] (Quest Door)

NORMAL: When you trying to pass the door, door open and you move in door
uo0004ew2.jpg

I WAN`T: When you trying to pass the door, door dont open just teleport you to otherside, like tibia 7.6 or 7.92 versions.

2) 7 items, 100 level, lever = use = teleport ?

If you got 7 items
ID = {2650, 2651, 2652, 2653, 2654, 2655, 2656)
You must place this item`s in position's:
2650 = x: 3450 y: 4059 z: 7
2651 = x: 3451 y: 4060 z: 7
2652 = x: 3452 y: 4061 z: 7
2653 = x: 3453 y: 4062 z: 7
2654 = x: 3454 y: 4063 z: 7
2655 = x: 3455 y: 4064 z: 7
2656 = x: 3456 y: 4065 z: 7
If you got 100 level, and placed items on positions, you use lever and you has been teleported to:
x: 5670 y: 3450 z: 8

3) Fishing without fishing skill
It`s possible to do it ?
I need fishing rod script without fishing skill.
Rod will fish normally fishes but without skill !

Anyone can help me ?
:huh:
 
Last edited:
test it now, fishing.lua
PHP:
local config = {
    waterIds = {493, 4608, 4609, 4610, 4611, 4612, 4613, 4614, 4615, 4616, 4617, 4618, 4619, 4620, 4621, 4622, 4623, 4624, 4625},
    allowFromPz = false,
    useWorms = true,
    rate = 10 -- To make it harder or easier to fish, change this value.
-- Harder = lower
-- Easier = higher
}

function onUse(cid, item, fromPosition, itemEx, toPosition)
    if(not isInArray(config.waterIds, itemEx.itemid)) then
        return false
    end

    if((config.allowFromPz or not getTileInfo(getCreaturePosition(cid)).protection) and itemEx.itemid ~= 493 and
        math.random(1, (100 + ((config.rate / 10))) and
        (not config.useWorms or (getPlayerItemCount(cid, ITEM_WORM) > 0 and doPlayerRemoveItem(cid, ITEM_WORM, 1))))) then
        doPlayerAddItem(cid, ITEM_FISH, 1)
    end

and, what uniqueID you put in the door? if is 1957, you need to change 1'000' <~ this is the level.

example: 1095 "95" is the level request.

Rep+ if i helped you. :thumbup:
 
doors.lua Bugs:
Code:
[17/07/2010 19:39:23] [Warning - Actions::registerEvent] Duplicate registered item with id: 6542, in fromid: 6541 and toid: 6545
[17/07/2010 19:39:23] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:23] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:23] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:23] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:23] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:23] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:23] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:23] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:23] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:24] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:24] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:25] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:25] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:25] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:25] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:25] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:25] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:25] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:25] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:25] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:25] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'
[17/07/2010 19:39:25] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/other/doors.lua)
[17/07/2010 19:39:25] data/actions/scripts/other/doors.lua:3: unexpected symbol near '{'

fishing.lua Bugs:
Code:
[17/07/2010 19:39:22] [Warning - Event::loadScript] Cannot load script (data/actions/scripts/tools/fishing.lua)
[17/07/2010 19:39:22] data/actions/scripts/tools/fishing.lua:17: 'end' expected (to close 'function' at line 8) near '<eof>'


HelpZ
 
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	local level = item.actionid - 1000
	if item.actionid == 0 or getPlayerLevel(cid) < level then
		return doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'Only the worthy may pass.')
	end

	local pos, door = getThingPos(cid), toPosition
	if isInArray({door.x-1, door.x+1}, pos.x) and pos.y == door.y then
		door.x = door.x + (pos.x < door.x and 1 or -1)
	elseif isInArray({door.y-1, door.y+1}, pos.y) and pos.x == door.x then
		door.y = door.y + (pos.y < door.y and 1 or -1)
	else
		return doPlayerSendCancel(cid, 'You must stand in front of the door!')
	end
	doTeleportThing(cid, door)
	doSendMagicEffect(door, CONST_ME_HEARTS)
	return true
end
 
Code:
local level = 100
local destination = {x=5670, y=3450, z=8}

local t = {
	[2650] = {x=3450, y=4059, z=7},
	[2651] = {x=3451, y=4060, z=7},
	[2652] = {x=3452, y=4061, z=7},
	[2653] = {x=3453, y=4062, z=7},
	[2654] = {x=3454, y=4063, z=7},
	[2655] = {x=3455, y=4064, z=7},
	[2656] = {x=3456, y=4065, z=7}
}

function onUse(cid, item, fromPosition, itemEx, toPosition)
	if getPlayerLevel(cid) < level then
		return doCreatureSay(cid, 'You don\'t have the required level.', TALKTYPE_ORANGE_1, false, cid)
	end

	local items = {}
	for id, pos in pairs(t) do
		local v = getTileItemById(pos, id).uid
		if v < 0 then
			return doCreatureSay(cid, 'One or more items are missing.', TALKTYPE_ORANGE_1, false, cid)
		end
		table.insert(items, v)
	end
	
	for i = 1, #items do
		doRemoveItem(items[i])
	end

	doTeleportThing(cid, destination)
	doSendMagicEffect(destination, CONST_ME_TELEPORT)

	return true
end
 
Back
Top