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

MOD Doesn't work

Northnorial

Member
Joined
May 30, 2009
Messages
742
Reaction score
5
Location
Germany
This script was made by Cykotitan.
I edited now, but it doesn't work anymore ...
Could anyone help me? oO

PHP:
<?xml version="1.0" encoding="UTF-8"?>
<mod name="TempleTP" enabled="yes">
	<config name="config"><![CDATA[
	validTowns = {1,2}, 
	time = 3
	]]></config>
	<talkaction words="!t" event="script"><![CDATA[
		domodlib('config')
		local param = tonumber(param)		
		function doTP(cid)
			doTeleportThing(cid, getTownTemplePosition(param))
			doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have been teleported to " .. getTownName(param) .. ".")
			doSendMagicEffect(getTownTemplePosition(param), CONST_ME_TELEPORT)
		end
		if getTileInfo(getThingPos(cid)).protection and param and isInArray(validTowns, param) then
					doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You will be teleported to " .. getTownName(param) .. " in " .. time .. " seconds.")
					doSendMagicEffect(getCreaturePosition(cid), CONST_ME_WATERSPLASH)	
					addEvent(doTP(cid), time*1000, cid)					
		end
		return TRUE
	]]></talkaction>
</mod>
 
Code:
<?xml version="1.0" encoding="UTF-8"?>
<mod name="TempleTP" enabled="yes">
	<config name="config"><![CDATA[
		validTowns = {1,2}
		time = 3
	]]></config>
	<talkaction words="!t" event="buffer"><![CDATA[
		domodlib('config')
		local param = tonumber(param)
		function doTP(cid)
			doTeleportThing(cid, getTownTemplePosition(param))
			doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have been teleported to " .. getTownName(param) .. ".")
			doSendMagicEffect(getTownTemplePosition(param), CONST_ME_TELEPORT)
		end
		if getTileInfo(getThingPos(cid)).protection and param and isInArray(validTowns, param) then
			doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You will be teleported to " .. getTownName(param) .. " in " .. time .. " seconds.")
			doSendMagicEffect(getThingPos(cid), CONST_ME_WATERSPLASH)
			addEvent(doTP, time*1000, cid)
		end
		return true
	]]></talkaction>
</mod>
 
Back
Top