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

OTClient Shared Experienc 8.0

Makin

New Member
Joined
Sep 17, 2018
Messages
37
Solutions
1
Reaction score
2
Hi, how can i enable exp shared in addition to the command. Because when I click enable shared experience I do not want to turn on. tfs 1.2

works only with this command
Lua:
function onSay(cid, words, param)
    local player = Player(cid)

    if player:getCondition(CONDITION_INFIGHT) then
        player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, "You need to be out of fight.")
        return false
    end

    local party = player:getParty()
    if not party then
        player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, "You are not in a party.")
        return false
    end

    if not player == party:getLeader() then
        player:sendTextMessage(MESSAGE_STATUS_CONSOLE_BLUE, "Only party leader can enable/disable shared experience.")
        return false
    end

    local boolean = not(party:isSharedExperienceActive())
    if party:setSharedExperience(boolean) then
        for _, pid in ipairs(party:getMembers()) do
            pid:sendTextMessage(MESSAGE_INFO_DESCR, "Shared Experience has been "..(boolean and "activated" or "deactivated")..".")
        end
    end
    return false
end
 
Back
Top