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

Lua How to say something when equipped?

DedicatedOT

New Member
Joined
Jun 13, 2009
Messages
977
Reaction score
4
Location
USA
Hi,


Anyone know how I can say some orange text when equipped say, demon armor???

Something like, Demon Armor Rox!?

Thanks!
 
ye..

Code:
<movevent type="DeEquip" itemid="demonarmorid" slot="armor" event="function" value="namecode.lua"/>
	<movevent type="Equip" itemid="demonarmorid" slot="armor" level="xx" event="function" value="namecode.lua">
		<vocation name="Sorcerer" showInDescription="0"/>
		<vocation name="Druid" showInDescription="0"/>
		<vocation name="Paladin" showInDescription="0"/>
		<vocation name="Knight" showInDescription="0"/>
		<vocation name="Master Sorcerer" showInDescription="0"/>
		<vocation name="Elder Druid" showInDescription="0"/>
		<vocation name="Royal Paladin" showInDescription="0"/>
		<vocation name="Elite Knight" showInDescription="0"/>
	</movevent>
 
Hey why is it now saying "this item doesn't dress there"??
Code:
	<movevent event="Equip" itemid="2497" slot="head" function="Equip" script="vipitems.lua"/>
	<movevent event="Equip" itemid="2503" slot="body" function="Equip" script="vipitems.lua"/>
	<movevent event="Equip" itemid="2504" slot="legs" function="Equip" script="vipitems.lua"/>
	<movevent event="Equip" itemid="2641" slot="feet" function="Equip" script="vipitems.lua"/>
Code:
function onEquip(cid, item, slot)
if item == 2502 then
doCreatureSay(cid, "a", TALKTYPE_ORANGE_1)
elseif item == 2503 then
doCreatureSay(cid, "n", TALKTYPE_ORANGE_1)
elseif item == 2504 then
doCreatureSay(cid, "b", TALKTYPE_ORANGE_1)
elseif item == 2641 then
doCreatureSay(cid, "c", TALKTYPE_ORANGE_1)
end
end
 
Back
Top