• Congratulations to the OTLand February Mapping Competition Winner! The grand prize of Otland Premium goes to eiserne festung.
  • 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!

Special sqm

matik

New Member
Joined
Oct 20, 2012
Messages
9
Reaction score
1
Hello
Is possible to have special sqm i mean i can only enter on this sqm when i have full citizen addon or any other .
Pls help me :)
 

averatec

Advanced OT User
Joined
Jun 1, 2007
Messages
2,244
Solutions
4
Reaction score
159
Location
Poland
Lua:
local outfitId = 123 -- fill this with desired outfit id
local addon = 0 -- i don't remember how it works, but probably 0,1,2,3 are possible values
function onStepIn(cid, item, position, fromPosition)
    if canPlayerWearOutfitId(cid, outfitId, addon) then
        return true
    end
    return false
end
 
OP
M

matik

New Member
Joined
Oct 20, 2012
Messages
9
Reaction score
1
i have in movements.xml
<movevent type="StepIn" itemid="7997" event="script" value="sqm.lua"/>

in script sqm.lua
local outfitId = 136 -- fill this with desired outfit id
local addon = 3 -- i don't remember how it works, but probably 0,1,2,3 are possible values
function onStepIn(cid, item, position, fromPosition)
if item.actionid == 7997 then
if canPlayerWearOutfitId(cid, outfitId, addon) then
return true
end
return false
end

I put in rme actionid 7997 on sqm
dont work ;/
 

WoDBO2 PL

New Member
Joined
Jul 5, 2020
Messages
7
Reaction score
0
local outfitId = 1
local addon = 3
function onStepIn(cid, item, position, fromPosition)
if canPlayerWearOutfitId(cid, outfitId, addon) then
return true
end
doTeleportThing(cid, fromPosition)
doPlayerSendCancel(cid, 'You need full citizen addon')
return false
end

Works perfect :p tak to ja kamyczekOTS XD
 
Top