• 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 Two Basic Questions!

korff

New Member
Joined
Sep 11, 2009
Messages
78
Reaction score
3
1) My Outifit Tile

The tile must change only the Outifit colors of the player! to red "86" and say: "Are you ready for war?" (Now, It's working but change the looktype and say only: "are you r", (why it is happening?someone knows?)

look the script:
local outfit = {lookType = 252, lookHead = 79, lookBody = 91, lookLegs = 91, lookFeet = 91, lookTypeEx = 0, lookAddons = 3}
local outfiti = {lookType = 252, lookHead = 86, lookBody = 86, lookLegs = 86, lookFeet = 86, lookTypeEx = 0, lookAddons = 3}


function onStepIn(cid, item, pos)
if isPlayer(cid) == TRUE and getPlayerSex(cid) == 0 then
doCreatureChangeOutfit(cid, outfit)
doSendMagicEffect(getThingPos(cid), 43)
doSendAnimatedText(getPlayerPosition(cid),"Are you ready for war?!", math.random(01,255))
else
if isPlayer(cid) == TRUE and getPlayerSex(cid) > 0 then
doCreatureChangeOutfit(cid, outfiti)
doSendMagicEffect(getThingPos(cid), 43)
doSendAnimatedText(getPlayerPosition(cid),"Are you ready for war?!", math.random(01,255))
end
end

return TRUE
end

2) Players can't heal with potions and UH , while they're running, how I can fix that?

Thanks, A LOT!!
 
Ok, But I want the script change only the player Outift colors! not the looktype and addons, how I Do that? can u pass me the script?
 
Ok, But I want the script change only the player Outift colors! not the looktype and addons, how I Do that? can u pass me the script?
Code:
function onStepIn(cid, item, position, fromPosition)
	if isPlayer(cid) then
		doCreatureChangeOutfit(cid, getPlayerSex(cid) == 0 and {lookType = getCreatureOutfit(cid).lookType, lookHead = 79, lookBody = 91, lookLegs = 91, lookFeet = 91, lookTypeEx = 0, lookAddons = getCreatureOutfit(cid).lookAddons} or {lookType = getCreatureOutfit(cid).lookType, lookHead = 86, lookBody = 86, lookLegs = 86, lookFeet = 86, lookTypeEx = 0, lookAddons = getCreatureOutfit(cid).lookAddons})
		doSendMagicEffect(position, CONST_ME_ICEATTACK)
		doCreatureSay(cid, "Are you ready for war?!", TALKTYPE_ORANGE_1)
	end
end
 
Last edited:
Back
Top