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

only certain vocation....

Snow

New Member
Joined
Jan 16, 2008
Messages
381
Reaction score
0
2 scripts....

first a change on script...
I want this script so that only paladins(or royal pallys) can flip it

LUA:
function onUse(cid, item, frompos, item2, topos)
local gatepos = {x=442, y=1386, z=10, stackpos=1}
local getgate = getThingfromPos(gatepos)

if item.uid == 10206 and item.itemid == 1945 and getgate.itemid == 6289 then
doRemoveItem(getgate.uid,1)
doTransformItem(item.uid,item.itemid+1)
elseif item.uid == 10206 and item.itemid == 1946 and getgate.itemid == 0 then
doCreateItem(6289,1,gatepos)
doTransformItem(item.uid,item.itemid-1)
else
doPlayerSendCancel(cid,"Sorry not possible.")
end
  return 1
  end

seocnd....
a movement...
player will step in action id x and will receive 300 damage if he's paladin, if not he'll receive 1000.

thx in adavance and I'll rep+++
 
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
	if isPaladin(cid) then
		if item.itemid == 1945 then
			doRemoveItem(getTileItemById({x=442, y=1386, z=10}, 6289).uid)
		elseif item.itemid == 1946 then
			doCreateItem(6289, 1, {x=442, y=1386, z=10})
		end
		doTransformItem(item.uid, item.itemid == 1945 and 1946 or 1945)
	else
		doCreatureSay(cid, "Only paladins may use this lever", TALKTYPE_ORANGE_1, false, cid, getThingPos(cid))
	end
	return true
end
Code:
function onStepIn(cid, item, position, fromPosition)
	if(isPlayer(cid)) then
		local v = isPaladin(cid) and -300 or -1000
		doTargetCombatHealth(0, cid, COMBAT_FIREDAMAGE, v, v, CONST_ME_NONE)
	end
	return true
end
 
Back
Top