WarOfTheTitans
Active Member
- Joined
- Feb 3, 2012
- Messages
- 430
- Reaction score
- 37
Is there any way to get the player looktype or addon outside the function? I really need it because it is checking the players outfit and gives the player the same addon/looktype but with another color and then gives condition "CONDITION_OUTFIT".
I don't want to use "doCreatureChangeOutfit(cid)" because the player got locked outfit. So thats why I am using condition.
for example:
The problem is that the condition:
needs to be outside of the function and:
have to be inside the function ...
Is there any other way to check the players outfit?
Thanks rep ++
I don't want to use "doCreatureChangeOutfit(cid)" because the player got locked outfit. So thats why I am using condition.
for example:
Lua:
local x = getCreatureOutfit(cid)
local outfit = {lookType = x.lookType, lookHead = 114, lookBody = 114, lookLegs = 114, lookFeet = 114, lookTypeEx = x.lookTypeEx, lookAddons = x.lookAddons}
local time = 5 -- min
local outfit = createConditionObject(CONDITION_OUTFIT)
setConditionParam(outfit, CONDITION_PARAM_TICKS, time*1000*60)
addOutfitCondition(outfit, outfit)
local function -- here begins the function that is containing "(cid)"
doAddCondition(cid, outfit)
return true end
The problem is that the condition:
Lua:
local outfit = createConditionObject(CONDITION_OUTFIT)
setConditionParam(outfit, CONDITION_PARAM_TICKS, time*1000*60)
addOutfitCondition(outfit, outfit)
Lua:
local x = getCreatureOutfit(cid)
have to be inside the function ...
Is there any other way to check the players outfit?
Thanks rep ++